mirror of
https://gitee.com/mirrors_PX4/PX4-Autopilot.git
synced 2026-10-31 01:31:35 +08:00
Defaulting to full auto in auto mode
This commit is contained in:
committed by
James Goppert
parent
13bb814f20
commit
dc5ddb9370
@@ -1845,15 +1845,16 @@ int commander_thread_main(int argc, char *argv[])
|
|||||||
update_state_machine_mode_manual(stat_pub, ¤t_status, mavlink_fd);
|
update_state_machine_mode_manual(stat_pub, ¤t_status, mavlink_fd);
|
||||||
|
|
||||||
} else if (sp_man.manual_override_switch < -STICK_ON_OFF_LIMIT) {
|
} else if (sp_man.manual_override_switch < -STICK_ON_OFF_LIMIT) {
|
||||||
/* check auto mode switch for correct mode */
|
// /* check auto mode switch for correct mode */
|
||||||
if (sp_man.auto_mode_switch > STICK_ON_OFF_LIMIT) {
|
// if (sp_man.auto_mode_switch > STICK_ON_OFF_LIMIT) {
|
||||||
/* enable guided mode */
|
// /* enable guided mode */
|
||||||
update_state_machine_mode_guided(stat_pub, ¤t_status, mavlink_fd);
|
// update_state_machine_mode_guided(stat_pub, ¤t_status, mavlink_fd);
|
||||||
|
|
||||||
} else if (sp_man.auto_mode_switch < -STICK_ON_OFF_LIMIT) {
|
// } else if (sp_man.auto_mode_switch < -STICK_ON_OFF_LIMIT) {
|
||||||
|
// XXX hardcode to auto for now
|
||||||
update_state_machine_mode_auto(stat_pub, ¤t_status, mavlink_fd);
|
update_state_machine_mode_auto(stat_pub, ¤t_status, mavlink_fd);
|
||||||
|
|
||||||
}
|
// }
|
||||||
|
|
||||||
} else {
|
} else {
|
||||||
/* center stick position, set SAS for all vehicle types */
|
/* center stick position, set SAS for all vehicle types */
|
||||||
|
|||||||
Reference in New Issue
Block a user