1 / 32

The Flooding Time Synchronization Protocol Miklós Maróti Branislav Kusy Gyula Simon

The Flooding Time Synchronization Protocol Miklós Maróti Branislav Kusy Gyula Simon Ákos Lédeczi SenSys’04, November 3–5, 2004, Baltimore, Maryland, USA. Outline. Introduction Uncertainties In Radio Message Delivery Clock draft Time synchronization approach Conclusion.

faunus
Download Presentation

The Flooding Time Synchronization Protocol Miklós Maróti Branislav Kusy Gyula Simon

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


  1. The Flooding Time Synchronization Protocol Miklós Maróti Branislav Kusy Gyula Simon Ákos Lédeczi SenSys’04, November 3–5, 2004, Baltimore, Maryland, USA.

  2. Outline • Introduction • Uncertainties In Radio Message Delivery • Clock draft • Time synchronization approach • Conclusion

  3. Introduction • describe the Flooding Time Synchronization Protocol (FTSP) for Wireless Sensor Network • designing the FTSP, our goals were to achieve network-wide time synchronization with error in the micro-second rang • The algorithm compensates for utilizing the concepts of MAC layer time-stamping and skew compensation with linear regression • The algorithm was implemented on Mica/Mica2 platforms running the TinyOS operating system

  4. Uncertainties In Radio Message Delivery

  5. Uncertainties In Radio Message Delivery • Send Time—Depending on the system call overhead of the operating system and on the current processor load • Access Time—message stay s the radio device buffer and waiting for access to the transmit channel • Interrupt Handling Time—the delay between the radio chip raising and the microcontroller responding to an interrupt. This time is mostly less than a few microsecond (waiting for the microcontroller to finish the currently executed instruction) • Transmission Time—depending on the length of the message and the speed of the radio • Propagation Time—is highly deterministic ,This time is less than one microsecond (for ranges under 300 meters) • Encoding Time—for the radio chip to encode and transform a part of the message to electromagnetic waves • Byte Alignment Time—because of the different byte alignment of the sender and receiver and can computed from bit offset and speed of the radio

  6. Uncertainties In Radio Message Delivery

  7. Sender uncertainty Propagation certainty Receiver uncertainty Variability in Packet Delay receiver sender software software MAC TX propagation RX ALL DELAYS ARE VARIABLE !

  8. Error of time synchronization • Clock Skew - cause by clock drift - variations in crystal oscillation frequency - due to environmental variation (temperature , humidity) or manufacturing - frequency difference - clock offset

  9. Variability in clock offset sender-receiver synchronization Host A T1 T4 Time T2 T3 Host B T2=T1+offset+ propagation delay T4=T3- offset+ propagation delay propagation delay = (T2-T1) + (T4-T3) /2 drift clock = (T2-T1) - (T4-T3)/2

  10. Node B clock Node A clock Local node time Ideal clock t1 Real Time t4 Relative drift Variability in clock offset

  11. Time Synchronization Techniques • Reference Broadcast Synchronization (RBS) Sender Receiver Receiver NIC NIC NIC I saw it at t=4 I saw it at t=5 Propagation Time Physical Media

  12. Time Synchronization Techniques • Reference Broadcast Synchronization (RBS) - A transmitter broadcast a reference packet to two receivers - Each receiver records the time that the reference was received , according to its local clock. - receivers exchange their observations each other - suitable only for low precision demands

  13. Time Synchronization Techniques • Reference Broadcast Synchronization (RBS) - advantage . Completely eliminating transmitter side uncertainties - disadvantage . Number of message exchanges is high . For n node . 1node broadcast , n-1 message exchange for sync result network traffic overhead and high energy consumption

  14. Time Synchronization Techniques • Timing-sync Protocol for Sensor Network (TPSN) - the TPSN algorithm first create a spanning tree of the network - level discovery phase . Create a hierarchy topology . Each node is assigned a level . A node is selected as the root node (level 0) . Root broadcast level_discovery package which contain identifier and level of the sender . Neighbor receive the package then assigned itself a level plus1 and subsequent message received are discard

  15. Time Synchronization Techniques • Timing-sync Protocol for Sensor Network (TPSN) . Node then rebroadcast level_discovery message . Until all nodes are assigned a level

  16. Time Synchronization Techniques Level Discovery Phase

  17. time synchronization techniques • Timing-sync Protocol for Sensor Network (TPSN) - synchronization phase . Using a sender-receiver synchronization . Use two-way message exchange . A node initiates synchronization by sending a pulse message that including the node’s level and local time . B node that receives and reply an acknowledgement that including the original time stamp . Calculate the drift clock and propagation delay and synchronizes itself with the receiving node

  18. Time Synchronization Techniques Synchronization Phase

  19. Recv at T2 Send at T3 Send at T1 T2 = T1 + DELAY + OFFSET A B Recv at T4 T4 = T3 + DELAY- OFFSET OFFSET = {(T2-T1)-(T4-T3)}/2 DELAY = {(T2-T1)+(T4-T3)}/2 Time Synchronization Techniques

  20. Time Synchronization Techniques • Timing-sync Protocol for Sensor Network (TPSN) - advantage . better Performance than RBS . More minimum error than RBS - disadvantage . Tow-way communication that higher communication load . Limits its accuracy

  21. Flooding Time Synchronization Protocol Broadcast a single radio message time stamp • When a node collects enough reference point , it estimates the offset and skew global time-stamp [global , local ] time-stamp Collect reference point root A local time-stamp Synchronization message format

  22. Flooding Time Synchronization Protocol • Multi-hop time synchronization - FTSP utilize reference points to perform synchronization - a reference points are generated by sending and receiving periodic broadcast message - a reference points contains a pair of global and local time stamp - When a node collects enough reference point , it estimates the offset and skew - the newly synchronized node can then broadcast synchronization messages to another node - offset and skew calculated by linear regression

  23. Flooding Time Synchronization Protocol • synchronization message format - consists three fields - timestamp , contains the global time estimate of the transmitter - rootID , ID of the root - SeqNum, sequence number set and incremented by the root when a new synchronization round , used to handle redundant synchronization message

  24. Flooding Time Synchronization Protocol • Managing redundant information - in a dense network a receiver may receive several message from different node in a short time interval - due to limited resources , subset of the message must be selected to create reference point - in the Mica2 implementation an eight-element regression table stores the reference point used to calculate the regression line - to aid message filtering for more beneficial to store reference point . Each node maintains a highestSeqNum variable and MyRootID

  25. Flooding Time Synchronization Protocol • The root election problem - election process is needed to provide a root after startup - to perform global synchronization that only one root is needed - nodes may fail or the network disconnected or no node can play the role of root - FTSP utilizes a simple election process base on unique node ID - when a node can’t receive new time synchronization message for ROOT_TIMEOUT number of message broadcast periods then declares itself to be the root (myrooID=myID) - ROOT_TIMEOUT = NUMENTRIES_LIMIT = times *Periodically re-sync

  26. Flooding Time Synchronization Protocol Heartbeats = numbers of message broadcast NUMENTRIES_LIMIT = times * Periodically re-sync • Managing redundant information (cont.)

  27. Experimental • 60 Mica2 motes deployed in a 5x12 grid • Each mote can communicate with neighbors only • ID1 is smallest id • When ID1 is fail then ID2 will replace ID1 • The period of time re-synchronization was 30 sec for 60 nodes ROOT_TIMEOUT=6

  28. Experimental

  29. Experimental • A: at 0:04 all motes were turned on • B: at 1:00 the root with ID1 was switched off, ID2 becomes the new root • C: between 2:00 and 2:15 randomly selected nodes were reset one by one with 30 second period • D: at 2:30 the motes with odd node IDs were switched off (half of the nodes are removed) • E: at 3:01 the motes with odd node IDs were switched back on (100% new nodes were introduced) • F: at 4:02 the experiment was ended.

  30. Experimental • The nodes were switched on at the time (0:04), but during the next 3 minutes (0:07) no node was synchronized because none of them declared itself to be the root. • Then many nodes timed out and became the roots of the network, which was the reason why the average and maximum synchronization errors soared for 10 minutes untill the election process has completed (0:17) and only a single root remained (ID1). • Complete synchronization has been achieved in 14 minutes (at 0:18)

  31. Experimental • When the root ID1 was switched off that global time had not been updated • until each node timed out and declared itself to be the root. • The election process again resulted in a single root (ID2) • the error stayed low during this time because nodes did not discard their old offset and skew estimates and the new root was broadcasting its estimation of the old global time • Election process finished at 1:06 (in 6 minutes)

  32. Conclusion • TPSN eliminates the send, access, interrupt handling, encoding, decoding and receive time errors • The authors of TPSN algorithm implemented both TPSN and RBS on the Mica platform using a 4 MHz clock for time-stamping, and compared the precision of the two algorithms. The resulting average errors for a single hop case for two nodes are 16.9µs and 29.1µs for the TPSN and RBS algorithms, • Multiple time-stamps with linear regression are used to estimate clock skew and offset. The average error of the algorithm for a single hop case using two nodes was 1.48µs • FTSP also utilizes less network resources than either RBS or TPSN

More Related