Skip to content

Commit

Permalink
delete unused code
Browse files Browse the repository at this point in the history
  • Loading branch information
MichaelLesirge committed Feb 24, 2024
1 parent 8985324 commit 2c5f12c
Show file tree
Hide file tree
Showing 3 changed files with 2 additions and 25 deletions.
21 changes: 0 additions & 21 deletions src/main/java/frc/robot/RobotContainer.java
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,6 @@
import frc.robot.Constants.ArmConstants;
import frc.robot.subsystems.Arm;
import frc.robot.commands.Autos;
import frc.robot.commands.ArmRemoteControl;
import frc.robot.commands.ArmRotateTo;
import frc.robot.commands.ChassisRemoteControl;
import frc.robot.Constants.VisionConstants;
Expand Down Expand Up @@ -122,7 +121,6 @@ public void setUpDriveController() {

drivetrain.removeDefaultCommand();

ArmRemoteControl armInputs;
ChassisDriveInputs inputs;
OptionButtonInput preciseModeButton, boostModeButton, fieldRelativeButton;

Expand All @@ -135,15 +133,6 @@ public void setUpDriveController() {
joystick::getTwist, -1,
Constants.DriverConstants.DEAD_ZONE);

armInputs = new ArmRemoteControl(arm,
new OptionButtonInput(joystick,11, ActivationMode.HOLD),
new OptionButtonInput(joystick,12, ActivationMode.HOLD),

new OptionButtonInput(joystick, 4, ActivationMode.HOLD),
new OptionButtonInput(joystick, 5, ActivationMode.HOLD),
new OptionButtonInput(joystick, 6, ActivationMode.HOLD)
);

preciseModeButton = new OptionButtonInput(joystick, 2, ActivationMode.TOGGLE);
boostModeButton = new OptionButtonInput(joystick, 1, ActivationMode.HOLD);
fieldRelativeButton = new OptionButtonInput(joystick, 3, ActivationMode.TOGGLE);
Expand All @@ -164,16 +153,6 @@ public void setUpDriveController() {
xbox::getRightX, -1,
Constants.DriverConstants.DEAD_ZONE);

armInputs = new ArmRemoteControl(arm,
new OptionButtonInput(xbox::rightBumper, ActivationMode.HOLD),
new OptionButtonInput(xbox::leftBumper, ActivationMode.HOLD),

new OptionButtonInput(xbox::povLeft, ActivationMode.HOLD),
new OptionButtonInput(xbox::povRight, ActivationMode.HOLD),
new OptionButtonInput(xbox::povDown, ActivationMode.HOLD)
);


preciseModeButton = new OptionButtonInput(xbox::b, ActivationMode.TOGGLE);
boostModeButton = new OptionButtonInput(xbox::leftStick, ActivationMode.HOLD);
fieldRelativeButton = new OptionButtonInput(xbox::povUp, ActivationMode.TOGGLE);
Expand Down
3 changes: 1 addition & 2 deletions src/main/java/frc/robot/commands/AutoRotateTo.java
Original file line number Diff line number Diff line change
Expand Up @@ -46,8 +46,7 @@ public AutoRotateTo(SwerveDrivetrain drivetrain, Rotation2d direction) {

@Override
public void initialize() {
currentAngleGoal = relative ? drivetrain.getHeading().getRadians()
: 0;
currentAngleGoal = relative ? drivetrain.getHeading().getRadians() : 0;
currentAngleGoal += angleGoal;
SmartDashboard.putNumber("Target Angle Auto", currentAngleGoal);
}
Expand Down
3 changes: 1 addition & 2 deletions src/main/java/frc/robot/commands/FollowTag.java
Original file line number Diff line number Diff line change
Expand Up @@ -52,8 +52,7 @@ public FollowTag(SwerveDrivetrain drivetrain, Vision vision, Transform2d targetD
*
* @param drivetrain the drivetrain of the robot
* @param vision the vision subsystem of the robot
* @param tagID the numerical ID of the the tag to follow, null
* for whatever best is
* @param tagID the numerical ID of the the tag to follow, null for whatever best is
* @param targetDistanceToTag the target distance away from the tag to be
* @param loseTagAfterSeconds how long to wait before giving up on rediscover
* tag, set to null to never finish
Expand Down

0 comments on commit 2c5f12c

Please sign in to comment.