Implement RunFLyWheel class, add motor methods to Shooter class
[3501/2017steamworks] / src / org / usfirst / frc / team3501 / robot / Robot.java
1 package org.usfirst.frc.team3501.robot;
2
3 import org.usfirst.frc.team3501.robot.commands.driving.TimeDrive;
4 import org.usfirst.frc.team3501.robot.subsystems.DriveTrain;
5 import org.usfirst.frc.team3501.robot.subsystems.Shooter;
6
7 import edu.wpi.first.wpilibj.IterativeRobot;
8 import edu.wpi.first.wpilibj.command.Scheduler;
9
10 public class Robot extends IterativeRobot {
11 private static DriveTrain driveTrain;
12 private static Shooter shooter;
13 private static OI oi;
14 private static Shooter shooter;
15
16 @Override
17 public void robotInit() {
18 driveTrain = DriveTrain.getDriveTrain();
19 oi = OI.getOI();
20 shooter = Shooter.getShooter();
21
22 }
23
24 public static DriveTrain getDriveTrain() {
25 return DriveTrain.getDriveTrain();
26 }
27
28 public static Shooter getShooter() {
29 return Shooter.getShooter();
30 }
31
32 public static OI getOI() {
33 return OI.getOI();
34 }
35
36 public static Shooter getShooter() {
37 return Shooter.getShooter();
38 }
39
40 @Override
41 public void autonomousInit() {
42 Scheduler.getInstance().add(new TimeDrive(1.5, 0.4));
43 }
44
45 @Override
46 public void autonomousPeriodic() {
47 Scheduler.getInstance().run();
48
49 }
50
51 @Override
52 public void teleopInit() {
53 }
54
55 @Override
56 public void teleopPeriodic() {
57 Scheduler.getInstance().run();
58
59 }
60 }