Important changes to repositories hosted on mbed.com
Mbed hosted mercurial repositories are deprecated and are due to be permanently deleted in July 2026.
To keep a copy of this software download the repository Zip archive or clone locally using Mercurial.
It is also possible to export all your personal repositories from the account settings page.
USBHid Class Reference
Public Member Functions | |
| def | lock |
| def | unlock |
| def | set_idle |
| def | get_descriptor |
| def | set_report_req |
| def | get_report_req |
| def | set_report |
| def | get_report |
Detailed Description
Wrapper class for a HID usb device
Definition at line 22 of file usb_hid.py.
Member Function Documentation
| def get_descriptor | ( | self, | |
| desc_type, | |||
| index | |||
| ) |
Get the given descriptor
Definition at line 105 of file usb_hid.py.
| def get_report | ( | self, | |
| size | |||
| ) |
Read report from the device
Definition at line 158 of file usb_hid.py.
| def get_report_req | ( | self, | |
| data_size, | |||
report_type = REPORT_TYPE_INPUT, |
|||
report_id = 0 |
|||
| ) |
Set a report of the given type
Definition at line 134 of file usb_hid.py.
| def lock | ( | self ) |
Acquire exclisive access to HID
Definition at line 64 of file usb_hid.py.
| def set_idle | ( | self, | |
report_id = 0, |
|||
duration = 0 |
|||
| ) |
Send a HID Set_Idle request
Definition at line 93 of file usb_hid.py.
| def set_report | ( | self, | |
| data | |||
| ) |
Send report to the device
Definition at line 149 of file usb_hid.py.
| def set_report_req | ( | self, | |
| data, | |||
report_type = REPORT_TYPE_OUTPUT, |
|||
report_id = 0 |
|||
| ) |
Set a report of the given type
Definition at line 119 of file usb_hid.py.
| def unlock | ( | self ) |
Release exclusive access to HID
Definition at line 79 of file usb_hid.py.
Generated on Tue Jul 12 2022 15:37:38 by
1.7.2