9 Commits

Author SHA1 Message Date
Matthias Grob
e841fe029a
[1.17] Bugfix: Let user take over from a degraded failsafe (#26269)
* astyle: remove max line length (#25717)

* failsafe unit test: add cases for 1 allow taking over from degraded failsafes 2 not cause immediate takeover when failsafe happens because of mode switch

The first test makes sure the user can take over when an RTL failsafe was triggered but degraded to a Land.

The second test rules out the easiest fix of removing the condition `_selected_action == selected_action` which causes the problem for test one but is there for a reason.

* commander/failsafe: fix user takeover not possible in fallback Land action when configured RTL is not possible

---------

Co-authored-by: Jacob Dahl <37091262+dakejahl@users.noreply.github.com>
2026-01-15 14:48:53 -05:00
Silvan Fuhrer
16f97635ce Separate RC and manual control terms
Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
2025-08-18 18:11:03 +02:00
Matthias Grob
b9f7b8f705 commander failsafe: never override user intended termination + unit test 2025-07-28 11:36:21 +02:00
Beat Küng
168d99cd18 commander: do not trigger obsolete failsafe when deactivating failsafe deferring
Previously, when deferring was active and e.g. RC loss was triggered, and
RC regained, the action was not cleared, as the RC loss action only clears
on mode switch/disarm (when set to RTL for example).
When deferring was then disabled, the RC loss failsafe would still trigger.

This changes the behavior to immediately remove those actions when
deferring is active.

It also ensures to reset the Hold delay when deferring is disabled and no
failsafe is being deferred.
2025-07-15 17:18:54 +02:00
Silvan Fuhrer
8fdf0931e5 Commander framework: only warn and do not re-start RTL if already in RTL
Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
2024-09-27 14:25:27 +02:00
Beat Küng
83c8c79af5
commander failsafe: add API to defer failsafes 2023-02-07 19:27:51 -05:00
Beat Küng
d542ffc10c refactor vehicle_status_flags: rename to failsafe_flags 2022-10-13 16:05:25 -04:00
Beat Küng
38d3739b6d refactor commander: rename rc_signal_lost -> manual_control_signal_lost, data_link_lost -> gcs_connection_lost 2022-10-11 22:31:20 -04:00
Beat Küng
e2d8ca73a5 commander: add unit tests for failsafe state machine 2022-10-11 22:31:20 -04:00