APM: fixed reset of control switch when short_fs_action is disabled

When FS_SHORT_ACTN is 0, we should not re-read the control switch
unless we changed mode on the initial short fs action
This commit is contained in:
Andrew Tridgell 2012-03-03 12:50:46 +11:00
parent d03b11092b
commit 8e162ec35b

View File

@ -71,7 +71,10 @@ static void failsafe_short_off_event()
// re-read the switch so we can return to our preferred mode
// --------------------------------------------------------
reset_control_switch();
if (control_mode == CIRCLE ||
(g.short_fs_action == 1 && control_mode == RTL)) {
reset_control_switch();
}
// Reset control integrators
// ---------------------