mirror of
https://github.com/betaflight/betaflight.git
synced 2025-07-25 01:05:27 +03:00
Fixed build failure of AFROMINI target
This commit is contained in:
parent
bc1109c546
commit
248f7184eb
1 changed files with 4 additions and 1 deletions
|
@ -75,10 +75,13 @@ static void updateBatteryVoltage(void)
|
|||
// store the battery voltage with some other recent battery voltage readings
|
||||
uint16_t vbatSample;
|
||||
|
||||
#ifdef USE_ESC_TELEMETRY
|
||||
if (batteryConfig->batteryMeterType == BATTERY_SENSOR_ESC && isEscTelemetryActive()) {
|
||||
vbatSample = vbatLatest = getEscTelemetryVbat();
|
||||
}
|
||||
else {
|
||||
else
|
||||
#endif
|
||||
{
|
||||
vbatSample = vbatLatest = batteryAdcToVoltage(adcGetChannel(ADC_BATTERY));
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue