From e69eeea246a31388b4b502c0a01b521388a567e0 Mon Sep 17 00:00:00 2001 From: Randy Mackay Date: Fri, 10 Jan 2014 16:20:31 +0900 Subject: [PATCH] Copter: log alt target from PosControl --- ArduCopter/GCS_Mavlink.pde | 2 +- ArduCopter/Log.pde | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/ArduCopter/GCS_Mavlink.pde b/ArduCopter/GCS_Mavlink.pde index bc01cb8c23..2255b30a82 100644 --- a/ArduCopter/GCS_Mavlink.pde +++ b/ArduCopter/GCS_Mavlink.pde @@ -255,7 +255,7 @@ static void NOINLINE send_nav_controller_output(mavlink_channel_t chan) control_yaw / 1.0e2f, wp_bearing / 1.0e2f, wp_distance / 1.0e2f, - altitude_error / 1.0e2f, + pos_control.get_alt_error() / 1.0e2f, 0, 0); } diff --git a/ArduCopter/Log.pde b/ArduCopter/Log.pde index ec253fef6d..7b44fe0e54 100644 --- a/ArduCopter/Log.pde +++ b/ArduCopter/Log.pde @@ -325,7 +325,7 @@ static void Log_Write_Control_Tuning() throttle_in : g.rc_3.control_in, angle_boost : angle_boost, throttle_out : g.rc_3.servo_out, - desired_alt : get_target_alt_for_reporting() / 100.0f, + desired_alt : pos_control.get_alt_target() / 100.0f, inav_alt : current_loc.alt / 100.0f, baro_alt : baro_alt, desired_sonar_alt : (int16_t)target_sonar_alt,