![]() |
Fun with PWM
0.32
|
Public Member Functions | |
| def | __init__ (self, dev_num) |
| def | get_name (self) |
| def | get_num_axis (self) |
| def | get_num_buttons (self) |
| def | get_axis_map (self) |
| def | get_button_map (self) |
| def | read_buttons (self, arg0='', arg1='') |
| def | registerCallbacks (self, callbacks) |
Public Attributes | |
| callbacks | |
| dev_num | |
| device | |
| info | |
The Joystick class is a GObject that sends signals that represent Joystick events
| def Joystick.Joystick.__init__ | ( | self, | |
| dev_num | |||
| ) |
initialize Joystick object
| def Joystick.Joystick.get_axis_map | ( | self | ) |
gets list of axis names @return list
| def Joystick.Joystick.get_button_map | ( | self | ) |
gets list of button names @return list
| def Joystick.Joystick.get_name | ( | self | ) |
gets the joystick name reads from the file: /sys/class/input/js0/device/name @return str
| def Joystick.Joystick.get_num_axis | ( | self | ) |
gets number of axis @return int
| def Joystick.Joystick.get_num_buttons | ( | self | ) |
gets number of axis @return int
| def Joystick.Joystick.read_buttons | ( | self, | |
arg0 = '', |
|||
arg1 = '' |
|||
| ) |
read the button and axis press event from the joystick device and emit a signal containing the event data
| def Joystick.Joystick.registerCallbacks | ( | self, | |
| callbacks | |||
| ) |
sets up one or more callbacks
accepts tuple: (name, func) or dict { 'name1': func1, 'name2': func2 }
@param callbacks
|
static |
|
static |
|
static |