04077944.pdf

download 04077944.pdf

of 6

Transcript of 04077944.pdf

  • 7/30/2019 04077944.pdf

    1/6

    I E E E I S I E 2 0 0 6 , J u l y 9 - 1 2 , 2 0 0 6 , M o n t r e a l , Q u e b e c , C a n a d a

    N TP versus PTP i n Com puterN etw orks ClockSynchronizationT e o d o r N e a g o e , A r r o w E l e c t r o n i c s , M o n t r e a l tgo rcom

    V a l e n t i n C r i s t e a , U n i v e r s i t y P o l i t e h n i c a , B u c h a r e s tvaL o g i c a B a n i c a , U n i v e r s i t y o f P i t e s t i , R o m a n i a o i iRoAbstractT r u s t e d a n d p r e c i s e t i m e s o u r c e s a r er e q u i r e d i n c o m p u t e r n e t wo r k s a n d I n t e r n e tf o r v a r i o u s r e a s o n s : t i m e s t a m p s f o re l e c t r o n i c d o c u m e n t s , o n l i n e t r a n s a c t i o n s ,s t o r a g e a n d d o c u m e n t r e t r i e v a l , e l e c t r o n i cm a i l , m u l t i m e d i a a p p l i c a t i o n s a n d manyo t h e r s . A l s o , t h e d e m a n d f o r E t h e r n e t a s ar e a l - t i m e c o n t r o l n e t w o r k i s i n c r e a s i n g , a sm a n u f a c t u r e r s r e a l i z e t h e b e n e f i t s o fe m p l o y i n g a s i n g l e n e t w o r k t e c h n o l o g ya c r o s s t h e p l a n t . F o r c o n t r o l a n dm e a s u r e m e n t a p p l i c a t i o n s , t h e n e e d o f a na c c u r a t e d i s t r i b u t i o n - w i d e s e n s e o f t i m e i se v e n m o r e s t r i n g e n t t h a n r e g u l a ra p p l i c a t i o n s . T h i s p a p e r i s c o m p a r i n g t w oc l o c k s y n c h r o n i z a t i o n p r o t o c o l s , t h eN e t w o r k T i m e P r o t o c o l a n d t h e I E E E - 1 5 8 8P r e c i s i o n T i m e P r o t o c o l . I t g i v e s a no v e r v i e w o f s y n c h r o n i z a t i o n m e t h o d s b y t h et i m e s t a m p i n g e m p l o y e d i n I P - b a s e d r e a l -t i m e a p p l i c a t i o n s l o o k i n g a t t h e p o s s i b l es o u r c e s o f e r r o r s a s w e l l a s t h e a c h i e v a b l ep e r f o r m a n c e o f t h e t w o s t a n d a r d s .1.Clock Synchronization protocolsC l o c k s y n c h r o n i z a t i o n a n d t i m e d i s t r i b u t i o nh a v e b e e n p a r t o f c o m m u n i c a t i o n n e t w o r k sf r o m t h e b e g i n n i n g . C u r r e n t l y , t h ed i s t r i b u t i o n o f t i m e i n f o r m a t i o n i s a c h i e v e dt h r o u g h t h e u s e o f r a d i o s i g n a l s , t e l e p h o n el i n e s o r d a t a c o m m u n i c a t i o n n e t w o r k s , s u c ha s I n t e r n e t [ 1 ] . R a d i o b a s e d p r o t o c o l s a r ee x p e n s i v e a s t h e y n e e d a g r e a t amount o fh a r d w a r e e q u i p m e n t . D e s p i t e t h i s , t h e y a r es t i l l l a r g e l y u s e d a n d t h e m o t i v a t i o n i s t h et r u s t w o r t h i n e s s o f t h e t i m e s o u r c e .I n t h e TDM t e l e p h o n e n e t w o r k s ,s y n c h r o n i z a t i o n i s a p h y s i c a l l a y e rp a r a m e t e r t h a t i s d e s i g n e d t o m e e t c e r t a i np e r f o r m a n c e s t a n d a r d s [ 9 ] . I n o r d e r t o u s et h e s e l i n e s t o a c h i e v e c l o c k s y n c h r o n i z a t i o n ,i t i s n e c e s s a r y t o e s t a b l i s h a d i a l c o n n e c t i o n

    t h a t may b e a l o n g d i s t a n c e c a l l s o , n o te c o n o m i c a l l y i n many a p p l i c a t i o n s .T o d a y ' s d a t a c o m m u n i c a t i o n n e t wo r k sb a s e d o n t h e T C P / I P p r o t o c o l a r e f o u n de v e r y w h e r e s o , i t b e c a m e n a t u r a l l y t o u s et h e m a s t h e c o m m u n i c a t i o n medium i n t i m es y n c h r o n i z a t i o n . T i m e k e e p i n g v i a t h eI n t e r n e t h a s b e c o m e a p o p u l a r s e r v i c e ,e x t e n d i n g t o h u n d r e d s o f t h o u s a n d s p u b l i cs e r v e r s a n d c l i e n t s i n many c o u n t r i e s a l lo v e r t h e w o r l d [ 1 1 ] . S e v e r a l c l o c ks y n c h r o n i z a t i o n p r o t o c o l s w e r e d e v e l o p e do v e r t i m e a n d among t h e m t h e f o l l o w i n g sc a n b e c i t e d : T i m e P r o t o c o l , D a y t i m eP r o t o c o l , N e t w o r k T i m e P r o t o c o l ( N T P ) a n dS i m p l e N e t w o r k T i m e P r o t o c o l ( S N T P ) [ 1 ] .2 . N etw ork T i m e P rotoco 1N e t w o r k T i m e P r o t o c o l ( N T P ) i s o n e o f t h em o s t p o p u l a r p r o t o c o l s u s e d f o r I n t e r n e tt i m e s y n c h r o n i z a t i o n . V e r s i o n 3 o f t h ep r o t o c o l w a s d e v e l o p e d b y D a v i d M i l l s i n1 9 9 2 a n d i s s p e c i f i e d i n I E T S RFT 1 3 0 5 .V e r s i o n 4 s t a r t e d a s S i m p l e N e t w o r k T i m eP r o t o c o l ( S N T P v 4 - TFC 2 0 3 0 ) a n d i s s t i l lu n d e r d e v e l o p m e n t . T h e b a s i c d i f f e r e n c ec o m p a r e d t o v e r s i o n 3 i s t h e h e a d e rs t r u c t u r e t h a t a c c o m m o d a t e s I P V 6a d d r e s s i n g [ 9 ] .T h e NT P p r o t o c o l i s u s e d t o a c h i e v e c l o c ks y n c h r o n i z a t i o n b e t w e e n a t r u s t e d t i m e -s e r v e r a n d i t ' s c l i e n t s . On a L o c a l A r e aN e t w o r k , w i t h o u t t o o much n e t w o r ke q u i p m e n t s u c h a s s w i t c h e s a n d r o u t e r s i tc a n a c h i e v e a p r e c i s i o n o f t e n s o fm i l l i s e c o n d s . A m a s s i v e s u r v e y o f t h ep r o t o c o l i n t h e g l o b a l I n t e r n e t r e v e a l e d t h a tm o s t NT P c l o c k s a r e w i t h i n 2 1 m s o f t h e i rs y n c h r o n i z a t i o n s o u r c e s a n d a l l a r e w i t h i n29ms on a v e r a g e [ 1 1 ] .

    1 - 4 2 4 4 - 0 4 9 7 - 5 / 0 6 / $ 2 0 . 0 0 2 0 0 6 I E E E 3 1 - 7

  • 7/30/2019 04077944.pdf

    2/6

    tFr- e f e r e n c e mt r a t u m O C l o c kS t r a i t u m 1

    S t r a t u m 2 S e r v e r S e - r v e r e H r-

    s e n d s b a c k t o t h e c l i e n t , t h e N T P _ r e s p o n s ew i t h t h e o r i g i n a t e t i m e s t a m p S T 2 .C l i e n t

    C T 1

    C T 2S t r a t u m- - .E v e r

    S t r a t u m ( I +1 )erer S e r v e r S e r v e r

    S e r v e r

    N T P _ R e s p

    T i m e

    S T 1

    S T 2R e q u e s tP r o c e s s i n g

    T i m eFigure 2 NTP Requestand Response

    Figure 1TypicalNTP H ierarchyT h e s y n c h r o n i z a t i o n a r c h i t e c t u r e u s e s as t r a t u m c o n c e p t , t h a t i s , a h i e r a r c h i c a lm o d e l ( t r e e t y p e ) w i t h e a c h s e r v e r o n o n el e v e l ( s t r a t u m ) s e r v i n g a s a t i m e s e r v e r t ol o w e r l e v e l s . P r i m a r y s e r v e r s a r e s e t a t t h er o o t o f t h e t r e e a s s t r a t u m 1 a n d a r es y n c h r o n i z e d t o e x t e r n a l c l o c k r e f e r e n c es o u r c e s s u c h a s n a t i o n a l s t a n d a r d s o r o n - s i t ea t o mi c s t a n da r d c l o c k s ( s t r a t u m o ) . E a c hf o l l o w i n g l e v e l t o w a r d s t h e l e a v e s , h a s as t r a t u m o n e h i g h e r t h a t t h e p r e c e d i n g l e v e la n d t h e maximum a l l o w e d v a l u e f o r t h es t r a t u m i s 1 5 ( F i g u r e 1 ) .

    2 . 1 P r o t o c o l I m p l e m e n t a t i o nT h e b a s i c s y n c h r o n i z a t i o n p r i n c i p l e i s t h a te a c h c l i e n t s e n d s p e r i o d i c r e q u e s t s t o a s e t o ft i m e - s e r v e r s t h a t r e s p o n d w i t h t h e i r l o c a lt i m e s t a m p . T h e l i s t o f s u i t a b l e s e r v e r s i sm a i n t a i n e d i n e a c h c l i e n t a n d i s u p d a t e dp e r i o d i c a l l y . I n t e r n a l a l g o r i t h m s e v a l u a t et h e t i m e s t a m p s f r o m a l l s e r v e r s i n o r d e r t os e l e c t t h e b e s t s e r v e r , w i t h t h e l o w e s ts t r a t u m a n d s y n c h r o n i z a t i o n d i s t a n c e ,w h i c h w i l l b e u s e d f o r s e t t i n g t h e c l o c ku p d a t e .T h e t i m e o f f s e t i s c a l c u l a t e d f r o m ac o l l e c t i o n o f f o u r t i m e s t a m p s ( t w o f r o m t h es e r v e r a n d t w o f r o m i t s o w n ) ( F i g u r e 2 ) .A C l i e n t , s e n d s a n N T P _ r e q u e s t m e s s a g et h a t c o n t a i n s t h e o r i g i n a t e t i m e s t a m p C T 1( C l i e n t T i m e s t a m p ) . Upon r e c e i v i n g t h eN T P _ r e q u e s t , t h e S e r v e r g e n e r a t e s t h er e c e i v e t i m e s t a m p S T 1 ( S l a v e T i m e s t a m p ) .A f t e r p r o c e s s i n g t h e r e q u e s t , t h e s e r v e r

    T h e c l i e n t r e c e i v e s t h e N T P r e s p o n s e a n dg e n e r a t e s t h e r e c e i v e t i m e s t a m p C T 2 .T h e f o l l o w i n g c a l c u l a t i o n s a r e p e r f o r m e d a tt h e C l i e n t a n d S l a v e l e v e l .ST1=CT1+D c s + c s ( 1 )w h e r e D C S i s t h e n e t w o r k d e l a y b e t w e e nc l i e n t a n d s e r v e r a n d O c s i s t h e c l o c k o f f s e to f t h e c l i e n t w i t h r e f e r e n c e t o t h e s e r v e r .CST2 =82 + D s c + 0 S C ( 2 )w h e r e D s c i s t h e n e t w o r k d e l a y b e t w e e ns e r v e r a n d c l i e n t a n d o S C i s t h e c l o c k o f f s e to f t h e s e r v e r w i t h r e f e r e n c e t o t h e c l i e n t .A d d i n g ( 1 ) a n d ( 2 ) a n d b e c a u s e 0 c s = - o s c t h er o u n d t r i p d e l a y i s :D s c +DC S= ( S T , 1 - C i T 1 ) + ( C T 2 -S T 2 ) ( 3)S u b t r a c t i n g ( 2 ) f r o m ( 1 ) a n d a s s u m i n g t h esame d e l a y , D c s = D s c , t h e o f f s e t i s :

    ( S T , r 1 - C T i 1 ) - ( C T 2 - 8 S T 2 )cs- 2 ( 4 )NT P i s b u i l t o n U D P / I P a n d i t si m p l e m e n t a t i o n i s p u r e s o f t w a r e ,t i m e s t a m p s b e i n g t a k e n a t t h e a p p l i c a t i o nl e v e l .

    3 1 8

  • 7/30/2019 04077944.pdf

    3/6

    2 . 2 P o s s i b l e S o u r c e s o f E r r o r i n NT PS e v e r a l f a c t o r s c o u l d a f f e c t t h e t i m i n gq u a l i t y a n d o f f s e t / d e l a y c a l c u l a t i o n s :

    * A s y m m e t r i c p r o p a g a t i o n d e l a y sb e t w e e n c l i e n t a n d s e r v e r ;* F l u c t u a t i o n s i n n e t w o r k p r o t o c o ls t a c k b e t w e e n t h e a p p l i c a t i o n l e v e la n d p h y s i c a l c o n n e c t i o n ;T i m e s t a m p m e a s u r e m e n t e r r o r s ;* C l o c k o s c i l l a t o r s t a b i l i t yE a c h NT P s e r v e r , m a i n t a i n s i t s l o c a l c l o c ko f f s e t a n d r o u n d t r i p d e l a y , r e l a t i v e t o t h ep r i m a r y r e f e r e n c e s o u r c e l o c a t e d a t t h e r o o to f t h e s y n c h r o n i z a t i o n t r e e . T h e r e f o r e , w h e na c l i e n t s e n d s a n N TP r e q u e s t b e f o r es e n d i n g a r e s p o n s e w i t h t i me s t a m p s , t h es e r v e r a d d s i t s a c c u m u l a t e d e r r o r s f r o m t h et i m e i t s c l o c k w a s l a s t u p d a t e d . T h u s t h ec l o c k o f f s e t a n d r o u n d t r i p d e l a y i n c r e a s e s a st h e s t r a t u m l e v e l i n c r e a s e s f r o m t h e p r i m a r yr e f e r e n c e s o u r c e .

    2 . 3 NT P A c h i e v a b l e P e r f o r m a n c eTwo i n d i c a t o r s a r e i m p o r t a n t w h e ne v a l u a t i n g a s y n c h r o n i z a t i o n p r o t o c o l : t i m eo f f s e t , m e a s u r e d b y t h e c l i e n t r e l a t i v e t o i t st i m e - s e r v e r a n d t h e t i m e o f f s e t , m e a s u r e d b yt h e s e r v e r r e l a t i v e t o t h e p e e r s e r v e r f o r e a c ha s s o c i a t i o n . A c c o r d i n g t o t h e s t a n d a r d , a nNT P c l i e n t i s s y n c h r o n i z e d w i t h t h e s e r v e r i ft h e t i m e o f f s e t s a r e w i t h i n 1 2 8 m s . T h e l o c a lc l o c k i s a d j u s t e d g r a d u a l l y i n s m a l l s t e p s i ft h e o f f s e t i s l e s s t h a n 1 2 8 m s . F o r o f f s e t sl a r g e r t h a n 1 2 8 m s , t h e s y n c h r o n i z a t i o np r o c e s s may t a k e l o n g e r o r n e v e r h a p p e n s .T h e a l g o r i t h m r e s e t s o r t h e w h o l e p r o c e s sr e b o o t s w h e n t h e c l o c k s d i f f e r e n c e i s g r e a t e rt h a n l o o o s .I n m o s t NT P i m p l e m e n t a t i o n s , S t r a t u m 1 i sl o c a t e d s o m e w h e r e i n t h e I n t e r n e t , S t r a t u m2 n e a r t h e g a t e w a y , w i t h S t r a t u m 3 a n dS t r a t u m 4 a t t h e L o c a l A r e a N e t w o r k l e v e l .I n t h i s c o n f i g u r a t i o n , p e e r - t o - p e e r t i m eo f f s e t w e r e f o u n d w i t h a mean v a l u e o f8 . 2 m s , m e d i a n o f 1 . 8 m s a n d s t a n d a r dd e v i a t i o n o f 1 8 m s . D i s p e r s i o n t o t h e r o o t , o rt h e p r i m a r y s e r v e r w a s f o u n d t o b e w i t h amean v a l u e o f 8 8 m s , m e d i a n o f 3 o m s a n dd e v i a t i o n o f 1 7 5 m s . P u b l i s h e dm e a s u r e m e n t s i n d i c a t e t h a t t h e o f f s e t o fS t r a t u m 4 b a s e d NT P c l i e n t f r o m d i f f e r e n tS t r a t u m 1 s e r v e r c l o c k s i n t h e I n t e r n e t w o u l db e o f t h e o r d e r o f i o o m s [ 9 ] .

    A s t u d y c o n d u c t e d b y M i l l s o n t h e I n t e r n e tr e v e a l e d t h a t p e e r - t o - p e e r t i m e o f f s e t s f o rs e r v e r s u s i n g t h e NT P p r o t o c o l h a d ac u m u l a t i v e d i s t r i b u t i o n f u n c t i o n w h e r e t h em e d i a n i s 2 0 . 1 m s a n d mean 2 8 . 7 m s [ 1 1 ] .3. P recision T i m e P ro t o co lI E E E 1 5 8 8 i s a S t a n d a r d f o r P r e c i s i o n C l o c kS y n c h r o n i z a t i o n P r o t o c o l f o r N e t w o r k e dM e a s u r e m e n t a n d C o n t r o l S y s t e m s [ 1 ] .I t i s a l s o k n o w n a s P r e c i s i o n T i m e P r o t o c o l[ P T P ] a n d i s u s e d f o r t i m e / c l o c ks y n c h r o n i z a t i o n i n p a c k e t - b a s e d n e t w o r k st h a t s u p p o r t m u l t i c a s t i n g . A s t h e names t a t e s , t h i s s t a n d a r d w a s o r i g i n a l l yi n t r o d u c e d f o r t e s t i n g a n d a u t o m a t i o ni n d u s t r y , t o a c h i e v e s y n c h r o n i z a t i o na c c u r a c i e s i n t h e o r d e r o f s u b m i c r o s e c o n d s .L a t e r o n , i t g a i n e d p o p u l a r i t y a n d s e v e r a lo t h e r g r o u p s a r e s h o w i n g i n t e r e s t ,t e l e c o m m u n i c a t i o n , e l e c t r i c a l p o w e rd i s t r i b u t i o n a n d m i l i t a r y a p p l i c a t i o n s [ 8 ] .T h e b a s i c p r i n c i p l e i s t h a t t h e m o s t p r e c i s ec l o c k o n t h e n e t w o r k s y n c h r o n i z e s a l l o t h e ru s e r s . A g r a n d m a s t e r c l o c k i s l o c a t e d a t t h er o o t o f t h e h i e r a r c h y a n d i s s e l e c t e d t h r o u g hs o - c a l l e d b e s t m a s t e r c l o c k a l g o r i t h m , b a s e do n t h e s o u r c e o f t i m e i t i s c o n n e c t e d t o [ 4 ] .A PTP s y s t e m i n c l u d e s s e v e r a l m a s t e r s ,s e r v i n g g r o u p s o f l o c a l c l o c k s o r s l a v e sF i g u r e 3 .S t r a t u m 1

    S t r a t u m 2

    S t r a t u m 3

    R e f e r e n c eC l o c k

    G r a n d

    S t r a t I u m 4 I - . -1 5 8 8 C l o c k 1 5 8 8 C l o c k

    Figure 3 M aster-S l a v e hierarchy i nT EE 1588

    PTP u s e s s t r a t u m n u m b e r s s i m i l a r t o NT Pa n d c l o c k i d e n t i f i e r s t o d e s c r i b e t h e q u a l i t yo f a p a r t i c u l a r c l o c k [ 9 ] . S t r a t u m 1 c l o c k si n c l u d e a n a t o m i c c l o c k , a GP S r e c e i v e r o r ah i g h p r e c i s i o n l o c a l o s c i l l a t o r . T h emaximum n u m b e r a l l o w e d f o r s t r a t u mb a s e d c l a s s i f i c a t i o n i s 2 5 6 w i t h o n l y f o u r

    3 3 9

    1 5 8 8 C l o c k 1 5 88 C l o c k

  • 7/30/2019 04077944.pdf

    4/6

    b e i n g c u r r e n t l y d e f i n e d i n t h e IEEE 1 5 8 8s t a n d a r d .A m a s t e r s e n d s c o n t i n u o u s m u l t i c a s tm e s s a g e s t o t h e s l a v e s w h i l e s l a v e s r e s p o n dt o t h e m a s t e r b y u n i c a s t m e s s a g e s .PTP i s b u i l t o v e r I P a n d U DP a n d u s e ss e v e r a l v a r i a b l e s t o c a l c u l a t e t h e o f f s e t a n dd e l a y o f a l o c a l c l o c k w i t h r e f e r e n c e t o t h em a s t e r . T h e p r o t o c o l u s e s b a s i c a l l y f o u rm e s s a g e s : S y n c , Folbw _U p , D e l a y _ R e q u e s ta n d D e ] a y _ R e s p o n s e b e t w e e n a m a s t e r a n ds l a v e s . S y n c a n d D e ] a y _ R e q u e s t a r e u s e d f o rt i m e s t a m p s , w h i l e t h e o t h e r t w o c a r r y t h ep r e c i s e t i m e s t a m p s f r o m t h e m a s t e r ,r e s p e c t i v e t h e s l a v e .3 . 1 P r o t o c o l i m p l e m e n t a t i o n

    E v e r y s l a v e s y n c h r o n i z e s t o i t ' s m a s t e r ' sc l o c k , b y e x c h a n g i n g s p e c i f i c m e s s a g e s . T h ePTP p r o t o c o l u t i l i z e s t w o p h a s e s f o r s e t t i n gt h e l o c a l c l o c k ( t i m e ) : 0 f s e t m e a s u r e m e n tp h a s e a n d D e l a y m e a s u r e m e n t p h a s e( F i g u r e 4 ) .

    M a s t e r

    e x a c t t i m e ( M T 1 ) o f t r a n s m i s s i o n o f t h eS y n c , m e a s u r e d a s c l o s e a s p o s s i b l e t o t h et r a n s m i s s i o n m e di a .A f t e r t h e f i r s t S y n c a n d F o l b w _ U pm e s s a g e s t h e S l a v e c o n c l u d e s t h e f o l l o w i n ge q u a t i o n :ST1= M T1+ 0 f F s e t + Delay ( 5 )T h e d i f f e r e n c e b e t w e e n t h e s l a v e t i m e S T 1a n d t h e m a s t e r t i m e M T i i s made u p o f b o t ht h e o f f s e t a n d t h e D e l a y .T o d e t e r m i n e t h e D e l a y , t h e s l a v e a t t i m eS T 2 , s e n d s a D e l a y _ R e q u e s t m e s s a g e t o t h em a s t e r t h a t i n r e t u r n s e n d s b a c k aD e l a y _ R e s p o n s e c o n t a i n i n g t h e p r e c i s e t i m ewhen D e l a y _ R e q u e s t h a s a r r i v e d a t h em a s t e r . A s a r e s u l t :M T 1 2 = S T 2 - 0 f F s e t + D e l a y ( 6 )B y a d d i n g ( 5 ) t o ( 6 ) a f E e t c a n c e l s o u t a n dwe c a n c a l c u l a t e t h e D e l a y a s s u m i n g i t i st h e s a m e i n b o t h d i r e c t i o n s :

    S l a v eC i T 1

    O f f s e tmeasurementp h a s e

    D e l a ymeasurement - Fp h a s e

    MT3F i n a l TS y n c h r o n i z a t i o n

    T i m e

    S y n c

    D e l a y _

    F o l l o w - U p

    De]ay - ( S T 1 - M T 1 ) + M T2-ST2)2S T 1( M T T 1 : )S T 2

    N o w , t h e o f f s e t c a n b e c a l c u l a t e d o n t h ef o l l o w i n g S y n c / F o l b w - U p m e s s a g ee x c h a n g e :O f F e t = S T 3 - M T3-Delay

    ( M T 2 )

    i S T 3i ( M V T 3 )i mei -

    Figure 4 0 ffsetand D elaym easurem en tD u r i n g t h e 0 f S e t m e a s u r e m e n t , t h e m a s t e rp e r i o d i c a l l y t r a n s m i t s s y n c m e s s a g e s t or e l a t e d s l a v e s u s i n g m u l t i c a s t i n g .T h e s e m e s s a g e s a r e s e n t a t p r e - d e f i n e di n t e r v a l s , b y d e f a u l t e v e r y 2 s e c o n d s . T h es y n c m e s s a g e c o n t a i n s t h e e s t i m a t e d t i m ew h e n t h e m e s s a g e w i l l l e a v e t h e m a s t e r .T h e m a s t e r m e a s u r e s t h e e x a c t t i m e o ft r a n s m i s s i o n M T ( M a t e r T i m e ) a n d t h es l a v e s m e a s u r e t h e e x a c t t i m e o f r e c e p t i o nS T ( S l a v e T i m e ) . O p t i o n a l l y , f o r h i g h l ya c c u r a t e s y n c h r o n i z a t i o n , t h e m a s t e r c a ns e n d a F o ] l w _ u p m e s s a g e t h a t c o n t a i n s t h e

    ( 8 )A t t h i s p o i n t s y n c h r o n i z a t i o n i s a c h i e v e d b ya d j u s t i n g t h e t i m e a t t h e s l a v e :NewST = 0ldST-O0ft-D e l a y ( 9 )T h e D e l a y m e a s u r e m e n t i s p e r f o r m e di r r e g u l a r l y a n d a t l a r g e r t i m e i n t e r v a l s t h e nt h e o f s e t m e a s u r e m e n t , i n o r d e r t o r e d u c et h e t r a f f i c o n t h e n e t w o r k .

    3 . 2 P o s s i b l e S o u r c e s o f E r r o r i n PTPS i m i l a r t o t h e NT P p r o t o c o l , o f f s e tm e a s u r e m e n t s a n d s y n c h r o n i z a t i o n a r ea f f e c t e d b y s e v e r a l f a c t o r s : n e t w o r k p r o t o c o ls t a c k d e l a y f l u c t u a t i o n s , n e t w o r k t e c h n o l o g ya r c h i t e c t u r e , c l o c k t i m e s t a m p a c c u r a c y a n dc l o c k o s c i l l a t o r s t a b i l i t y [ 5 ] .T i m e s t a m p s a r e m o r e a c c u r a t e i n PTPb e c a u s e o f t h e u s a g e o f t h e F o ] l w - U p a n d3 4 0

  • 7/30/2019 04077944.pdf

    5/6

    D e l a y _ R e s p o n s e m e s s a g e s t h a t c a r r y t h ee x a c t t i m e s t a m p s m e a s u r e d a s c l o s e a sp o s s i b l e t o t h e p h y s i c a l t r a n s m i s s i o n l i n e .A l s o , 1 5 8 8 u s e s t w o s e t s o f m e a s u r e m e n t sw i t h o n e ( s y n c ) e x e c u t e d m o r e o f t e n t h a nt h e o t h e r . When c o m p a r e d t o N T P , t r a f f i c i sa l m o s t d o u b l e i n a PTP b a s e d s y s t e m . T h i sc a n c a u s e p r o b l e m s o n l o w b a n d w i d t h l i n k s .T o o v e r c o m e t h e p r o b l e m , t h e 1 5 8 8s p e c i f i c a t i o n r e q u i r e s a c e r t a i n l o c a l c l o c ko s c i l l a t o r s t a b i l i t y t h a t w i l l a l l o w i t sm e s s a g e s t o b e s e n t a t much l a r g e r t i m ei n t e r v a l s .3 . 3 H a r d w a r e V e r s u s S o f t w a r e IEEE1 5 8 8 I m p l e m e n t a t i o n s

    A t t h e p r e s e n t t i m e t w o i m p l e m e n t a t i o n s o ft h e 1 5 8 8 PTP e x i s t i n t h e i n d u s t r y : s o f t w a r eo n l y i m p l e m e n t a t i o n s a n d h a r d w a r e -a s s i s t e d s o f t w a r e i m p l e m e n t a t i o n s [ 5 ] . I ns o f t w a r e o n l y i m p l e m e n t a t i o n ( F i g u r e 5 ) t h ew h o l e p r o t o c o l i s e x e c u t e d a t t h e a p p l i c a t i o nl e v e l , i n c l u d i n g t h e p r o c e s s i n g o f t h et i m e s t a m p s a n d c o n t r o l o f t h e R e a l T i m eC l o c k .

    m i l l i s e c o n d s , d e p e n d i n g o n t h e o p e r a t i n gs y s t e m [ 5 ] .G o i n g down o n t h e I E E E - 1 5 8 8 m e s s a g ep a t h , a n d p r o c e s s i n g t h e t i m e s t a m p a t t h ep h y s i c a l l a y e r , c o u l d l e a d t o g r e a t e ra c c u r a c y , i n t h e o r d e r o f t e n s o fn a n o s e c o n d s .H a r d w a r e a s s i s t m e t h o d s , g e n e r a t e a n dp r o c e s s t i m e s t a m p s a s c l o s e a s p o s s i b l e t ot h e t r a n s m i s s i o n m e d i a a n d t y p i c a l l yi n c o r p o r a t e o t h e r f u n c t i o n s l i k e h a r d w a r eR e a l T i m e C l o c k , P r o c e s s o r I n t e r f a c e , e t c .F i g u r e 6 p r e s e n t s a p r o p o s e d h a r d w a r ea s s i s t e d s o f t w a r e i m p l e m e n t a t i o n o f t h eI E E E 1 5 8 8 p r o t o c o l [ 4 ] .

    N e t w v o r kP r o t o c o lS t a c k ( O S )

    M i l I FP H P h y s i c a l W i r e

    F i g u re 5 I E E E 1 5 8 8 S o f t w are Im p l e m en t a t i o nT h e r e f o r e , i t y i e l d s t h e l e a s t a c c u r a c y , a s t h el a r g e s t amount o f e r r o r s i s i n t r o d u c e d i n t ot h e t i m e s t a m p , e s p e c i a l l y b e c a u s e o f t h ef l u c t u a t i o n s i n t h e n e t w o r k . T y p i c a l l y , i n as o f t w a r e i m p l e m e n t a t i o n , e r r o r s r a n g e i nt h e o r d e r o f h u n d r e d o f m i c r o s e c o n d s t o

    Figure 6 I EE E-1588 HW Im plem en t a t i o nT h e T i m e S t a m p U n i t ( T S U ) i s c o n n e c t e d a tt h e M I I i n t e r f a c e a n d i s r e s p o n s i b l e f o ri n s e r t i n g o r e x t r a c t i n g t h e T i m e S t a m p f r o mt h e IEEE 1 5 8 8 p a c k e t s a n d s e n d i t t o t h ep r o t o c o l t a s k . T h e HW R e a l T i m e C l o c k i sp r o g r a m m e d i n i t i a l l y b y t h e O p e r a t i n gS y s t e m a n d u p d a t e d b y t h e 1 5 8 8 s o f t w a r eb u t i t c o u n t s i n d e p e n d e n t l y , b a s e d o n t h eh a r d w a r e c l o c k o f t h e p r o c e s s o r .M o s t o f t o d a y ' s h a r d w a r e i m p l e m e n t a t i o n sa r e b a s e d o n FPGA c i r c u i t s c o n n e c t e d a t t h eMAC l e v e l o f t h e n e t w o r k i n t e r f a c e c a r d [ 7 ] .Some m a n u f a c t u r e r s a r e o f f e r i n g h a r d w a r ea s s i s t e d 1 5 8 8 i m p l e m e n t a t i o n s i n t h ep r o c e s s o r s i l i c o n . I n t e l ( C o r p o r a t i o n i s o n eo f t h e f i r s t o n e s w i t h t h e new I X P 4 6 5 f a m i l y o f x S c a l e n e t w o r k p r o c e s s o r s [ 5 ] .

    3 . 4 L i m i t a t i o n s a n d A c h i e v a b l eP e r f o r m a n c e i n PTPIEEE 1 5 8 8 d e f i n e s t w o s e p a r a t e t y p e s o fc l o c k s : o r d i n a r y c l o c k s , i n d e v i c e s t h a t h a v ea s i n g l e p o r t a n d b o u n d a r y c l o c k s i n d e v i c e ss u c h a s h u b s o r s w i t c h e s t h a t h a v e more

    3 5 1

    T . . j

  • 7/30/2019 04077944.pdf

    6/6

    t h a n o n e PTP p o r t [ 1 2 ] . T h e a c y c l i c t o p o l o g ys p e c i f i e d b y t h e s t a n d a r d ( n o m o r e t h a n o n em a s t e r c l o c k p e r c o m m u n i c a t i o n p a t h )r e p r e s e n t s a s i n g l e p o i n t o f f a i l u r e a n d mayl e a d t o l o s s o f s y n c h r o n i z a t i o n i n p a r t s o f t h en e t w o r k . A l s o , t h e I E E E 1 5 8 8 s t a n da r d d o e sn o t s p e c i f y d e t a i l s a b o u t r o b u s t n e s s o f c l o c ks y n c h r o n i z a t i o n . T h i n g s l i k e f a i l u r er e c o v e r y , t i m i n g p a t h s a n d r e d u n d a n c y o ft h e m a s t e r c l o c k s a r e l e f t t o i m p l e m e n t a t i o n .B e i n g a r e l a t i v e l y new s t a n d a r d i t w a s n o ty e t i m p l e m e n t e d a n d t e s t e d t o t h e f u l le x t e n t . H o w e v e r , c o m p a r e d t o N T P ,p r e l i m i n a r y d a t a s h o w s o n L A N s ,s y n c h r o n i z a t i o n s i n s u b - m i l l i s e c o n d r a n g ef o r s o f t w a r e i m p l e m e n t a t i o n s .On t h e o t h e r h a n d , h a r d w a r ei m p l e m e n t a t i o n s o f 1 5 8 8 f a l l i n s u b -m i c r o s e c o n d r a n g e f o r t h e s a m e t y p e o fn e t w o r k . E x p e r i m e n t s w i t h a n F P G A - b a s e dh a r d w a r e a s s i s t e d i m p l e m e n t a t i o n r e a l i z e db y A g i l e n t T e c h n o l o g i e s , o b s e r v e ds y n c h r o n i z a t i o n b e t w e e n a m a s t e r a n d as l a v e o n t h e s a m e LAN c a p a b l e o f k e e p i n gt i m e w i t h i n 2 o n s [ 1 7 .4 . C on c l u sin sC l o c k a n d t i m e s y n c h r o n i z a t i o n o nc o m p u t e r n e t w o r k s a n d I n t e r n e t i se x t r e m e l y i m p o r t a n t . T h i s p a p e r h a se x a m i n e d t w o t i m e s y n c h r o n i z a t i o np r o t o c o l s , NT P a n d PTP a n d c o m p a r e d t h e i ra r c h i t e c t u r e , p r o t o c o l i m p l e m e n t a t i o n ,s o u r c e s o f e r r o r a n d a c h i e v a b l ep e r f o r m a n c e .NT P i s w e l l e s t a b l i s h e d a n d i s w i d e l y u s e do n t h e I n t e r n e t . I t i s s a t i s f a c t o r y f o r manya p p l i c a t i o n s w i t h s y n c h r o n i z a t i o n s i nm i l l i s e c o n d s f o r L o c a l A r e a N e t w o r k s a n dh u n d r e d s o f m i l l i s e c o n d s f o r W i d e A r e aN e t w o r k s a n d I n t e r n e t . I t d o e s n ' t s a t i s f y t h emore s t r i n g e n t r e a l - t i m e m u l t i m e d i a o rc o n t r o l a p p l i c a t i o n s .PTP i s a r e l a t i v e l y new s t a n d a r d , e m b r a c e dm a i n l y b y t h e c o n t r o l a n d m e a s u r e m e n ti n d u s t r y a n d p r e l i m i n a r y t e s t s d e m o n s t r a t e da c h i e v a b l e s y n c h r o n i z a t i o n p e r f o r m a n c e o fs u b - m i c r o s e c o n d s i n L o c a l A r e a N e t w o r k s .H o w e v e r , I n t e r n e t c o m m u n i t y i s a l s oi n t e r e s t e d a n d t h e r e a r e p r o p o s a l s f o rm o d i f i e d v e r s i o n s o f t h e s t a n d a r d t o b ea d o p t e d i n M e t r o E n t e r p r i s e S o l u t i o n s [ 1 3 ] .A c o m b i n a t i o n o f t h e t w o s t a n d a r d s w i t hNT P o n t h e b a c k g r o u n d I n t e r n e t a n d PTP a tt h e L o c a l A r e a N e t w o r k l e v e l , may b e t h ei d e a l c o n f i g u r a t i o n .

    R eferences[ 1 ] J . d a S i l v a S . D i a s , R . F . C u s t o d i o , D . B .D e m e t r i o , C . R . De R o l t " R e l i a b l e C l o c kS y n c h r o n i z a t i o n f o r E l e c t r o n i c D o c u m e n t s " ,S a n t a C a t a r i n a S t a t e U n i v e r s i t y , 2 0 0 2 .[ 2 ] IEEE S t d . 1 5 8 8 - 2 0 0 2 , S t a n d a r d f o r aP r e c i s i o n C l o c k S y n c h r o n i z a t i o n P r o t o c o l f o rN e t w o r k e d M e a s u r e m e n t a n d C o n t r o lS y s t e m s , N o v e m b e r 2 0 0 2[ 3 ] S . B a l a s u b r a m a n i a n , K . R . H a r r i s a n d A .M o l d o v a n s k y " A F r e q u e n c y C o m p e n s a t e dC l o c k f o r P r e c i s i o n S y n c h r o n i z a t i o n u s i n gI E E E 1 5 8 8 a n d i t s A p p l i c a t i o n s t o E h t e r n e t "I E E E - 1 5 8 8 W o r k s h o p S e p t e m b e r 2 0 0 3 .[ 4 ] D i r k S . M o h l , " I E E E 1 5 8 8 - P r e c i s e T i m eS y n c h r o n i z a t i o n a s t h e B a s i s f o r R e a l T i m eA p p l i c a t i o n s i n A u t o m a t i o n " , WEB a r t i c l e .[ 1 ] P u n e e t S h a r m a , " H a r d w a r e A s s i s t e dIEEE 1 5 8 8 I m p l e m e n t a t i o n i n a N e x tG e n e r a t i o n I n t e l N e t w o r k P r o c e s s o r " ,I E E E - 1 5 8 8 C o n f e r e n c e , S e p t e m b e r 2 0 0 4 .[ 6 ] D a v i d L . M i l l s " N T P A r c h i t e c t u r e ,P r o t o c o l a n d A l g o r i t h m s " , U n i v e r s i t y o fD e l a w a r e , A u g u s t 2 0 0 4 .[ 1 ] J . G u i l f o r d , " D e s i g n o f a n F P G A - B a s e dH a r d w a r e I E E E - 1 5 8 8 I m p l e m e n t a t i o n " ,I E E E - 1 5 8 8 C o n f e r e n c e , S e p t e m b e r 2 0 0 5 .[ 8 ] D a v e T o n k s , " I E E E 1 5 8 8 i nT e l e c o m m u n i c a t i o n A p p l i c a t i o n s " , IEEEi 5 8 8 C o n f e r e n c e , S e p t e m b e r , 2 0 0 5 .[ g ] R a d h a T e l i k e p a l l i , " T e c h n i c a lA s s e s s m e n t o f S y n c h r o n i z a t i o n M e t h o d s i nI P n e t w o r k s f r o m Q u a l i t y o f E x p e r i e n c eP e r s p e c t i v e " , T R 4 1 . 4 / o 5 - 1 1 - o o 5 , 2005.[ i o ] T . N e a g o e , M . H a m d i , V . C r i s t e a" F r e q u e n c y C o m p e n s a t e d , H a r d w a r e I E E E -i 5 8 8 I m p l e m e n t a t i o n " , M o n t r e a l 2 0 0 6 .[ i l ] D . L . M i l l s , A . T h y a g a r j a n , B . C .H u f f m a n , " I n t e r n e t T i m e k e e p i n g A r o u n dt h e G l o b e " , U n i v e r s i t y o f D e l a w a r e , 2 0 0 2 .[ 1 2 ] P a u l a D o y l e , " I n t r o d u c t i o n t o R e a l -T i m e E t h e r n e t " , T h e E x t e n s i o n , V o l u m e 5 ,I s s u e 4 , J u l y - A u g u s t , 2 0 0 4 .[ 1 3 ] G l e n n A l g i e , " I E E E 1 5 8 8 p r o p o s a l f o rM e t r o E t h e r n e t E n t e r p r i s e S o l u t i o n s " ,N o r t e l N e t w o r k s , IEEE 1 5 8 8 W o r k s h o p ,S e p t . 2 0 0 3

    3 6 2