RobotCore
Robot Core Documentation
|
Public Member Functions | |
JoystickButton (GenericHID joystick, int buttonNumber) | |
boolean | get () |
Public Member Functions inherited from edu.wpi.first.wpilibj2.command.button.Button | |
Button () | |
Button (BooleanSupplier isPressed) | |
Button | whenPressed (final Command command, boolean interruptible) |
Button | whenPressed (final Command command) |
Button | whenPressed (final Runnable toRun, Subsystem... requirements) |
Button | whileHeld (final Command command, boolean interruptible) |
Button | whileHeld (final Command command) |
Button | whileHeld (final Runnable toRun, Subsystem... requirements) |
Button | whenHeld (final Command command, boolean interruptible) |
Button | whenHeld (final Command command) |
Button | whenReleased (final Command command, boolean interruptible) |
Button | whenReleased (final Command command) |
Button | whenReleased (final Runnable toRun, Subsystem... requirements) |
Button | toggleWhenPressed (final Command command, boolean interruptible) |
Button | toggleWhenPressed (final Command command) |
Button | cancelWhenPressed (final Command command) |
Public Member Functions inherited from edu.wpi.first.wpilibj2.command.button.Trigger | |
Trigger (BooleanSupplier isActive) | |
Trigger () | |
Trigger | whenActive (final Command command, boolean interruptible) |
Trigger | whenActive (final Command command) |
Trigger | whenActive (final Runnable toRun, Subsystem... requirements) |
Trigger | whileActiveContinuous (final Command command, boolean interruptible) |
Trigger | whileActiveContinuous (final Command command) |
Trigger | whileActiveContinuous (final Runnable toRun, Subsystem... requirements) |
Trigger | whileActiveOnce (final Command command, boolean interruptible) |
Trigger | whileActiveOnce (final Command command) |
Trigger | whenInactive (final Command command, boolean interruptible) |
Trigger | whenInactive (final Command command) |
Trigger | whenInactive (final Runnable toRun, Subsystem... requirements) |
Trigger | toggleWhenActive (final Command command, boolean interruptible) |
Trigger | toggleWhenActive (final Command command) |
Trigger | cancelWhenActive (final Command command) |
Trigger | and (Trigger trigger) |
Trigger | or (Trigger trigger) |
Trigger | negate () |
A Button that gets its state from a GenericHID.
edu.wpi.first.wpilibj2.command.button.JoystickButton.JoystickButton | ( | GenericHID | joystick, |
int | buttonNumber | ||
) |
Creates a joystick button for triggering commands.
joystick | The GenericHID object that has the button (e.g. Joystick, KinectStick, etc) |
buttonNumber | The button number (see GenericHID#getRawButton(int) |
boolean edu.wpi.first.wpilibj2.command.button.JoystickButton.get | ( | ) |
Gets the value of the joystick button.
Reimplemented from edu.wpi.first.wpilibj2.command.button.Trigger.