The use of ptp4l has some issues.

取消
显示结果 
显示  仅  | 搜索替代 
您的意思是: 

The use of ptp4l has some issues.

652 次查看
rqyang
Contributor I

Hi

     I am using the S32G274ARDB2 board with the BSP33 kernel. Currently, I am facing an issue while using ptp4l for time synchronization.

I first checked the capabilities of eth0. It can be observed that eth0 is using hardware timestamping from /dev/ptp0.

rqyang_0-1692868400876.png

When I connect two boards and try to perform hardware time synchronization using the following command, I am unable to sync the hardware time of the other board to the local hardware time of the S32G board.

ptp4l -m -q -P -H -2 -i eth0 --step_threshold=0.00002 -l 6

rqyang_1-1692868654755.png

 

Then I tried using "phc2sys" to synchronize the hardware time to the system time. I used the following command:  (failed again)

phc2sys -c /dev/ptp0 -s CLOCK_REALTIME -O 0 -q --step_threshold=0.00002 -m

rqyang_2-1692868754076.png

 

After running our hardware timestamping tool, we noticed that the hardware timestamp on the S32G board remained unchanged. For more details, please refer to the log. (Our tool adds 3600 seconds to the timestamp after running it to verify if it can be written to the hardware timestamp.)

 

Therefore, I believe that the reason for the failed time synchronization is that the hardware time recorded in /dev/ptp0 does not change on its own. Is this the reason? If so, what methods can I use to synchronize the hardware clock?

 

 

 

 

0 项奖励
1 回复

603 次查看
rqyang
Contributor I

hello,

       Can experts help me?

0 项奖励