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 attitude controller clean up #22472

Merged
merged 7 commits into from
Dec 7, 2023
Merged

Conversation

sfuhrer
Copy link
Contributor

@sfuhrer sfuhrer commented Dec 1, 2023

Clean up / refactor the FW attitude control classes a bit.

Originally we used to have a fixed-wing "attitude" controller library that also contained the rate control methods. That was then moved to the new fixed-wing rate control module. Currently there is though still the wheel attitude and rate control in it, together with the attitude controller for the in-flight phase. As these controllers are largely different (different inputs etc), I find it cleaner to completely split it up into four classes that don't share a common base class:

RollController
PitchController
YawController
WheelController

Going forward we can then also place the wheel controller at a different place if needed, as it's no longer linked to the attitude controller.

@sfuhrer sfuhrer self-assigned this Dec 1, 2023
@dagar
Copy link
Member

dagar commented Dec 1, 2023

Nice, definitely long overdue.

…to header

Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
Copy link
Member

@Jaeyoung-Lim Jaeyoung-Lim left a comment

Choose a reason for hiding this comment

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

Awesome! Thanks for the long overdue refactor.
Nothing really stands out and looks good to me :)

For moving forward -> Do we want to keep the structure of controllers controlling the three axis independently? Or would it be better to have a full attitude based error metric (e.g. quaternion based like multicopters) for controlling attitude?

@sfuhrer
Copy link
Contributor Author

sfuhrer commented Dec 7, 2023

Or would it be better to have a full attitude based error metric (e.g. quaternion based like multicopters) for controlling attitude?

Nothing speaks against having a unified one. Ideally even a shared one between MC/FW. We just need to find a good place for the turn coordination controller.

@sfuhrer sfuhrer merged commit c61ac78 into main Dec 7, 2023
88 of 90 checks passed
@sfuhrer sfuhrer deleted the pr-fw-att-c-clean-up-ecl-main branch December 7, 2023 16:21
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

3 participants