1 package org
.usfirst
.frc
.team3501
.robot
.subsystems
;
3 import org
.usfirst
.frc
.team3501
.robot
.Constants
;
5 import edu
.wpi
.first
.wpilibj
.CANTalon
;
6 import edu
.wpi
.first
.wpilibj
.DoubleSolenoid
;
7 import edu
.wpi
.first
.wpilibj
.DoubleSolenoid
.Value
;
8 import edu
.wpi
.first
.wpilibj
.command
.Subsystem
;
10 public class Scaler
extends Subsystem
{
11 private DoubleSolenoid piston
;
12 private CANTalon winch
;
15 piston
= new DoubleSolenoid(Constants
.Scaler
.FORWARD_CHANNEL
,
16 Constants
.Scaler
.REVERSE_CHANNEL
);
17 winch
= new CANTalon(Constants
.Scaler
.WINCH_MOTOR
);
21 <<<<<<< 39cd129b533ffb726c00d5d5cd98b541a25d23bd
22 public void setPistonStatus(int status
) {
27 >>>>>>> Add set motor speed methods in defense arm and add potentiometer getter methods
28 public Value
getSolenoidValue() {
32 public void liftScissorLift() {
33 piston
.set(DoubleSolenoid
.Value
.kReverse
);
36 public void lowerScissorLift() {
37 piston
.set(DoubleSolenoid
.Value
.kForward
);
40 public void engageHook() {
44 public void disengageHook() {
47 public void runWinch(double speed
) {
56 <<<<<<< 39cd129b533ffb726c00d5d5cd98b541a25d23bd
59 * This method returns boolean value true or false on whether piston is
63 * returns true if piston is extended, false if otherwise.
65 public boolean getPistonStatus() {
70 * This method sets the motor voltage for the scissor lift. The range is from
74 * The voltage that you set the motor at. The range of the voltage of
75 * the motor is from [-1,1].
77 public void setScalarSpeed(double speed
) {
82 * This method sets the piston status for the scissor lift.
83 * The piston can either be extended or not extended.
86 * The status of the piston.
87 * 0 for the piston to be extended, 1 for the piston to not be
91 public void setPistonStatus(int status
) {
95 >>>>>>> Add set motor speed methods in defense arm and add potentiometer getter methods
97 protected void initDefaultCommand() {
100 <<<<<<< 39cd129b533ffb726c00d5d5cd98b541a25d23bd
103 >>>>>>> Add set motor speed methods in defense arm and add potentiometer getter methods