diff options
author | Farid Chahla <farid.chahla@sony.com> | 2020-03-30 11:09:48 -0700 |
---|---|---|
committer | Siarhei Vishniakou <svv@google.com> | 2020-04-01 20:50:55 +0000 |
commit | 853f0d322a7e41491dae3296f11a9602e1a294f6 (patch) | |
tree | 4fe32d81af39f2cbbe9e6bf14a66d901f8c0abdd /cmds/hid | |
parent | 91b4f26c5b40292eac5a00e477eb747f1f859ba3 (diff) |
Updated documentation for CTS uhid tests
A new field was added where bus can be specified for testing uhid
devices. This commit adds the relevant documention to the README.
Bug: 144949707
Test: none
Change-Id: If5f6673dd0fdd268b702119b6ccd4abdc37f65bd
Diffstat (limited to 'cmds/hid')
-rw-r--r-- | cmds/hid/README.md | 9 |
1 files changed, 7 insertions, 2 deletions
diff --git a/cmds/hid/README.md b/cmds/hid/README.md index 7e22d08eeaeb..620336f30327 100644 --- a/cmds/hid/README.md +++ b/cmds/hid/README.md @@ -38,17 +38,21 @@ legal JSON format, as this would imply multiple root elements). Register a new uhid device | Field | Type | Description | -|:-------------:|:-------------:|:--------------------------| +|:-------------:|:-------------:|:-------------------------- | | id | integer | Device id | | command | string | Must be set to "register" | | name | string | Device name | | vid | 16-bit integer| Vendor id | | pid | 16-bit integer| Product id | +| bus | string | Bus that device should use | | descriptor | byte array | USB HID report descriptor | Device ID is used for matching the subsequent commands to a specific device to avoid ambiguity when multiple devices are registered. +Device bus is used to determine how the uhid device is connected to the host. +The options are "usb" and "bluetooth". + USB HID report descriptor should be generated according the the USB HID spec and can be checked by reverse parsing using a variety of tools, for example [usbdescreqparser][5]. @@ -61,6 +65,7 @@ Example: "name": "Odie (Test)", "vid": 0x18d1, "pid": 0x2c40, + "bus": "usb", "descriptor": [0x05, 0x01, 0x09, 0x05, 0xa1, 0x01, 0x85, 0x01, 0x05, 0x09, 0x0a, 0x01, 0x00, 0x0a, 0x02, 0x00, 0x0a, 0x04, 0x00, 0x0a, 0x05, 0x00, 0x0a, 0x07, 0x00, 0x0a, 0x08, 0x00, 0x0a, 0x0e, 0x00, 0x0a, 0x0f, 0x00, 0x0a, 0x0d, 0x00, 0x05, 0x0c, 0x0a, 0x24, 0x02, 0x0a, @@ -142,4 +147,4 @@ for debugging purposes. [3]: ../../../../cts/tests/tests/hardware/res/raw/ [4]: https://developer.android.com/training/game-controllers/controller-input.html#button [5]: http://eleccelerator.com/usbdescreqparser/ -[6]: https://developer.android.com/training/game-controllers/controller-input.html
\ No newline at end of file +[6]: https://developer.android.com/training/game-controllers/controller-input.html |