Fixed wing land detector: Filter GPS speeds more since they are unreliable, leave airspeed filter where it was

This commit is contained in:
Lorenz Meier 2015-06-24 17:44:11 +02:00
parent 0f21733cfc
commit 289ad91bcc
1 changed files with 2 additions and 2 deletions

View File

@ -85,12 +85,12 @@ bool FixedwingLandDetector::update()
bool landDetected = false;
if (hrt_elapsed_time(&_vehicleLocalPosition.timestamp) < 500 * 1000) {
float val = 0.95f * _velocity_xy_filtered + 0.05f * sqrtf(_vehicleLocalPosition.vx *
float val = 0.97f * _velocity_xy_filtered + 0.03f * sqrtf(_vehicleLocalPosition.vx *
_vehicleLocalPosition.vx + _vehicleLocalPosition.vy * _vehicleLocalPosition.vy);
if (isfinite(val)) {
_velocity_xy_filtered = val;
}
val = 0.95f * _velocity_z_filtered + 0.05f * fabsf(_vehicleLocalPosition.vz);
val = 0.99f * _velocity_z_filtered + 0.01f * fabsf(_vehicleLocalPosition.vz);
if (isfinite(val)) {
_velocity_z_filtered = val;