Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 6 additions & 6 deletions src/main/java/raidzero/robot/RobotContainer.java
Original file line number Diff line number Diff line change
Expand Up @@ -102,7 +102,7 @@ private void configureBindings() {
climbWinch.setDefaultCommand(climbWinch.stop());

// * Driver controls
joystick.rightBumper().whileTrue(
joystick.rightTrigger().whileTrue(
swerve.applyRequest(
() -> fieldCentricDrive
.withVelocityX(-joystick.getLeftY() * MaxSpeed * (arm.isUp() ? 0.3 : 1.0))
Expand All @@ -111,8 +111,8 @@ private void configureBindings() {
)
);

joystick.rightBumper().onTrue(new InstantCommand(() -> armStrip.setStrobeInterval(0.15)));
joystick.rightBumper().negate().onTrue(new InstantCommand(() -> armStrip.setStrobeInterval(0.5)));
joystick.rightTrigger().onTrue(new InstantCommand(() -> armStrip.setStrobeInterval(0.15)));
joystick.rightTrigger().negate().onTrue(new InstantCommand(() -> armStrip.setStrobeInterval(0.5)));

joystick.a().whileTrue(
swerve.applyRequest(
Expand All @@ -121,8 +121,8 @@ private void configureBindings() {
)
);

joystick.leftTrigger().whileTrue(coralIntake.extake());
joystick.rightTrigger().onTrue(coralIntake.intake());
joystick.leftBumper().whileTrue(coralIntake.extake());
joystick.rightBumper().onTrue(coralIntake.intake());

joystick.b().whileTrue(
swerve.pathToStation()
Expand Down Expand Up @@ -178,7 +178,7 @@ private void configureBindings() {

operator.button(Constants.Bindings.CORAL_EXTAKE).whileTrue(coralIntake.extake());
operator.button(Constants.Bindings.CORAL_INTAKE).onTrue(coralIntake.intake());
operator.button(Constants.Bindings.CORAL_SCOOCH).onTrue(coralIntake.scoochCoral());
operator.button(Constants.Bindings.CORAL_SCOOCH).whileTrue(coralIntake.run(-Constants.TelescopingArm.Intake.EXTAKE_SPEED));

operator.button(Constants.Bindings.BOTTOM_RIGHT).onTrue(coralIntake.unstuckServo());

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -76,16 +76,6 @@ public Command intake() {
.until(() -> getBottomLaserDistance() <= Constants.TelescopingArm.Intake.LASERCAN_DISTANCE_THRESHOLD_MM);
}

/**
* Creates a {@link Command} to scooch the coral upwards if too low
*
* @return A {@link Command} to scooch the coral upwards
*/
public Command scoochCoral() {
return run(() -> roller.set(-Constants.TelescopingArm.Intake.INTAKE_LOWER_SPEED))
.until(() -> getTopLaserDistance() <= Constants.TelescopingArm.Intake.LASERCAN_DISTANCE_THRESHOLD_MM);
}

/**
* Creates a {@link Command} to move the coral upwards to unstuck the servo block
*
Expand Down