mirror of
https://gitee.com/mirrors_PX4/PX4-Autopilot.git
synced 2026-10-23 06:43:34 +08:00
EKF: Update tuning parameters
Set conservative defaults as a baseline for tuning Add a missing parameter for magnetometer observation noise. Correct error in definition of magnetic heading observations noise (previous parameter defined the variance directly, not the noise). Scale vertical GPS noise to allow for average EPV to EPH ratio. Update documentation and display names for consistency.
This commit is contained in:
+4
-2
@@ -55,7 +55,8 @@ void Ekf::fuseMag()
|
||||
float magD = _state.mag_I(2);
|
||||
|
||||
// XYZ Measurement uncertainty. Need to consider timing errors for fast rotations
|
||||
float R_MAG = 1e-3f;
|
||||
float R_MAG = fmaxf(_params.mag_noise, 1.0e-3f);
|
||||
R_MAG = R_MAG*R_MAG;
|
||||
|
||||
// intermediate variables from algebraic optimisation
|
||||
float SH_MAG[9];
|
||||
@@ -471,7 +472,8 @@ void Ekf::fuseHeading()
|
||||
float magY = _mag_sample_delayed.mag(1);
|
||||
float magZ = _mag_sample_delayed.mag(2);
|
||||
|
||||
float R_mag = _params.mag_heading_noise;
|
||||
float R_mag = fmaxf(_params.mag_heading_noise, 1.0e-2f);
|
||||
R_mag = R_mag*R_mag;
|
||||
|
||||
float t2 = q0 * q0;
|
||||
float t3 = q1 * q1;
|
||||
|
||||
Reference in New Issue
Block a user