Overview of Time Synchronization Issues in Sensor Networks
5.5 Time Synchronization Protocols for Sensor Networks
There are three types of timing techniques as shown in Table ., and each of these types has to address the design challenges and factors affecting time synchronization as mentioned in Sections
. and ., respectively. In addition, the timing techniques have to address the mapping between the sensor network time and the Internet time, e.g., universal coordinated time. In the following, examples of these types of timing techniques are described, namely the Network Time Protocol (NTP) [], Timing-sync Protocol for Sensor Networks (TPSN) [], H-sensor Broadcast Synchro-nization (HBS) [], Time SynchroSynchro-nization for High Latency (TSHL) [], Reference-Broadcast Synchronization (RBS) [], Adaptive Clock Synchronization [], Time-Diffusion Synchroniza-tion Protocol (TDP) [], Rate-Based Diffusion Algorithm [], and Adaptive-Rate SynchronizaSynchroniza-tion Protocol (ARSP) [].
In Internet, the NTP is used to discipline the frequency of each node’s oscillator. The accuracy of the NTP synchronization is in the order of milliseconds []. It may be useful to use NTP to disciple the oscillators of the sensor nodes, but the connection to the time servers may not be possible because of frequent sensor node failures. In addition, disciplining all the sensor nodes in the sensor field maybe a problem due to interference from the environment and large variation of delay between different parts of the sensor field. The interference can temporarily disjoint the sensor field into multiple smaller fieldscausing undisciplined clocks among these smaller fields. The NTP protocol may be considered as type () of the timing techniques. In addition, it has to be refined in order to address the design challenges presented by the sensor networks.
As of now, the NTP is very computational intensive and requires a precise time server to synchro-nize the nodes in the network. In addition, it does not take into account of the energy consumption required for time synchronization. As a result, the NTP does not satisfy the energy aware, server-less, and lightweight design challenges of the sensor networks. Although the NTP can be robust, it may suffer large propagation delay when sending timing messages to the time servers. In addition, the nodes are synchronized in a hierarchical manner, and some time servers in the middle of the hierarchy may fail causing unsynchronized nodes in the network. Once these nodes fail, it is hard to reconfigure the network since the hierarchy is manually configured.
Richard Zurawski/Networked Embedded Systems K_C Finals Page -- #
Overview of Time Synchronization Issues in Sensor Networks 5-7 Synchronization pulse
Another time synchronization technique that adopts some concepts from NTP is TPSN. The TPSN requires the root node to synchronize all or part of the nodes in the sensor field. The root node synchronizes the nodes in a hierarchical way. Before synchronization, the root node constructs the hierarchy by broadcasting a level_discovery packet. The first level of the hierarchy is level , which is where the root node resides. The nodes receiving the level_discovery packet from the root node are the nodes belonging to level . Afterwards, the nodes in level broadcast their level_discovery packet, and neighbor nodes receiving the level_discovery packet for the first time are the level nodes. This process continues until all the nodes in the sensor field has a level number.
The root node sends a time_sync packet to initialize the time synchronization process. After-wards, the nodes in level synchronize to level by performing the two-way handshake as shown in Figure .. This type of handshake is used by the NTP to synchronize the clocks of distributed computer systems. At the end of the handshake at time g, node A obtains the time g, g, and g
from the ACK packet. The time g and g are obtained from the clock of sensor node B while g
and gare from the node A. After processing the ACK packet, the node A readjusts its clock by the clock drift value ∆, where ∆ = (g−g) − (g−g)/. At the same time, the level nodes overhear this message handshake and wait for a random time before synchronizing with level nodes. This synchronization process continues until all the nodes in the network are synchronized. Since TPSN enables time synchronization from one root node, it is type () of the timing techniques.
TheTPSN is based on a sender–receiver synchronization model, where the receiver synchronizes with the time of the sender according to the two-way message handshake as shown in Figure ..
It is trying to provide a lightweight and tunable time synchronization service. On the other hand, it requires a time server and does not address the robust and energy aware design goal. Since the design of TPSN is based on a hierarchical methodology similar to NTP, nodes within the hierarchy may fail and cause nodes to be unsynchronized. In addition, node movements may render the hierarchy useless, because nodes may move out of their levels. Hence, nodes at level i cannot synchronize with nodes at level i − . Afterwards, synchronization may fail throughout the network.
Currently, there is an interest in improving time synchronization schemes and making them secure from different attacks, such as masquerade, replay, message manipulation, and delay attacks.
One such protocol is HBS [], which is based on TPSN. HBS assumes the cluster heads are high power sensor nodes that can run encryption algorithms and synchronize using GPS. The cluster heads tag each timing message with a sequence number and a message authentication code using the shared key between two nodes. The preloaded public/private keys are protected by tamper-resistant hardware.
To authenticate that a timing message sent by a cluster head is valid, neighboring cluster heads check the message authentication code by using the stored public key. This is assuming that the broadcast by the cluster head is heard by neighboring cluster heads. If the message authentication code is not valid, an alarm message will be broadcasted.
Another variation of the TPSN is TSHL [], it has two components, clock skew compensation and clock offset correction. For clock skew compensation, the beacon nodes send out beacon messages so nodes can use linear regression to estimate and correct the clock skew. Afterwards, the nodes use
Richard Zurawski/Networked Embedded Systems K_C Finals Page -- #
5-8 Networked Embedded Systems
C
Transmitters Receivers
Translation nodes A
B
FIGURE . Illustration of the RBS.
a two-way message handsake as shown in Figure . to synchronize and correct any clock offset. The objective of TSHL is to address long propagation delay in acoustic sensor networks.
As for type () of the timing techniques, the RBS provides an instantaneous time synchronization among a set of receivers that are within the reference broadcast of the transmitter. The transmitter broadcasts m reference packets. Each of the receivers that are within the broadcast range records the time-of-arrival of the reference packets. Afterwards, the receivers communicate with each other to determine the offsets. To provide multihop synchronization, it is proposed to use nodes that are receiving two or more reference broadcasts from different transmitters as translation nodes. These translation nodes are used to translate the time between different broadcast domains.
As shown in Figure ., nodes A, B, and C are the transmitter, receiver, and translation nodes, respectively. The transmitter nodes broadcast their timing messages, and the receiver nodes receive these messages. Afterwards, the receiver nodes synchronize with each other. The sensor nodes that are within the broadcast regions of both transmitter nodes A are the translation nodes. When an event occurs, a message describing the event with a time stamp is translated by the translation nodes when the message is routed back to the sink. Although this time synchronization service is tunable and lightweight, there may not be translation nodes on the route path that the message is relayed.
As a result, services may not be available on some routes. In addition, this protocol is not suitable for medium access scheme such as TDMA since the clocks of all the nodes in the network are not adjusted to a common time.
PalChaudhuri et al. [] extends the work on RBS and provides a probabilistic bound on the accu-racy of clock synchronization. The synchronization error is assumed to be Gaussian distributed, and it is possible to calculate the probability of synchronization error given the maximum allowed error.
For instance, given the maximum error between two synchronizing nodes is єmax, the probability of synchronization with an error є ≤ єmaxis calculated as follows:
P(∣є∣ ≤ єmax) =er f (
√nєmax
σ ) (.)
where
er f is the error function
n is the number of messages needed to achieve the probability P σ is the standard deviation of the Gaussian distribution
Richard Zurawski/Networked Embedded Systems K_C Finals Page -- #
Overview of Time Synchronization Issues in Sensor Networks 5-9
Hops
D G
C 1 E 3
1 2
3
Diffused leader nodes Master nodes
N M
2 F
FIGURE . TDP concept.
Another emerging timing technique is the TDP. The TDP is used to maintain the time throughout the network within a certain tolerance. The tolerance level can be adjusted based on the purpose of the sensor networks. The TDP automatically self-configures by electing master nodes to synchronize the sensor network. In addition, the election process is sensitive to energy requirement as well as the quality of the clocks. The sensor network may be deployed in unattended areas, and the TDP still synchronizes the unattended network to a common time. It is considered as a type () of the timing techniques.
TheTDP concept is illustrated in Figure .. The elected master nodes are nodes C and G. First, the master nodes send a message to their neighbors to measure the round-trip times. Once the neigh-bors receive the message, they self-determine if they should become diffuse leader nodes. The ones elected to become diffuse leader nodes reply to the master nodes and start sending a message to measure the round-trip to their neighbors. As shown in Figure ., nodes M, N, and D are the dif-fused leader nodes of node C. Once the replies are received by the master nodes, the round-trip time and the standard deviation of the round-trip time are calculated. The one-way delay from the master nodes to the neighbor nodes is half of the measured round-trip time. Afterwards, the master nodes send a time-stamped message containing the standard deviation to the neighbor nodes. The time in the time-stamped message is adjusted with the one-way delay. Once the diffuse leader nodes receive the time-stamped message, they broadcast the time-stamped message after adjusting the time, which is in the message, with their measured one-way delay and inserting their standard deviation of the round-trip time. This diffusion process continues for n times, where n is the number of hops from the master nodes. From Figure ., the time is diffused three hops from the master nodes C and G.
Thenodes D, E, and F are the diffused leader nodes that diffuse the time-stamped messages originated from the master nodes.
For the nodes that have received more than one time-stamped messages originated from different master nodes, they use the standard deviations carried in the time-stamped messages as weighted ratio of their time contribution to the new time. In essence, the nodes weight the times diffused by the master nodes to obtain a new time for them. This process is to provide a smooth time variation between the nodes in the network. The smooth transition is important for some applications such as target tracking and speed estimating.
Themaster nodes are autonomously elected, so the network is robust to failures. Although some of the nodes may die, there are still other nodes in the network that can self-determine to become master nodes. This feature also enables the network to become server-less if necessary and to reach an equilibrium time. In addition, the master and diffusion leader nodes are self-determined based on their own energy level. Also, the TDP is lightweight, but it may not be as tunable as the RBS.
Richard Zurawski/Networked Embedded Systems K_C Finals Page -- #
5-10 Networked Embedded Systems
Li and Rus [] propose another diffusion technique called rate-based diffusion algorithm. The diffusion algorithm has two types: synchronous and asynchronous. The synchronous diffusion algorithm performs the following steps:
. Do the following with some given frequency
. for each sensor niin the network do
. Exchange clock times with n′is neighbors
. for each neighbor njdo
. Let the time difference between niand njbe ti−tj
. Change n′is time to ti−ri j(ti−tj)
Thesynchronous method allows the sensor nodes to exchange their clock values and adjust them by ri j(ti−tj), where ri jis the diffusion rate and (ti−tj)is the time difference between nodes niand nj. The diffusion rate is greater than zero and can be chosen randomly provided that the ∑j≠iri j≤. If nodes niand njare not neighbors, then the diffusion rate is equal to zero.
The synchronous version of the rate-based diffusion algorithm requires all nodes to perform tasks in a set order. To relax such constraint, the asynchronous version of the rate-based diffusion algorithm is executed as follows:
. for each node niwith uniform probability do
. Ask its neighbors the clock readings (read values from niand its neighbors)
. Average the readings (compute)
. Send back to the neighbors the new value (write values to niand its neighbors)
As with TDP, the Rate-based Diffusion Algorithm is lightweight but cannot provide tunable services.
Macii and Petri [] propose another adaptive-rate time synchronization technique called ARSP.
ARSP is based on the simple response method that adaptively adjust the calibration intervals of mea-surement instruments based on the last calibration []. The objective of ARSP is to assure that the probability of having time offsets larger than εmaxat the end of kth synchronization is smaller than
− PT, where PTis the desired end-of-period synchronization probability.
First, the nodes in the network elects a synchronization master. The synchronization master broad-casts a synchronization packet, and all nodes that receive the packet measure the arrival time, ̂Tik. Afterwards, a reference master is elected. The arrival time of the synchronization packet measured by the reference master is ̂Tmk. The elected reference master sends ̂Tmkto all nodes, where they will compare ̂Tmkto the arrival time of the synchronization packet. If the difference ∣̂Tik− ̂Tmk∣is greater than the allowed maximum error εmax, then the node will set probability pik to ; otherwise, pikis set to .
After all the nodes calculate pik, they send it to the reference master, where it calculates the probability Pkas follows:
Pk= ∑Mi=,i≠mpik
M − (.)
where
M is the number of sensor nodes that the reference master is connected to k represents kth synchronization
Afterward, the reference master calculates the next synchronization interval Ik+ according to the following:
Ik+= { Ik( + a) Pk≥PT
Ik( − b) Pk<PT (.)
Richard Zurawski/Networked Embedded Systems K_C Finals Page -- #
Overview of Time Synchronization Issues in Sensor Networks 5-11 where a > , < b < , and PTis the desired end-of-period synchronization probability. The ARSP is also lightweight and provides some tunable service such as changing the desired end-of-period synchronization probability and increasing the maximum synchronization error allowed.
In summary, the above mentioned timing techniques may be used for different types of applica-tions; each of them has its own benefits. All of these techniques try to address the factors influencing time synchronization while design according to the challenges as described in Section .. Depending on the types of services required by the applications or the hardware limitation of the sensor nodes, some of these timing techniques may be applied.
5.6 Conclusions
Thedesign challenges and factors influencing time synchronization for sensor networks are described in Sections . and ., respectively. They are to provide guidelines for developing time synchro-nization protocols. The requirements of sensor networks are different from traditional distributed computer systems. As a result, new types of timing techniques are required to address the specific needs of the applications. These techniques are described in Section .. Since the range of applica-tions in the sensor networks is wide, new timing techniques are encouraged for different types of applications. This is to provide optimized schemes tailored for unique environments and purposes.
References
. Akyildiz, I. F. et al., Wireless sensor networks: A survey, Computer Networks (Elsevier) Journal, ,
–, March .
. Allan, D., Time and frequency (time-domain) characterization, estimation, and prediction of preci-sion clocks and oscillators, IEEE Transactions on Ultrasonics, Ferroelectrics, and Frequency Control,
(), –, November .
. Bianchi, G., Performance analysis of the IEEE . distributed coordination function, IEEE Journal on Selected Areas in Communications, (), –, March .
. Cristian, F. and Fetzer, C., Probabilistic internal clock synchronization, Proceedings of the Thirteenth Symposium on Reliable Distributed Systems, pp. –, Dana Point, CA, October .
. Crow, B. P. et al., Investigation of the IEEE . medium access control (MAC) sublayer functions, IEEE INFOCOM’, pp. –, Kobe, Japan, April .
. Du, X., Guizani, M., Xiao, Y., and Chen, H., IEEE Global Telecommunications Conference, pp. –
, Washington, DC, November .
. Elson, J., Girod, L., and Estrin, D., Fine-grained network time synchronization using reference broad-casts, Proceedings of the Fifth Symposium on Operating Systems Design and Implementation (OSDI
), pp. –, Boston, MA, December .
. Ganeriwal, S., Kumar, R., and Srivastava, M. B., Timing-sync protocol for sensor networks, ACM SenSys , pp. –, Los Angeles, CA, November .
. IEEE , Standard for a precision clock synchronization protocol for networked measurement and control systems, .
. Levine, J., Time synchronization over the Internet using an adaptive frequency-locked loop, IEEE Transaction on Ultrasonics, Ferroelectrics, and Frequency Control, (), –, July .
. Li, Q. and Rus, D., Global clock synchronization in sensor networks, Proceedings of the IEEE Confer-ence on Computer Communications (INFOCOM ), vol. , pp. –, Hong Kong, China, March
.
. Macii, D. and Petri, D., An adaptive-rate time synchronization protocol for wireless sensor net-works, IEEE Instrumentation and Measurement Technology Conference, pp. –, Warsaw, Poland, May .
Richard Zurawski/Networked Embedded Systems K_C Finals Page -- #
5-12 Networked Embedded Systems
. MICA Motes and Sensors, http://www.xbow.com
. Mills, D. L., Internet time synchronization: The network time protocol, Global States and Time in Distributed Systems, IEEE Computer Society Press, Los Alamitos, CA, .
. Mills, D. L., Adaptive hybrid clock discipline algorithm for the network time protocol, IEEE/ACM Transactions on Networking, (), –, October .
. NCSL, Establishment and adjustment of calibration intervals, Recommended Practice RP-, January
.
. PalChaudhuri, S., Saha, A., and Johnson, D. B., Adaptive clock synchronization in sensor networks, IEEE Symposium on Information Processing in Sensor Networks, pp. –, Berkeley, CA, April .
. Pottie, G. J. and Kaiser, W. J., Wireless integrated network sensors, Communications of the ACM, (),
–, May .
. Su, W. and Akyildiz, I. F., Time-diffusion synchronization protocol for sensor networks, IEEE/ACM Transactions on Networking, (), –, April .
. Syed, A. and Heidemann, J., Time synchronization for high latency acoustic networks, IEEE Infocom Conference, pp. –, Barcelona, Spain, April .
. Tay, Y. C. and Chua, K. C., A capacity analysis for the IEEE . MAC protocol, ACM Wireless Networks Journal, , –, .
Richard Zurawski/Networked Embedded Systems K_C Finals Page -- #