mirror of
https://gitee.com/mirrors_PX4/PX4-Autopilot.git
synced 2026-10-25 13:53:35 +08:00
EKF: Use unfiltered airspeed if airspeed is large enough - rely for better stability on the filtered speed for the threshold. Lower the threshold to 5 m/s to ensure airspeed fusion even on small wings
This commit is contained in:
@@ -1062,7 +1062,7 @@ void AttitudePositionEstimatorEKF::updateSensorFusion(const bool fuseGPS, const
|
|||||||
}
|
}
|
||||||
|
|
||||||
// Fuse Airspeed Measurements
|
// Fuse Airspeed Measurements
|
||||||
if (fuseAirSpeed && _ekf->VtasMeas > 7.0f) {
|
if (fuseAirSpeed && _airspeed.true_airspeed_m_s > 5.0f) {
|
||||||
_ekf->fuseVtasData = true;
|
_ekf->fuseVtasData = true;
|
||||||
_ekf->RecallStates(_ekf->statesAtVtasMeasTime,
|
_ekf->RecallStates(_ekf->statesAtVtasMeasTime,
|
||||||
(IMUmsec - _parameters.tas_delay_ms)); // assume 100 msec avg delay for airspeed data
|
(IMUmsec - _parameters.tas_delay_ms)); // assume 100 msec avg delay for airspeed data
|
||||||
@@ -1320,7 +1320,7 @@ void AttitudePositionEstimatorEKF::pollData()
|
|||||||
orb_copy(ORB_ID(airspeed), _airspeed_sub, &_airspeed);
|
orb_copy(ORB_ID(airspeed), _airspeed_sub, &_airspeed);
|
||||||
perf_count(_perf_airspeed);
|
perf_count(_perf_airspeed);
|
||||||
|
|
||||||
_ekf->VtasMeas = _airspeed.true_airspeed_m_s;
|
_ekf->VtasMeas = _airspeed.true_airspeed_unfiltered_m_s;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user