I’m trying to disable the output for my landing gear when disarmed using the BRD_SAFETY_MASK param. I can’t find any explanation of which outputs correspond to which outputs on the Cube carrier board. I know there are 14 total; 8 for motors, then another 6 pwm outputs. But how is the ordering of them? Looks like:
The one I am trying to disable while disarmed is the #6 highlighted by white. Would this be output #14 for the bitmask? This would assume outputs start with the motor outputs 1-8 then 1-6 highlighted in white corresponding to 9-14. Right?
Thinking about it a bit more, I’m not sure there is a way to disable Copter landing gear (disarmed) without scripting. I hope someone proves me wrong.
I can envision a script that would not only prevent landing gear movement while disarmed but also assert a prearm flag to prevent arming with the gear switch up.
A real PR is beyond my programming skills, but I can follow your scripts once you write them.
Thinking about it , this is like a couple of different cases, maybe best with a script…
Although it wouldnt be bad as an Option in the firmware and probably not a big code change. That would suit companies that do many builds and would like to set read-only firmware defaults for their aircraft.
drone crew grabs their multirotor out of the shipping box, landing gear is retracted for transport, connect battery and lower the landing gear before setting it on the ground. Also have to retract after disarming to pack everything away → need to operate landing gear anytime
drone newbie accidentally retracts gear before launching, damages payload → disallow landing gear changes when not flying
should there be a delay? landing gear can be changed while disarmed within the first xyz seconds of powering up, or only after xyz seconds after disarming
We’re getting into a few scenarios and more complexity
I’m sure the Devs are fully loaded with more critical things.
I feel like I’m overthinking it now, the current LGR params arent too bad.
Plus, a WOW switch doesn’t even really need to be enabled in firmware. Just have it interrupt the power circuit to the gear when actuated. KISS.
In the script, I think a double switch actuation would suffice for disarmed behavior.
In other words, if the gear is up for transport and needs to be lowered for launch, flick the switch twice within one second. Otherwise, no change (other than a text warning).
After changing this parameter (a bitmask,) I am no longer able to accidentally flip my landing gear switch while the safety switch is not enabled, in other words, before launching or while on the ground. I’ve disabled “Output14” which corresponds to the black on white “6” on the outputs on the back of my carrier board:
This is all I was wanting to do, and satisfies my needs. I think in my post, I used the term “armed” in lieui of what I meant, which was with the safety switch not depressed. It satisfies my needs, but I think your idea to work it into an actual “armed” state, since lots of people don’t use the hardware safety switch, would be great and maybe better even for people who do. To me it seems like it would be a useful and much appreciated feature that might save a lot of people a lot of money into landfill waste.