Is there a PTP (Precision Time Protocol | IEEE 1588) library?

I had reffered, the following answer from this site http://code.google.com/p/ptpv2d/wiki/Introduction, which i gave me a clear idea on ptpv2d, hope you also get the clear information, about this.

Pls refer this also http://code.google.com/p/ptpv2d/

ptpv2d is GPL licensed open source code of IEEE 1588 version 1, version 2 and IEEE 802.1AS including hardware timestamping for Freescale MPC831x family of processors.

The ptpv2d is a Precision Time Protocol which has the following features:

  1. The User mode application which runs under standard LINUX, with a modular design that ensures easy portation to additional operating systems.
  2. An extensive optional print-to-console debug message function. This message functionality can be added or omitted at compile time. If it is included, then the output level is command-line selectable. Debug messages are uniformly formatted for quicker, easier analysis. The POSIX socket calls is used to retrive all messages. Message handling is contained in a separate module to ensure easy portation to any desired operating system.
  3. Freescale MPC8313E Ethernet port driver with full support for PTP version 1 and version 2 message hardware time stamping.
  4. Ability to adjust the Hardware clock very precisely (as precise as one part per billion). Software algorithm for fine (as small as one part per billion) adjustment of the Hardware clock .
  5. Ability to report detected variances from Grandmaster clock in parts per million
  6. Command line ability to set four different debug output levels: none, basic, verbose, and Message 7.Ability to set Sync/Follow-up transmit time values of less than one second. This allows for multiple Sync/Follow-ups per second, which provides enhanced accuracy and tracking of the "slave" system to the "grandmaster" system.
  7. Additional run time options and support code include:
  8. Selection of PTP version 1 or version 2 encapsulation and protocol 10.Selection of IEEE 1588 PTP over IPv4/UDP, IEEE P1588 PTP over Ethernet (draft 2.2)or IEEE P802.1AS encapsulation and protocol(draft 1.0) User specified clock period to synthesize other base clocks, not just at 10 MHz.

These features have gone through extensive testing using dual MPC8313E-RDB boards running both PTP and Ping traffic. On a Freescale MPC8313E-RDB board running eight Sync/Follow-up Messages per second, it will support a plus or minus 50 nanosecond offset from master more than 99.9% of the time. At 128 Sync/Follow-ups per seconds, the system will synchronize within 16 nanoseconds of the "grandmaster" system.


Look at http://sourceforge.net/projects/ptpd/

The PTP daemon (PTPd) implements the Precision Time protocol (PTP) as defined by the IEEE 1588 standard. PTP was developed to provide very precise time coordination of LAN connected computers.


I've created a IEEE-1588 library some time ago. It was partly difficult especially if you require good sync between clocks. Good ptp library involves a lot of statistics, prediction, and signal processing. The best you can try is ptpd - it's very simple to learn how ptp works, and it will give you a good start.

Tags:

.Net

Time

Ieee