Add 'requires' command and fill in execute method
authorArunima DIvya <adivya822@student.fuhsd.org>
Tue, 24 Jan 2017 03:47:08 +0000 (19:47 -0800)
committerArunima DIvya <adivya822@student.fuhsd.org>
Thu, 26 Jan 2017 04:14:05 +0000 (20:14 -0800)
src/org/usfirst/frc/team3501/robot/commands/intake/RunIntakeContinuous.java

index 9036f15f42ad2f13b18842266879ea0b5695631c..961c3fc3b1a9abcf3eb6b5e69730401ff6cf92e8 100644 (file)
@@ -1,5 +1,6 @@
 package org.usfirst.frc.team3501.robot.commands.intake;
 
+import org.usfirst.frc.team3501.robot.Robot;
 import org.usfirst.frc.team3501.robot.subsystems.Intake;
 
 import edu.wpi.first.wpilibj.command.Command;
@@ -16,7 +17,7 @@ public class RunIntakeContinuous extends Command {
   // speed to 0
 
   public RunIntakeContinuous() {
-
+    requires(Robot.getIntake());
   }
 
   @Override
@@ -34,7 +35,7 @@ public class RunIntakeContinuous extends Command {
   // Called repeatedly when this Command is scheduled to run
   @Override
   protected void execute() {
-
+    Robot.getIntake().setSpeed(Robot.getIntake().INTAKE_SPEED);
   }
 
   // Called once after isFinished returns true