add corrections
[3501/2017steamworks] / src / org / usfirst / frc / team3501 / robot / commands / shooter / RunFlyWheelContinuous.java
index 2ae906c7be9753d2ba15de5b2994ccf765273a06..823088e5a00603b635f8a0888c52301ac85ee637 100644 (file)
@@ -28,15 +28,15 @@ public class RunFlyWheelContinuous extends Command {
   private double target;
 
   public RunFlyWheelContinuous() {
-    this.wheelP = this.shooter.wheelP;
-    this.wheelI = this.shooter.wheelI;
-    this.wheelD = this.shooter.wheelD;
+    this.wheelP = this.shooter.getWheelP();
+    this.wheelI = this.shooter.getWheelI();
+    this.wheelD = this.shooter.getWheelD();
     this.wheelController = new PIDController(this.wheelP, this.wheelI,
         this.wheelD);
     this.wheelController.setDoneRange(0.5);
     this.wheelController.setMaxOutput(1.0);
     this.wheelController.setMinDoneCycles(3);
-    this.target = this.shooter.CURRENT_SHOOTING_SPEED;
+    this.target = this.shooter.getShootingSpeed();
   }
 
   @Override
@@ -51,7 +51,7 @@ public class RunFlyWheelContinuous extends Command {
     //
     // this.shooter.setFlyWheelMotorVal(shooterSpeed);
     System.out.println(shooter.getShooterRPM());
-    this.shooter.setFlyWheelMotorVal(this.shooter.CURRENT_SHOOTING_SPEED);
+    this.shooter.runFlyWheel();
   }
 
   @Override