CLOCK DRIFT REDUCTION FOR RELATIVE TIME SLOT TDMA-BASED SENSOR NETWORKS R.Tjoa Electrical and Computer Engineering, Faculty of Engineering, National University of Singapore, [email protected] K. L. Chee, P. K. Sivaprasad, S.V. Rao and J.G. Lim Radio Systems Department, Communications and Devices Division, Institute for Infocomm Research, Singapore-117674, {cheekl, pksiva, raosv, limjg}@i2r.a-star.edu.sg

Abstract In an ad hoc sensor network clock synchronization is a serious issue as nodes in the sensor network have different clock drifts. One of the common solutions for the time synchronization among these nodes is the active transmission of time stamp messages. However this method consumes some resources and channel bandwidth, and is not suitable for resource constrained nodes in the sensor network. This paper presents a novel method with minimum overhead that reduces clock drift effects in the synchronization of nodes in sensor networks using relative time-slot referencing TDMA based MAC protocol. Keywords: Sensor network, MAC, TDMA, Clock drift, Synchronization

1.

INTRODUCTION

Time synchronization is a major issue in wireless distributed systems, especially in the resource constrained sensor networks. Time synchronization mechanism allows sensor networks to synchronize during startup and maintain its synchronization during normal operation in the presence of clock drift at the nodes. The clock drift is a hardware problem caused by variation in the crystal frequency due to noise, temperature, aging, voltage change etc. The cost of the crystal increases with the accuracy and the low-cost nodes in the sensor network generally use less accurate crystal. Clock drifting in a distributed network can cause various effects ranging from slight to severe, depending on how the system works. For example, in a Time Division Multiple Access (TDMA) [1]-based wireless network where different units have different scheduled time-slots for transmission and reception, clock drifts, if not properly handled may cause the system to malfunction. Many methods have been developed to reduce or even eliminate clock drift problem, however these solutions may not work in all systems. The method employed in one architecture may not necessarily be suitable for another. For example, the TDMA synchronization approach given in [2]

has less communication and synchronization time overhead; but the computation and memory overheads are high. This scheme is suitable for safety critical real-time distributed applications with nodes having enough computation capabilities and lots of memory. But the above scheme is not suitable for resource constrained sensor network. Most of the current solutions use active transmission of periodic time stamp messages to keep the time between any two nodes synchronized. Also, some papers [3, 4] have provided methods that guarantee the accuracy of the synchronization. In this paper, we will present a novel approach based on relative time slot referencing, to reduce clock drifting in networks having TDMA scheme for media access. This paper is organized as follows. In section 2 we give an overview of a TDMA based MAC scheme SMART [6] suitable for sensor networks. Our approach is applicable to all TDMA based schemes. SMART is chosen only for convenience as it is designed in-house and can be easily modified for further studies. Following that, in Section 3, a short description on the clock drift problem encountered in the sensor network using the SMART is given. In section 4, the time synchronization mechanism for the SMART scheme is explained in detail. Subsequently we cover the simulation and experimental result of the clock drift reduction scheme. 2.

SMART FOR SENSOR NETWORK

In a Sensor Network (Figure 1) nodes are spread over a large area and each node has direct communication with immediate neighbors that are within the communication range of the node. Power conservation at the nodes of the sensor network is an important issue and TDMA is a suitable choice as its MAC protocol. There are various schemes developed for TDMA [5]. Fixed allocation TDMA protocols have the advantage of having predictable time slots to schedule the switch-off-times of the RF transceivers and avoid data collisions. But the resource-constrained nodes of sensor network cannot afford to have complex synchronization mechanisms.

providing a guard band to avoid abrupt slot overlapping due to clock drift, SMART uses time-slot duration shorter than a typical message length. That means each node uses a few time slots (e.g. 2 to 4) for its transmissions and the messages span over variable time slots depending on the message length. Since nodes in an Ad hoc Sensor network are spread over a large geographical area it is very difficult to have a centralized synchronization mechanism that provides synchronized clock to all nodes in the Sensor network. In order to synchronize the clock, a node can only communicate to its own neighbor nodes within its communication range, making it impossible to have perfect synchronization amongst all nodes in the network.

