Hello,
I am facing an odd issue with DateTime class in NMF, while I was working on my code to test one of the sensors, I tried to display the sensor readings alongside the time of reading as a time stamp, anyway I tried to run the code twice and every time I got a fixed date and time!!! (06/01/2011 00:00:00)!!!
I thought my system has a problem with CPU cycle, I have created a non NMF project (console application) and the time was correct and accurate!! So nothing wrong with my OS!
this is an example of my original code just to test to display the current time&date:
using System;
using System.Collections;
using System.Threading;
using Microsoft.SPOT;
using Microsoft.SPOT.Presentation;
using Microsoft.SPOT.Presentation.Controls;
using Microsoft.SPOT.Presentation.Media;
using Microsoft.SPOT.Touch;
using Gadgeteer.Networking;
using GT = Gadgeteer;
using GTM = Gadgeteer.Modules;
namespace GadgeteerApp1
{
public partial class Program
{
void ProgramStarted()
{
Debug.Print("Program Started "+ DateTime.Today.ToString());
}
}
}
It sounds a simple issue but I couldn’t tell where is exactly the problem in order to be solved!!
BTW I am using FEZ Spider mainboard and Visual C# 2010 Express.
Thank you in advance,