mirror of
https://gitee.com/mirrors_PX4/PX4-Autopilot.git
synced 2026-10-20 13:23:35 +08:00
microRTPS: add timesync handshake
This commit is contained in:
@@ -124,6 +124,9 @@ void RtpsTopics::publish(uint8_t topic_ID, char data_buffer[], size_t len)
|
||||
@[ end if]@
|
||||
// apply timestamp offset
|
||||
_timesync->applyOffset(st.timestamp());
|
||||
@[ if topic == 'Timesync' or topic == 'timesync']@
|
||||
if (st.sys_id() == 1)
|
||||
@[ end if]@
|
||||
_@(topic)_pub.publish(&st);
|
||||
}
|
||||
break;
|
||||
|
||||
Reference in New Issue
Block a user