uavcan: use px4 timestamp for the esc status message

- there is a timeshift between the esc and px4 time so until there is some
kind of offset estimation we are better off using px4 time since the logging
system uses that as reference

Signed-off-by: Roman <bapstroman@gmail.com>
This commit is contained in:
Roman
2019-01-30 11:34:21 +01:00
committed by Daniel Agar
parent 795e13ca59
commit e49549a433
+1 -1
View File
@@ -203,7 +203,7 @@ void UavcanEscController::esc_status_sub_cb(const uavcan::ReceivedDataStructure<
{
if (msg.esc_index < esc_status_s::CONNECTED_ESC_MAX) {
_esc_status.esc_count = uavcan::max<int>(_esc_status.esc_count, msg.esc_index + 1);
_esc_status.timestamp = msg.getMonotonicTimestamp().toUSec();
_esc_status.timestamp = hrt_absolute_time();
auto &ref = _esc_status.esc[msg.esc_index];