AP_LandingGear: move logging of LandingGear event into LandingGear

Less code and Plane will get the event logged too.
This commit is contained in:
Peter Barker 2020-12-05 17:51:34 +11:00 committed by Peter Barker
parent b8c58bd900
commit bacbe21011
1 changed files with 2 additions and 0 deletions

View File

@ -139,6 +139,7 @@ void AP_LandingGear::deploy()
// set deployed flag
_deployed = true;
_have_changed = true;
AP::logger().Write_Event(LogEvent::LANDING_GEAR_DEPLOYED);
}
/// retract - retract landing gear
@ -150,6 +151,7 @@ void AP_LandingGear::retract()
// reset deployed flag
_deployed = false;
_have_changed = true;
AP::logger().Write_Event(LogEvent::LANDING_GEAR_RETRACTED);
// send message only if output has been configured
if (SRV_Channels::function_assigned(SRV_Channel::k_landing_gear_control)) {