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

Plane: add option to use boost motor in forward flight, tiltrotors and tailsitters only #12865

Closed
wants to merge 2 commits into from

Conversation

IamPete1
Copy link
Member

This gives the option to use the boost motor in forward flight, this is actually an improvement because currently the boost motor can be used in Q modes but just stays at its last value in forward flight. This fixes that.

Tested with a Realflight model from Fanman

https://discuss.ardupilot.org/t/new-tricopter-quadplane-concept/47469?u=iampete

@IamPete1 IamPete1 requested a review from kd0aij November 21, 2019 15:00
Copy link
Contributor

@kd0aij kd0aij left a comment

Choose a reason for hiding this comment

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

LGTM, I tested in RF8 and the boost motor seemed to work correctly in qhover and fbwa

While this shouldn't affect tiltrotors and MatrixTailsitters if the q_option bit isn't set, I assume this hasn't been tested for those cases.

@IamPete1
Copy link
Member Author

@kd0aij I tested on a tiltrotor, it works as it should. The user wants the boost motor to be the only tilting one. Should work for tailsitters also although not tested myself.

I put this in for MatrixTailsitters also but I think in that case its actuality not useful because I'm not sure if they output the boost motor in hover in the first place.

Copy link

@Fanman74 Fanman74 left a comment

Choose a reason for hiding this comment

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

Checked all modes, FBWA, QHOVER, Stabilize, Manual & QRTL. SITL model behaves as expected.

@kd0aij
Copy link
Contributor

kd0aij commented Feb 26, 2020

I had forgotten about this PR... This brings up a question as to why the "boost" motor wasn't handled by just adding it as a separate frame type, so that the motor mask could be used to enable/disable it in forward flight. The disadvantage would be that you would have to add a frame type for every motor configuration (quad/hex/etc). But then use of the boost motor could be more sophisticated; instead of a static boost scale factor, output_armed_stabilizing() could include the presence of a boost motor in its calculations, perhaps enhancing stability when a motor is lost.

@kd0aij
Copy link
Contributor

kd0aij commented Feb 27, 2020

I think you only need the new options bits and argument to output_motor_mask because the boost motor isn't in the logical motor_mask. Perhaps there's a better way to do this... maybe add a new frame type which includes the boost motor. Then you would also have a way to specify whether or not the boost motor tilts (and is active in forward flight) using tilt_mask. It might be a good idea to add a separate mask to indicate which motors are active in forward flight too, if there is ever a case in which non-tilting motors should remain active.

@IamPete1
Copy link
Member Author

we should probably also convert the param uint16_t. Currently if you have a boost motor it is always output in hover and this gives the option to also output it in forward flight. Not a fan of doing new mixers, then we have to do a new one each time. This supports all frames.

I will re-base this and see how its looking

@kd0aij
Copy link
Contributor

kd0aij commented Feb 27, 2020

There's a bug in AP_MotorsMulticopter::output_boost_throttle() too: if you change MOT_BOOST_SCALE to zero, the boost motor keeps running at its last value.

@IamPete1
Copy link
Member Author

rebased

@IamPete1
Copy link
Member Author

I don't remember the use case for this, it conflicts so I'm closing.

@IamPete1 IamPete1 closed this Oct 27, 2020
@Fanman74
Copy link

What is the conflict? have been testing the boost motor for the forward flight propulsion unit.

@IamPete1
Copy link
Member Author

@Fanman74 There were file conflicts, this would need a little work to rebase on master.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants