Copter: fix Battery FailSafe action with auto mode

This commit is contained in:
Tatsuya Yamaguchi 2018-02-04 15:53:50 -08:00 committed by Randy Mackay
parent 83d1e71cb2
commit 6698660fd6

View File

@ -62,7 +62,7 @@ void Copter::failsafe_battery_event(void)
set_mode_SmartRTL_or_RTL(MODE_REASON_BATTERY_FAILSAFE);
} else if (g.failsafe_battery_enabled == FS_BATT_SMARTRTL_OR_LAND) {
set_mode_SmartRTL_or_land_with_pause(MODE_REASON_BATTERY_FAILSAFE);
} else if (g.failsafe_battery_enabled == FS_BATT_RTL || control_mode == AUTO) {
} else if (g.failsafe_battery_enabled == FS_BATT_RTL) {
set_mode_RTL_or_land_with_pause(MODE_REASON_BATTERY_FAILSAFE);
} else { // g.failsafe_battery_enabled == FS_BATT_LAND
set_mode_land_with_pause(MODE_REASON_BATTERY_FAILSAFE);