Package frc.robot.subsystems
Class LEDs
java.lang.Object
edu.wpi.first.wpilibj2.command.SubsystemBase
frc.robot.subsystems.LEDs
LEDs subsystem
-
Constructor Summary
ConstructorsConstructorDescriptionLEDs
(AddressableLEDBuffer passedBuffer, int start, int end) constructorLEDs
(AddressableLEDBuffer passedBuffer, int start, int end, boolean reversed) -
Method Summary
Modifier and TypeMethodDescriptionBlink LEDsBlink LEDs for a certain timeoutvoid
periodic()
setLEDsBreathe
(Color color) Set LEDs to breathesetLEDsGradient
(Color color, Color color2) Set LEDs to color gradientsetLEDsSolid
(Color color) Set LEDs to solid colorsetPoliceLeds
(Boolean isRight) Set LEDs to police pattern/colorSets specified LED side to Rainbow even when disabledMethods inherited from class edu.wpi.first.wpilibj2.command.SubsystemBase
addChild, getName, getSubsystem, initSendable, setName, setSubsystem
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface edu.wpi.first.wpilibj2.command.Subsystem
defer, getCurrentCommand, getDefaultCommand, register, removeDefaultCommand, run, runEnd, runOnce, setDefaultCommand, simulationPeriodic, startEnd, startRun
-
Constructor Details
-
LEDs
constructor -
LEDs
-
-
Method Details
-
periodic
public void periodic() -
blinkLEDs
Blink LEDs- Parameters:
mainColor
- color to blink (on and off)- Returns:
- Command to blink leds
-
blinkLEDs
Blink LEDs for a certain timeout- Parameters:
mainColor
- color to blink (on and off)timeout
- Number of seconds to blink- Returns:
- Command to blink leds
-
setLEDsSolid
Set LEDs to solid color- Parameters:
color
- color to set the leds to solidly- Returns:
- Command to set leds to a solid color
-
setLEDsGradient
Set LEDs to color gradient- Parameters:
color
- first color for gradientcolor2
- second color for gradient- Returns:
- sets color gradient
-
setLEDsBreathe
Set LEDs to breathe- Parameters:
color
- Color to set leds to- Returns:
- leds breathe command
-
setPoliceLeds
Set LEDs to police pattern/color -
setRainbow
Sets specified LED side to Rainbow even when disabled
-