From 3deac5727c5ab225eb03ba64a978617a7189f888 Mon Sep 17 00:00:00 2001 From: Hyon Lim Date: Tue, 17 Sep 2013 06:16:26 +1000 Subject: [PATCH] Update attitude_estimator_so3_comp_main.cpp Anton found this bug. --- .../attitude_estimator_so3_comp_main.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/modules/attitude_estimator_so3_comp/attitude_estimator_so3_comp_main.cpp b/src/modules/attitude_estimator_so3_comp/attitude_estimator_so3_comp_main.cpp index 86bda3c75ecb..f3aab553a727 100755 --- a/src/modules/attitude_estimator_so3_comp/attitude_estimator_so3_comp_main.cpp +++ b/src/modules/attitude_estimator_so3_comp/attitude_estimator_so3_comp_main.cpp @@ -236,7 +236,7 @@ void NonlinearSO3AHRSupdate(float gx, float gy, float gz, float ax, float ay, fl } //! If magnetometer measurement is available, use it. - if((mx == 0.0f) && (my == 0.0f) && (mz == 0.0f)) { + if((mx != 0.0f) && (my != 0.0f) && (mz != 0.0f)) { float hx, hy, hz, bx, bz; float halfwx, halfwy, halfwz;