Package com.ctre.phoenix.led
Class Animation
java.lang.Object
com.ctre.phoenix.led.Animation
- Direct Known Subclasses:
ColorFlowAnimation
,FireAnimation
,LarsonAnimation
,RainbowAnimation
,RgbFadeAnimation
,SingleFadeAnimation
,StrobeAnimation
,TwinkleAnimation
,TwinkleOffAnimation
public abstract class Animation extends Object
The base class for all animations that CANdle supports.
-
Constructor Summary
Constructors Constructor Description Animation(int idx, double speed, int numLed, int ledOffset)
Constructor for an Animation class -
Method Summary
Modifier and Type Method Description void
setLedOffset(int ledOffset)
Sets where the animation will start along the LED stripvoid
setNumLed(int numLed)
Sets the number of LEDs the animation will run onvoid
setSpeed(double speed)
Sets the speed of the animation
-
Constructor Details
-
Animation
Constructor for an Animation class- Parameters:
idx
- The animation-specific IDspeed
- The rate at which the animation runs at. Higher is generally fasternumLed
- The number of LEDs to run the animation onledOffset
- Where to start the animation
-
-
Method Details
-
setSpeed
Sets the speed of the animation- Parameters:
speed
- The rate at which the animation runs at. Higher is generally faster
-
setNumLed
Sets the number of LEDs the animation will run on- Parameters:
numLed
- The number of LEDs to run the animation on
-
setLedOffset
Sets where the animation will start along the LED strip- Parameters:
ledOffset
- Where to start the animation
-