12#ifndef ZEPHYR_INCLUDE_USBD_HID_CLASS_DEVICE_H_
13#define ZEPHYR_INCLUDE_USBD_HID_CLASS_DEVICE_H_
int hid_device_submit_report(const struct device *dev, const uint16_t size, const uint8_t *const report)
Submit new input report.
int hid_device_register(const struct device *dev, const uint8_t *const rdesc, const uint16_t rsize, const struct hid_device_ops *const ops)
Register HID device report descriptor and user callbacks.
@ HID_REPORT_TYPE_INPUT
Definition: usbd_hid.h:78
@ HID_REPORT_TYPE_OUTPUT
Definition: usbd_hid.h:79
@ HID_REPORT_TYPE_FEATURE
Definition: usbd_hid.h:80
USB Human Interface Device (HID) common definitions header.
__UINT32_TYPE__ uint32_t
Definition: stdint.h:90
__UINT8_TYPE__ uint8_t
Definition: stdint.h:88
__UINT16_TYPE__ uint16_t
Definition: stdint.h:89
Runtime device structure (in ROM) per driver instance.
Definition: device.h:403
HID device user callbacks.
Definition: usbd_hid.h:94
void(* sof)(const struct device *dev)
Optional Start of Frame (SoF) event callback.
Definition: usbd_hid.h:177
void(* set_idle)(const struct device *dev, const uint8_t id, const uint32_t duration)
Notification to limit input report frequency.
Definition: usbd_hid.h:138
void(* iface_ready)(const struct device *dev, const bool ready)
The interface ready callback is called with the ready argument set to true when the corresponding int...
Definition: usbd_hid.h:102
void(* output_report)(const struct device *dev, const uint16_t len, const uint8_t *const buf)
New output report callback.
Definition: usbd_hid.h:169
int(* set_report)(const struct device *dev, const uint8_t type, const uint8_t id, const uint16_t len, const uint8_t *const buf)
This callback is called for the HID Set Report request to set a feature, input, or output report,...
Definition: usbd_hid.h:126
void(* input_report_done)(const struct device *dev)
Notification that input report submitted with hid_device_submit_report() has been sent.
Definition: usbd_hid.h:160
void(* set_protocol)(const struct device *dev, const uint8_t proto)
Notification that the host has changed the protocol from Boot Protocol(0) to Report Protocol(1) or vi...
Definition: usbd_hid.h:152
uint32_t(* get_idle)(const struct device *dev, const uint8_t id)
If a report ID is used in the report descriptor, the device must implement this callback and return t...
Definition: usbd_hid.h:146
int(* get_report)(const struct device *dev, const uint8_t type, const uint8_t id, const uint16_t len, uint8_t *const buf)
This callback is called for the HID Get Report request to get a feature, input, or output report,...
Definition: usbd_hid.h:114