Basics of real-time measurement, control, and communication using IEEE 1588: Part 3

John Eidson, Agilent Technologies

January 14, 2008

John Eidson, Agilent Technologies

The role of the PTP boundary clock
PTP uses a device called a boundary clock to logically segment a network into a minimum spanning tree, thus reducing cyclic graphs, as shown in Figure 3.3 above, to acyclic graphs as illustrated in Figure 3.4 below. This is accomplished by removing one or more communication links, in this case links C and E.

This network segmentation is implemented in PTP by means of an algorithm called the best master clock algorithm. This is a modified spanning tree algorithm, and operates based on information contained in the Sync messages.

Figure 3.4. Topology of Figure 3.3 pruned by the boundary clocks

In Figure 3.4, clock-5 is presumed to be the best clock in the system. The best clock in the system is termed the grandmaster clock in IEEE 1588. PTP places the grandmaster clock, in this case clock-5, at the root of the minimum spanning tree. Branch points in the tree occur only at boundary clocks. The actual PTP topology is determined by the state of each clock port in the system.

PTP defines a number of states for each port of a clock. Ordinary clocks have a single port, while boundary clocks have multiple ports. The states relevant to this discussion are master, slave, and passive, indicated in Figures 3.4 above and 3.5 below by M, S, and P in the boxes representing the various clocks.

In the example of Figure 3.4, all four ports of the grandmaster clock, clock- 5, are in the master state. The single port of each ordinary clock directly connected to clock-5 is in the slave state, for example, clock-9 connected by path L.

The PTP spanning tree algorithm then prunes the network so that the number of boundary clocks between any ordinary clock and the grandmaster is reduced to a minimum. This is done in a completely distributed manner by the PTP algorithm executing independently on the remaining boundary clocks, i.e., clock-6 and clock-3 in this example.

These boundary clocks place one or more of their ports in the passive state, with the single port closest to the grandmaster in the slave state. Synchronization takes place only between pairs of clock ports in which one port is in the master state and the other is in the slave state.

The passive state is used by PTP to create the spanning tree. Thus, in Figure 3.4, the ports of clock-3 connected to paths C and E are in the passive state.

Figure 3.5. Topology of Figure 3.3 with two grandmaster clocks

The spanning tree algorithm works differently if there are two or more clocks in the system that are determined to be equivalent and, in addition, are accurately traceable to UTC. Figure 3.5 above illustrates this topology.

In this example, clock-8 and clock-12 are both designated as grandmaster clocks. The algorithm will then logically segment the network into disjoint subnetworks by subnetworks will contain exactly one grandmaster clock. In this example, both clock-6 and clock-3 have ports in the passive state, effectively removing paths E, D, and H from the network seen by PTP.

The internal architecture of a boundary clock is illustrated in Figure 3.6 below. The figure shows a three-port boundary clock. Each port is effectively serviced by a multiplexer that separates PTP traffic from all other network traffic.

Figure 3.6. Internal view of a boundary clock

Non- PTP traffic is directed to the usual switch or router functionality, while PTP traffic is directed to the block labeled "IEEE 1588 Functions" that implement the PTP boundary clock functions. This block maintains a separate section for each port, to allow each port to be in a different state.

Generally, there is a single clock in the PTP block serving all ports. If one of the ports is in the slave state, then this clock will synchronize to a master clock connected to that port. If the clock in the boundary clock is selected as the grandmaster, then clocks connected to any of its ports will generally synchronize to the internal clock of the boundary clock.

The exception to this is if one of the boundary clock ports, or the port of a clock connected to a boundary clock port is in the passive state for the purpose of segmenting the network, as shown in Figure 3.5 earlier, where

1) Clock-11 synchronizes to clock-12,
2) Clock-6 (the internal clock of boundary clock-6) synchronizes to clock-12 via the port on clock-6 that is in the slave state,
3) Clock-10 synchronizes to the internal clock of boundary clock-6 via a port on clock-6 that is in the master state, and
4) Clock-6 does not synchronize to clock-5 because the port on clock-6 servicing link-H is in the passive state.

One of the key features of a boundary clock is that it does not forward Sync, Delay Req, Follow Up, or Delay Resp messages. Instead, each port of a boundary clock intercepts these four message types.

To devices connected to each of these ports, the ports appear as an ordinary clock. However, the timestamps issued by the ports are based on the internal clock of the boundary clock, thus creating the clock hierarchy.

A boundary clock will forward management messages so that a complex network of clocks may be managed using the multicast communication model. This forwarding is limited to a finite number of boundary clock retransmissions by a field in the management message. This feature is provided to contain the management messages within the IEEE 1588 system.

< Previous
Page 2 of 3
Next >

Loading comments...

Most Commented

  • Currently no items

Parts Search Datasheets.com

KNOWLEDGE CENTER