Interface Device (HID) gamepad Class.
Common APIs used by high level application to use this USB class.
See Quick start guide for USB device gamepad.
Modules | |
Interface with USB Device Core (UDC) | |
Structures and functions required by UDC. | |
Implementation of UDI HID gamepad | |
Class internal implementation. | |
USB interface descriptors | |
The following structures provide predefined USB interface descriptors. | |
Functions | |
bool | udi_hid_gpd_buttons (bool b_state, uint8_t key_id) |
Send events key pressed or released. More... | |
bool | udi_hid_gpd_moveX (int8_t pos) |
Move the x axe. More... | |
bool | udi_hid_gpd_moveY (int8_t pos) |
Move the y axe. More... | |
bool | udi_hid_gpd_throttle_move (int8_t pos) |
Move the throttle. More... | |
Send events key pressed or released.
key_id | ID of key |
b_state | Key Pressed or released |
1
if function was successfully done, otherwise 0
. References cpu_irq_restore(), cpu_irq_save(), udi_hid_gpd_b_report_valid, udi_hid_gpd_report, and udi_hid_gpd_send_report().
Referenced by zid_report_data_indication().
bool udi_hid_gpd_moveX | ( | int8_t | pos | ) |
Move the x axe.
pos | Signed value to move |
1
if function was successfully done, otherwise 0
. References cpu_irq_restore(), cpu_irq_save(), pos, udi_hid_gpd_b_report_valid, udi_hid_gpd_report, and udi_hid_gpd_send_report().
Referenced by zid_report_data_indication().
bool udi_hid_gpd_moveY | ( | int8_t | pos | ) |
Move the y axe.
pos | Signed value to move |
1
if function was successfully done, otherwise 0
. References cpu_irq_restore(), cpu_irq_save(), pos, udi_hid_gpd_b_report_valid, udi_hid_gpd_report, and udi_hid_gpd_send_report().
Referenced by zid_report_data_indication().
bool udi_hid_gpd_throttle_move | ( | int8_t | pos | ) |
Move the throttle.
pos | Signed value to move |
1
if function was successfully done, otherwise 0
. References cpu_irq_restore(), cpu_irq_save(), pos, udi_hid_gpd_b_report_valid, udi_hid_gpd_report, and udi_hid_gpd_send_report().
Referenced by zid_report_data_indication().