Skip to content

Commit

Permalink
Disable rumble
Browse files Browse the repository at this point in the history
  • Loading branch information
AceiusRedshift committed Apr 3, 2024
1 parent 64e254c commit a12c7d6
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 3 deletions.
2 changes: 2 additions & 0 deletions src/main/java/frc/robot/Constants.java
Original file line number Diff line number Diff line change
Expand Up @@ -106,6 +106,8 @@ public static class DriverConstants {
// max angular velocity for drivetrain, in radians per second
public static final double[] maxSpeedOptionsRotation = { 0.25 * MAX_ROTATION_SPEED, 0.5 * MAX_SPEED,
0.85 * MAX_SPEED, MAX_SPEED };

public static final boolean ENABLE_RUMBLE = false;
}

public static class ArmConstants {
Expand Down
10 changes: 7 additions & 3 deletions src/main/java/frc/robot/commands/Autos.java
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@
import edu.wpi.first.wpilibj2.command.WaitCommand;
import frc.robot.Constants;
import frc.robot.Constants.ArmConstants;
import frc.robot.Constants.DriverConstants;
import frc.robot.Constants.IntakeShooterConstants;
import frc.robot.RobotContainer;
import frc.robot.subsystems.SwerveDrivetrain;
Expand Down Expand Up @@ -182,9 +183,12 @@ public static Command shootInSpeaker(SwerveDrivetrain drivetrain, Arm arm, Intak
new SpinFlywheelShooter(shooter, 0),
new SpinIntakeGrabbers(shooter, 0),
new ArmRotateTo(arm, ArmConstants.ARM_STOW_2_DEGREES)),
new SetControllerRumbleFor(robotContainer.driverXboxRaw, 3, 1),
new SetControllerRumbleFor(robotContainer.operatorXboxRaw, 3, 1))
.onlyIf(shouldRunSupplier);
DriverConstants.ENABLE_RUMBLE ? new SetControllerRumbleFor(robotContainer.driverXboxRaw, 3, 1)
: Commands.sequence(),
DriverConstants.ENABLE_RUMBLE ? new SetControllerRumbleFor(robotContainer.operatorXboxRaw, 3, 1)
: Commands.sequence()
// if rumble isn't enabled pass an empty sequence instead
).onlyIf(shouldRunSupplier);
}

public static Command intakeFromFloorStart(Arm arm, IntakeShooter shooter) {
Expand Down

0 comments on commit a12c7d6

Please sign in to comment.