LPCOpen Platform
LPCOpen Platform for NXP LPC Microcontrollers
 All Data Structures Files Functions Variables Typedefs Enumerations Enumerator Macros Groups Pages
USBD_HID_API_T Struct Reference

HID class API functions structure.This structure contains pointers to all the function exposed by HID function driver module. More...

#include "usbd_hiduser.h"

Data Fields

uint32_t(* GetMemSize )(USBD_HID_INIT_PARAM_T *param)
 
ErrorCode_t(* init )(USBD_HANDLE_T hUsb, USBD_HID_INIT_PARAM_T *param)
 

Detailed Description

HID class API functions structure.

This structure contains pointers to all the function exposed by HID function driver module.

Definition at line 345 of file usbd_hiduser.h.

Field Documentation

uint32_t GetMemSize

Function to determine the memory required by the HID function driver module.

This function is called by application layer before calling pUsbApi->hid->Init(), to allocate memory used by HID function driver module. The application should allocate the memory which is accessible by USB controller/DMA controller.

Note
Some memory areas are not accessible by all bus masters.
Parameters
paramStructure containing HID function driver module initialization parameters.
Returns
Returns the required memory size in bytes.

Definition at line 358 of file usbd_hiduser.h.

Function to initialize HID function driver module.

This function is called by application layer to initialize HID function driver module. On successful initialization the function returns a handle to HID function driver module in passed param structure.

Parameters
hUsbHandle to the USB device stack.
paramStructure containing HID function driver module initialization parameters.
Returns
Returns ErrorCode_t type to indicate success or error condition.
Return values
LPC_OKOn success
ERR_USBD_BAD_MEM_BUFMemory buffer passed is not 4-byte aligned or smaller than required.
ERR_API_INVALID_PARAM2Either HID_GetReport() or HID_SetReport() callback are not defined.
ERR_USBD_BAD_DESCHID_HID_DESCRIPTOR_TYPE is not defined immediately after interface descriptor.
ERR_USBD_BAD_INTF_DESCWrong interface descriptor is passed.
ERR_USBD_BAD_EP_DESCWrong endpoint descriptor is passed.

Definition at line 381 of file usbd_hiduser.h.


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