mirror of
https://github.com/ArduPilot/ardupilot
synced 2025-01-24 17:48:35 -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;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
AP_Logger *logger = AP_Logger::get_singleton();
|
fence->enable(ch_flag == HIGH);
|
||||||
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);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
void RC_Channel::do_aux_function_clear_wp(const aux_switch_pos_t ch_flag)
|
void RC_Channel::do_aux_function_clear_wp(const aux_switch_pos_t ch_flag)
|
||||||
|
Loading…
Reference in New Issue
Block a user