JoystickButton
- class commands2.button.JoystickButton(joystick: GenericHID, buttonNumber: int)[source]
Bases:
TriggerA Button that gets its state from a
wpilib.GenericHID.Creates a joystick button for triggering commands.
- Parameters:
joystick – The GenericHID object that has the button (e.g. Joystick, KinectStick, etc)
buttonNumber – The button number (see
wpilib.GenericHID.getRawButton()