Skip to content

Commit

Permalink
AP_HAL_ChibiOS: make tracked timestamp public method
Browse files Browse the repository at this point in the history
  • Loading branch information
bugobliterator committed Apr 3, 2024
1 parent fc25efd commit d13fa83
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions libraries/AP_HAL_ChibiOS/CANIface.h
Original file line number Diff line number Diff line change
Expand Up @@ -243,6 +243,11 @@ class ChibiOS::CANIface : public AP_HAL::CANIface
// CAN Peripheral register structure
static constexpr bxcan::CanType* const Can[HAL_NUM_CAN_IFACES] = { HAL_CAN_BASE_LIST };

// get timestamp of last packet sent with matching mask and value
uint64_t get_tracked_tx_timestamp() override {
return tracked_tx_timestamp_us;
}

protected:
bool add_to_rx_queue(const CanRxItem &rx_item) override {
return rx_queue_.push(rx_item);
Expand All @@ -257,11 +262,6 @@ class ChibiOS::CANIface : public AP_HAL::CANIface
tracked_tx_ts_mask = mask;
tracked_tx_ts_value = value;
}

// get timestamp of last packet sent with matching mask and value
uint64_t get_tracked_tx_timestamp() override {
return tracked_tx_timestamp_us;
}
};
#endif //HAL_NUM_CAN_IFACES
#endif //# if defined(STM32H7XX) || defined(STM32G4)

0 comments on commit d13fa83

Please sign in to comment.