add git ignore and empty code base
[3501/autonomous-driving] / src / org / usfirst / frc / team3501 / robot / OI.java
1 package org.usfirst.frc.team3501.robot;
2
3 import edu.wpi.first.wpilibj.buttons.Button;
4 import org.usfirst.frc.team3501.robot.commands.ExampleCommand;
5
6 /**
7 * This class is the glue that binds the controls on the physical operator
8 * interface to the commands and command groups that allow control of the robot.
9 */
10 public class OI {
11 //// CREATING BUTTONS
12 // One type of button is a joystick button which is any button on a joystick.
13 // You create one by telling it which joystick it's on and which button
14 // number it is.
15 // Joystick stick = new Joystick(port);
16 // Button button = new JoystickButton(stick, buttonNumber);
17
18 // There are a few additional built in buttons you can use. Additionally,
19 // by subclassing Button you can create custom triggers and bind those to
20 // commands the same as any other Button.
21
22 //// TRIGGERING COMMANDS WITH BUTTONS
23 // Once you have a button, it's trivial to bind it to a button in one of
24 // three ways:
25
26 // Start the command when the button is pressed and let it run the command
27 // until it is finished as determined by it's isFinished method.
28 // button.whenPressed(new ExampleCommand());
29
30 // Run the command while the button is being held down and interrupt it once
31 // the button is released.
32 // button.whileHeld(new ExampleCommand());
33
34 // Start the command when the button is released and let it run the command
35 // until it is finished as determined by it's isFinished method.
36 // button.whenReleased(new ExampleCommand());
37 }
38