Wixel SDK
Data Fields
HID_KEYBOARD_OUT_REPORT Struct Reference

#include <usb_hid.h>

Data Fields

uint8 leds
 

Detailed Description

This struct contains the output data sent in HID reports from the host to the keyboard interface. If the Wixel is connected to a Windows machine, you can use this struct to determine whether the Caps Lock, Num Lock, or Scroll Lock options are active. This might not work on Linux or Mac OS computers.

Definition at line 30 of file usb_hid.h.

Field Documentation

uint8 leds

Keyboard LED indicator data. Each bit contains the state of one indicator (1 = on, 0 = off), with the lowest bit representing Num Lock (usage ID 0x01) and the highest bit representing Do Not Disturb (usage ID 0x08) in the LED usage Page. See usb_hid_constants.h for the meaning of each bit. The keyboard's HID Report Descriptor is defined as keyboardReportDescriptor in usb_hid.c.

Example usage:

if (usbHidKeyboardOutput.leds & (1<<LED_CAPS_LOCK))
{
// The Caps Lock LED is on.
}
   This might not work on Linux or Mac OS computers.

Definition at line 49 of file usb_hid.h.


The documentation for this struct was generated from the following file: