Class FireAnimation

java.lang.Object
com.ctre.phoenix.led.Animation
com.ctre.phoenix.led.FireAnimation

public class FireAnimation
extends Animation
Animation that looks similarly to a flame flickering
  • Constructor Details

    • FireAnimation

      public FireAnimation​(double brightness, double speed, int numLed, double sparking, double cooling, boolean reverseDirection, int ledOffset)
      Constructor for a FireAnimation
      Parameters:
      brightness - How bright should the animation be [0, 1]
      speed - How fast will the flame be processed at [0, 1]
      numLed - How many LEDs is the CANdle controlling
      sparking - The rate at which the Fire "Sparks" [0, 1]
      cooling - The rate at which the Fire "Cools" along the travel [0, 1]
      reverseDirection - True to reverse the animation direction, so instead of fire going "away" from the CANdle, it will go "toward" the CANdle.
      ledOffset - Where to start the animation
    • FireAnimation

      public FireAnimation​(double brightness, double speed, int numLed, double sparking, double cooling)
      Constructor for a FireAnimation
      Parameters:
      brightness - How bright should the animation be [0, 1]
      speed - How fast will the flame be processed at [0, 1]
      numLed - How many LEDs is the CANdle controlling
      sparking - The rate at which the Fire "Sparks" [0, 1]
      cooling - The rate at which the Fire "Cools" along the travel [0, 1]
    • FireAnimation

      public FireAnimation()
      Constructor for a FireAnimation. Call individual setters to tune the parameters further
  • Method Details

    • setSparking

      public void setSparking​(double sparking)
      Sets the sparking value of the FireAnimation
      Parameters:
      sparking - The rate at which the Fire "Sparks" [0, 1]
    • setCooling

      public void setCooling​(double cooling)
      Sets the cooling value of the FireAnimation
      Parameters:
      cooling - The rate at which the Fire "Cools" [0, 1]
    • setBrightness

      public void setBrightness​(double brightness)
      Sets the brightness of this animation
      Parameters:
      brightness - The brightness to run the animation at. This is a scalar from [0, 1]
    • getBaseStandardAnimation

      public com.ctre.phoenix.led.BaseStandardAnimation getBaseStandardAnimation()
    • getBaseTwoSizeAnimation

      public com.ctre.phoenix.led.BaseTwoSizeAnimation getBaseTwoSizeAnimation()