Motion control systems operating over Ethernet networks, such as EtherNet/IP, typically involve time-based operations, and if the devices on the network, such as motion controllers, I/O devices, and actuators, are not operating with synchronized clocks, these operations will fail.
The IEEE 1588 standard was developed to provide a method for ensuring a reliable, consistent time reference between devices operating over Ethernet networks.
IEEE 1588, officially titled IEEE Standard for a Precision Clock Synchronization Protocol for Networked Measurement and Control Systems, defines a protocol that enables “precise synchronization of clocks in measurement and control systems implemented with technologies such as networking communication, local computing, and distributed objects.” This protocol is commonly known as the Precision Time Protocol, or PTP.
Recall that Ethernet is non-deterministic, making it unsuitable for applications that require real-time communication or time synchronization. The IEEE 1588 Precision Time Protocol (released in 2002 and updated in 2008) was developed specifically for applications operating over non-deterministic Ethernet networks. It operates at layer 2 (the data link layer) of the network and overcomes Ethernet latency and jitter issues through hardware time stamping at layer 1 (the physical layer) of the network.
The ODVA adoption of IEEE 1588 is called CIP Sync. CIP Sync is a network extension to EtherNet/IP that makes it suitable for event sequencing and motion control applications by enabling EtherNet/IP to provide deterministic, real-time, performance.
Clock Types
IEEE 1588 PTP defines three clock types: ordinary, boundary, and transparent.
Ordinary: An ordinary clock functions as a node in the PTP network and has only one PTP port. Ordinary clocks can serve as master, slave, or grandmaster. (Note that it is the only clock type the can function as a grandmaster, which is explained below.)
Boundary: A boundary clock has more than one PTP port, with each port being a separate communication path on the PTP network. The boundary clock functions as a slave on one port and a master on another port. The master port synchronizes all the clocks connected downstream from the boundary clock, and the slave port synchronizes with the master clock located upstream.
Transparent: A transparent clock compensates for latency (delays, typically caused by switches) by inserting delay corrections into PTP packets. These clocks do not serve as nodes on the PTP network. Instead, they sit “between” the master and slave clocks to provide time correction to these devices. There are two types of transparent clock — end-to-end and peer-to-peer.
And end-to-end transparent clock uses messages between it and the master to determine network delay time. It then adds this delay to a correction field in the PTP package, and the slave uses this information to calculate the time difference between the slave and the master.
The peer-to-peer type of transparent clock can be more accurate than end-to-end type due to way it determines network delays. However, industrial applications almost exclusively use end-to-end transparent clocks due to interoperability limitations of peer-to-peer types.
Clock Roles
The basis of IEEE 1588 PTP functionality is the best master clock algorithm (BMCA) — a monitoring function that determines which clock on the network has the highest quality. This clock is referred to as the grandmaster clock, and all other clocks on the network are synchronized to the grandmaster. (The grandmaster is synchronized to UTC, often via GPS or CDMA.) The BMCA runs continuously and makes adjustments to the master clock assignment if the best master clock is no longer available or is no longer the best.
Slave clocks are synchronized to the master clock via bidirectional, multicast communications that occur at specified intervals (up to 10 per second). Synchronization involves exchanging messages between the master and slave, with each message time-stamped at the time of transmission and of receipt, and then sent back to its source. After several of these exchanges, each slave can estimate the round-trip delay time. This synchronization also allows information to be gathered about each clock’s behavior and detects any network issues.
Note that grandmaster, master, and slave are sometimes referred to as clock types. But more accurately, they are roles filled by the clocks.
The Precision Time Protocol defined in IEEE 1588 provides nanosecond accuracy to networked devices in industrial automation and processing applications. And it does so while requiring minimal bandwidth and low processing overhead.
Leave a Reply
You must be logged in to post a comment.