PTP
PTP, known as Precision Time Protocol, or IEEE 1588v2, is a packet-dependent, highly accurate time synchronisation technology. PTP was originally developed to improve the time synchronisation capabilities of telecommunication systems. It is now used widely in mobile backhaul networks and distributed systems to make sure that clocks stay accurately coordinated within IP networks as demand increases.
PTP makes sure that the master clock and the client clocks stay in sync by sending packets with timestamps. This works really well in mobile backhaul networks, and thanks to new hardware timestamping tech, it can now sync to the nanosecond. That makes it one of the most precise time synchronisation methods out there.
How does PTP work?
Implementing PTP time synchronisation in a network is roughly divided into the following steps:
Synchronisation mode selection: PTP supports a variety of synchronisation modes, such as E2E (end-to-end) mode and P2P (point-to-point) mode. Short paths are suitable for E2E mode and long paths are suitable for P2P mode.
Establishment of master-slave relationship: PTP firstly establishes a master-slave relationship by exchanging messages: Master Clock periodically sends Sync messages and records the sending time t1; Slave Clock records the receiving time t2 after receiving Sync messages, thus completing the initial time synchronisation between the two.
Delay Measurement: PTP needs to measure and compensate the propagation delay in the network. The Master Clock sends a Delay_Req message and the Slave Clock receives it and sends a Delay_Resp message; the Master Clock records the time of receiving the Delay_Resp, t3. The base time of the Slave Clock is adjusted by calculating the difference between t1, t2 and t3.
Time Offset Calculation: the PTP further uses the delay information to calculate the time offset. Assuming symmetric network latency, with four timestamps (t1, t2, t3, and t4, where t4 is the time when the slave clock sends the Delay_Resp), PTP can estimate the time offsets of the master and slave clocks and calibrate the slave clocks to the master clock synchronisation state.
Features of PTP
PTP has significant advantages in high-precision time synchronisation, making it an important choice in modern networks.
Security: Compared to relying on GNSS radio signals, PTP is safer based on fibre-optic connections and is effective against natural and human interference.
Accuracy: PTP achieves nanosecond synchronisation accuracy, significantly better than the sub-second accuracy of NTP.
Flexibility: PTP is applicable to a variety of network topologies and supports the coexistence of multiple services and profiles on the same physical connection to meet different application requirements.
Reliability: The master and slave clocks in the PTP system form an automatic hierarchical structure, so that when the master clock fails, it can be quickly switched to the next best clock, which improves the stability of the system.
Application of PTP
PTP's application scope is gradually expanding, has become a key time synchronisation method in many fields.
Industrial automation: PTP makes sure that devices, sensors and controllers are all working at the same time. For example, robotic arms on a production line can work together perfectly, which makes them more productive and reliable.
Mobile Communications: In telecoms networks, PTP is used for time synchronisation between base stations to make sure that all the data is consistent across base stations, which improves network capacity and coverage.
Scientific research: PTP was first used for precision control in laboratories, but now it's used in lots of different scientific research.
Financial transactions: In the financial sector, PTP provides high-precision time synchronisation services suitable for high-frequency trading and real-time settlement scenarios, and meets the timestamping requirements of MiFID II regulations.