mirror of
https://gitee.com/mirrors_PX4/PX4-Autopilot.git
synced 2026-10-21 15:23:34 +08:00
terrain_estimator: introduce quality metric in rng
This commit introduces a quality measure in the range data. It is used to properly decide whether to initialize the HAGL estimate on sensor data or MIN_HGT parameter, as well as in the decision of whether a 'fake' measurement should be published on the ground to allow for optical flow take-offs.
This commit is contained in:
committed by
Paul Riseborough
parent
3e05fd552e
commit
a12186c285
+2
-2
@@ -1198,7 +1198,7 @@ void Ekf::checkRangeDataValidity()
|
||||
return;
|
||||
} else {
|
||||
// reset fault status when we get new data
|
||||
_rng_hgt_faulty = false;
|
||||
_rng_hgt_faulty = (_range_sample_delayed.quality == 0);
|
||||
}
|
||||
|
||||
// Check if excessively tilted
|
||||
@@ -1244,7 +1244,7 @@ void Ekf::checkRangeDataValidity()
|
||||
}
|
||||
|
||||
_control_status.flags.rng_stuck = true;
|
||||
_rng_hgt_faulty = true;
|
||||
_rng_hgt_faulty = (_range_sample_delayed.quality == 0);
|
||||
}
|
||||
|
||||
} else {
|
||||
|
||||
Reference in New Issue
Block a user