aboutsummaryrefslogtreecommitdiff
path: root/src/modules/ekf_att_pos_estimator
diff options
context:
space:
mode:
authorJohan Jansen <jnsn.johan@gmail.com>2015-01-06 11:46:59 +0100
committerJohan Jansen <jnsn.johan@gmail.com>2015-01-15 14:37:50 +0100
commitcffba8440e056b71a01003a0d90a7e6f4cffd648 (patch)
tree99e0bcddf63b9f594099349286aa24806b530906 /src/modules/ekf_att_pos_estimator
parent642063c3b8fdcd3f5e748666d1bb0412ea434b5f (diff)
downloadpx4-firmware-cffba8440e056b71a01003a0d90a7e6f4cffd648.tar.gz
px4-firmware-cffba8440e056b71a01003a0d90a7e6f4cffd648.tar.bz2
px4-firmware-cffba8440e056b71a01003a0d90a7e6f4cffd648.zip
EKF: Removed the fixed wing land detector in the EKF module
Diffstat (limited to 'src/modules/ekf_att_pos_estimator')
-rw-r--r--src/modules/ekf_att_pos_estimator/ekf_att_pos_estimator_main.cpp25
1 files changed, 1 insertions, 24 deletions
diff --git a/src/modules/ekf_att_pos_estimator/ekf_att_pos_estimator_main.cpp b/src/modules/ekf_att_pos_estimator/ekf_att_pos_estimator_main.cpp
index c41777968..866e5dc84 100644
--- a/src/modules/ekf_att_pos_estimator/ekf_att_pos_estimator_main.cpp
+++ b/src/modules/ekf_att_pos_estimator/ekf_att_pos_estimator_main.cpp
@@ -290,10 +290,6 @@ private:
AttPosEKF *_ekf;
- float _velocity_xy_filtered;
- float _velocity_z_filtered;
- float _airspeed_filtered;
-
/**
* Update our local parameter cache.
*/
@@ -422,10 +418,7 @@ FixedwingEstimator::FixedwingEstimator() :
_mavlink_fd(-1),
_parameters{},
_parameter_handles{},
- _ekf(nullptr),
- _velocity_xy_filtered(0.0f),
- _velocity_z_filtered(0.0f),
- _airspeed_filtered(0.0f)
+ _ekf(nullptr)
{
_last_run = hrt_absolute_time();
@@ -1434,22 +1427,6 @@ FixedwingEstimator::task_main()
_local_pos.v_z_valid = true;
_local_pos.xy_global = true;
- _velocity_xy_filtered = 0.95f*_velocity_xy_filtered + 0.05f*sqrtf(_local_pos.vx*_local_pos.vx + _local_pos.vy*_local_pos.vy);
- _velocity_z_filtered = 0.95f*_velocity_z_filtered + 0.05f*fabsf(_local_pos.vz);
- _airspeed_filtered = 0.95f*_airspeed_filtered + 0.05f*_airspeed.true_airspeed_m_s;
-
-
- /* crude land detector for fixedwing only,
- * TODO: adapt so that it works for both, maybe move to another location
- */
- if (_velocity_xy_filtered < 5
- && _velocity_z_filtered < 10
- && _airspeed_filtered < 10) {
- _local_pos.landed = true;
- } else {
- _local_pos.landed = false;
- }
-
_local_pos.z_global = false;
_local_pos.yaw = _att.yaw;