Package frc.robot.subsystems
Class LEDs
java.lang.Object
edu.wpi.first.wpilibj2.command.SubsystemBase
frc.robot.subsystems.LEDs
LEDs subsystem
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionBlink LEDsBlink LEDs for a certain timeoutvoidperiodic()setLEDsBreathe(Color color) Set LEDs to breathesetLEDsGradient(Color color, Color color2) Set LEDs to color gradientsetLEDsSolid(Color color) Set LEDs to solid colorSet rainbow patternMethods inherited from class edu.wpi.first.wpilibj2.command.SubsystemBase
addChild, getName, getSubsystem, initSendable, setName, setSubsystemMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface edu.wpi.first.wpilibj2.command.Subsystem
defer, getCurrentCommand, getDefaultCommand, idle, register, removeDefaultCommand, run, runEnd, runOnce, setDefaultCommand, simulationPeriodic, startEnd, startRun
-
Constructor Details
-
LEDs
public LEDs()constructor
-
-
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
-
setRainbow
Set rainbow pattern- Returns:
- Command
-