Figure 1. Sensor Network SMART [6] is a simple MAC based on fixed-allocation TDMA using relative time slot referencing and is suitable for a resource constrained wireless ad hoc sensor network.

Node X Node Y

Slot Slot Slot Slot Slot 255 000 001 002 003 Slot Slot Slot Slot Slot 245 246 247 248 249

Slot Slot Slot Slot 010 011 012 013 Slot Slot Slot Slot 000 001 002 003

Figure 2. Relative Time Slot In relative time slot TDMA scheme, a cyclic duration is specified as a frame (see Figure 2). Within one frame, all the nodes in the neighborhood have their own time slots, such that only one node may transmit at a time. Each node marks its own transmission slot as slot 0. The node keeps track of its neighbors’ transmission slots relative to its own. Since this information is used internally in the node, there is no requirement to have global time synchronization. In the example given in Figure 2, in node X’s time schedule slot 10 is reserved for Y’s transmission. Similarly, in Y’s time schedule, slot 246 is reserved for X’s transmission During initialization process, each node records and reserves certain time slots for its neighboring nodes’ transmissions in one period of frame. The time slot assignment is arbitrary. When a node wants to join a network, it will listen and record all its neighbors’ transmission time slots. After that it will randomly select an unused slot and transmit a message over that time slot to join the neighborhood. If there is no collision with transmission from other nodes, the neighbor nodes will record the time slot for this new node and send back the acceptance message. This neighborhood joining is an independent process and the alignment of frame of every node is not absolute; which means one node may have different frame alignment when measured relative to its neighbor nodes as shown in Figure 2. For flexibility in handling variable length messages and

3. CLOCK DRIFT Figure 3 shows an instance of the time schedule for 3 different nodes, where each node has reserved few time slots for transmission and to provide guard band to avoid abrupt disruption of the scheduling due to clock drifts. When clock drifts occur a node will transmit earlier or later than the specified schedule in its neighbor nodes. This means that there is a shift either to the right or to the left depending on the difference in the rate of the clock drifts between any two nodes. A Node A

B

B Node B

C

C Node C

C (a) A (b) A

B (c)

Figure 3. Time Slot Schedule for 3 Nodes Figures 3a, 3b and 3c show the relative positions of the time slots of each node with respect to the other two. If node C has a faster clock rate than A and B, after a while node A and B will record the transmission time for C shifted to the left, whereas node C will record transmission time for A and B shifted to the right. In SMART, the relative time slot TDMA scheme, when the clock drift is neglected over a period of time, the slot schedules of the nodes may shift considerably and result in data collision. This might lead to communication failure among the nodes, as the time slot is not synchronized anymore. Normally, in this situation, the nodes whose transmissions disrupted due to collisions are required to rejoin the network to obtain new time slots and hence avoid transmission collisions. Fortunately, in normal cases clock drift rate is bounded by a constant, as shown in [3, 4].

4.

TIME SYNCHRONIZATION

