1 package org
.usfirst
.frc
.team3501
.robot
.commands
.climber
;
3 import org
.usfirst
.frc
.team3501
.robot
.Robot
;
5 import edu
.wpi
.first
.wpilibj
.command
.Command
;
8 * This command will run the winch motor continuously until the button
9 * triggering it is released. This command also runs the drive train.
11 * pre-condition: This command must be run by a button in OI. The robot must be
12 * attached to the rope.
14 * post-condition: Winch motor set to a specified speed.
17 * value range is from -1 to 1
19 * @author shivanighanta
22 public class RunWinchContinuous
extends Command
{
23 private double motorVal
;
26 * See JavaDoc comment in class for details
29 * value range is from -1 to 1
31 public RunWinchContinuous(double motorVal
) {
32 requires(Robot
.getDriveTrain());
33 this.motorVal
= motorVal
;
37 protected void initialize() {
38 Robot
.getDriveTrain().setMotorValues(motorVal
, motorVal
);
43 protected void execute() {
48 protected boolean isFinished() {
53 protected void end() {
58 protected void interrupted() {