mirror of
https://gitee.com/mirrors_PX4/PX4-Autopilot.git
synced 2026-10-21 08:53:34 +08:00
ekf2: preflight checks only reset on STANDBY change
- avoid storing unnecessary state and call setVehicleCanObserveHeadingInFlight() directly
This commit is contained in:
@@ -120,11 +120,6 @@ public:
|
||||
private:
|
||||
void Run() override;
|
||||
|
||||
PreFlightChecker _preflt_checker;
|
||||
void runPreFlightChecks(float dt, const filter_control_status_u &control_status,
|
||||
const estimator_innovations_s &innov, const bool can_observe_heading_in_flight);
|
||||
void resetPreFlightChecks();
|
||||
|
||||
template<typename Param>
|
||||
void update_mag_bias(Param &mag_bias_param, int axis_index);
|
||||
|
||||
@@ -234,7 +229,6 @@ private:
|
||||
bool _standby{false}; // standby arming state
|
||||
bool _landed{true};
|
||||
bool _in_ground_effect{false};
|
||||
bool _can_observe_heading_in_flight{false};
|
||||
|
||||
uORB::PublicationMulti<ekf2_timestamps_s> _ekf2_timestamps_pub{ORB_ID(ekf2_timestamps)};
|
||||
uORB::PublicationMulti<ekf_gps_drift_s> _ekf_gps_drift_pub{ORB_ID(ekf_gps_drift)};
|
||||
@@ -255,6 +249,8 @@ private:
|
||||
uORB::PublicationMulti<vehicle_global_position_s> _global_position_pub;
|
||||
uORB::PublicationMulti<vehicle_odometry_s> _odometry_pub;
|
||||
|
||||
PreFlightChecker _preflt_checker;
|
||||
|
||||
Ekf _ekf;
|
||||
|
||||
parameters *_params; ///< pointer to ekf parameter struct (located in _ekf class instance)
|
||||
|
||||
Reference in New Issue
Block a user