manual_control: ORBIT and PRECLAND not supported

ORBIT and PRECLAND are not actually possible on the flight mode switch.
This commit is contained in:
Julian Oes 2021-05-18 11:47:06 +02:00 committed by Matthias Grob
parent 2e9edfcd89
commit 9cbfa2ca95

View File

@ -391,15 +391,11 @@ void ManualControl::send_mode_command(int32_t commander_main_state)
break;
case commander_state_s::MAIN_STATE_AUTO_PRECLAND:
command.param2 = PX4_CUSTOM_MAIN_MODE_AUTO;
command.param3 = PX4_CUSTOM_SUB_MODE_AUTO_PRECLAND;
break;
// FALLTHROUGH
case commander_state_s::MAIN_STATE_ORBIT:
// TODO: check if this works without the DO_ORBIT command
command.param2 = PX4_CUSTOM_MAIN_MODE_POSCTL;
command.param3 = PX4_CUSTOM_SUB_MODE_POSCTL_ORBIT;
break;
PX4_WARN("Unhandled main_state");
return;
case commander_state_s::MAIN_STATE_MAX: