Add buttons to OI class
[3501/2017steamworks] / src / org / usfirst / frc / team3501 / robot / commands / shooter / RunFlyWheelContinuous.java
index 081b13e3e8891e4638cf5b36374a27b86a1c25c3..cc07893019111c9e88f0115784de98d079981862 100644 (file)
@@ -5,9 +5,12 @@ import org.usfirst.frc.team3501.robot.Robot;
 import edu.wpi.first.wpilibj.command.Command;
 
 /**
- * This command will run the fly wheel motor continuously until the button
+ * This command runs the fly wheel continuously when OI button managing fly
+ * wheel is pressed. The command will run the fly wheel motor until the button
  * triggering it is released.
  *
+ * Should only be run from the operator interface.
+ *
  * pre-condition: This command must be run by a button in OI, with
  * button.whileHeld(...).
  *
@@ -51,8 +54,7 @@ public class RunFlyWheelContinuous extends Command {
 
   @Override
   protected boolean isFinished() {
-    // TODO
-    return false;
+    return !Robot.getOI().toggleFlyWheel.get();
   }
 
 }