A simple time synchronization mechanism suitable for nodes in the Sensor network is essential, for the system mentioned above, to allow continuous transmission during their scheduled time slot. This means whenever clock drift occurs and the neighbor node’s time slots shift (which can be either because of its own or the other nodes’ clock drifts) a node should adjust its own clock to tune the time schedule as close as possible to the original setting. In our method, in order to reduce the effect of the clock drift, we assume that always there are some transmissions during a certain interval. Since our method is reactive, this is important to ensure that the algorithm is to be applied before the time difference due to the clock drifts becomes too large. Reactive here means that synchronization is triggered by events and it does not require any specific transmission for synchronization and hence saves the channel bandwidth. Our method is simple and does not require complex calculation, which is important in a power constraint system like sensor network. Every node in the network records the last transmission time slot for a neighbor node, takes the difference from its previous transmission time slot and adds it to an accumulated value of clock drift. This is done repeatedly for each transmission and for every neighbor node. When a node detects that one of its neighbor nodes has an accumulated clock drift value exceeding a constant threshold α, it takes the average of the accumulated values of clock drifts of all neighbor nodes and shifts its own clock accordingly. This means if the average value of the clock drifts is positive then it shifts its own clock forward in positive direction such that its new time clock becomes closer to the average of all neighbor nodes’ clock. This clock shift is bounded by a minimum value between the average clock drift and a constant β. After synchronization is done, it must not synchronize its time schedule again within a fixed number of frames say, τ (another constant) to allow the synchronization to spread and converge within the network. Notice that the clock shift adjustment actually does not depend on the individual clock drift, but on the overall drift of the neighbor nodes. The algorithm needs to make the overall clock drifts converge to a certain degree in order to keep the individual clock drift within a specified limit. Figure 4 shows the most common topologies that may occur in a network. In Figure 4(a) where only two nodes exist in the neighborhood, it is easy to show that the algorithm is able to recover the clock drift. In Figure 4(b), the nodes labeled from 1 to an arbitrary positive constant n are located in one neighborhood, which means every node is able to transmit directly to any other node. Assume that every node in the network has a certain bounded clock drift relative to the real time. From these nodes we can find two nodes, one with the least clock drift and other with most clock drift, and label their clock drifts relative to the real time as C(1) and C(n) respectively. Hence after arrangement, we can have an inequality as follows,

(a)

1

n

(b)

i-1

i

i+1

(c) Figure 4. Common Node Topology C(1) ≤ C(2) ≤ …≤ C(n-1) ≤ C(n) When the clock shift adjustment is taken from the average of all the neighbor nodes’ clock drift, the value of C(1) will increase and C(n) will decrease and the other clock drift value may decrease or increase to a new value bounded by the initial value of C(1) and C(n). Hence the possibility of divergence of the clock drifts is eliminated. When the values of C(i) become close or equal to one another then we have the nodes synchronized. When the topology becomes more complex as shown in Figure 4(c), it becomes more difficult to perceive the convergence of synchronization. For example let us assume that a node “i“ has two neighboring nodes, “i-1” and “i+1”, which are not part of the same neighborhood. In this case, the synchronization may need to reach the whole network boundary before it starts to converge and meanwhile there may be some oscillations within network. In order to reduce some oscillations that may occur and reduce the convergence time, the parameter τ is crucial to be appropriately calculated and related to the topology of the network. The algorithm for the method is given as follows,

neighbor nodes and take the average. Sum all these values obtained from every node in the network and take the average, IF transmission from the neighbor node Ni received := Æ record the time slot Æ subtract this value from the previous time slot and add this result to ACD(i), the accumulated clock drift value for Ni IF (ABS(ACD(i)) > α) && ( τ frames has elapsed since the last synchronization) := Æ take the average value AVG of ACD(i), where i := 1, 2, …, n IF ABS(AVG) < β := Æ shift clock AVG time slots accordingly Æ reset ACD(i) := 0 ELSE Æ shift clock β time slots (direction according the value of AVG) Æ reset ACD(i) := 0 END IF

,

N Where ACD is the Average total Clock Drift, AVG (▪) is the average, CD is the accumulated clock drift of neighbor nodes, N is the total number of nodes in the network, i = 1, 2, 3 …, N and j = 1, 2, 3, …, no. of neighbor nodes. When the nodes are static and the network establishment time (all the nodes have joined the network) is much shorter than the simulation time, the value of ACD is a good indicator of the performance of the algorithm. In Figure 5 and Figure 6 the average total clock drift value and the average clock drift value per second is plotted against the simulation time. It should be noted that in the simulation absolute values of the clock drifts is considered to clearly see the accumulated drift and the difference between the two schemes.

