AC_Fence: clear breach if breached fence is not enabled

This commit is contained in:
Rishabh 2020-03-26 19:01:00 +05:30 committed by Randy Mackay
parent 7f429302ed
commit b3a2b360e6
1 changed files with 3 additions and 0 deletions

View File

@ -323,6 +323,9 @@ uint8_t AC_Fence::check()
return 0;
}
// clear any breach from a non-enabled fence
clear_breach(~_enabled_fences);
// check if pilot is attempting to recover manually
if (_manual_recovery_start_ms != 0) {
// we ignore any fence breaches during the manual recovery period which is about 10 seconds