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

Reorganize subsystems/commands to be more readable & consistent #2

Merged
merged 30 commits into from Mar 18, 2022

Conversation

5t0n3
Copy link
Member

@5t0n3 5t0n3 commented Mar 16, 2022

For commands, I tried to rename them to better reflect what they do. I've also started trying to migrate away from InstantCommands since they're meant to be used in only one place, and we were repeating them. Commands were also moved to the respective folders based on the subsystems they act on, or the utilities folder if they don't act on a subsystem.

In the way of subsystems:

  • I removed some unused code from ShooterSubsystem, and moved calculations to utilities/ShooterMath.java (although this file only has one method).
  • I tried to document the methods in DriveSubsystem more, as well as added odometry back in for use with RAMSETE control.

I haven't really touched the other subsystems yet, but I might in future commits.

We should also definitely test these changes before merging them into main.

5t0n3 added 21 commits March 11, 2022 08:46
TaxiThenShoot (and by extension RampThenShoot) no longer depend on supplying a
controller.

ClimbEasyHighBar and ClimbTimed timings have been tuned a bit.

Timeouts were also added for AlignWithHubSmart because it wasn't
reaching its goal, preventing drivers from driving the robot.
Also added in some delays to ClimbTimed.

The default angle in ShooterSubsystem was changed to 12 from 5 as well.
Increased feedforward constant for turning with Smart Motion because of
increase friction due to the carpet.

Increased the current limit for the intake arm to 15 amps, and Increased
its max power to full power.

Undo port forwarding because it might be causing robot code to cut out?

Added reversal for intake and indexer.

Intake now runs for all of TaxiThenShoot autonomous.

Also fixed RampThenShoot, as it was throwing a NullPointerException in
the past.

Intake lift motors were changed to coast mode from brake mode to avoid
shredding the gears (they're aluminum).
Added arbitrary feedforward power for turning using Smart Motion.

Secondary camera feed is now functional, but for some reason the
limelight feed doesn't work on the driver station.

Adjusted ClimbTimed timings again.

Started implementing speed switching in DefaultDrive but didn't finish.

IntakeLift is meant to be used when the intake lift motors are in brake
mode to reduce wear on the gears.

Shooter ramp time in RampThenShoot was increased to a maximum of 1
second.
Also move calculations to utilities/ShooterMath.java, although that
might not be necessary.
@5t0n3 5t0n3 added the enhancement New feature or request label Mar 16, 2022
@5t0n3 5t0n3 self-assigned this Mar 16, 2022
@5t0n3 5t0n3 marked this pull request as ready for review March 16, 2022 04:13
@5t0n3 5t0n3 marked this pull request as draft March 16, 2022 04:14
I don't know why this was necessary but here we are.
This also required a few changes elsewhere due to removed/renamed
methods.
This included the renaming of some methods & changes elsewhere to
reflect these new names.

An enum switch is now used for RunUpperIndexer, just as with
RunIntakeRoller.
Also fixed a few NullPointerExceptions and the like elsewhere.
@5t0n3 5t0n3 marked this pull request as ready for review March 18, 2022 00:27
@5t0n3 5t0n3 merged commit f7f28ec into main Mar 18, 2022
@5t0n3 5t0n3 deleted the reorganization branch March 24, 2022 21:23
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants