Commit | Line | Data |
---|---|---|
292b55d3 CZ |
1 | package org.usfirst.frc.team3501.robot.commands.shooter; |
2 | ||
3 | import org.usfirst.frc.team3501.robot.Robot; | |
4 | import org.usfirst.frc.team3501.robot.subsystems.Shooter; | |
5 | ||
6 | import edu.wpi.first.wpilibj.command.Command; | |
7 | ||
8 | /** | |
9 | * This command resets the speed at which the flywheel runs to the default | |
10 | * shooting speed | |
11 | * | |
12 | * post-condition: the shooting speed is reset | |
13 | */ | |
14 | public class ResetShootingSpeed extends Command { | |
15 | private Shooter shooter = Robot.getShooter(); | |
16 | ||
17 | public ResetShootingSpeed() { | |
18 | requires(shooter); | |
19 | } | |
20 | ||
21 | @Override | |
22 | protected void initialize() { | |
7ba6bc91 | 23 | shooter.resetTargetShootingSpeed(); |
292b55d3 CZ |
24 | } |
25 | ||
26 | @Override | |
27 | protected void execute() { | |
28 | } | |
29 | ||
30 | @Override | |
31 | protected boolean isFinished() { | |
32 | return true; | |
33 | } | |
34 | ||
35 | @Override | |
36 | protected void end() { | |
37 | } | |
38 | ||
39 | @Override | |
40 | ||
41 | protected void interrupted() { | |
42 | end(); | |
43 | } | |
44 | } |