mirror of
https://github.com/PX4/PX4-Autopilot.git
synced 2026-11-30 21:12:20 +08:00
refactor(commander): remove duplicate failure_detector_status from vehicle_status (#26754)
The failure_detector_status bitmask in vehicle_status duplicates the separate FailureDetectorStatus topic. Remove it and read directly from the dedicated topic in failureDetectorCheck and HIGH_LATENCY2.
This commit is contained in:
1 parent
375d540cf8
commit
7d56582915
9 files changed
+286
-30
No files matched your search
@@ -1925,7 +1925,6 @@ void Commander::run()
|
||||
|
||||
// Check for failure detector status
|
||||
if (_failure_detector.update(_vehicle_status, _vehicle_control_mode)) {
|
||||
_vehicle_status.failure_detector_status = _failure_detector.getStatus().value;
|
||||
_status_changed = true;
|
||||
}
|
||||
|
||||
@@ -1998,7 +1997,7 @@ void Commander::run()
|
||||
send_parachute_command();
|
||||
}
|
||||
|
||||
// publish states (armed, control_mode, vehicle_status, failure_detector_status) at 2 Hz or immediately when changed
|
||||
// publish states (armed, control_mode, vehicle_status) at 2 Hz or immediately when changed
|
||||
if ((now >= _vehicle_status.timestamp + 500_ms) || _status_changed || nav_state_or_failsafe_changed
|
||||
|| !(_actuator_armed == actuator_armed_prev)) {
|
||||
|
||||
|
||||
Reference in new issue
Block a user