END IF

We use a discrete event triggered C-based simulator to do the simulation. The algorithm is implemented at MAC-layer where our relative time slot TDMA-based scheme is used. The number of nodes used is 40, random seeds are used to generate the topology and the clock drifts of the nodes. The lower and upper bound of the clock drifts are -20 and +20 ppm respectively. The frame length is 1 sec simulation time and divided into 256 slots. Each node reserves 4 time slot for its transmission to accommodate variable message length. To observe the effectiveness of the algorithm and to reduce the clock drifts, each slot is divided into 128 minislots. That means each node occupies 4x128 mini slots. For an initial trial we have assumed the value of α, β, and τ to be 5, 10, and 5 respectively. The position of the nodes is static. The average number of total drifts of neighbor nodes is taken from each node. These values from each node are summed up and divided by the number of nodes (40) to get the average. This average value is plotted against the simulation time to observe the reduction of the clock drifts of the nodes. The parameters that are observed here are the average total clock drift value and the average clock drift value per sec. Average total clock drift is calculated as follows, for each node we sum all the accumulated clock drifts of its

80000 70000 60000 50000 40000

Original

30000

Modified

20000 10000 00

100

10100

20100

30100

40100

50100

Simulation Time (Sec)

Figure 5. Average Total Clock Drift

Clock Drift - Mini Time Slots per Sec

SIMULATION

Clock Drift - Mini Time Slots

Average Total Clock Drift

END IF

5.

∑ AVG i( ∑ CDj)

ACD =

Avg. Total Clock Drift per Sec 20 15 10

Original Modified

05 00 00

10000

20000

30000

40000

50000

60000

Simulation Time (Sec)

Figure 6. Avg Total Clock Drift per Sec

Figure 6 shows that the clock drift rate between any two nodes is indeed bounded. From the plotted graphs (Figure 5 & 6) we observe that when the algorithm is implemented the total clock drift is reduced significantly and the time synchronization becomes better and the nodes can stay in synchronization for long time. In the implementation without the clock drift reduction algorithm, the total clock drift increases with the simulation time affecting the synchronization of the nodes. 6.

R

(a)

EXPERIMENT

An experiment is conducted using the actual sensor nodes (Figure 7) developed for the ad hoc network based localization research [7] at Institute of Infocomm Research. These nodes, having a communication range of 5m, are built around Texas Instruments’ low-power micro-controller (MSP430F149) with 60 K bytes of program memory and 2 Kbytes of RAM. Chipcon’s low-power programmable RF transceivers (CC1000) operating at 868 MHz provides wireless connectivity at 9.6 Kbps. Each node has RS232 serial communication capability for communication with the host system if needed.

R

(b) Figure 8. Experimental Topology

Table 1. Experimental Average Clock Drift

Figure 7. Snapshot of a Sensor The firmware for the MAC (Relative time slot TDMA) and routing layer of the above card is developed using an event-driven scheduler [7] with power saving capability. We strictly followed all parameters used for the simulation except for the number of users that was only seven due to limited hardware resources available. Two topologies were used in the experiment as shown in Figure 8. Topology shown in Figure 8(a) was used to test the clock drift reduction in one neighborhood with many nodes. The clock drifts of the units are read from the unit in the center (labeled as ‘R’). Topology shown in Figure 8(b) was used to test the algorithm when there is more than one neighborhood. We observed the system with and without our algorithms for about 15 minutes. The experimental results are given in the Table 1. The result of the experiments is comparable to the simulation result proving our algorithm’s effectiveness in

System without ClockDrift Algorithm

System with Clock-Drift Algorithm

Test 1 Figure 8(a)

0.136 minislots/sec

0.0183 minislots/sec

Test 2 Figure 8(b)

0.26 minislots/sec

0.04 minislots/sec

reducing clock drift effects in ad hoc sensor network without introducing any communication overhead in the system. 7.

