V2#84
Conversation
There was a problem hiding this comment.
Pull request overview
This PR updates multiple robot subsystems and command flows to a “V2” hardware/software layout, including a redesigned shooter (4 motors + SysId), a new motor-driven shooter hood, and a new HopperExtension mechanism, with corresponding updates across commands, operator/driver bindings, and autonomous routines.
Changes:
- Replaces the old dual “ShooterHoods” (servo hub) implementation with a single motor-driven
ShooterHoodsubsystem and updates commands/dashboard bindings accordingly. - Refactors
Shooterto a 4-motor SparkMax setup and adds SysId characterization hooks plus a newShooterSysIDauton. - Introduces
HopperExtension+ command, removesAcquisitionPivot(and its commands/constants), and updates autos + joystick bindings.
Reviewed changes
Copilot reviewed 38 out of 41 changed files in this pull request and generated 10 comments.
Show a summary per file
| File | Description |
|---|---|
| src/main/java/frc/robot/subsystems/SwagLights.java | Makes SerialPort field final. |
| src/main/java/frc/robot/subsystems/ShooterHoods.java | Removes legacy servo-hub-based hood subsystem. |
| src/main/java/frc/robot/subsystems/ShooterHood.java | Adds new motor-driven shooter hood subsystem (SparkMax + absolute encoder). |
| src/main/java/frc/robot/subsystems/Shooter.java | Refactors shooter to 4 SparkMax motors, adds SysId routine helpers, updates distance/angle math. |
| src/main/java/frc/robot/subsystems/Kicker.java | Refactors kicker into two SparkFlex motors (kicker + feeder) with separate controllers. |
| src/main/java/frc/robot/subsystems/Indexer.java | Switches indexer motor controller to SparkFlex and renames forward/reverse actions. |
| src/main/java/frc/robot/subsystems/HopperExtension.java | Adds new hopper extension subsystem with limit switches and closed-loop control. |
| src/main/java/frc/robot/subsystems/Dashboard.java | Updates shooter hood constants reference; removes acquisition tilt dashboard value. |
| src/main/java/frc/robot/subsystems/AcquisitionPivot.java | Removes legacy acquisition pivot subsystem. |
| src/main/java/frc/robot/subsystems/Acquisition.java | Changes acquisition from duty-cycle control to velocity control with configured PID/FF. |
| src/main/java/frc/robot/constants/ShooterHoodsConstants.java | Removes old servo hood constants. |
| src/main/java/frc/robot/constants/ShooterHoodConstants.java | Adds new shooter hood constants (CAN IDs, limits, PID/FF placeholders). |
| src/main/java/frc/robot/constants/ShooterConstants.java | Updates shooter motor CAN IDs and replaces module translation constants with barrel center offset. |
| src/main/java/frc/robot/constants/KickerConstants.java | Splits constants for kicker vs feeder motor/controllers and adds feeder RPMs. |
| src/main/java/frc/robot/constants/IndexerConstants.java | Updates CAN ID and replaces duty-cycle constants with forward/backward power. |
| src/main/java/frc/robot/constants/HopperExtensionConstants.java | Adds new constants for hopper extension control. |
| src/main/java/frc/robot/constants/AcquisitionPivotConstants.java | Removes legacy pivot constants. |
| src/main/java/frc/robot/constants/AcquisitionConstants.java | Updates CAN ID and adds PID/FF + RPM setpoints for velocity control. |
| src/main/java/frc/robot/commands/ShootCommand.java | Updates shooter usage and removes acquisition pivot/tilt timing logic. |
| src/main/java/frc/robot/commands/RetractHoodsCommand.java | Removes old dual-hood retract command. |
| src/main/java/frc/robot/commands/RetractHoodCommand.java | Adds new single-hood retract command. |
| src/main/java/frc/robot/commands/IndexerCommand.java | Renames Mode enum and updates indexer direction method calls. |
| src/main/java/frc/robot/commands/HopperExtensionCommand.java | Adds command to drive hopper extension until limit switch triggers. |
| src/main/java/frc/robot/commands/AlignCommand.java | Updates alignment logic to aim using field target vector rather than shooter module bisector. |
| src/main/java/frc/robot/commands/AdjustHoodCommand.java | Renames/updates hood adjustment command for new single hood subsystem. |
| src/main/java/frc/robot/commands/AcquisitionPivotTrenchRetract.java | Removes legacy pivot trench retract command. |
| src/main/java/frc/robot/commands/AcquisitionPivotCommand.java | Removes legacy acquisition pivot setpoint command. |
| src/main/java/frc/robot/commands/AcquisitionCommand.java | Renames Mode enum and updates naming around intake/dispose direction. |
| src/main/java/frc/robot/autons/ShooterSysID.java | Adds new SysId auton sequence for shooter characterization. |
| src/main/java/frc/robot/autons/RightTrenchAuto.java | Updates command sequence to use hopper extension + new hood/shoot interfaces. |
| src/main/java/frc/robot/autons/RightPreloadAuto.java | Updates preload auton to use hopper extension + new hood/shoot interfaces. |
| src/main/java/frc/robot/autons/MiddlePreloadAuto.java | Updates preload auton to use hopper extension + new hood/shoot interfaces. |
| src/main/java/frc/robot/autons/LeftTrenchAuto.java | Updates command sequence to use hopper extension + new hood/shoot interfaces. |
| src/main/java/frc/robot/autons/LeftPreloadAuto.java | Updates preload auton to use hopper extension + new hood/shoot interfaces. |
| src/main/java/frc/robot/autons/DepotAuto.java | Updates depot auton to use hopper extension + new hood/shoot interfaces. |
| src/main/java/frc/robot/autons/AutonSelector.java | Adds ShooterSysID to auton choices and chooser options. |
| src/main/java/frc/robot/OperatorJoystick.java | Updates bindings to new hopper extension + retract hood + simplified shoot command. |
| src/main/java/frc/robot/DriverJoystick.java | Updates default/trigger commands to use new hood commands and subsystem. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
| import java.io.IOException; | ||
| import java.util.Optional; | ||
|
|
||
| import frc.robot.commands.*; |
There was a problem hiding this comment.
Wildcard import (import frc.robot.commands.*;) diverges from the explicit-import style used elsewhere in autons (e.g., RightPreloadAuto uses explicit command imports at src/main/java/frc/robot/autons/RightPreloadAuto.java:5-9). Please switch back to explicit imports to keep dependencies clear.
| import frc.robot.commands.*; | |
| import frc.robot.commands.AcquisitionCommand; | |
| import frc.robot.commands.AdjustHoodCommand; | |
| import frc.robot.commands.AlignCommand; | |
| import frc.robot.commands.HopperExtensionCommand; | |
| import frc.robot.commands.ShootCommand; |
| import java.io.IOException; | ||
| import java.util.Optional; | ||
|
|
||
| import frc.robot.commands.*; |
There was a problem hiding this comment.
Wildcard import (import frc.robot.commands.*;) diverges from the explicit-import style used elsewhere in autons (e.g., RightPreloadAuto uses explicit command imports at src/main/java/frc/robot/autons/RightPreloadAuto.java:5-9). Please switch back to explicit imports to keep dependencies clear.
| import frc.robot.commands.*; | |
| import frc.robot.commands.AcquisitionCommand; | |
| import frc.robot.commands.AdjustHoodCommand; | |
| import frc.robot.commands.AlignCommand; | |
| import frc.robot.commands.HopperExtensionCommand; | |
| import frc.robot.commands.ShootCommand; |
|
|
||
| @Override | ||
| public void initialize() { | ||
| shooterHood.setAngle(ShooterHoodConstants.SHOOTER_FULL_RETRACTION_ANGLE); |
There was a problem hiding this comment.
This command sets the hood angle to SHOOTER_FULL_RETRACTION_ANGLE, but ShooterHood.setAngle() clamps angles to ShooterHoodConstants.MAX_ANGLE. With the current constants, the requested value is above MAX_ANGLE, so the hood will never actually reach the commanded value. Consider using MAX_ANGLE here (or adjust the constants so full retraction is within the valid range).
| shooterHood.setAngle(ShooterHoodConstants.SHOOTER_FULL_RETRACTION_ANGLE); | |
| shooterHood.setAngle(ShooterHoodConstants.MAX_ANGLE); |
| import java.io.IOException; | ||
| import java.util.Optional; | ||
|
|
||
| import frc.robot.commands.*; |
| import java.io.IOException; | ||
| import java.util.Optional; | ||
|
|
||
| import frc.robot.commands.*; |
| import java.io.IOException; | ||
| import java.util.Optional; | ||
|
|
||
| import frc.robot.commands.*; |
| classDiagram | ||
| direction LR | ||
|
|
||
| class ShooterConstants { |
There was a problem hiding this comment.
why was this final removed?
| direction LR | ||
|
|
||
| class ShooterFormula { | ||
| <<static inner>> |
There was a problem hiding this comment.
Is shooter formula still static inner?
| classDiagram | ||
| direction LR | ||
|
|
||
| class SwerveConstants { |
There was a problem hiding this comment.
Why was this final removed?
| classDiagram | ||
| direction LR | ||
|
|
||
| class VisionConstants { |
| Right | ||
| None | ||
| } | ||
| classDiagram |
There was a problem hiding this comment.
Why are there even changes to this file?
|
Now that the hoods won't hit the trench, can we bring back the hood adjustment running constantly? |
Pull Request
Closes #83
Issue Number
Comments