import edu.wpi.first.wpilibj.IterativeRobot;
import edu.wpi.first.wpilibj.command.Scheduler;
import edu.wpi.first.wpilibj.smartdashboard.SendableChooser;
-import edu.wpi.first.wpilibj.smartdashboard.SmartDashboard;
public class Robot extends IterativeRobot {
public static OI oi;
oi = new OI();
- initializeSendableChooser();
- addFrontChooserOptions();
- sendSendableChooserToSmartDashboard();
-
camera = CameraServer.getInstance();
- camera.setQuality(50);
+ camera.setQuality(25);
camera.startAutomaticCapture("cam0");
}
- private void initializeSendableChooser() {
- frontChooser = new SendableChooser();
- }
-
- private void addFrontChooserOptions() {
- frontChooser.addDefault("Intake", false);
- frontChooser.addObject("Shooter", true);
- }
-
- private void sendSendableChooserToSmartDashboard() {
- SmartDashboard.putData("PositionChooser", frontChooser);
- }
-
@Override
public void autonomousInit() {
- // get options chosen from drop down menu
- boolean flip = (boolean) frontChooser.getSelected();
-
- if (flip) {
- driveTrain.toggleFlipped();
- }
-
- Scheduler.getInstance().add(new TimeDrive(4, .7));
+ //
+ // Scheduler.getInstance().add(new
+ // MoveIntakeArm(Constants.IntakeArm.RETRACT));
+ // Scheduler.getInstance().add(new TimeDrive(1, .6));
+ // Scheduler.getInstance().add(new WaitCommand(1));
+ // Scheduler.getInstance().add(new
+ // MoveIntakeArm(Constants.IntakeArm.EXTEND));
+ Scheduler.getInstance().add(new TimeDrive(8, -.8));
}
@Override