1
0
Fork 0
mirror of https://github.com/iNavFlight/inav.git synced 2025-07-23 00:05:28 +03:00

Extra safety for NAV_LAUNCH if enabled via BOX

This commit is contained in:
giacomo892 2018-05-31 16:29:21 +02:00
parent 5c76229981
commit 05c5f0f866

View file

@ -2322,9 +2322,13 @@ static navigationFSMEvent_t selectNavEventFromBoxModeInput(void)
}
}
else {
// If we were in LAUNCH mode - force switch to IDLE
// If we were in LAUNCH mode - force switch to IDLE only if the throttle is low
if (FLIGHT_MODE(NAV_LAUNCH_MODE)) {
return NAV_FSM_EVENT_SWITCH_TO_IDLE;
throttleStatus_e throttleStatus = calculateThrottleStatus();
if (throttleStatus != THROTTLE_LOW)
return NAV_FSM_EVENT_NONE;
else
return NAV_FSM_EVENT_SWITCH_TO_IDLE;
}
}
}