mirror of
https://gitee.com/mirrors_PX4/PX4-Autopilot.git
synced 2026-10-24 14:43:33 +08:00
ekf2: refactor output predictor to class
- refactor all EKF backend output predictor pieces into new OutputPredictor class - output states are now calculated immediately with new high rate IMU rather than after EKF update - IMU delayed sample is passed as around as control data to avoid storing an extra copy and make the requirement clear
This commit is contained in:
@@ -137,8 +137,8 @@ void Ekf::fuseGpsYaw()
|
||||
gnss_yaw.fused = is_fused;
|
||||
|
||||
if (is_fused) {
|
||||
_time_last_heading_fuse = _imu_sample_delayed.time_us;
|
||||
gnss_yaw.time_last_fuse = _imu_sample_delayed.time_us;
|
||||
_time_last_heading_fuse = _time_delayed_us;
|
||||
gnss_yaw.time_last_fuse = _time_delayed_us;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -159,7 +159,7 @@ bool Ekf::resetYawToGps(const float gnss_yaw)
|
||||
const float yaw_variance = sq(fmaxf(_params.gps_heading_noise, 1.e-2f));
|
||||
resetQuatStateYaw(measured_yaw, yaw_variance);
|
||||
|
||||
_aid_src_gnss_yaw.time_last_fuse = _imu_sample_delayed.time_us;
|
||||
_aid_src_gnss_yaw.time_last_fuse = _time_delayed_us;
|
||||
_gnss_yaw_signed_test_ratio_lpf.reset(0.f);
|
||||
|
||||
return true;
|
||||
|
||||
Reference in New Issue
Block a user