From ab7eb93c29af8ce8e6d8f7bfd3a549d0894a51b7 Mon Sep 17 00:00:00 2001 From: Henry Wurzburg Date: Thu, 28 Nov 2024 20:27:06 -0600 Subject: [PATCH] Plan:wip;fix altitude slope issue --- ArduPlane/mode_autoland.cpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/ArduPlane/mode_autoland.cpp b/ArduPlane/mode_autoland.cpp index e5082894474cb..9f3e4bf1d2b9d 100644 --- a/ArduPlane/mode_autoland.cpp +++ b/ArduPlane/mode_autoland.cpp @@ -73,7 +73,7 @@ void ModeAutoLand::update() { plane.calc_nav_roll(); plane.calc_nav_pitch(); - + plane.set_offset_altitude_location(plane.prev_WP_loc, plane.next_WP_loc); if (plane.landing.is_throttle_suppressed()) { // if landing is considered complete throttle is never allowed, regardless of landing type SRV_Channels::set_output_scaled(SRV_Channel::k_throttle, 0.0); @@ -93,6 +93,7 @@ void ModeAutoLand::navigate() land_started = true; plane.prev_WP_loc = plane.current_loc; plane.next_WP_loc = home_loc; + plane.set_offset_altitude_location(plane.prev_WP_loc, plane.next_WP_loc); plane.start_command(cmd); } return;