From 2e03084d349ce4ba404615f8c79b6d820d3335b6 Mon Sep 17 00:00:00 2001 From: CarlOlsson Date: Thu, 19 Oct 2017 16:49:54 +0200 Subject: [PATCH] EKF: If aligning yaw for fw with low GPS velocity, use mag --- EKF/ekf_helper.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/EKF/ekf_helper.cpp b/EKF/ekf_helper.cpp index 524cb7ffd5..521e00e5c4 100644 --- a/EKF/ekf_helper.cpp +++ b/EKF/ekf_helper.cpp @@ -464,8 +464,8 @@ bool Ekf::realignYawGPS() } } else { - // we were unable to verify the alignment - return false; + // attempt a normal alignment using the magnetometer + return resetMagHeading(_mag_sample_delayed.mag); } }