Class StateMachine

java.lang.Object
org.firstinspires.ftc.teamcode.subsystems.fsm.StateMachine

public class StateMachine extends Object
Represents a finite state machine.
  • Constructor Details

    • StateMachine

      public StateMachine()
  • Method Details

    • addState

      public StateMachine addState(State state)
      Add a state to the state machine.
      Parameters:
      state - The state to add.
      Returns:
      The state machine.
    • loop

      public void loop()
      Called on every frame of the robot, it ticks and manages the state machine.
    • generateDot

      public String generateDot()
      Generate a Graphviz DOT diagram of the currently fixed state machine.