Delete OI code in commands that run continuously
[3501/2017steamworks] / src / org / usfirst / frc / team3501 / robot / commands / shooter / RunFlyWheelContinuous.java
CommitLineData
809609c9 1package org.usfirst.frc.team3501.robot.commands.shooter;
2
dbec800d 3import org.usfirst.frc.team3501.robot.Robot;
4
809609c9 5import edu.wpi.first.wpilibj.command.Command;
6
7/**
89a76b33 8 * This command will run the fly wheel motor continuously until the button
9 * triggering it is released.
b6e97560 10 *
973f0ac4 11 * pre-condition: This command must be run by a button in OI, with
12 * button.whileHeld(...).
357feb5c 13 *
973f0ac4 14 * @author Shaina
809609c9 15 */
16public class RunFlyWheelContinuous extends Command {
b6e97560 17 private double motorVal;
55cbd9ba 18
b7ef589a 19 /**
20 * See JavaDoc comment in class for details
21 *
22 * @param motorVal
23 * value range from -1 to 1
24 */
b6e97560 25 public RunFlyWheelContinuous(double motorVal) {
26 this.motorVal = motorVal;
55cbd9ba 27 }
28
29 // Called just before this Command runs the first time
30 @Override
31 protected void initialize() {
dbec800d 32 Robot.getShooter().setFlyWheelMotorVal(motorVal);
55cbd9ba 33 }
34
35 // Called repeatedly when this Command is scheduled to run
36 @Override
37 protected void execute() {
38 }
39
40 // Called once after isFinished returns true
41 @Override
42 protected void end() {
43 }
44
45 // Called when another command which requires one or more of the same
46 // subsystems is scheduled to run
47 @Override
48 protected void interrupted() {
89a76b33 49 end();
55cbd9ba 50 }
51
52 @Override
53 protected boolean isFinished() {
f3db582d 54 // TODO
cba5dc5b 55 return false;
55cbd9ba 56 }
809609c9 57
58}