ekf: add logging for rng kinematic consistency check

This commit is contained in:
bresch
2022-04-13 11:41:48 +02:00
committed by Mathieu Bresciani
parent 8693ad15a7
commit d903613c9c
4 changed files with 5 additions and 0 deletions
+1
View File
@@ -493,6 +493,7 @@ union filter_control_status_u {
uint32_t rng_fault : 1; ///< 28 - true when the range finder has been declared faulty and is no longer being used
uint32_t inertial_dead_reckoning : 1; ///< 29 - true if we are no longer fusing measurements that constrain horizontal velocity drift
uint32_t wind_dead_reckoning : 1; ///< 30 - true if we are navigationg reliant on wind relative measurements
uint32_t rng_kin_consistent : 1; ///< 31 - true when the range finder kinematic consistency check is passing
} flags;
uint32_t value;
};
+2
View File
@@ -142,6 +142,8 @@ void Ekf::controlFusionModes()
_range_sensor.setRange(_range_sensor.getRange() + pos_offset_earth(2) / _range_sensor.getCosTilt());
_rng_consistency_check.update(_range_sensor.getDistBottom(), getRngHeightVariance(), _state.vel(2), P(6, 6), _time_last_imu);
}
_control_status.flags.rng_kin_consistent = _rng_consistency_check.isKinematicallyConsistent();
}
if (_flow_buffer) {