import org.usfirst.frc.team3501.robot.subsystems.Shooter;
import edu.wpi.first.wpilibj.IterativeRobot;
+import edu.wpi.first.wpilibj.command.CommandGroup;
import edu.wpi.first.wpilibj.command.Scheduler;
+import edu.wpi.first.wpilibj.smartdashboard.SendableChooser;
public class Robot extends IterativeRobot {
private static Shooter shooter;
private static OI oi;
private static Intake intake;
+ private static CommandGroup commandGroup;
+ private static SendableChooser chooser;
@Override
public void robotInit() {
oi = OI.getOI();
shooter = Shooter.getShooter();
intake = Intake.getIntake();
+ chooser = new SendableChooser();
- // init
}
public static DriveTrain getDriveTrain() {
@Override
public void autonomousInit() {
Scheduler.getInstance();
+ commandGroup = (CommandGroup) chooser.getSelected();
+ commandGroup.start();
+
}
@Override
public void autonomousPeriodic() {
Scheduler.getInstance().run();
-
}
@Override