mirror of
https://github.com/ArduPilot/ardupilot
synced 2025-02-21 15:23:57 -04:00
AP_TemperatureSensor: create and use AP_BATTERY_ENABLED
simply as a way to get HAL_PERIPH_ENABLE_BATTERY out of the main code
This commit is contained in:
parent
209cba7f89
commit
5df6b835b0
@ -80,7 +80,7 @@ void AP_TemperatureSensor_Backend::update_external_libraries(const float tempera
|
||||
break;
|
||||
#endif
|
||||
|
||||
#if !defined(HAL_BUILD_AP_PERIPH) || defined(HAL_PERIPH_ENABLE_BATTERY)
|
||||
#if AP_BATTERY_ENABLED
|
||||
case AP_TemperatureSensor_Params::Source::Battery_Index:
|
||||
AP::battery().set_temperature(temperature, _params.source_id-1);
|
||||
break;
|
||||
|
Loading…
Reference in New Issue
Block a user