EasyManuals Logo

NXP Semiconductors LPC11U3x User Manual

NXP Semiconductors LPC11U3x
523 pages
To Next Page IconTo Next Page
To Next Page IconTo Next Page
To Previous Page IconTo Previous Page
To Previous Page IconTo Previous Page
Page #202 background imageLoading...
Page #202 background image
UM10462 All information provided in this document is subject to legal disclaimers. © NXP B.V. 2016. All rights reserved.
User manual Rev. 5.5 — 21 December 2016 202 of 523
NXP Semiconductors
UM10462
Chapter 10: LPC11U3x/2x/1x USB on-chip drivers
Table 207. USBD_HID_INIT_PARAM class structure
Member Description
mem_base
uint32_t USBD_HID_INIT_PARAM::mem_base
Base memory location from where the stack can allocate data and buffers.
Remark: The memory address set in this field should be accessible by USB DMA controller. Also
this value should be aligned on 4 byte boundary.
mem_size
uint32_t USBD_HID_INIT_PARAM::mem_size
The size of memory buffer which stack can use.
Remark: The mem_size should be greater than the size returned by
USBD_HID_API::GetMemSize() routine.
max_reports
uint8_t USBD_HID_INIT_PARAM::max_reports
Number of HID reports supported by this instance of HID class driver.
pad
uint8_t USBD_HID_INIT_PARAM::pad[3][3]
intf_desc
uint8_t * USBD_HID_INIT_PARAM::intf_desc
Pointer to the HID interface descriptor within the descriptor array (
report_data
USB_HID_REPORT_T *USB_HID_REPORT_T* USBD_HID_INIT_PARAM::report_data
Pointer to an array of HID report descriptor data structure (
Remark: This array should be of global scope.
HID_GetReport
ErrorCode_t(* USBD_HID_INIT_PARAM::HID_GetReport)(USBD_HANDLE_T hHid, USB_SETUP_PACKET *pSetup,
uint8_t **pBuffer, uint16_t *length)
HID get report callback function.
This function is provided by the application software. This function gets called when host sends a
HID_REQUEST_GET_REPORT request. The setup packet data (
Remark: HID reports are sent via interrupt IN endpoint also. This function is called only when report
request is received on control endpoint. Application should implement HID_EpIn_Hdlr to send
reports to host via interrupt IN endpoint.
Parameters:
1. hHid = Handle to HID function driver.
2. pSetup = Pointer to setup packet received from host.
3. pBuffer = Pointer to a pointer of data buffer containing report data. Pointer-to-pointer is used to
implement zero-copy buffers. See Zero-Copy Data Transfer model for more details on
zero-copy concept.
4. length = Amount of data copied to destination buffer.
Returns:
The call back should returns ErrorCode_t type to indicate success or error condition.
Return values:
1. LPC_OK = On success.
2. ERR_USBD_UNHANDLED = Event is not handled hence pass the event to next in line.
3. ERR_USBD_xxx = For other error conditions.

Table of Contents

Questions and Answers:

Question and Answer IconNeed help?

Do you have a question about the NXP Semiconductors LPC11U3x and is the answer not in the manual?

NXP Semiconductors LPC11U3x Specifications

General IconGeneral
BrandNXP Semiconductors
ModelLPC11U3x
CategoryMicrocontrollers
LanguageEnglish

Related product manuals