mirror of
https://gitee.com/mirrors_PX4/PX4-Autopilot.git
synced 2026-10-24 17:03:33 +08:00
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:
committed by
Lorenz Meier
parent
48d83f3bcb
commit
c032126745
+1
-1
@@ -729,7 +729,7 @@ bool Ekf::resetMagHeading(Vector3f &mag_init)
|
|||||||
}
|
}
|
||||||
|
|
||||||
// update the yaw angle variance using the variance of the measurement
|
// 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
|
// using error estimate from external vision data
|
||||||
angle_err_var_vec(2) = sq(fmaxf(_ev_sample_delayed.angErr, 1.0e-2f));
|
angle_err_var_vec(2) = sq(fmaxf(_ev_sample_delayed.angErr, 1.0e-2f));
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user