AP_CANManager: CANSensor: add getter for initialized

This commit is contained in:
Iampete1 2024-05-01 03:26:16 +01:00 committed by Andrew Tridgell
parent 513a6b6206
commit 632d0a93c1
1 changed files with 3 additions and 0 deletions

View File

@ -36,6 +36,9 @@ public:
void init(uint8_t driver_index, bool enable_filters) override;
bool add_interface(AP_HAL::CANIface* can_iface) override;
// Return true if this sensor has been successfully registered to a driver and initialized.
bool initialized() const { return _initialized; }
// handler for incoming frames
virtual void handle_frame(AP_HAL::CANFrame &frame) = 0;