Add intakearm constants and intake arm methods including initial dropping and also...
[3501/stronghold-2016] / src / org / usfirst / frc / team3501 / robot / subsystems / IntakeArm.java
1 package org.usfirst.frc.team3501.robot.subsystems;
2
3 import org.usfirst.frc.team3501.robot.Constants;
4
5 import edu.wpi.first.wpilibj.CANTalon;
6 import edu.wpi.first.wpilibj.command.Subsystem;
7
8 public class IntakeArm extends Subsystem {
9
10 private CANTalon intake;
11
12 public IntakeArm() {
13 intake = new CANTalon(Constants.IntakeArm.PORT);
14
15 }
16
17 /*
18 * Intake only moves once at the beginning of the match. It lowers at the
19 * beginning of the match and is held there by mechanical stops until the end
20 * of the match.
21 *
22 * Must be used in a command that has a timer variable to stop it.
23 */
24 public void dropIntake() {
25 intake.set(0.3);
26 }
27
28 public void intake() {
29 intake.set(Constants.IntakeArm.INTAKE_SPEED);
30 }
31
32 public void output() {
33 intake.set(Constants.IntakeArm.OUTPUT_SPEED);
34 }
35
36 @Override
37 protected void initDefaultCommand() {
38
39 }
40 }