remove unnecessary code that double checks speed input & add javadoc style comment...
authorLauren Meier <meier.lauren@gmail.com>
Fri, 12 Feb 2016 04:38:09 +0000 (20:38 -0800)
committerKevin Zhang <icestormf1@gmail.com>
Mon, 15 Feb 2016 00:22:19 +0000 (16:22 -0800)
src/org/usfirst/frc/team3501/robot/commands/SetWinchSpeed.java

index c66e4000d7e137b705babe15b1345ad74ac49615..be0ea21988154d10264ba47bd7debc23accd30a5 100644 (file)
@@ -4,16 +4,24 @@ import org.usfirst.frc.team3501.robot.Robot;
 
 import edu.wpi.first.wpilibj.command.Command;
 
+/***
+ * This command will set the winch motor to a specified speed.
+ *
+ * pre-condition: This command must be run by a button in OI with method
+ * whileHeld()
+ *
+ * post-condition: winch motor set to a specified speed.
+ *
+ * @author Meryem and Avi
+ *
+ */
+
 public class SetWinchSpeed extends Command {
   double winchUpSpeed;
 
   public SetWinchSpeed(double speed) {
     requires(Robot.scaler);
     winchUpSpeed = speed;
-    if (winchUpSpeed > 1)
-      winchUpSpeed = 1;
-    if (winchUpSpeed < -1)
-      winchUpSpeed = -1;
   }
 
   @Override