fix runwinchcontinuous 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/**
d8ebba03
CZ
8 * This command runs the drive train motors (which runs the winch) continuously
9 * at a specified speed until the button triggering it is released
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 *
d8ebba03 14 * post-condition: Drive train motors set to a specified speed.
e2e9a7a7 15 *
9738295a
SG
16 * @author shivanighanta
17 *
18 */
19public class RunWinchContinuous extends Command {
20 private double motorVal;
21
ad877a7e 22 /**
411129cd
SG
23 * See JavaDoc comment in class for details
24 *
ad877a7e 25 * @param motorVal
411129cd 26 * value range is from -1 to 1
ad877a7e 27 */
9738295a 28 public RunWinchContinuous(double motorVal) {
411129cd 29 requires(Robot.getDriveTrain());
9738295a
SG
30 this.motorVal = motorVal;
31 }
32
33 @Override
34 protected void initialize() {
411129cd 35 Robot.getDriveTrain().setMotorValues(motorVal, motorVal);
9738295a
SG
36 }
37
38 @Override
39 protected void execute() {
40
41 }
42
43 @Override
44 protected boolean isFinished() {
3e515b75 45 return false;
9738295a
SG
46 }
47
48 @Override
49 protected void end() {
411129cd 50
9738295a
SG
51 }
52
53 @Override
54 protected void interrupted() {
a04ce2ff 55 end();
9738295a
SG
56 }
57}