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

Fixed-wing Position Control: Split up control methods for VTOL backtransition #23893

Open
wants to merge 6 commits into
base: main
Choose a base branch
from

Conversation

RomanBapst
Copy link
Contributor

@RomanBapst RomanBapst commented Nov 5, 2024

Solved Problem

Previously, the method to control a transition to hover was handling both cases when position was available, and when it was not available.
It's cleaner to have the methods separates for once. Other than that, the method which controls the transition for the case when position is not available, now does heading hold, which is better than just demanded 0 roll, which was done previously.

Changelog Entry

Control heading during backtransition when local position is not available.

Test coverage

Currently tested in SITL, following up with plots from real tests.

Context

The figure below is from a simulation, where the vehicle approaches the transition point with a 10m/s crosswind (see large difference between heading and track)
The heading of the vehicle is tracked as the initial heading when local position is lost (when the nav state changes).
The roll angle setpoint is continuous, despite the mode switch. This is because the controller had already compensated for the crosswind when approaching the transition waypoint.
image

@RomanBapst RomanBapst requested a review from sfuhrer November 5, 2024 08:12
Copy link
Contributor

@sfuhrer sfuhrer left a comment

Choose a reason for hiding this comment

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

Have you already some flight testing results to share? I'm curious to see if it really makes a difference to control heading in the Descend case or not.

src/modules/fw_pos_control/FixedwingPositionControl.cpp Outdated Show resolved Hide resolved
@RomanBapst
Copy link
Contributor Author

Have you already some flight testing results to share? I'm curious to see if it really makes a difference to control heading in the Descend case or not.

@sfuhrer Yes, the reason I implemented this was actually because the test vehicle flew a turn with the previous implementation, which was just to set roll to 0. I guess it makes a big difference it you have crosswind or not.
Also, I think this is cleaner in general.

sfuhrer
sfuhrer previously approved these changes Nov 28, 2024
Copy link
Contributor

@sfuhrer sfuhrer left a comment

Choose a reason for hiding this comment

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

Just some minor comments.
Let's clean up the commits or squash merge.

@sfuhrer sfuhrer changed the title Split up control methods for backtransition Fixed-wing Position Control: Split up control methods for VTOL backtransition Nov 28, 2024
Signed-off-by: RomanBapst <[email protected]>
Signed-off-by: RomanBapst <[email protected]>
Copy link
Contributor

@sfuhrer sfuhrer left a comment

Choose a reason for hiding this comment

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

still over flash on v6x but otherwise good to go.

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

Successfully merging this pull request may close these issues.

2 participants