NiDsPS4ControllerSim
- class wpilib.simulation.NiDsPS4ControllerSim(*args, **kwargs)
Bases:
GenericHIDSimClass to control a simulated NiDsPS4 controller.
Overloaded function.
__init__(self: wpilib.simulation._simulation.NiDsPS4ControllerSim, joystick: wpilib._wpilib.NiDsPS4Controller) -> None
Constructs from a NiDsPS4Controller object.
- Parameters:
joystick – controller to simulate
__init__(self: wpilib.simulation._simulation.NiDsPS4ControllerSim, port: typing.SupportsInt | typing.SupportsIndex) -> None
Constructs from a joystick port number.
- Parameters:
port – port number
- set_circle_button(value: bool) None
Change the value of the circle button on the controller.
- Parameters:
value – the new value
- set_cross_button(value: bool) None
Change the value of the cross button on the controller.
- Parameters:
value – the new value
- set_l1_button(value: bool) None
Change the value of the left trigger 1 button on the controller.
- Parameters:
value – the new value
- set_l2_axis(value: SupportsFloat | SupportsIndex) None
Change the value of the left trigger 2 axis on the controller.
- Parameters:
value – the new value
- set_l2_button(value: bool) None
Change the value of the left trigger 2 button on the controller.
- Parameters:
value – the new value
- set_l3_button(value: bool) None
Change the value of the L3 (left stick) button on the controller.
- Parameters:
value – the new value
- set_left_x(value: SupportsFloat | SupportsIndex) None
Change the left X value of the controller’s joystick.
- Parameters:
value – the new value
- set_left_y(value: SupportsFloat | SupportsIndex) None
Change the left Y value of the controller’s joystick.
- Parameters:
value – the new value
- set_options_button(value: bool) None
Change the value of the options button on the controller.
- Parameters:
value – the new value
- set_ps_button(value: bool) None
Change the value of the PlayStation button on the controller.
- Parameters:
value – the new value
- set_r1_button(value: bool) None
Change the value of the right trigger 1 button on the controller.
- Parameters:
value – the new value
- set_r2_axis(value: SupportsFloat | SupportsIndex) None
Change the value of the right trigger 2 axis on the controller.
- Parameters:
value – the new value
- set_r2_button(value: bool) None
Change the value of the right trigger 2 button on the controller.
- Parameters:
value – the new value
- set_r3_button(value: bool) None
Change the value of the R3 (right stick) button on the controller.
- Parameters:
value – the new value
- set_right_x(value: SupportsFloat | SupportsIndex) None
Change the right X value of the controller’s joystick.
- Parameters:
value – the new value
- set_right_y(value: SupportsFloat | SupportsIndex) None
Change the right Y value of the controller’s joystick.
- Parameters:
value – the new value
Change the value of the share button on the controller.
- Parameters:
value – the new value
- set_square_button(value: bool) None
Change the value of the square button on the controller.
- Parameters:
value – the new value
- set_touchpad_button(value: bool) None
Change the value of the touchpad button on the controller.
- Parameters:
value – the new value
- set_triangle_button(value: bool) None
Change the value of the triangle button on the controller.
- Parameters:
value – the new value