From: Lauren Meier Date: Sat, 13 Feb 2016 23:05:04 +0000 (-0800) Subject: rename filed from Toggle to Continuous X-Git-Url: http://challenge-bot.com/repos/?p=3501%2Fstronghold-2016;a=commitdiff_plain;h=03d32daffb42012ffa21a746d0ec01007f08fa10 rename filed from Toggle to Continuous --- diff --git a/src/org/usfirst/frc/team3501/robot/commands/BallRollerExpelContinuous.java b/src/org/usfirst/frc/team3501/robot/commands/BallRollerExpelContinuous.java new file mode 100644 index 00000000..30947453 --- /dev/null +++ b/src/org/usfirst/frc/team3501/robot/commands/BallRollerExpelContinuous.java @@ -0,0 +1,48 @@ +package org.usfirst.frc.team3501.robot.commands; + +import org.usfirst.frc.team3501.robot.Robot; + +import edu.wpi.first.wpilibj.command.Command; + +/*** + * This command will continually roll the rollers of the intake arm in the + * outwards direction and stop the rollers once the command is canceled. + * + * pre-condition: This command must be called by a button with the method + * .whileHeld() in OI + * + * @author Lauren and Niyati + * + */ + +public class BallRollerExpelContinuous extends Command { + + public BallRollerExpelContinuous() { + requires(Robot.intakeArm); + } + + @Override + protected void initialize() { + Robot.intakeArm.outputBall(); + } + + @Override + protected void execute() { + + } + + @Override + protected boolean isFinished() { + return true; + } + + @Override + protected void end() { + Robot.intakeArm.stopRollers(); + } + + @Override + protected void interrupted() { + end(); + } +} diff --git a/src/org/usfirst/frc/team3501/robot/commands/BallRollerIntakeContinuous.java b/src/org/usfirst/frc/team3501/robot/commands/BallRollerIntakeContinuous.java new file mode 100644 index 00000000..f8c3ffdd --- /dev/null +++ b/src/org/usfirst/frc/team3501/robot/commands/BallRollerIntakeContinuous.java @@ -0,0 +1,49 @@ +package org.usfirst.frc.team3501.robot.commands; + +import org.usfirst.frc.team3501.robot.Robot; + +import edu.wpi.first.wpilibj.command.Command; + +/*** + * This command will continually roll the rollers of the intake arm in the + * inwards direction and stop the rollers once the command is canceled. + * + * pre-condition: This command must be called by a button with the method + * .whileHeld() in OI + * + * @author Lauren and Niyati + * + */ + +public class BallRollerIntakeContinuous extends Command { + + public BallRollerIntakeContinuous() { + requires(Robot.intakeArm); + } + + @Override + protected void initialize() { + Robot.intakeArm.intakeBall(); + } + + @Override + protected void execute() { + + } + + @Override + protected boolean isFinished() { + return true; + } + + @Override + protected void end() { + Robot.intakeArm.stopRollers(); + } + + @Override + protected void interrupted() { + end(); + } + +} diff --git a/src/org/usfirst/frc/team3501/robot/commands/ToggleBallRollerExpel.java b/src/org/usfirst/frc/team3501/robot/commands/ToggleBallRollerExpel.java deleted file mode 100644 index f7df18f0..00000000 --- a/src/org/usfirst/frc/team3501/robot/commands/ToggleBallRollerExpel.java +++ /dev/null @@ -1,48 +0,0 @@ -package org.usfirst.frc.team3501.robot.commands; - -import org.usfirst.frc.team3501.robot.Robot; - -import edu.wpi.first.wpilibj.command.Command; - -/*** - * This command will continually roll the rollers of the intake arm in the - * outwards direction and stop the rollers once the command is canceled. - * - * pre-condition: This command must be called by a button with the method - * .whileHeld() in OI - * - * @author Lauren and Niyati - * - */ - -public class ToggleBallRollerExpel extends Command { - - public ToggleBallRollerExpel() { - requires(Robot.intakeArm); - } - - @Override - protected void initialize() { - Robot.intakeArm.outputBall(); - } - - @Override - protected void execute() { - - } - - @Override - protected boolean isFinished() { - return true; - } - - @Override - protected void end() { - Robot.intakeArm.stopRollers(); - } - - @Override - protected void interrupted() { - end(); - } -} diff --git a/src/org/usfirst/frc/team3501/robot/commands/ToggleBallRollerIntake.java b/src/org/usfirst/frc/team3501/robot/commands/ToggleBallRollerIntake.java deleted file mode 100644 index 767b24ad..00000000 --- a/src/org/usfirst/frc/team3501/robot/commands/ToggleBallRollerIntake.java +++ /dev/null @@ -1,49 +0,0 @@ -package org.usfirst.frc.team3501.robot.commands; - -import org.usfirst.frc.team3501.robot.Robot; - -import edu.wpi.first.wpilibj.command.Command; - -/*** - * This command will continually roll the rollers of the intake arm in the - * inwards direction and stop the rollers once the command is canceled. - * - * pre-condition: This command must be called by a button with the method - * .whileHeld() in OI - * - * @author Lauren and Niyati - * - */ - -public class ToggleBallRollerIntake extends Command { - - public ToggleBallRollerIntake() { - requires(Robot.intakeArm); - } - - @Override - protected void initialize() { - Robot.intakeArm.intakeBall(); - } - - @Override - protected void execute() { - - } - - @Override - protected boolean isFinished() { - return true; - } - - @Override - protected void end() { - Robot.intakeArm.stopRollers(); - } - - @Override - protected void interrupted() { - end(); - } - -}