Open schaveyt opened 4 years ago
It is possible to work with software timestamps, like below software-transmit (SOF_TIMESTAMPING_TX_SOFTWARE) software-receive (SOF_TIMESTAMPING_RX_SOFTWARE)
When HW timestamps are not available, it unlikely has PTP clock and ethtool -T shows as bellow PTP Hardware Clock: none
To run with it, need to create a virtual ptp clock, which is created by adding a virtual network port. Running gptp2d as bellow $ gptp2d -d cbeth0,eth0 the first virtual network port:'cbeth0' creates a virtual ptp device, and gptp2d can run with the software timestamps on eth0.
With the software timestamps, the Pdelay value often goes beyond acceptable value on the other side, and in such case, the other side must be configured to accept big number of PDelay Value.
Regarding the 2nd question, If it means the system clock wants to synchronize gptp clock, it is just a matter of setting the system clock by gptp clock value. If gptp clock wants to start with synchronize to the system clock, use '-t' option with gptp2d.
Hmm. Still learning the term here. The object here would be to run this software on a switch whose role would be a AS-2011 PTP Relay Instance (a.k.a 1588 Boundary Clock).
This switch would say have its port 1 a slave to a PTP End Instance Grandmaster, and its other 4 switch port of this switch then act as master port to their connect PTP End Instances
I am currently doing what you are looking for. Running this software on a Linux machine to act as my Grandmaster. Then I have three TSN Evaluation Kits from Innovasics which can emulate PTP End Instances and act as Slaves in the network. Just building this software and configuring the Best Master Priorities to be anything above 248 results in a network with one GM and several Slaves depending on how many TSN Evaluation Kits you have.
This is the solution that worked for me. PTPdV2 and LinuxPTP all didn't work. My only problem with this, is that the first board connected to the server running this software has a huge offset but reports that the link delay is 0ns which I am not sure is correct.
How big the clock difference shouldn't matter to measure the Pdelay. If Pdealy is 0, there must be something wrong to measure it. It is likely that capturing timestamps is not working.
So if this software is running on a Linux machine and we connect the cable from one port with another gPTP supporting device. The link delay shows that it is 0ns which is virtually not possible. There must be some difference when all the PTP event messages are being sent between the master and the slave. I expected the delay to be something but not 0. Do not know what causes this.
Does anyone have an idea why, when trying to synchronize the Excelfore gptp to a different device, the Excelfore gptp complains about ERR:gptp:read_recdata:deviceIndex=0, no RX timestamp for msgtype=PDELAY_RESP, domain=0. It seems it's waiting for the response but never gets it back. Thanks and hope for some feedback
I am still learning a bit here. If I were to follow along with this walk-through of setting up a linux system. But instead of using ptp4l, i replace it with this gptp software.
Can I assume the following:
Synchronizing the PHC is handled by this gptp software as it requires the eth interfaces with HW TIMESTAMPING.
Synchronizing the System Clock should still be handled using the phc2sys software from the linuxptp package?
Ultimately I want to try out this software's bridge mode. Any recommendations for some basic switch to use?