diff --git a/include/board.h b/include/board.h index 15dbe117..4a5886cf 100644 --- a/include/board.h +++ b/include/board.h @@ -41,6 +41,7 @@ namespace rosflight_firmware { + class Board { public: @@ -68,10 +69,13 @@ class Board virtual void serial_flush() = 0; // sensors - virtual void sensors_init() = 0; - virtual uint16_t num_sensor_errors() = 0; + virtual void sensors_init(void) = 0; + virtual uint16_t sensors_errors_count() = 0; + virtual uint16_t sensors_init_message_count() = 0; + virtual uint16_t sensors_init_message(char &message, uint32_t i) = 0; // IMU + virtual bool imu_present() = 0; virtual bool imu_has_new_data() = 0; virtual bool imu_read(float accel[3], float * temperature, float gyro[3], uint64_t * time) = 0; virtual void imu_not_responding_error() = 0; diff --git a/src/comm_manager.cpp b/src/comm_manager.cpp index 6e872c5e..7d4b9ed5 100644 --- a/src/comm_manager.cpp +++ b/src/comm_manager.cpp @@ -361,7 +361,7 @@ void CommManager::send_status(void) comm_link_.send_status( sysid_, RF_.state_manager_.state().armed, RF_.state_manager_.state().failsafe, RF_.command_manager_.rc_override_active(), RF_.command_manager_.offboard_control_active(), - RF_.state_manager_.state().error_codes, control_mode, RF_.board_.num_sensor_errors(), + RF_.state_manager_.state().error_codes, control_mode, RF_.board_.sensors_errors_count(), RF_.get_loop_time_us()); }