Skip to content

Commit

Permalink
mavlink stream: Heartbeat system status should neglect the actuator_a…
Browse files Browse the repository at this point in the history
…rmed.lockdown flag in HIL, since this is always enabled for HIL.
  • Loading branch information
KonradRudin committed May 24, 2023
1 parent 822d784 commit f6790a8
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 f6790a8

Please sign in to comment.