CONCLUSION

In conclusion, the new method we introduced in this paper can be used to reduce the clock drift in TDMA based sensor networks. The results obtained from the experiment are consistent with that obtained from the simulation where the algorithm reduces the clock drifts by more than 85 percents. Both results show conclusively that the implementation of the algorithm could give a significant improvement to the system. The performance of time synchronization and the rate of convergence may be different for a different topology and mobility scenario or a different rate of hardware clock drift. This new method,

although simple and suitable for power saving systems, it does not guarantee the accuracy or the convergence of the synchronization as it may oscillate in certain cases. The three parameters α, β, and τ play a very crucial role in this case, and a proper selection of these values will improve the performance. REFERENCES [1] Rappaport T. S., Wireless Communications: Principle And Practice, 2nd ed., pp. 453-454, Prentice Hall Inc., NJ, 2002. [2] Claesson, V; Lonn, H and Suri, N, ”Efficient TDMA synchronization for distributed embedded systems”, Reliable Distributed Systems, 2001. Proceedings. 20th IEEE Symposium on , pg 198-201, 28-31 Oct. 2001. [3] Srikanth T. K. and Toueg S, “Optimal Clock Synchronization”, Journal of the Assoc. for Comp. Machinery Vol. 34, No. 3, Cornell University, Ithaca, NY, 1987. [4] Romer K. , ”Time Synchronization in Ad Hoc Networks” , Technical Report, ETH Zurich, Switzerland, 1997. [5] Santivanez. C, and Stravakakis I., “Study of Various TDMA Schemes for Wireless Networks in the Presence of Deadlines and Overhead”, IEEE Journal on Selected Area of Comms, Vol 17, no 7, 1999. [6] Chee K.L., Lim J.G., Rao S.V. and Sivaprasad P.K., “A Simple and Efficient MAC for Implementation in a Wireless Sensor Network” TDMA Schemes for Wireless Networks in the Presence of Deadlines and Overhead”, Proc. Fifth Mobile Wireless Communications Networks Conference , October 2003, Singapore. [7] Lim J.G., Chee K. L. , Leow H. B., Chong Y. K. , Sivaprasad P.K., Rao S.V. “Implementing a Self-organizing Wireless Sensor Network: Experiences and Challenges”, Proc. Fifth Mobile Wireless Communications Networks Conference, October 2003, Singapore.

clock drift reduction for relative time slot tdma-based sensor networks

Electrical and Computer Engineering, Faculty of Engineering,. National ... Radio Systems Department, Communications and Devices Division, Institute for Infocomm Research, ... sensor networks to synchronize during startup and maintain.

379KB Sizes 1 Downloads 160 Views

Recommend Documents

Global Clock Synchronization in Sensor Networks - Computer Science
Dartmouth College. Hanover, NH 03755. Email: [email protected] .... The solution targets an ad hoc network in which two nodes may be out of range and ...

Global Clock Synchronization in Sensor Networks - Computer Science
... in a distributed system. Papers on synchronization in sensor networks include [6], [5], ... of our diffusion-based algorithm is to use local operations to achieve global ..... In a zone scheme, we can use the same method as Alg. 1 to first design

Global Clock Synchronization in Sensor Networks
sensor network: a node-based approach, a hierarchical cluster- .... The time of a computer clock is measured as a function of ...... ment of Homeland Security.

Real Time Communication in Sensor Networks
Sensor field. Task Manager. Node. User. Satellite. Internet and. Sink ... High failure rate of sensor nodes. ▫ Physical ... Uses the concept of 'speed' to achieve.

Real Time Communication In Sensor Networks
Wireless Sensor networks represent a new generation of Real-time systems with ... biological detection, domestic security systems like intruder detection ...

Using Recurrent Neural Networks for Slot Filling in Spoken ... - Microsoft
two custom SLU data sets from the entertainment and movies .... searchers employed statistical methods. ...... large-scale data analysis, and machine learning.

