Skip to content
This repository has been archived by the owner on Mar 23, 2024. It is now read-only.

Implemented WingsailController Class #27

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

Conversation

evannawfal
Copy link
Contributor

@evannawfal evannawfal commented Feb 18, 2024

Description

Made a Wingsail Controller class and a class for testing as well.

Verification

Created tests to validate functionality.

Resources

#20

Copy link
Contributor

@DFriend01 DFriend01 left a comment

Choose a reason for hiding this comment

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

Good initial work. There are a few things that need to be addressed before this can be merged into the main branch.

controller/wingsail/controllers.py Outdated Show resolved Hide resolved
controller/wingsail/controllers.py Outdated Show resolved Hide resolved
controller/wingsail/controllers.py Outdated Show resolved Hide resolved
controller/wingsail/controllers.py Show resolved Hide resolved
tests/unit/wingsail/test_controllers.py Show resolved Hide resolved
@DFriend01
Copy link
Contributor

DFriend01 commented Feb 18, 2024

@evannawfal Please change the title of the PR to something more descriptive. This is the message that shows up in the commit history in the main branch, so it needs to be descriptive enough for others to have a high-level understanding of what this PR was for.

@evannawfal evannawfal changed the title User/evannawfal/21 sail controller class Implemented WingsailController Class Mar 2, 2024
controller/common/constants.py Outdated Show resolved Hide resolved
controller/wingsail/controllers.py Outdated Show resolved Hide resolved
controller/wingsail/controllers.py Outdated Show resolved Hide resolved
controller/wingsail/controllers.py Outdated Show resolved Hide resolved
Comment on lines +60 to +62
def get_trim_tab_angle(
self, apparent_wind_speed: float, apparent_wind_direction: float
) -> float:
Copy link
Contributor

Choose a reason for hiding this comment

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

I recommend overloading this function where you accept the apparent wind vector, calculate the wind speed and direction, and then call this function to get the trim tab angle.

Copy link
Contributor

Choose a reason for hiding this comment

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

Let's hold off doing this until we figured out the angle convention.

controller/wingsail/controllers.py Show resolved Hide resolved
tests/unit/wingsail/test_controllers.py Outdated Show resolved Hide resolved
tests/unit/wingsail/test_controllers.py Show resolved Hide resolved
tests/unit/wingsail/test_controllers.py Outdated Show resolved Hide resolved
@DFriend01
Copy link
Contributor

We want to change the angle convention as per our conversation, but let's leave that in another issue

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

Successfully merging this pull request may close these issues.

Sail Controller Class
2 participants