Package com.marswars.auto
Class AutoManager
java.lang.Object
com.marswars.auto.AutoManager
Singleton manager for autonomous routine selection and visualization.
-
Method Summary
Modifier and TypeMethodDescriptionstatic AutoManagerGets the singleton AutoManager instance.Get the selected auto routinevoidvoidperiodic()Must be called from robotPeriodic().voidregisterAutos(Auto... autos) Register multiple auto routines to the chooser
-
Method Details
-
getInstance
Gets the singleton AutoManager instance.- Returns:
- the AutoManager instance
-
registerAutos
Register multiple auto routines to the chooser- Parameters:
autos- Varargs of Auto routines to register
-
periodic
public void periodic()Must be called from robotPeriodic(). Processes any pending auto selection changes outside of SmartDashboard's updateValues() iteration to avoid ConcurrentModificationException. -
getSelectedAuto
Get the selected auto routine- Returns:
- The selected Auto as a command sequence
-
onSelectedAutoChange
public void onSelectedAutoChange()
-