forked from Archive/PX4-Autopilot
position_estimator_inav bugfixes
This commit is contained in:
parent
e12ae6b3ba
commit
2124c52cff
|
@ -20,7 +20,7 @@ void inertial_filter_correct(float edt, float x[3], int i, float w)
|
|||
|
||||
if (i == 0) {
|
||||
x[1] += w * ewdt;
|
||||
//x[2] += e * w * w * w * dt / 3.0; // ~ 0.0
|
||||
x[2] += w * w * ewdt / 3.0;
|
||||
|
||||
} else if (i == 1) {
|
||||
x[2] += w * ewdt;
|
||||
|
|
|
@ -355,7 +355,7 @@ int position_estimator_inav_thread_main(int argc, char *argv[])
|
|||
}
|
||||
|
||||
if (sensor.baro_counter > baro_counter) {
|
||||
baro_corr = baro_alt0 - sensor.baro_alt_meter - z_est[2];
|
||||
baro_corr = baro_alt0 - sensor.baro_alt_meter - z_est[0];
|
||||
baro_counter = sensor.baro_counter;
|
||||
baro_updates++;
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue