From f08aee0a7dab450252935c562c2d16125744336d Mon Sep 17 00:00:00 2001 From: Paul Riseborough Date: Sat, 4 Jun 2016 00:36:07 +1000 Subject: [PATCH] EKF: Fix covariance index bug --- EKF/control.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/EKF/control.cpp b/EKF/control.cpp index 63288eec45..9266315cec 100644 --- a/EKF/control.cpp +++ b/EKF/control.cpp @@ -306,7 +306,7 @@ void Ekf::controlHeightSensorTimeouts() _time_bad_vert_accel = _time_last_imu; } - if ((P[8][8] > sq(_params.hgt_reset_lim)) && ((_time_last_imu - _time_last_hgt_fuse) > 5e6)) { + if ((P[9][9] > sq(_params.hgt_reset_lim)) && ((_time_last_imu - _time_last_hgt_fuse) > 5e6)) { // boolean that indicates we will do a height reset bool reset_height = false;