WIRELESS SENSOR NETWORKS FOR MEDICAL SERVICE
concerning the involvement of WSNs in bio-medical service is ... sors is to replace existing wired telemetry systems for ... consequence management needs.

WIRELESS SENSOR NETWORKS FOR MEDICAL SERVICE
Abstract: The present work surveys and classifies various applications of the Wireless Sensor Networks. (WSNs) technology in bio-medical service. A review.

Communication–aware Deployment for Wireless Sensor Networks
which is the case for many sensor network applications in the environmental ... example for an environmental monitoring application scenario (temperature ...

Sensor Networks for Monitoring Traffic
Aug 5, 2004 - traffic monitoring system using wireless sensor networks that offers high ... P. Varaiya is Professor in Electrical Engineering and Computer ...

Using Recurrent Neural Networks for Slot Filling in Spoken ... - Microsoft
experiments on the well-known airline travel information system. (ATIS) benchmark. ... The dialog manager then interprets and decides on the ...... He received an. M.S. degree in computer science from the University .... He began his career.

Real-time Tracking for Sensor Networks via SDP and ...
May 26, 2008 - We will use a new proposed further relax- ation of SDP approach[7] to solve the first stage localization problem, and use gradient method.

Real-time Tracking for Sensor Networks via SDP and ...
ally given dynamic data concerning the Euclid- ean distance between the sensors. Usually the distance is known between two sensors if they are close enough. During the tracking process, the set of the pairs of sensors whose distance are known may cha

Sensor Data Cryptography in Wireless Sensor Networks - IEEE Xplore
IEEE TRANSACTIONS ON INFORMATION FORENSICS AND SECURITY, VOL. 3, NO. 2, JUNE 2008. 273. Sensor Data Cryptography in. Wireless Sensor ...

The Next Generation of Sensor Node in Wireless Sensor Networks
good choice for a battery-limited device likes sensor node. This paper ... Index Terms—Wireless sensor network, Dynamic Partial Reconfigurable, FPGA.

Sensor placement in sensor and actuator networks
sor placement in wireless sensor and actuator networks (WSAN). One or more ..... This scheme has obvious advantage over the algorithms in [MXD+07] in mes-.

Recurrent Neural Networks for Noise Reduction in Robust ... - CiteSeerX
duce a model which uses a deep recurrent auto encoder neural network to denoise ... Training noise reduction models using stereo (clean and noisy) data has ...

An Online Prediction Framework for Sensor Networks
Keywords: Wireless Sensor Networks, Data. Gathering ... These algorithms use in-network data aggregation ..... W. Hong, "TAG: a Tiny AGgregation Service.

Designing A Secure Reliable File System for Sensor Networks
1. INTRODUCTION. A wireless sensor network is composed of sensor nodes that have ...... Sense-and-Respond Systems, Applications and Services. (2005) ...

STCP: A Generic Transport Layer Protocol for Wireless Sensor Networks
Dept. of Computer Science. University of ... port layer protocol for energy-constrained sensor networks. We ... SYSTEM MODEL .... The nodes maintain a buffer.

Wireless Sensor Networks for Habitat Monitoring
[9] D. Estrin, R. Govindan, J. S. Heidemann, and. S. Kumar. Next century challenges: Scalable coordination in sensor networks. In Mobile Computing and Networking, pages 263–270, 1999. [10] K. Fall. Delay-tolerant networking for extreme environments

Wireless Mobile Ad-hoc Sensor Networks for Very ... - Semantic Scholar
proactive caching we significantly improve availability of sensor data in these extreme conditions ... farmers over the web interface, e-mail, or post and stored in a.

Wireless Mobile Ad-hoc Sensor Networks for Very ...
{mvr, bzw}@cs.nott.ac.uk. T. Page 2. is typically archived in a powerful server geographically ... the pre-determined powerful servers in the labs e.g. The Great.