iNavFlight / inav

INAV: Navigation-enabled flight control software
https://inavflight.github.io
GNU General Public License v3.0
3.15k stars 1.48k forks source link

Unable to disarm after recovering from failsafe with OVERRIDE_ARMING_SAFETY on Aux channel #6496

Closed Epiphron123 closed 3 years ago

Epiphron123 commented 3 years ago

I found a somewhat dangerous issue while doing thorough tests on the bench, fiddling with the OVERRIDE ARMING SAFETY feature (after I saw this video: https://www.youtube.com/watch?v=bWktM8WBV6k) on Inav 2.6: it turns out that in some situations you can't disarm the quad using the arming switch.

STEPS TO REPRODUCE:

In the Programming tab:

Set logic condition (#0) as follows:

Operation = HIGH; Operand A = RC channel X (in my case, channel 5); Active = Always

Set global function (#1) as:

Operation = OVERRIDE ARMING SAFETY; Active = Logic condition 0

In a more concise way:

# logic
logic 0 1 -1 6 1 5 0 0 0
logic 1 1 0 22 0 0 0 0 0

This allows to turn off the arming safeties on demand with the flick of a switch.

In the Modes tab:

Configure channel Y (6 in my case) to arm when LOW.

Now, turn on the radio, plug in the quad. You can force it to arm with channel X HIGH (disable safety) and Y LOW (arm) and then disarm it setting channel Y back to HIGH.

However, if you:

  1. Turn off the radio while the quad is powered on (armed or disarmed it doesn't seem to matter)
  2. Set the switches as if you wanted to force-arm (while the radio is still off)
  3. Turn the radio back on (ignoring the switch warnings)
  4. The quad will immediately arm (as it should)
  5. BUT YOU WON'T BE ABLE TO DISARM IT USING CHANNEL Y... Only unplugging the battery will stop the motors (and maybe a Killswitch I didn't test that). Failsafe mode also stays on...

Here's a GIF of what's happening:

ezgif-7-35097ac8202f

BACKGROUND:

I wanted to be able to force rearm in mid-air because I had an issue two days ago after a failsafe: RTH was initiated and when recovering signal, the quad disarmed for no visible reason and fell out of the sky (probably the issue presented here: https://www.youtube.com/watch?v=rIFTbSQ2Wjc&lc=UgxmV-MRsd6W7GmsU0x4AaABAg.9DpT5t9T1hH9ILzlvEwbWA as I'm using R9M).

Epiphron123 commented 3 years ago

I found my problem, I needed to move the sticks to leave failsafe mode and be able to disarm. Sorry for the agitation. It doesn't explain the sudden disarm after failsafe I tried to prevent, but that's for another story.