1 / 34

Time Synchronization

Time Synchronization. In Wireless Sensor Networks Anisha Menon. The need for physical time synchronization. Object tracking Consistent state updates Distributed beam forming Duplicate detection Temporal order delivery Energy conservation. Characterizing Time Synchronization. Precision

ianna
Download Presentation

Time Synchronization

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. Time Synchronization In Wireless Sensor Networks Anisha Menon MONET 05

  2. The need for physical time synchronization • Object tracking • Consistent state updates • Distributed beam forming • Duplicate detection • Temporal order delivery • Energy conservation

  3. Characterizing Time Synchronization • Precision • Lifetime • Scope and Availability • Efficiency • Cost and Size

  4. Constraints of existing methods • Network Time Protocol (NTP)[8] • connectionless messaging protocol • exchange of clock information between clients and one/few servers • algorithm for updating local server • Assumptions made for internet are not applicable to sensor networks • Energy inefficiencies • Hardware heterogeneity • Lack of infrastructure • Mobility of nodes • Disconnected nodes

  5. Design Principles • Tradeoff between • Energy • Precision • Scope • Lifetime • Cost • Tiered architecture • Tunable – Adaptive Fidelity • No Global Timescale

  6. Sources of Time Sync Error[9] • Send Time □ time spent to construct message • Access Time □ delay incurred waiting for access to the transmission channel • Propagation Time □ time required for transit of message from sender to receiver • Receive Time □ time required for receivers network interface to receive the message and notify host of its arrival

  7. REFERENCE BROADCAST SYNCHRONIZATION[3] • Assumptions ▫ a message that is broadcast at the physical layer will arrive at a set of receivers with very little variability in its delay ▫ propagation time for message is zero ▫ the receiver jitter is less than a single bit time Single Hop Time Synchronization ● Estimation of phase offset 1. A transmitter broadcasts a reference packet to two receivers (i and j). 2. Each receiver records the time that the reference was received according to its local clock. 3. The receivers exchange their observations.

  8. A Reference packet ni nj Exchange Information

  9. Estimation of clock skew Perform a least-squares linear regression on the phase offsets. This offers a fast, closed-form method for finding the best fit line through the phase error observations over time. The frequency and phase of the local node's clock with respect to the remote node can be recovered from the slope and intercept of the line. Each point is the difference between the times that the two nodes reported receiving a reference broadcast plotted on a timescale defined by one node's clock. Tr,b = r’s clock when it received broadcast b for each pulse k And plot x = Tr1,b y = Tr2,b – Tr1,b The line represents the best linear fit to the data.

  10. Multiple Hop Time Synchronization A B 3 6 E1 E2 1 4 7 E7 = B - 4 2 5 E1 = A + 2 A = B + 10 E1 = E7 + 16 Timebase conversions – E1(N1) → E1(N4) → E1(N7)

  11. The synchronization error introduced by reference broadcast is Gaussian. The per hop contribution to error are independent because of phase and skew estimates being calculated for every broadcast. The total path error will also have Gaussian distribution. If standard deviation along path is σ, then for n hops the error is σ√n To achieve synchronization with external timescales, a GPS receiver can be connected to one of the nodes. It can give out reference signals in the form of pulse per second signals of the GPS receiver. Other nodes in the system will align themselves to the node via single or multi-hop methods.

  12. RBS was tested against NTP In light traffic conditions, RBS performed 8 times better than NTP. Under heavy traffic scenario, RBS performance was affected only slightly while NTP performance degraded drastically.

  13. Advantages of RBS • The largest source of nondeterministic latency (send and access time delays) can be removed from critical path by using broadcast channel to synchronize receivers with one another. • RBS broadcast always used as a relative time reference. This further reduces the error due to send and access time delay. • Multiple broadcasts used to overcome large offset differences at receiver. Precision of synchronization is increased and larger group size of nodes can be accommodated in the single-hop stage. • RBS allows construction of local timescales. • Outliers and lost packets are handled gracefully by best fit method. • RBS can be used for post-facto synchronization.

  14. Disadvantages of RBS • It assumes presence of a broadcast channel. • The multi-hop algorithm relies on effective clustering of nodes around broadcast groups as well as overlap of clusters for inter-cluster synchronization. • It has a complexity of O(mn2) - for each of the m received reference packets, a node exchanges information with all n-1 receivers. • It assumes that two receivers lying within the range of a single sender can communicate with each other.

  15. TINY/MINI TIME SYNCHRONIZATION SCHEME[1] Features • Low computation and storage complexity • Tight bounds on precision ▫Tight, deterministic bounds on estimates of offset and drift of clocks • Insensitivity to communication errors

  16. Data Collection Algorithm The hardware clock of node i is a monotonically non-decreasing function of t where t is the Coordinated Universal Time (UTC) The oscillator’s frequency depends on the ambient conditions but can be approximated with good accuracy by an oscillator with fixed frequency: ti(t) = ait + bi where ai = drift of node i’s clock bi = offset of node i’s clock

  17. Consider 2 nodes 1 and 2, with their hardware clocks t1(t) and t2(t). t1 and t2 are linearly related by t1(t) = a12t2(t) + b12 a12 = relative drift b12 = relative offset tb t2 to tr t1 The three time stamps form a data-point which limit the possible values of a12 and b12 to(t) < a12tb(t) + b12 tr(t) > a12tb(t) + b12

  18. a12 and b12 can be bounded by, True parameters a12 and b12 estimated as, where -

  19. Node 2 usually takes some time to respond to the probe message. This will not affect the analysis, if node 2 time-stamps the probe message upon receipt and resending. However as the delay t0 and tr increases, the precision of the estimates will decrease. To decrease the overhead of the algorithm, probes can be piggybacked on data messages.

  20. TINY SYNC We don’t need all 3 data points to estimate a12 and b12 bounds. Keep only 4 data constraints that define the best bounds. On arrival of new data points the two new constraints are compared with existing four constraints and two constraints are discarded. Despite being efficient, the algorithm does not always reach the optimal value. On analysis the difference in performance between tiny and mini sync algorithm is only 2%.

  21. MINI SYNC Upon receipt of a new data point the algorithm checks if the new constraints can eliminate any old constraints. A constraint Aj which satisfies the following condition can be discarded where m(X,Y) = slope of line joining X and Y Experiments showed that 40 data points were enough to obtain the optimum result.

  22. Aj can be discarded and keep Ai , Ak

  23. Synchronizing an Entire Network Use the synchronization transitivity to obtain synchronization over the network Node s synchronies to node u and node u synchronizes with node v If u sends its bounds to s, then s can compute the bounds where -

  24. The network is logically organized as a hierarchy. Data fusion takes place at nodes at upper levels. If nodes synchronize with a root node, the precision decreases linearly with number of layers spanning from root node. Instead nodes should synchronize with the fusion nodes in the layer immediately above it. Nodes in the intermediate level i synchronizes with nodes in layer i-1. If a node reports to more than one intermediate node, the node will synchronize with all of them.

  25. Experimental Result Lower and upper bounds on a12 samples ∆a12 Bounds for a12 and ∆a12 samples

  26. Lower and upper bounds on b12 Bounds for b12 and ∆b12 samples ∆b12 samples

  27. LIGHTWEIGHT TREE BASED SYNCHRONIATION SCHEME[5] It exploits the relaxed constraints on accuracy for sensor networks. For a single-hop, pair-wise synchronization is used. Multi-hop synchronization consists of pair-wise synchronizations along the network edges that form a spanning tree. Multi-hop synchronizations require only n-1 pair-wise synchronizations for a network of n nodes. Focus on minimizing overhead (energy) and being robust and self configuring.

  28. Pair-WiseSynchronization Node j transmits 1st packet with timestamp t1. Node k records time t2 when it receives packet. t2 = t1 + D + d Where D = transmission time, d = phase offset between node j and k clocks Node k transmits a second packet to j that contains t1 and t2. Time stamped by k at t3. Node j receives second packet at time t4 = t3 + D – d Offset calculated at node j by t4 – t2 = t1 – t3 + 2d Packet 1 k j Packet 2 Transmission time D

  29. Multi-Hop Synchronization Assume that at least one node has access to a global time reference. It will be maintained at an accuracy much greater than required by the network. Can perform selective synchronization if desired. Due to clock drift, the nodes have to be periodically resynchronized depending on estimated error.

  30. Centralized Multi-Hop Synchronization Construction of a low depth spanning tree T comprising of network nodes. New spanning tree formed each time algorithm is performed using Distributed Depth First Search (DDFS)[2] or ECHO algorithms. Reference nodes initiates synchronization by synchronizing with all immediate children in T. Each child synchronizes with its subsequent children in T. The algorithm terminates when it reaches leaf nodes. The error for pair-wise sync is Gaussian. Hence a node at depth d in T will have variance in error given by 4*d*σ where σ is receiver variance. The reference node initiates resynchronization which occurs periodically. More efficient when all nodes participate.

  31. Distributed Multi-Hop LTS Pair-wise synchronization done in distributed manner. Algorithm does not use an overlay spanning tree to direct pair-wise synchronization. The individual nodes decide when to resynchronize depending on parameters – accuracy desired, distance from reference node, and time elapsed since last synchronization. When node decides to resynchronize it sends request to nearest reference node. More efficient when certain nodes need frequent resynchronization. Advantage : Nodes can opportunistically synchronize. Disadvantage : Cycles may occur when node at the head of request chain sends synchronization request to a node further down the request chain.

  32. Disadvantages of LTS It is dependent on reliability of information being shared between nodes and reference node. Synchronization will fail if clock failure occurs.

  33. CONCLUSION Time synchronization is a critical piece of infrastructure for any distributed system. Different systems have unique requirements in scope, lifetime, and precision of synchronization achieved as well as energy and time spent to achieve it. Existing algorithms have to be adapted to meet those requirements.

  34. References [1] M.L. Sichitiu and C. Veerarittiphan, Simple, Accurate Time Synchronization for Wireless Sensor Networks. IEEE Wireless Communications and Networking Conference, WCNC 2003 [2] B. Awerbuch, A new distributed depth first search algorithm, Inf. Proc. Lett. 20 (1985), 147-150. [3] Jeremy Elson, Lewis Girod, and Deborah Estrin. Fine-Grained Network Time Synchronization using Reference Broadcasts. In Proceedings of the Fifth Symposium onOperating Systems Design and Implementation (OSD/2002),Boston, MA, December 2002. [4] Santashil PalChaudhuri, Amit Kumar Saha, David B. Johnson. Adaptive Clock Synchronization in Sensor Networks. Proceedings of the third international symposium on Information processing in sensor networks,Berkeley, California.Pages 340-348. published 2004. [5] Jana van Greunen, Jan Rabaey. Lightweight Time Synchronization for Wireless Networks. Proceedings of the 2nd ACM international conference on Wireless sensor networks and applications. San Diego, CA, USA .Pages: 11 - 19 ,Year of Publication: 2003 [6] Jeremy Elson, Deborah Estrin. Time Synchronization for Wireless Networks. Parallel and Distributed Processing Symposium., Proceedings 15th International 23-27 April 2001 Page(s):1965 - 1970 . [7] Jeremy Elson, Kay Romer. Wireless Sensor Networks:New regime for Time Synchronization. in ACM SIGCOMM Computer Communications Review. Vol 33, Jan 2003. [8] David L.Mills, Internet Time Synchronization: The Network Time Protocol. In Communications, IEEE Transactions on Volume 39,  Issue 10,  Oct. 1991 Page(s):1482 - 1493 [9] Kopetz,H. Wilhelm Ochsenreiter : Global Time in Distributed Real Time Systems. Technical report 15/89,Technische Universitat Wien, Wien Austria(1989).

More Related