[Tinyos-devel] Re: [Tinyos Core WG] time sync interfaces

Andreas Koepke koepke at tkn.tu-berlin.de
Tue Dec 18 07:45:38 PST 2007


I guess I lost the track of the discussion, here are my 2c from what is
implemented for the eyesIFX platform:

All I use is an accessor interface, like:
setCreationTime, getCreationTime.
(currently using the meta field directly).
Using receivedSFD/transmittedSFD the radio stack computes the intra-stack
delay and sends just that. I currently use 32.768kHz with 32bit width.

Accuracy and resolution depend on protocol requirements, which in turn may
depend on radio hardware.

A high accuracy is only possible with quartz crystals -- and platforms
tend to have a different number of those with different frequencies. So I
guess that a completely platform independent interface will be hard. Even
if we could divide one to the common base, a high frequency quartz has a
lower accuracy than a low frequency one (10-20ppm for 32kHz, 100ppm for
1MHz, 5% for VCOs) -- which requires different guard times in the
protocols.

Best, Andreas

> Regarding timestamp precision: I'm afraid this is platform specific.
> Making things worse, microsecond precision means 921600Hz on a micaz that
> uses the external clock source, while it means 1000000Hz when the micaz is
> configured to use the internal oscillator. This is 8% difference in
> frequencies, which is pretty hard to tolerate in a layer-3 protocol.
>
> Specifying a "network time precision" a la "network byte order", on the
> other hand, would put too much burden on the radio stack. I would classify
> a 16-bit integer division as "extensive" computation.
>
> Similarly, including metainformation in the packet header would mean
> excessive overhead (not mentioning the effort to push this change through
> the t2 code).
>
> Of course, higher-level protocols must have some means to communicate
> timestamping-related metainformation. This could be solved with a
> TimeStampingInfo interface, provided by the radio stack, that contains a
> getter such as command uint32_t getTicksPerSecond() which returns a
> constant such as 32768 or 921600.
>
> Similarly, the TimeStampingInfo interface could include commands to query
> for the position and size of the timestamp, as well.
>
> This way the implementation is not constrained to any specific timestamp
> precision, size or position within the packet; and the responsibility of
> ensuring cross-platform interoperability is delegated to higher-level
> protocols.
>
>
> Janos
>
>
> -----Original Message-----
> From: tinyos-devel-bounces at millennium.berkeley.edu
> [mailto:tinyos-devel-bounces at millennium.berkeley.edu] On Behalf Of Philip
> Levis
> Sent: Wednesday, December 12, 2007 2:14 PM
> To: David Gay
> Cc: TinyOS Development; Miklos Maroti
> Subject: Re: [Tinyos-devel] Re: [Tinyos Core WG] time sync interfaces
>
>
> On Dec 12, 2007, at 11:59 AM, David Gay wrote:
>
>> On Dec 12, 2007 11:09 AM, Philip Levis <pal at cs.stanford.edu> wrote:
>>> PacketTimeSynch is a bit tougher, as it actually embeds a sender
>>> timestamp in a packet. This has two basic issues:
>>>
>>>    2) How do nodes running different applications agree on the
>>> timestamp precision?
>>
>> Why is this an issue? I might as well ask how different applications
>> agree on the meaning/layout of packets (I am starting from an
>> assumption that the presence of a timestamp is packet-specific rather
>> than a general feature).
>>
>
> If a layer 3 protocol specification says "this packet has 32kHz, 16-
> bit timestamps in it," or some variant thereof, I agree. But if this
> is platform-specific rather than protocol-specific, there's an issue.
> Specifying it in a protocol might mean that some platforms cannot
> support certain protocols.
>
> Phil
> _______________________________________________
> Tinyos-devel mailing list
> Tinyos-devel at millennium.berkeley.edu
> https://www.millennium.berkeley.edu/cgi-bin/mailman/listinfo/tinyos-devel
>
> No virus found in this incoming message.
> Checked by AVG Free Edition.
> Version: 7.5.503 / Virus Database: 269.17.1/1181 - Release Date:
> 12/11/2007 5:05 PM
>
> _______________________________________________
> Tinyos-devel mailing list
> Tinyos-devel at millennium.berkeley.edu
> https://www.millennium.berkeley.edu/cgi-bin/mailman/listinfo/tinyos-devel
>




More information about the Tinyos-devel mailing list