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

Allow scaled passthru to go to trim on rc failsafe #24036

Merged
merged 7 commits into from Jun 29, 2023

Conversation

Hwurzburg
Copy link
Collaborator

Allows selecting any scaled passthru channel to go to input trim on rc failsafe instead of freezing
Allows pilot controlled gimbals to revert to forward position while returning to home

builds off some of @peterbarker work

@Hwurzburg Hwurzburg requested a review from rmackay9 June 12, 2023 08:25
Copy link
Member

@IamPete1 IamPete1 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Do we need per channel options? Would one bit for all in RC_OPTIONS work?

@Hwurzburg
Copy link
Collaborator Author

Do we need per channel options? Would one bit for all in RC_OPTIONS work?

No...could have some pass thru things like airbrakes/slats...lights...etc that you want to stay unchanged while in fs also

@IamPete1
Copy link
Member

Another option instead of a new parameter is to add another bunch of 16 scaled output functions for "RC in scaled trim in FS".

But I tend to think were getting a little too niche for most users and might be better just to say use scripting at this point. For example what if I want my scaled output to go to min or max on failsafe, should we add more parameters for that?

@Hwurzburg Hwurzburg force-pushed the passthru_fs branch 2 times, most recently from 18eb384 to 0377fe9 Compare June 13, 2023 01:19
@Hwurzburg
Copy link
Collaborator Author

scripting is not available on many popular autopilots.....the F4 class is resurging with the new Chinese cpus also

@IamPete1
Copy link
Member

I guess a alternative would be to still update rc in while in failsafe. Then you could set your failsafe positions in the transmitter and have them passed through.

@Hwurzburg
Copy link
Collaborator Author

Not a solution for rc failure failsafes...that is why we recommend using no pulses

@Hwurzburg
Copy link
Collaborator Author

SITL and board tested

@IamPete1
Copy link
Member

Would fixing #24093 remove the need for this PR?

@Hwurzburg
Copy link
Collaborator Author

no...thats gimbal....and this PR actually stimulated that for the Gimbal library...this covers nonGimbal library applications...ie just a couple of servos which are pilot only controlled

libraries/SRV_Channel/SRV_Channel.h Outdated Show resolved Hide resolved
libraries/SRV_Channel/SRV_Channel_aux.cpp Outdated Show resolved Hide resolved
@rmackay9
Copy link
Contributor

In general this looks OK to me. I worry a little about scope creep going forward and the leak of failsafe actions out of the vehicle code and into the libraries.

@peterbarker peterbarker merged commit 53a4194 into ArduPilot:master Jun 29, 2023
81 checks passed
@Hwurzburg Hwurzburg deleted the passthru_fs branch June 29, 2023 15:02
@Hwurzburg Hwurzburg added the WikiNeeded needs wiki update label Jul 5, 2023
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.

None yet

6 participants