From 11f8da5fc64de2d7bb9b5ee1af8e18cdd09d5784 Mon Sep 17 00:00:00 2001 From: lovettchris Date: Fri, 23 Sep 2016 15:14:32 -0700 Subject: [PATCH] AUTO_LOITER respect disabled RC link loss param (#5499) --- src/modules/commander/state_machine_helper.cpp | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/src/modules/commander/state_machine_helper.cpp b/src/modules/commander/state_machine_helper.cpp index e279ee159a..75114ccfd3 100644 --- a/src/modules/commander/state_machine_helper.cpp +++ b/src/modules/commander/state_machine_helper.cpp @@ -855,9 +855,10 @@ bool set_nav_state(struct vehicle_status_s *status, struct commander_state_s *in status->nav_state = vehicle_status_s::NAVIGATION_STATE_TERMINATION; } - /* go into failsafe if RC is lost and datalink loss is not set up */ + /* go into failsafe if RC is lost and datalink loss is not set up and rc loss is not disabled */ + + } else if (status->rc_signal_lost && rc_loss_enabled && !data_link_loss_enabled) { - } else if (status->rc_signal_lost && !data_link_loss_enabled) { status->failsafe = true; if (status_flags->condition_global_position_valid && status_flags->condition_home_position_valid) {