ArduPlane: correct compilation with AP_RRSI_ENABLED false

Co-authored-by: David Buzz <davidbuzz@gmail.com>
This commit is contained in:
Peter Barker 2024-07-23 20:51:07 +10:00 committed by Peter Barker
parent 6dac230ccb
commit c451518bdd
3 changed files with 6 additions and 0 deletions

View File

@ -255,9 +255,11 @@ void Plane::Log_Write_RC(void)
{
logger.Write_RCIN();
logger.Write_RCOUT();
#if AP_RSSI_ENABLED
if (rssi.enabled()) {
logger.Write_RSSI();
}
#endif
Log_Write_AETR();
}

View File

@ -975,9 +975,11 @@ const AP_Param::Info Plane::var_info[] = {
GOBJECT(rpm_sensor, "RPM", AP_RPM),
#endif
#if AP_RSSI_ENABLED
// @Group: RSSI_
// @Path: ../libraries/AP_RSSI/AP_RSSI.cpp
GOBJECT(rssi, "RSSI_", AP_RSSI),
#endif
// @Group: NTF_
// @Path: ../libraries/AP_Notify/AP_Notify.cpp

View File

@ -45,7 +45,9 @@ void Plane::init_ardupilot()
// initialise battery monitoring
battery.init();
#if AP_RSSI_ENABLED
rssi.init();
#endif
#if AP_RPM_ENABLED
rpm_sensor.init();