diff --git a/libraries/AP_InertialNav/AP_InertialNav.cpp b/libraries/AP_InertialNav/AP_InertialNav.cpp index 957932d10c..761a346817 100644 --- a/libraries/AP_InertialNav/AP_InertialNav.cpp +++ b/libraries/AP_InertialNav/AP_InertialNav.cpp @@ -69,7 +69,7 @@ void AP_InertialNav::update(float dt) // convert accelerometer readings to earth frame Matrix3f dcm = _ahrs->get_dcm_matrix(); - accel_ef = dcm * _ins->get_accel(); + accel_ef = _ahrs->get_accel_ef(); // remove influence of gravity accel_ef.z += AP_INTERTIALNAV_GRAVITY;