mirror of
https://github.com/paparazzi/paparazzi.git
synced 2026-05-24 22:05:58 +08:00
[rotorcraft] don't force failsafe commands if motors are off
This commit is contained in:
@@ -93,11 +93,14 @@ void autopilot_periodic(void) {
|
||||
autopilot_detect_ground = FALSE;
|
||||
}
|
||||
#endif
|
||||
if ( !autopilot_motors_on ||
|
||||
|
||||
/* set failsafe commands, if in FAILSAFE or KILL mode */
|
||||
#ifndef FAILSAFE_GROUND_DETECT
|
||||
autopilot_mode == AP_MODE_FAILSAFE ||
|
||||
if (autopilot_mode == AP_MODE_KILL ||
|
||||
autopilot_mode == AP_MODE_FAILSAFE) {
|
||||
#else
|
||||
if (autopilot_mode == AP_MODE_KILL) {
|
||||
#endif
|
||||
autopilot_mode == AP_MODE_KILL ) {
|
||||
SetCommands(commands_failsafe,
|
||||
autopilot_in_flight, autopilot_motors_on);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user