diff --git a/libraries/AP_Baro/AP_Baro.h b/libraries/AP_Baro/AP_Baro.h index 9825b835b2..185de9bddc 100644 --- a/libraries/AP_Baro/AP_Baro.h +++ b/libraries/AP_Baro/AP_Baro.h @@ -115,6 +115,9 @@ public: // slots it will panic uint8_t register_sensor(void); + // return number of registered sensors + uint8_t num_instances(void) const { return _num_sensors; } + private: // how many drivers do we have? uint8_t _num_drivers;