diff --git a/EKF/ekf.cpp b/EKF/ekf.cpp index ffe380dc68..c9d8888879 100644 --- a/EKF/ekf.cpp +++ b/EKF/ekf.cpp @@ -85,9 +85,9 @@ bool Ekf::update() // measurement updates if (_mag_buffer.pop_first_older_than(_imu_sample_delayed.time_us, &_mag_sample_delayed)) { - //fuseHeading(); - fuseMag(_mag_fuse_index); - _mag_fuse_index = (_mag_fuse_index + 1) % 3; + fuseHeading(); + //fuseMag(_mag_fuse_index); + //_mag_fuse_index = (_mag_fuse_index + 1) % 3; } if (_baro_buffer.pop_first_older_than(_imu_sample_delayed.time_us, &_baro_sample_delayed)) { diff --git a/EKF/estimator_base.cpp b/EKF/estimator_base.cpp index 20b293bdea..ed88c1f8a8 100644 --- a/EKF/estimator_base.cpp +++ b/EKF/estimator_base.cpp @@ -311,7 +311,7 @@ void EstimatorBase::initialiseVariables(uint64_t time_usec) _gps_speed_valid = false; _mag_healthy = false; - _in_air = true; // XXX get this flag from the application + _in_air = false; // XXX get this flag from the application _time_last_imu = 0; _time_last_gps = 0;