Delete StopWinch and Climber subsystem, edit javadoc comments
[3501/2017steamworks] / src / org / usfirst / frc / team3501 / robot / commands / climber / RunWinchContinuous.java
CommitLineData
9738295a
SG
1package org.usfirst.frc.team3501.robot.commands.climber;
2
a04ce2ff
SG
3import org.usfirst.frc.team3501.robot.Robot;
4
9738295a
SG
5import edu.wpi.first.wpilibj.command.Command;
6
7/**
de8c65d3 8 * This command will run the winch motor continuously until the button
411129cd 9 * triggering it is released. This command also runs the drive train.
e2e9a7a7
SG
10 *
11 * pre-condition: This command must be run by a button in OI. The robot must be
12 * attached to the rope.
13 *
14 * post-condition: Winch motor set to a specified speed.
15 *
16 * @param motorVal
17 * value range is from -1 to 1
9738295a
SG
18 *
19 * @author shivanighanta
20 *
21 */
22public class RunWinchContinuous extends Command {
23 private double motorVal;
24
ad877a7e 25 /**
411129cd
SG
26 * See JavaDoc comment in class for details
27 *
ad877a7e 28 * @param motorVal
411129cd 29 * value range is from -1 to 1
ad877a7e 30 */
9738295a 31 public RunWinchContinuous(double motorVal) {
411129cd 32 requires(Robot.getDriveTrain());
9738295a
SG
33 this.motorVal = motorVal;
34 }
35
36 @Override
37 protected void initialize() {
411129cd 38 Robot.getDriveTrain().setMotorValues(motorVal, motorVal);
cf086549 39
9738295a
SG
40 }
41
42 @Override
43 protected void execute() {
44
45 }
46
47 @Override
48 protected boolean isFinished() {
411129cd 49 return false;
9738295a
SG
50 }
51
52 @Override
53 protected void end() {
411129cd 54
9738295a
SG
55 }
56
57 @Override
58 protected void interrupted() {
a04ce2ff 59 end();
9738295a
SG
60 }
61}