Class POVButton
java.lang.Object
org.wpilib.command2.button.Trigger
org.wpilib.command2.button.POVButton
- All Implemented Interfaces:
BooleanSupplier
A
Trigger that gets its state from a POV on a GenericHID.
This class is provided by the NewCommands VendorDep
-
Constructor Summary
ConstructorsConstructorDescriptionPOVButton(GenericHID joystick, DriverStation.POVDirection angle) Creates a POV button for triggering commands.POVButton(GenericHID joystick, DriverStation.POVDirection angle, int povNumber) Creates a POV button for triggering commands. -
Method Summary
Methods inherited from class Trigger
and, debounce, debounce, getAsBoolean, multiPress, negate, onChange, onFalse, onTrue, or, toggleOnFalse, toggleOnTrue, whileFalse, whileTrue
-
Constructor Details
-
POVButton
Creates a POV button for triggering commands.- Parameters:
joystick- The GenericHID object that has the POVangle- The desired anglepovNumber- The POV number (seeGenericHID.getPOV(int))
-
POVButton
Creates a POV button for triggering commands. By default, acts on POV 0- Parameters:
joystick- The GenericHID object that has the POVangle- The desired angle
-