1
0
Fork 0
mirror of https://github.com/betaflight/betaflight.git synced 2025-07-24 00:35:39 +03:00

Add battery warning beeper. Update MSP_MISC/MSP_SET_MISC.

Note the old beeper was essentially 'battery critical'.
This commit is contained in:
Dominic Clifton 2014-12-19 22:16:13 +00:00
parent 49cf725b41
commit 367eb79bd0
12 changed files with 67 additions and 24 deletions

View file

@ -570,7 +570,7 @@ void applyLedWarningLayer(uint8_t updateNow)
if (updateNow && warningFlashCounter == 0) {
warningFlags = WARNING_FLAG_NONE;
if (feature(FEATURE_VBAT) && shouldSoundBatteryAlarm()) {
if (feature(FEATURE_VBAT) && calculateBatteryState() != BATTERY_OK) {
warningFlags |= WARNING_FLAG_LOW_BATTERY;
}
if (failsafe->vTable->hasTimerElapsed()) {