a653293d97ad4ca99b0dca5aa21c785415d87917
1 package org
.usfirst
.frc
.team3501
.robot
.commands
.shooter
;
3 import org
.usfirst
.frc
.team3501
.robot
.Constants
;
4 import org
.usfirst
.frc
.team3501
.robot
.Robot
;
5 import org
.usfirst
.frc
.team3501
.robot
.subsystems
.Shooter
;
7 import edu
.wpi
.first
.wpilibj
.command
.Command
;
9 public class ToggleIndexerPiston
extends Command
{
10 private Shooter shooter
= Robot
.getShooter();
13 * See JavaDoc comment in class for details
16 * value range from -1 to 1
18 public ToggleIndexerPiston() {
22 // Called just before this Command runs the first time
24 protected void initialize() {
27 // Called repeatedly when this Command is scheduled to run
29 protected void execute() {
30 if (shooter
.getPistonValue() == Constants
.Shooter
.LOW_GEAR
) {
31 shooter
.setHighGear();
37 // Called once after isFinished returns true
39 protected void end() {
42 // Called when another command which requires one or more of the same
43 // subsystems is scheduled to run
45 protected void interrupted() {
50 protected boolean isFinished() {