From 05c5f0f866badbc7edff3ea39b61359c1e3e6078 Mon Sep 17 00:00:00 2001 From: giacomo892 Date: Thu, 31 May 2018 16:29:21 +0200 Subject: [PATCH] Extra safety for NAV_LAUNCH if enabled via BOX --- src/main/navigation/navigation.c | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/src/main/navigation/navigation.c b/src/main/navigation/navigation.c index a9000fe920..40d18170de 100755 --- a/src/main/navigation/navigation.c +++ b/src/main/navigation/navigation.c @@ -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; } } }