A Kalman Filter Approach To Clock Synchronization ...

9 downloads 2094 Views 517KB Size Report
Using the time-stamps, a slave element learns the relation between its own clock and the .... Section. 3 derives the state-space model for the networked clock.
Proceedings of the First IFAC Workshop on Estimation and Control of Networked Systems September 24-26, 2009, Venice, Italy

A Kalman Filter Approach To Clock Synchronization Of Cascaded Network Elements Chongning Na ∗ Ruxandra Lupas Scheiterer ∗ Dragan Obradovic ∗ Josef A. Nossek ∗∗ ∗ Siemens AG, Corporate Technology, Information and Communications, Munich Germany (e-mail: na.chongning.ext, ruxandra.scheiterer, [email protected]). ∗∗ Institute for Circuit Theory and Signal Processing, Technische Universit¨ at M¨ unchen, 80290, Munich, Germany (e-mail: [email protected].)

Abstract: The Precision Time Protocol specified by IEEE 1588 standard has been proved to be an appropriate network synchronization protocol. The PTP protocol is based on exchanging appropriate timing information, generated by time stamping according to the local clocks, between adjacent clocks. Using the time-stamps, a slave element learns the relation between its own clock and the master clock so that it can synchronize its time to the reference time provided by the master. Uncertainties, e.g., random stamping and quantization errors, greatly affect the synchronization precision. This paper presents a probabilistic state-space model which quantifies the uncertainties and represents the relation between the system variables. Then clock synchronization is posed as a state estimation problem and solved by using Kalman filter. The performance of this approach is verified by numerical results. Keywords: synchronization, Precision Time Protocol, state-space model, Kalman filter. 1. INTRODUCTION Clock synchronization is a basis for the proper functioning of process automation and control systems. Typically, each element of an automation system possesses an internal clock (quartz) which has to be synchronized with the clock of the a priori selected Master element. The Standard Network Time Protocol (NTP) (Mills (1989, 1994)), executed over Ethernet provides synchronization accuracy at the millisecond level, which is appropriate for processes that are not time critical. However, in many applications, for example base station synchronization or motion control, where only sub-microsecond level synchronization errors are allowed, a more accurate synchronization solution is needed. The Precision Time Protocol (PTP), delivered by the IEEE 1588 standard (IEEE (2002)) published in 2002 is a promising Ethernet synchronization protocol. It was enhanced by the transparent clock (TC) concept, introduced in Jasperneite et al. (2004), which has been adopted in IEEE 1588 version 2. After running the ”Best Master Algorithm”, which determines the so-called ”master” clock, messages carrying precise timing information are periodically transmitted by the master and propagated by the so-called ”slave” clocks after acquiring and updating the contained timing information. Intermediate bridges have to be ”IEEE-1588-conform”, i.e. are network components with known delay. ⋆ Sponsor and financial support acknowledgment goes here. Paper titles should be written in uppercase and lowercase letters, not all uppercase.

978-3-902661-52-4/09/$20.00 © 2009 IFAC

54

Factors that affect the synchronization quality achievable by PTP include the stability of oscillators, the resolution and precision of time stamping the messages, the frequency of sending synchronization messages, and the propagation delay variation caused by the jitter in the intermediate elements. Some analytical work has been presented in Scheiterer et al. (2009) to show the influence of these factors on the synchronization accuracy. It can be seen from the analytical results that stamping errors, including quantization error and stamping jitters, have very adverse effects because the errors introduced by different elements accumulate along the network. On the other hand, each clock in the network is a dynamic system. Clock synchronization can be formulated as a state estimation of dynamic systems. In this paper, we present a probabilistic state-space model which quantifies the uncertainties and represents the relation between system variables. Using this model, we translate the synchronization problem into the problem of estimating hidden state variables (the master time corresponding to a given slave time) given the observations (the time stamps associated with the IEEE 1588 messages). Kalman filtering algorithms are presented in Abubakari and Sastry (2008) and Bletsas (2003) to achieve end-to-end synchronization based on the NTP protocol. The authors of Auler and d’Amore (2007) presented a Kalman filter approach which tracks the rate of change of the offset between a pair of clocks. To our knowledge, most related works are only applied to a small number of devices and

10.3182/20090924-3-IT-4005.0047

