From 26650724e4697bb6a75afb3d78db99a8825c0690 Mon Sep 17 00:00:00 2001 From: pip Date: Mon, 27 Dec 2010 09:48:11 +0000 Subject: [PATCH] Fixed coding error on line 317 .. changed while (xxx & xxxx) to while (xxx && xxxx) git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@2296 ebee16cc-31ac-478f-84a7-5cbb03baadba --- flight/AHRS/ahrs.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/flight/AHRS/ahrs.c b/flight/AHRS/ahrs.c index d8bbf0de8..337c7c57f 100644 --- a/flight/AHRS/ahrs.c +++ b/flight/AHRS/ahrs.c @@ -314,7 +314,8 @@ void ins_init_algorithm() /* Ensure we get mag data in a timely manner */ uint16_t fail_count = 50; // 50 at 200 Hz is up to 0.25 sec - while(using_mags && !mag_data.updated & fail_count--) { + while (using_mags && !mag_data.updated && fail_count--) + { get_accel_gyro_data(); AhrsPoll(); }