Class AutonOpMode

java.lang.Object
com.stuypulse.robot.opmodes.AutonOpMode
All Implemented Interfaces:
AutoCloseable, org.wpilib.opmode.OpMode

public class AutonOpMode extends Object implements org.wpilib.opmode.OpMode
  • Field Details

    • chooser

      protected static final org.littletonrobotics.junction.networktables.LoggedNetworkChooser<Auton> chooser
    • robot

      protected final Robot robot
    • auto

      protected Auton auto
  • Constructor Details

  • Method Details

    • addDefaultAuton

      public static void addDefaultAuton(String name, Auton auton)
    • addAuton

      public static void addAuton(String name, Auton auton)
    • setAuto

      private void setAuto(Auton auton)
    • ifNotNull

      private void ifNotNull(Consumer<Auton> consumer)
    • start

      public final void start()
      Specified by:
      start in interface org.wpilib.opmode.OpMode
    • startCallback

      protected void startCallback()
      Start callback method for being overridden by extending autons

      Will run after the command is scheduled and auto paths cleared from the display

    • end

      public final void end()
      Specified by:
      end in interface org.wpilib.opmode.OpMode
    • close

      public final void close()
      Specified by:
      close in interface AutoCloseable
      Specified by:
      close in interface org.wpilib.opmode.OpMode
    • endCallback

      public void endCallback()
      End callback method for being overridden by extending autons

      Will run after the command is canceled and auto paths cleared from the display

    • closeCallback

      public void closeCallback()
      Close callback method for being overridden by extending autons

      Will run after the command is canceled, auto paths cleared from the display, and the chooser listener is removed