Skip to content

Commit

Permalink
Flash aqua on source pickup
Browse files Browse the repository at this point in the history
  • Loading branch information
superpenguin612 committed Mar 22, 2024
1 parent c20670a commit c64038e
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 2 deletions.
6 changes: 5 additions & 1 deletion src/main/java/frc/robot/Controls.java
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@
import frc.robot.subsystems.NoteLift;
import frc.robot.subsystems.Shooter;
import frc.robot.subsystems.ShooterTilt;
import frc.robot.subsystems.LEDs.LEDState;

public class Controls {
public static void configureDriverControls(int port, Drivetrain drivetrain, Intake intake, Shooter shooter,
Expand Down Expand Up @@ -71,7 +72,10 @@ public static void configureDriverControls(int port, Drivetrain drivetrain, Inta
.alongWith(shooterTilt.moveToPositionCommand(() -> ShooterTiltPosition.INTAKE).asProxy()))
.onFalse(intake.moveToPositionCommand(() -> IntakePosition.STOW));

joystick.centerTopHatButton().whileTrue(intake.intakeFromSourceCommand())
joystick.centerTopHatButton().whileTrue(
Commands.parallel(
intake.intakeFromSourceCommand(),
leds.requestStateCommand(LEDState.FLASHING_AQUA)))
.onFalse(intake.moveToPositionCommand(() -> IntakePosition.STOW));

joystick.redButton().whileTrue(RobotCommands.ampPrepIntakeCommand(intake, shooterTilt))
Expand Down
3 changes: 2 additions & 1 deletion src/main/java/frc/robot/subsystems/LEDs.java
Original file line number Diff line number Diff line change
Expand Up @@ -52,9 +52,10 @@ public enum LEDState {

FLASHING_WHITE(flash(Color.kWhite, 0.5, LEDSection.ALL)),
SUBWOOFER_ONLY(flash(Color.kYellow, 1, LEDSection.SHOOTER_TOP)),
PODIUM_ONLY(flash(Color.kAqua, 1, LEDSection.SHOOTER_TOP)),
PODIUM_ONLY(flash(Color.kBlue, 1, LEDSection.SHOOTER_TOP)),
SOLID_BLUE(solid(Color.kBlue, LEDSection.ALL)),
SOLID_GREEN(solid(Color.kGreen, LEDSection.ALL)),
FLASHING_AQUA(flash(Color.kAqua, 0.5, LEDSection.ALL)),
PURPLE_WAVE(wave(new Color("#9000DD"), 30, 20, 100, 255,
LEDSection.SHOOTER)),
RAINBOW(rainbow(255, 3, LEDSection.ALL)),
Expand Down

0 comments on commit c64038e

Please sign in to comment.