From 2d212e5bd4d24b3dab318f235dd0785f2c00f6cc Mon Sep 17 00:00:00 2001 From: Michael du Breuil Date: Mon, 30 Jan 2017 12:09:27 -0700 Subject: [PATCH] AP_InertialNav: Update for AHRS NED changes --- libraries/AP_InertialNav/AP_InertialNav_NavEKF.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/libraries/AP_InertialNav/AP_InertialNav_NavEKF.cpp b/libraries/AP_InertialNav/AP_InertialNav_NavEKF.cpp index e109c78116..9f87328292 100644 --- a/libraries/AP_InertialNav/AP_InertialNav_NavEKF.cpp +++ b/libraries/AP_InertialNav/AP_InertialNav_NavEKF.cpp @@ -16,14 +16,14 @@ void AP_InertialNav_NavEKF::update(float dt) { // get the NE position relative to the local earth frame origin Vector2f posNE; - if (_ahrs_ekf.get_relative_position_NE(posNE)) { + if (_ahrs_ekf.get_relative_position_NE_origin(posNE)) { _relpos_cm.x = posNE.x * 100; // convert from m to cm _relpos_cm.y = posNE.y * 100; // convert from m to cm } // get the D position relative to the local earth frame origin float posD; - if (_ahrs_ekf.get_relative_position_D(posD)) { + if (_ahrs_ekf.get_relative_position_D_origin(posD)) { _relpos_cm.z = - posD * 100; // convert from m in NED to cm in NEU }