forked from Archive/PX4-Autopilot
EKF: Fix bug causing incorrect yaw variance value to be used
This bug causes the variance of the Z axis rotation vector uncertainty to not be reset to the correct value.
This commit is contained in:
parent
48d83f3bcb
commit
c032126745
|
@ -729,7 +729,7 @@ bool Ekf::resetMagHeading(Vector3f &mag_init)
|
|||
}
|
||||
|
||||
// update the yaw angle variance using the variance of the measurement
|
||||
if (!_control_status.flags.ev_yaw) {
|
||||
if (_control_status.flags.ev_yaw) {
|
||||
// using error estimate from external vision data
|
||||
angle_err_var_vec(2) = sq(fmaxf(_ev_sample_delayed.angErr, 1.0e-2f));
|
||||
|
||||
|
|
Loading…
Reference in New Issue