commander: move ownership of vehicle_status_flags_s to HealthAndArmingChecks

This commit is contained in:
Beat Küng
2022-10-11 22:31:20 -04:00
committed by Daniel Agar
parent cf2eb69d25
commit 6fda555cba
8 changed files with 42 additions and 28 deletions
@@ -323,7 +323,10 @@ private:
*/
void reset();
void prepare(uint8_t vehicle_type);
void finalize();
/**
* Called after all checks are run. Returns true if the results changed
*/
bool finalize();
bool report(bool is_armed, bool force);
@@ -337,6 +340,7 @@ private:
bool _already_reported{false};
bool _had_unreported_difference{false}; ///< true if there was a difference not reported yet (due to rate limitation)
bool _results_changed{false};
hrt_abstime _last_report{0};
Results _results[2]; ///< Previous and current results to check for changes