Hi,all,
I am using Crossbow's iris mote. I want to send current system time in the
mote.

I tried to use the Time interface in SimpleTimeM. However, I always get zero
value for the system time.

This is the interface:
interface Time {
 /**
  * get current time. Return it in tos_time_t structure
  **/
 async command tos_time_t get();
 /** get the high 32 bits of current time */
 async command uint32_t getHigh32();
 /** get the lower 32 bits of current time */
 async command uint32_t getLow32();
 /** get clock phase offset since last clock tick
   * in unit of micro-seconds.
  **/
 async command uint16_t getUs();
}

In my function, I write:

atomic a=call Time.getHigh32();
atomic b=call Time.getLow32();

However, I always get 0.  I am pretty sure that the problem should be in
'call Time.getHigh32()'.

So how can I fix this problem. Why I always get the 0 of the system time?
Thanks very much!


-----Chenda Liao
_______________________________________________
Tinyos-help mailing list
[email protected]
https://www.millennium.berkeley.edu/cgi-bin/mailman/listinfo/tinyos-help

Reply via email to