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

Chassis update #5

Merged
merged 62 commits into from
Jan 13, 2024
Merged

Chassis update #5

merged 62 commits into from
Jan 13, 2024

Conversation

outsidermm
Copy link
Member

Rewrite chassis.py and physics.py using Pheonix 6 API and maintain TalonSRX support through Pheonix 5

@outsidermm outsidermm self-assigned this Jan 6, 2024
physics.py Outdated Show resolved Hide resolved
components/chassis.py Outdated Show resolved Hide resolved
components/chassis.py Outdated Show resolved Hide resolved
components/chassis.py Outdated Show resolved Hide resolved
components/chassis.py Outdated Show resolved Hide resolved
components/chassis.py Outdated Show resolved Hide resolved
components/chassis.py Outdated Show resolved Hide resolved
components/chassis.py Outdated Show resolved Hide resolved
components/chassis.py Outdated Show resolved Hide resolved
components/chassis.py Outdated Show resolved Hide resolved
components/chassis.py Outdated Show resolved Hide resolved
@outsidermm outsidermm marked this pull request as draft January 6, 2024 12:15
@@ -396,7 +417,7 @@ def get_tilt_rate(self) -> float:

@feedback
def get_drive_current(self) -> float:
return sum(abs(x.drive.getStatorCurrent()) for x in self.modules)
return sum(abs(x.drive.get_stator_current().value) for x in self.modules)
Copy link
Member

Choose a reason for hiding this comment

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

Eep, this is a code smell. The Chassis component should never have been reaching into the SwerveModule internals in the first place.

nit: add a SwerveModule.get_drive_current() -> float method

@outsidermm outsidermm added the bug Something isn't working label Jan 8, 2024
@outsidermm
Copy link
Member Author

Is the sim working for you guys? Amber says navx is having issues, but I'm having issues with the sim not showing the TalonFX objects on one of its tabs

robot.py Outdated
# print(pov)
if pov != -1:
joysticks[0] = 0
joysticks[1] = 0
Copy link
Member

Choose a reason for hiding this comment

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

What's with this joysticks list?

Copy link
Member

@auscompgeek auscompgeek left a comment

Choose a reason for hiding this comment

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

LGTM

@auscompgeek auscompgeek removed the bug Something isn't working label Jan 13, 2024
@LucienMorey LucienMorey merged commit 9110384 into main Jan 13, 2024
2 of 3 checks passed
@LucienMorey LucienMorey deleted the chassis-update branch January 13, 2024 00:35
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.

6 participants