Hi!
I use HID example and try to understand in a hid service init for why report_map_data[] with a table.
What is do this array? If I use keyboard example, I should get event in the on_hids_evt(). But this array for what?
Hi!
I use HID example and try to understand in a hid service init for why report_map_data[] with a table.
What is do this array? If I use keyboard example, I should get event in the on_hids_evt(). But this array for what?
Hi,
That array is the USB HID report descriptor. The descriptor is a hard coded array of bytes that describes the device's data packets. Which includes, how many packets the device supports, the size of the packets, and the purpose of each byte and bit in the packet.
You can read more about HID here. Also check out the specification.
It depends on what you are trying to do. If you want it to be a keyboard, you should just leave it as it is.
Not sure what you mean by "this ble HID", do you mean the HID Keyboard example from the SDK? If so, yes the example that implements the HID over GATT profile for keyboard. Yes it should send some keys out, have a look at how you can test the example here.
What you mean by receive data? What kind of data?
Yes, I mean the HID Keyboard example from the SDK.
For why function on_hid_rep_char_write(p_evt); in a BLE_HIDS_EVT_REP_CHAR_WRITE case?
You get the BLE_HIDS_EVT_REP_CHAR_WRITE event when a new value has been written to an Report characteristic. And the function on_hid_rep_char_write(p_evt) is a function for handling the HID Report Characteristic Write event.
You get the BLE_HIDS_EVT_REP_CHAR_WRITE event when a new value has been written to an Report characteristic.
Do you mean written by whom? Written by my app (keyboard) or received from host?
This is on_hids_evt() I received all from remote host ble device?
You will get BLE_HIDS_EVT_REP_CHAR_WRITE when a new value has been received from the host. It is the host that sends to the keyboard.
You will get BLE_HIDS_EVT_REP_CHAR_WRITE when a new value has been received from the host. It is the host that sends to the keyboard.