mirror of
https://github.com/ArduPilot/ardupilot
synced 2025-01-08 17:08:28 -04:00
RC_Channel: stop writing events when fence enabled or disabled
AC_Fence now does this
This commit is contained in:
parent
973b103a4a
commit
f04acbd7de
@ -646,18 +646,7 @@ void RC_Channel::do_aux_function_fence(const aux_switch_pos_t ch_flag)
|
||||
return;
|
||||
}
|
||||
|
||||
AP_Logger *logger = AP_Logger::get_singleton();
|
||||
if (ch_flag == HIGH) {
|
||||
fence->enable(true);
|
||||
if (logger != nullptr) {
|
||||
logger->Write_Event(LogEvent::FENCE_ENABLE);
|
||||
}
|
||||
} else {
|
||||
fence->enable(false);
|
||||
if (logger != nullptr) {
|
||||
logger->Write_Event(LogEvent::FENCE_DISABLE);
|
||||
}
|
||||
}
|
||||
fence->enable(ch_flag == HIGH);
|
||||
}
|
||||
|
||||
void RC_Channel::do_aux_function_clear_wp(const aux_switch_pos_t ch_flag)
|
||||
|
Loading…
Reference in New Issue
Block a user