On Wed, Oct 30, 2013 at 11:17 AM, João Amaral <[email protected]> wrote:
> Hello. > > Is it possible to include time.h in nesC code? Not really. Too painful. Sure it is possible, probably with a lot of work….. But first let me ask why? What problem are you trying to solve? I ran "grep -R 'time.h'" on > $TOSROOT and I saw some occurrences in .c files (mainly CoAP related), but > Those are all files that get compiled for use on Linux boxes. > only one in a nesC file (TcpP.nc). Evern that one is still for a Linux box. Its inside an #ifdef PC. Not sure what he is doing there though. > I tried using "include <time.h>" and > "include <sys/time.h>" in my application, but both result in compilation > error: time.h: No such file or directory. > > I need to compute the difference between two instants of time. > First the time values that you have on a mote don't look like what is inside time.h anyway. I assume you have two TMillis that you are subtracting. Where are you getting your times anyway and what do they look like? eric > > > > -- > View this message in context: > http://tinyos-help.10906.n7.nabble.com/Use-time-h-in-nesC-applications-tp23747.html > Sent from the TinyOS - Help mailing list archive at Nabble.com. > _______________________________________________ > Tinyos-help mailing list > [email protected] > https://www.millennium.berkeley.edu/cgi-bin/mailman/listinfo/tinyos-help > -- Eric B. Decker Senior (over 50 :-) Researcher
_______________________________________________ Tinyos-help mailing list [email protected] https://www.millennium.berkeley.edu/cgi-bin/mailman/listinfo/tinyos-help
