Skip to content

Commit

Permalink
arming state fix for HITL
Browse files Browse the repository at this point in the history
  • Loading branch information
jnippula committed Aug 9, 2024
1 parent 3d7ac24 commit 9975d7c
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/modules/mavlink/streams/HEARTBEAT.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -122,7 +122,8 @@ class MavlinkStreamHeartbeat : public MavlinkStream
}

// system_status overrides
if (actuator_armed.force_failsafe || actuator_armed.lockdown || actuator_armed.manual_lockdown
if (actuator_armed.force_failsafe || (actuator_armed.lockdown && vehicle_status.hil_state == vehicle_status_s::HIL_STATE_OFF)
|| actuator_armed.manual_lockdown
|| vehicle_status.nav_state == vehicle_status_s::NAVIGATION_STATE_TERMINATION) {
system_status = MAV_STATE_FLIGHT_TERMINATION;

Expand Down

0 comments on commit 9975d7c

Please sign in to comment.