root/Examples_CP-JR_ARM7_LPC2368/ETT_LPC2368_Examples/USB_DEMO/USBHID/usbuser.h

Revision 8, 3.0 kB (checked in by phil, 16 years ago)

Added Examples etc. from CD

Line 
1 /*----------------------------------------------------------------------------
2  *      U S B  -  K e r n e l
3  *----------------------------------------------------------------------------
4  *      Name:    USBUSER.H
5  *      Purpose: USB Custom User Definitions
6  *      Version: V1.10
7  *----------------------------------------------------------------------------
8  *      This file is part of the uVision/ARM development tools.
9  *      This software may only be used under the terms of a valid, current,
10  *      end user licence from KEIL for a compatible version of KEIL software
11  *      development tools. Nothing else gives you the right to use it.
12  *
13  *      Copyright (c) 2005-2006 Keil Software.
14  *---------------------------------------------------------------------------*/
15
16 #ifndef __USBUSER_H__
17 #define __USBUSER_H__
18
19
20 /* USB Device Events Callback Functions */
21 extern void USB_Power_Event     (BOOL  power);
22 extern void USB_Reset_Event     (void);
23 extern void USB_Suspend_Event   (void);
24 extern void USB_Resume_Event    (void);
25 extern void USB_WakeUp_Event    (void);
26 extern void USB_SOF_Event       (void);
27 extern void USB_Error_Event     (DWORD error);
28
29 /* USB Endpoint Callback Events */
30 #define USB_EVT_SETUP       1   /* Setup Packet */
31 #define USB_EVT_OUT         2   /* OUT Packet */
32 #define USB_EVT_IN          3   /*  IN Packet */
33 #define USB_EVT_OUT_NAK     4   /* OUT Packet - Not Acknowledged */
34 #define USB_EVT_IN_NAK      5   /*  IN Packet - Not Acknowledged */
35 #define USB_EVT_OUT_STALL   6   /* OUT Packet - Stalled */
36 #define USB_EVT_IN_STALL    7   /*  IN Packet - Stalled */
37 #define USB_EVT_OUT_DMA_EOT 8   /* DMA OUT EP - End of Transfer */
38 #define USB_EVT_IN_DMA_EOT  9   /* DMA  IN EP - End of Transfer */
39 #define USB_EVT_OUT_DMA_NDR 10  /* DMA OUT EP - New Descriptor Request */
40 #define USB_EVT_IN_DMA_NDR  11  /* DMA  IN EP - New Descriptor Request */
41 #define USB_EVT_OUT_DMA_ERR 12  /* DMA OUT EP - Error */
42 #define USB_EVT_IN_DMA_ERR  13  /* DMA  IN EP - Error */
43
44 /* USB Endpoint Events Callback Pointers */
45 extern void (* const USB_P_EP[16])(DWORD event);
46
47 /* USB Endpoint Events Callback Functions */
48 extern void USB_EndPoint0  (DWORD event);
49 extern void USB_EndPoint1  (DWORD event);
50 extern void USB_EndPoint2  (DWORD event);
51 extern void USB_EndPoint3  (DWORD event);
52 extern void USB_EndPoint4  (DWORD event);
53 extern void USB_EndPoint5  (DWORD event);
54 extern void USB_EndPoint6  (DWORD event);
55 extern void USB_EndPoint7  (DWORD event);
56 extern void USB_EndPoint8  (DWORD event);
57 extern void USB_EndPoint9  (DWORD event);
58 extern void USB_EndPoint10 (DWORD event);
59 extern void USB_EndPoint11 (DWORD event);
60 extern void USB_EndPoint12 (DWORD event);
61 extern void USB_EndPoint13 (DWORD event);
62 extern void USB_EndPoint14 (DWORD event);
63 extern void USB_EndPoint15 (DWORD event);
64
65 /* USB Core Events Callback Functions */
66 extern void USB_Configure_Event (void);
67 extern void USB_Interface_Event (void);
68 extern void USB_Feature_Event   (void);
69
70
71 #endif  /* __USBUSER_H__ */
Note: See TracBrowser for help on using the browser.