
UM10375
All information provided in this document is subject to legal disclaimers.
© NXP B.V. 2011. All rights reserved.
User manual
Rev. 3 — 14 June 2011
172 of 368
NXP Semiconductors
UM10375
Chapter 11: LPC13xx USB on-chip drivers
DeviceInfo.DevDetailPtr = (uint32_t)&HidDevInfo;
(*rom)->pUSBD->init(&DeviceInfo);
6. Add the USB interrupt handler to your project:
USB_IRQHandler(void)
{
(*rom)->pUSBD->isr();
}
7. Call USB connect:
USB Connect
(*rom)->pUSBD->connect(TRUE);
11.5 USB driver structure definitions
11.5.1 ROM driver table
The following structure is used to access the USB driver table stored in ROM:
typedef struct _ROM {
const USBD * pUSBD;
} ROM;
11.5.2 USB driver table
The following structure is used to access the functions exposed by the USB driver:
typedef struct _USBD {
void (*init_clk_pins)(void);
void (*isr)(void);
void (*init)( USB_DEV_INFO * DevInfoPtr );
void (*connect)(uint32_t con);
} USBD;
11.5.3 USB device information
The following structure is used to pass the USB device type and information:
typedef struct _USB_DEVICE_INFO {
uint16_t DevType;
uint32_t DevDetailPtr;
} USB_DEV_INFO;