X-Git-Url: http://challenge-bot.com/repos/?a=blobdiff_plain;f=src%2Forg%2Fusfirst%2Ffrc3501%2FRiceCatRobot%2Frobot%2FRobotMap.java;fp=src%2Forg%2Fusfirst%2Ffrc3501%2FRiceCatRobot%2Frobot%2FRobotMap.java;h=95604c371f7a05dc6396ecd854a04d01fde2f6f5;hb=4b8a525ff87cb3ba85058e8b53f5e896a25320bb;hp=0000000000000000000000000000000000000000;hpb=284904c741c7a805b8611302f6beed3b7f34e90f;p=3501%2F2015-FRC-Spark diff --git a/src/org/usfirst/frc3501/RiceCatRobot/robot/RobotMap.java b/src/org/usfirst/frc3501/RiceCatRobot/robot/RobotMap.java new file mode 100644 index 0000000..95604c3 --- /dev/null +++ b/src/org/usfirst/frc3501/RiceCatRobot/robot/RobotMap.java @@ -0,0 +1,41 @@ +package org.usfirst.frc3501.RiceCatRobot.robot; + +import edu.wpi.first.wpilibj.DoubleSolenoid; +import edu.wpi.first.wpilibj.DoubleSolenoid.Value; + +/** + * The RobotMap is a mapping from the ports sensors and actuators are wired into + * to a variable name. This provides flexibility changing wiring, makes checking + * the wiring easier and significantly reduces the number of magic numbers + * floating around. + */ +public class RobotMap { + public final static int LEFT_STICK_PORT = 0, RIGHT_STICK_PORT = 1; + public final static int TRIGGER_PORT = 1, TOGGLE_PORT = 2, + TOGGLE_COMPRESSOR_PORT = 11; + public static final int DRIVE_FRONT_LEFT = 4, DRIVE_FRONT_RIGHT = 5, + DRIVE_REAR_LEFT = 3, DRIVE_REAR_RIGHT = 6; + public static final int DRIVE_LEFT_A = 3, DRIVE_LEFT_B = 4, + DRIVE_RIGHT_A = 2, DRIVE_RIGHT_B = 1; + + public static final double DISTANCE_PER_PULSE = ((3.66 / 5.14) * 6 * Math.PI) / 256; + + public static final int ARM_LEFT = 2, ARM_RIGHT = 7; + public static final double ARM_HIGH_SPEED = 0.5, ARM_LOW_SPEED = 0.5; + + // Claw + public static final int SOLENOID_FORWARD = 0, SOLENOID_REVERSE = 1, + MODULE_NUMBER = 0; + public final static Value open = DoubleSolenoid.Value.kForward, + close = DoubleSolenoid.Value.kReverse; + public static double DRIVE_DEAD_ZONE = 0.25; + // Compressor + public static final int COMPRESSOR_PORT = 0; + + public static void init() { + } + + public static enum Direction { + LEFT, RIGHT, DOWN, UP, FORWARD, BACKWARD; + } +}