diff options
Diffstat (limited to 'src/examples')
-rw-r--r-- | src/examples/fixedwing_control/main.c | 9 |
1 files changed, 6 insertions, 3 deletions
diff --git a/src/examples/fixedwing_control/main.c b/src/examples/fixedwing_control/main.c index 1753070e2..7bf99785c 100644 --- a/src/examples/fixedwing_control/main.c +++ b/src/examples/fixedwing_control/main.c @@ -294,8 +294,10 @@ int fixedwing_control_thread_main(int argc, char *argv[]) /* control */ - if (vstatus.state_machine == SYSTEM_STATE_AUTO || - vstatus.state_machine == SYSTEM_STATE_STABILIZED) { +#warning fix this +#if 0 + if (vstatus.navigation_state == NAVIGATION_STATE_AUTO_ || + vstatus.navigation_state == NAVIGATION_STATE_STABILIZED) { /* simple heading control */ control_heading(&global_pos, &global_sp, &att, &att_sp); @@ -313,7 +315,7 @@ int fixedwing_control_thread_main(int argc, char *argv[]) /* set flaps to zero */ actuators.control[4] = 0.0f; - } else if (vstatus.state_machine == SYSTEM_STATE_MANUAL) { + } else if (vstatus.navigation_state == NAVIGATION_STATE_MANUAL) { if (vstatus.manual_control_mode == VEHICLE_MANUAL_CONTROL_MODE_SAS) { /* if the RC signal is lost, try to stay level and go slowly back down to ground */ @@ -377,6 +379,7 @@ int fixedwing_control_thread_main(int argc, char *argv[]) } } } +#endif /* publish rates */ orb_publish(ORB_ID(vehicle_rates_setpoint), rates_pub, &rates_sp); |