monet 05 time synchronization in wireless sensor networks anisha menon

34
MONET 05 Time Synchronization In Wireless Sensor Networks Anisha Menon

Upload: clarence-saner

Post on 29-Mar-2015

217 views

Category:

Documents


1 download

TRANSCRIPT

Page 1: MONET 05 Time Synchronization In Wireless Sensor Networks Anisha Menon

MONET 05

Time Synchronization

In Wireless Sensor Networks

Anisha Menon

Page 2: MONET 05 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

Page 3: MONET 05 Time Synchronization In Wireless Sensor Networks Anisha Menon

Characterizing Time Synchronization

Precision Lifetime Scope and Availability Efficiency Cost and Size

Page 4: MONET 05 Time Synchronization In Wireless Sensor Networks Anisha Menon

Constraints of existing methodsNetwork 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

Page 5: MONET 05 Time Synchronization In Wireless Sensor Networks Anisha Menon

Design Principles

• Tradeoff between Energy Precision Scope Lifetime Cost

• Tiered architecture• Tunable – Adaptive Fidelity• No Global Timescale

Page 6: MONET 05 Time Synchronization In Wireless Sensor Networks Anisha Menon

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

Page 7: MONET 05 Time Synchronization In Wireless Sensor Networks Anisha Menon

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 offset1. 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.

Page 8: MONET 05 Time Synchronization In Wireless Sensor Networks Anisha Menon

A

njni

Reference packet

Exchange Information

Page 9: MONET 05 Time Synchronization In Wireless Sensor Networks Anisha Menon

Estimation of clock skewPerform 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.

Page 10: MONET 05 Time Synchronization In Wireless Sensor Networks Anisha Menon

Multiple Hop Time Synchronization

A B

5

7

6

1

2

4

3

E2E1

Timebase conversions – E1(N1) → E1(N4) → E1(N7)

E1 = A + 2

E7 = B - 4

A = B + 10

E1 = E7 + 16

Page 11: MONET 05 Time Synchronization In Wireless Sensor Networks Anisha Menon

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 timescalessynchronization 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.

Page 12: MONET 05 Time Synchronization In Wireless Sensor Networks Anisha Menon

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.

Page 13: MONET 05 Time Synchronization In Wireless Sensor Networks Anisha Menon

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.

Page 14: MONET 05 Time Synchronization In Wireless Sensor Networks Anisha Menon

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.

Page 15: MONET 05 Time Synchronization In Wireless Sensor Networks Anisha Menon

TINY/MINI TIME SYNCHRONIZATION SCHEME[1]

FeaturesLow computation and storage complexity

Tight bounds on precision

▫Tight, deterministic bounds on estimates of offset and drift of clocks

Insensitivity to communication errors

Page 16: MONET 05 Time Synchronization In Wireless Sensor Networks Anisha Menon

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

Page 17: MONET 05 Time Synchronization In Wireless Sensor Networks Anisha Menon

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 driftb12 = relative offset

to

tb

tr

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

t1

t2

Page 18: MONET 05 Time Synchronization In Wireless Sensor Networks Anisha Menon

a12 and b12 can be bounded by,

True parameters a12 and b12 estimated as,

where -

Page 19: MONET 05 Time Synchronization In Wireless Sensor Networks Anisha Menon

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.

Page 20: MONET 05 Time Synchronization In Wireless Sensor Networks Anisha Menon

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 comparedwith 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%.

Page 21: MONET 05 Time Synchronization In Wireless Sensor Networks Anisha Menon

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.

Page 22: MONET 05 Time Synchronization In Wireless Sensor Networks Anisha Menon

Aj can be discarded and keep Ai , Ak

Page 23: MONET 05 Time Synchronization In Wireless Sensor Networks Anisha Menon

Synchronizing an Entire 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 -

Use the synchronization transitivity to obtain synchronization over the network

Page 24: MONET 05 Time Synchronization In Wireless Sensor Networks Anisha Menon

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 layerimmediately 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 willsynchronize with all of them.

Page 25: MONET 05 Time Synchronization In Wireless Sensor Networks Anisha Menon

Experimental Result

Bounds for a12 and ∆a12

samples

Low

er a

nd u

pper

bou

nds

on a

12

samples

∆a

12

Page 26: MONET 05 Time Synchronization In Wireless Sensor Networks Anisha Menon

Bounds for b12 and ∆b12

samples

samples

Low

er a

nd u

pper

bou

nds

on

b12

∆b

1

2

Page 27: MONET 05 Time Synchronization In Wireless Sensor Networks Anisha Menon

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.

Page 28: MONET 05 Time Synchronization In Wireless Sensor Networks Anisha Menon

Pair-Wise SynchronizationNode j transmits 1st packet with timestamp t1.Node k records time t2 when it receives packet.

t2 = t1 + D + dWhere D = transmission time,

d = phase offset between node j and k clocksNode 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 – dOffset calculated at node j by

t4 – t2 = t1 – t3 + 2d

j k

Packet 1

Packet 2

Transmission time D

Page 29: MONET 05 Time Synchronization In Wireless Sensor Networks Anisha Menon

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.

Page 30: MONET 05 Time Synchronization In Wireless Sensor Networks Anisha Menon

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.

Page 31: MONET 05 Time Synchronization In Wireless Sensor Networks Anisha Menon

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.

Page 32: MONET 05 Time Synchronization In Wireless Sensor Networks Anisha Menon

It is dependent on reliability of information being shared between nodes and reference node.

Synchronization will fail if clock failure occurs.

Disadvantages of LTS

Page 33: MONET 05 Time Synchronization In Wireless Sensor Networks Anisha Menon

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.

Page 34: MONET 05 Time Synchronization In Wireless Sensor Networks Anisha Menon

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).