Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

add parachute-unavailable code #26128

Open
wants to merge 4 commits into
base: master
Choose a base branch
from

Conversation

peterbarker
Copy link
Contributor

/*
 *  This is not standard parameter conversion code; it is
 *  compatability code we are using to remove parachute support from
 *  1MB boards without leaving users that *are* using parachutes on
 *  1MB boards with a sneakily broken parachute system.  We enable
 *  just enough of the parachute library to check if the enable
 *  parameter is set; if it is we throw a config error, making the
 *  vehicle non-flyable.
 */
// PARAMETER_CONVERSION - Added: Feb-2024

@peterbarker peterbarker force-pushed the pr/parachute-unavailable branch 3 times, most recently from 524c01b to 2803d39 Compare February 2, 2024 21:40
@peterbarker
Copy link
Contributor Author

peterbarker commented Feb 2, 2024

------------------------  --------------  -----  ----------  ------  -----  -----  -----  ----
Board                     antennatracker  blimp  bootloader  copter  heli   plane  rover  sub
BETAFPV-F405                                     *           -1440
BeastF7                   -392            -456   *           -1440   -1488  -1304  -416   -456
BeastF7v2                 -392            -456   *           -1440   -1488  -1304  -416   -456
F35Lightning              -392            -456   *           -1440   -1488  -1312  -424   -456
FlywooF405Pro                                    *           -1440
FlywooF405S-AIO                                  *           -1440
HEEWING-F405                                     *                          -1312
HEEWING-F405v2                                   *                          -1312
KakuteF4                  -392            -456   *           -1440   -1488  -1304  -424   -456
KakuteF4Mini              16              16     *           16      16     16     16     16
MambaF405-2022            -392            -456   *           -1440   -1464  -1280  -424   -456
MambaF405US-I2C           -392            -456   *           -1448   -1496  -1312  -424   -464
MambaF405v2               -400            -464   *           -1440   -1472  -1280  -424   -464
OmnibusNanoV6             -400            -464   *           -1440   -1488  -1312  -424   -456
OmnibusNanoV6-bdshot      -400            -464   *           -1448   -1496  -1312  -424   -456
SITL_arm_linux_gnueabihf  0               0                  0       0      0      0      0
SITL_x86_64_linux_gnu     0               0                  0       0      0      0      0
SpeedyBeeF405Mini                                *           -1440
omnibusf4v6               -392            -456   *           -1440   -1488  -1304  -416   -456
revo-mini                 -392            -456   *           -1432   -1472  -1440  -424   -456
revo-mini-bdshot          -392            -456   *           -1440   -1480  -1448  -424   -464
revo-mini-i2c             -392            -456   *           -1440   -1488  -1312  -424   -456
revo-mini-i2c-bdshot      -392            -456   *           -1440   -1488  -1304  -416   -448
speedybeef4               -392            -456   *           -1440   -1488  -1312  -424   -456
speedybeef4v3             -392            -456   *           -1440   -1488  -1408  -424   -456
speedybeef4v4             -400            -464   *           -1440   -1488  -1408  -424   -464
------------------------  --------------  -----  ----------  ------  -----  -----  -----  ----

@IamPete1
Copy link
Member

IamPete1 commented Feb 2, 2024

Unfortunately because the enable function directly sets the enable parameter its perfectly possible to have the parameter disabled at boot. Then enable via RC or mission command at some later point.

The 3 pos switch actually enables and then immediately deploys.

copter.parachute.enabled(true);
copter.parachute_manual_release();

I think the only way to check is to look for the outputs being setup. I'm not really sure how you can do that.... on master its quite easy because you can look for the parachute servo or relay output functions. However, the relay param conversion likely won't have been done in this case (and won't be done if the chute lib is missing) so you would probably have to also look at the old pin param too....

@andyp1per
Copy link
Collaborator

Unfortunately because the enable function directly sets the enable parameter its perfectly possible to have the parameter disabled at boot. Then enable via RC or mission command at some later point.

The 3 pos switch actually enables and then immediately deploys.

copter.parachute.enabled(true);
copter.parachute_manual_release();

I think the only way to check is to look for the outputs being setup. I'm not really sure how you can do that.... on master its quite easy because you can look for the parachute servo or relay output functions. However, the relay param conversion likely won't have been done in this case (and won't be done if the chute lib is missing) so you would probably have to also look at the old pin param too....

At some point we have bite the bullet and remove this. I'm pretty sure the number of people that this might affect is vanishingly small if not 0. Eventually you just have to print a big fat warning and move on.

@IamPete1
Copy link
Member

IamPete1 commented Feb 2, 2024

At some point we have bite the bullet and remove this. I'm pretty sure the number of people that this might affect is vanishingly small if not 0. Eventually you just have to print a big fat warning and move on.

Well, the point is we can't tell, so we can't print the warning. It should be in the release notes of course. I agree the number of users this affects is probbibly very small, but those that it does affect will have a very bad day.

Note that this odd enable stuff also affects the param conversion to the new relay functions, #26132 so we might have already broken it for all those people already....

@peterbarker
Copy link
Contributor Author

We should probably check that parameter conversion code :-)

We could add an additional check that the user doesn't have an RC switch configured for it. And a Mission check that they don't have any parachutey stuff in there either.

Which leaves triggering via mavlink, scripting and buttons, I think. I don't think we can do anything about those.... would that (along with release notes!) be enough to say we've made a best-effort?

@rmackay9 rmackay9 mentioned this pull request Feb 13, 2024
92 tasks
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants