This post is older than 2 years and might not be relevant anymore
More Info: Consider searching for newer posts

Sending Function Keys using nrf52832 HID Keyboard

Hi, I need to use nrf52832 as HID keyboard and send function keys F1-F9 to computer. I have tired to run HID keyboard example in nrf5 SDK. How do I send function keys instead of ASCII codes of the letters? Thanks

Parents Reply
  • Hello Hakon,

    Do you have any example that works on nRF52 development board? The Example you linked seems to be for nRF51 board.

    Is there any document to explain how report_map_data is determined?

    Also where are the values for each control action from? I couldn't find them in the USB document.

    typedef enum
    {
    RELEASE_KEY = 0x00,
    CONSUMER_CTRL_PLAY = 0x01,
    CONSUMER_CTRL_ALCCC = 0x02,
    CONSUMER_CTRL_SCAN_NEXT_TRACK = 0x04,
    CONSUMER_CTRL_SCAN_PREV_TRACK = 0x08,
    CONSUMER_CTRL_VOL_DW = 0x10,
    CONSUMER_CTRL_VOL_UP = 0x20,
    CONSUMER_CTRL_AC_FORWARD = 0x40,
    CONSUMER_CTRL_AC_BACK = 0x80,
    } consumer_control_t;

    Thanks

Children
  • Hi,

    xhr0428 said:
    Is there any document to explain how report_map_data is determined?

    In BLE HID over GATT, the transport layer is closely coupled with USB HID. If you want to know more, I would recommend reading up on "usb descriptors" in general, on sites like "usb made simple" or "usb in a nutshell".

    If you look at a USB descriptor, they have a usage, and that usage can be looked up in the previously linked document.

    Kind regards,

    Håkon

Related