[Unitree Go2] Time synch Orin and onboard pc

Hi,
I am wondering if there is a way to synchronize the onboard pc of the Go2 to the Jetson Orin extension board.
When looking at the time stamps in the messages published by the onboard pc after booting up, they are completely off compared to the clock on the Orin. Hence, any ROS nodes running on the Orin will live in a different timeline.
Is there any functionality implemented in the firmware that runs on the board to act as a master or slave clock to synchronize it with an external pc like the Orin board?
Many thanks in advance!

Connect the Go2 to the internet and run

sudo date -s "$(wget --method=HEAD -qSO- --max-redirect=0 google.com 2>&1 | sed -n 's/^ *Date: *//p')"

If I understand correctly, your answer implies that the onboard pc automatically fetches the time from an internet time server when being connected to a Wifi network?
And you suggest to manually set the time on the Orin to a reference clock from the internet to approximately synchronize them once, using a common internet time server.
But is there also a way to synchronize them directly and continuously using e.g. chrony or even PTP, which also works if not both the orin and the onboard pc are connected to the internet?

Yes

Generally the Nvidia board has a little battery for keeping hardware sync to current time we haven’t verified it for the GO2 but it should be possible to sync the hw clock with the set time

Yes there should be for that you can look into the Nvidia forums on how to activate chrony or PTP on the board to get from a common server.

I have my Jetson Orion connected to the internet with a Wi-Fi module, and it keeps accurate time. However, I see that the Go2’s MCU doesn’t have the correct time. The system, based on messages I receive from ROS2 (for example, from the odometer), shows a difference of many hours. Is it possible that the MCU synchronizes with the Jetson’s time?

The best way for this is to either sync from the internet the time or you can use chrony/ntp to sync betwen the computers. You can follow any online tutorial for syncing it.

Thanks for the input. The issue is that my Jetson is up-to-date with NTP and connected to the internet. It’s precisely the internal board of the Go2 robot (MCU 192.168.123.161) that I can’t configure with NTP because I don’t have access to it!

Ahh for this the only solution is to have like a small c++ bridge that subscribes and republishes the time with correct data. I will ask unitree if they have a solution for this.

1 Like

Thanks for the idea, that’s exactly it. I have it in a go2_driver node. I collect the messages that come to me from the different parts of the robot and I’ve added a new timestamp with the date() function from Jetson.

Yes, this will work, but is rather a workaround, since this just provides timestamps “on arrival” and means that we consider any time stamp information in any message sent by the MCU as being unusable.
A solution to synchronize MCU and Jetson would be great, so one can synchronize sensor readings sent by the MCU with additional sensors connected to the Jetson. I contacted the Unitree support regarding this, but they also just suggested to connect both to the same network. Thanks for reaching out to them, if you get any further information, please let us know, thanks!