mirror of https://github.com/ArduPilot/ardupilot
Plane: don't do battery failsafe when disarmed
This commit is contained in:
parent
abdd37ea2c
commit
5101e263fa
|
@ -75,7 +75,9 @@ void Plane::read_battery(void)
|
|||
battery.read();
|
||||
compass.set_current(battery.current_amps());
|
||||
|
||||
if (!usb_connected && battery.exhausted(g.fs_batt_voltage, g.fs_batt_mah)) {
|
||||
if (!usb_connected &&
|
||||
hal.util->get_soft_armed() &&
|
||||
battery.exhausted(g.fs_batt_voltage, g.fs_batt_mah)) {
|
||||
low_battery_event();
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue