From 5642d2449a9483039406a709c72e64c4f1425909 Mon Sep 17 00:00:00 2001 From: Iampete1 Date: Sun, 10 Dec 2023 17:42:34 +0000 Subject: [PATCH] Plane: allow set_takeoff_expected in manual mode --- ArduPlane/servos.cpp | 11 ++++------- 1 file changed, 4 insertions(+), 7 deletions(-) diff --git a/ArduPlane/servos.cpp b/ArduPlane/servos.cpp index 51a28e1ee3..35dc8b0801 100644 --- a/ArduPlane/servos.cpp +++ b/ArduPlane/servos.cpp @@ -472,13 +472,8 @@ void Plane::throttle_watt_limiter(int8_t &min_throttle, int8_t &max_throttle) /* setup output channels all non-manual modes */ -void Plane::set_servos_controlled(void) +void Plane::set_throttle(void) { - if (flight_stage == AP_FixedWing::FlightStage::LAND) { - // allow landing to override servos if it would like to - landing.override_servos(); - } - // convert 0 to 100% (or -100 to +100) into PWM int8_t min_throttle = aparm.throttle_min.get(); int8_t max_throttle = aparm.throttle_max.get(); @@ -836,9 +831,11 @@ void Plane::set_servos(void) if (control_mode != &mode_manual) { set_throttle(); - set_takeoff_expected(); } + // Warn AHRS if we might take off soon + set_takeoff_expected(); + // setup flap outputs set_servos_flaps();