mirror of
https://gitee.com/mirrors_PX4/PX4-Autopilot.git
synced 2026-10-25 22:03:34 +08:00
EKF: range_finder parameterize range sensor quality hysteresis time
Signed-off-by: Claudio Micheli <claudio@auterion.com> Co-authored-by: bresch <brescianimathieu@gmail.com>
This commit is contained in:
co-authored by
bresch
parent
6158d6d841
commit
c4d162f9a0
@@ -83,6 +83,10 @@ public:
|
||||
_rng_valid_max_val = max_distance;
|
||||
}
|
||||
|
||||
void setQualityHysteresis(float valid_quality_threshold_s){
|
||||
_quality_hyst_us = uint64_t(valid_quality_threshold_s * 1e6f);
|
||||
}
|
||||
|
||||
float getCosTilt() const { return _cos_tilt_rng_to_earth; }
|
||||
|
||||
void setRange(float rng) { _sample.rng = rng; }
|
||||
@@ -146,7 +150,7 @@ private:
|
||||
* Quality check
|
||||
*/
|
||||
uint64_t _time_bad_quality_us{}; ///< timestamp at which range finder signal quality was 0 (used for hysteresis)
|
||||
uint64_t _quality_hyst_us{1000000}; ///< minimum duration during which the reported range finder signal quality needs to be non-zero in order to be declared valid (us)
|
||||
uint64_t _quality_hyst_us{}; ///< minimum duration during which the reported range finder signal quality needs to be non-zero in order to be declared valid (us)
|
||||
};
|
||||
|
||||
} // namespace sensor
|
||||
|
||||
Reference in New Issue
Block a user