1st IFAC NECSYS (NECSYS'09) Venice, Italy, September 24-26, 2009

Fig. 1. System model

Fig. 2. PTP messages

not in a cascaded networked system where the estimation error propagates and greatly degrades the synchronization accuracy at a remote slave element. As a consequence, they are not appropriate for synchronization with transparent clocks. The backbone of the paper is the probabilistic state-space model, based on which either centralized or distributed estimation methods can be developed. This paper presents an estimation method that is implemented in a centralized way. All the time stamps associated with the Sync messages are transmitted to a fusion center, where a Kalman filter is used to solve the state estimation problem. The solution is optimal in the sense of minimizing the mean square error. The results are then sent to the corresponding slave elements so that they can work out the relationship between their own clock and the master clock.

are propagated along the network. Quantities, certain or not, linked with the Sync message transmitted by the master at time t(k) are labelled by the index k. Upon the reception of a Sync message, slave n generates the time stamp T S(Snin(k)) according to its jittered reading of its own clock counter at the time of reception, where Snin (k) is the true slave counter state at this time. Each time a timestamp is read, a jitter ξ of known distribution is incurred, e.g. due to the quantizing effect of having to wait for the next rising edge of the logic circuitry. A time labelled by Sn (resp. M ) means ”measured in the local time of slave n (resp. master time)”; a hat on a symbol means ”estimate”. Time intervals measured by two different clocks will be called ”skewed”. To be able to add or subtract them from each other they have to be converted to the same time basis. To this end each slave determines its frequency offset to the master. The rate compensation factor (RCF, also ”rate ratio”) is defined as the frequency ratio of two clocks. We use RCFX/Y to denote the estimated frequency ratio between X and Y, i.e. RCFX/Y = fX /fY ideally.

Usually a distributed implementation of the state estimation is preferable, in order to avoid extra network traffic and the adverse effect of additional delays. However, the centralized method optimally exploits all available timing information, thus providing the best synchronization performance. Hence this centralized Kalman filtering yields a lower bound to the synchronization error achieved by any other synchronization algorithm that is based on the same state-space model. The paper is organized as follows. Section 2 introduces the IEEE 1588 peer-to-peer system model analyzed in this paper and briefly describes the PTP protocol. Section 3 derives the state-space model for the networked clock synchronization problem. Simulation results are shown in Section 4 to verify the performance of the state-space model and the Kalman filter. Finally, Section 5 provides conclusions. 2. THE PRECISION TIME PROTOCOL Fig. 1 shows a system with N + 1 cascaded elements connected in a line topology. The PTP has a master/slave structure. The first element is the time source, also called (grand)master, which provides the reference time to the rest N elements, called slave elements. Fig. 2 illustrates the messages defined in PTP for the time synchronization. The master element periodically sends Sync messages which carry the (time)counter state of the master clock M (k), stamped at the sending time, and

The received Sync message is forwarded to the next slave after a bridge delay BDn , which is recorded at each slave as the difference of the times stamped at reception and forwarding. The line delay LDn is the propagation time between the nth slave and its uplink element, and is estimated by using the ”line delay estimation process”, shown on the right in Fig. 2, where j indexes the line delay computation. This process uses 4 time-stamps: with periodicity ∆, slave n (the requester) sends a request message to slave n − 1 j and records its time of departure, T S(Sn,req out ). Node n − 1 (the responder) reports the two time-stamps of receiving the request message and transmitting the reply: j j T S(Sn−1,req in ) and T S(Sn−1,resp out ). The responder dej lay of node n− 1 is RDn−1 in absolute time, and is in local time: Sˆj = T S(S j ) − T S(S j ) (1) n−1,respD

n−1,resp out

n−1,req in

j T S(Sn,resp in )

of receiving the Node n records the time, desired reply, after a requester delay in node n time of: j j j Sˆn,reqD = T S(Sn,resp in ) − T S(Sn,req out )

(2)

To be able to subtract the skewed time intervals of (1) and (2), each element maintains an ”RCF peer” estimate, i.e. frequency ratio estimate to its predecessor, estimated via:

55

ID 717827

Title A Kalman Filter Approach To Clock Synchronization Of Cascaded Network Elements*

http://fulltext.study/article/717827

http://FullText.Study

Pages 6

Suggest Documents