root/Examples_CP-JR_ARM7_LPC2368/ETT_LPC2368_Examples/USB_DEMO/USBMem/usbcfg.h

Revision 8, 4.5 kB (checked in by phil, 15 years ago)

Added Examples etc. from CD

Line 
1 /*----------------------------------------------------------------------------
2  *      U S B  -  K e r n e l
3  *----------------------------------------------------------------------------
4  *      Name:    USBCFG.H
5  *      Purpose: USB Custom Configuration
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-2007 Keil Software.
14  *---------------------------------------------------------------------------*/
15
16 #ifndef __USBCFG_H__
17 #define __USBCFG_H__
18
19
20 //*** <<< Use Configuration Wizard in Context Menu >>> ***
21
22
23 /*
24 // <h> USB Configuration
25 //   <o0> USB Power
26 //        <i> Default Power Setting
27 //        <0=> Bus-powered
28 //        <1=> Self-powered
29 //   <o1> Max Number of Interfaces <1-256>
30 //   <o2> Max Number of Endpoints  <1-32>
31 //   <o3> Max Endpoint 0 Packet Size
32 //        <8=> 8 Bytes <16=> 16 Bytes <32=> 32 Bytes <64=> 64 Bytes
33 //   <e4> DMA Transfer
34 //     <i> Use DMA for selected Endpoints
35 //     <o5.0>  Endpoint 0 Out
36 //     <o5.1>  Endpoint 0 In
37 //     <o5.2>  Endpoint 1 Out
38 //     <o5.3>  Endpoint 1 In
39 //     <o5.4>  Endpoint 2 Out
40 //     <o5.5>  Endpoint 2 In
41 //     <o5.6>  Endpoint 3 Out
42 //     <o5.7>  Endpoint 3 In
43 //     <o5.8>  Endpoint 4 Out
44 //     <o5.9>  Endpoint 4 In
45 //     <o5.10> Endpoint 5 Out
46 //     <o5.11> Endpoint 5 In
47 //     <o5.12> Endpoint 6 Out
48 //     <o5.13> Endpoint 6 In
49 //     <o5.14> Endpoint 7 Out
50 //     <o5.15> Endpoint 7 In
51 //     <o5.16> Endpoint 8 Out
52 //     <o5.17> Endpoint 8 In
53 //     <o5.18> Endpoint 9 Out
54 //     <o5.19> Endpoint 9 In
55 //     <o5.20> Endpoint 10 Out
56 //     <o5.21> Endpoint 10 In
57 //     <o5.22> Endpoint 11 Out
58 //     <o5.23> Endpoint 11 In
59 //     <o5.24> Endpoint 12 Out
60 //     <o5.25> Endpoint 12 In
61 //     <o5.26> Endpoint 13 Out
62 //     <o5.27> Endpoint 13 In
63 //     <o5.28> Endpoint 14 Out
64 //     <o5.29> Endpoint 14 In
65 //     <o5.30> Endpoint 15 Out
66 //     <o5.31> Endpoint 15 In
67 //   </e>
68 // </h>
69 */
70
71 #define USB_POWER           0
72 #define USB_IF_NUM          4
73 #define USB_EP_NUM          32
74 #define USB_MAX_PACKET0     64
75 #define USB_DMA             0
76 #define USB_DMA_EP          0x00000000
77
78
79 /*
80 // <h> USB Event Handlers
81 //   <h> Device Events
82 //     <o0.0> Power Event
83 //     <o1.0> Reset Event
84 //     <o2.0> Suspend Event
85 //     <o3.0> Resume Event
86 //     <o4.0> Remote Wakeup Event
87 //     <o5.0> Start of Frame Event
88 //     <o6.0> Error Event
89 //   </h>
90 //   <h> Endpoint Events
91 //     <o7.0>  Endpoint 0 Event
92 //     <o7.1>  Endpoint 1 Event
93 //     <o7.2>  Endpoint 2 Event
94 //     <o7.3>  Endpoint 3 Event
95 //     <o7.4>  Endpoint 4 Event
96 //     <o7.5>  Endpoint 5 Event
97 //     <o7.6>  Endpoint 6 Event
98 //     <o7.7>  Endpoint 7 Event
99 //     <o7.8>  Endpoint 8 Event
100 //     <o7.9>  Endpoint 9 Event
101 //     <o7.10> Endpoint 10 Event
102 //     <o7.11> Endpoint 11 Event
103 //     <o7.12> Endpoint 12 Event
104 //     <o7.13> Endpoint 13 Event
105 //     <o7.14> Endpoint 14 Event
106 //     <o7.15> Endpoint 15 Event
107 //   </h>
108 //   <h> USB Core Events
109 //     <o8.0>  Set Configuration Event
110 //     <o9.0>  Set Interface Event
111 //     <o10.0> Set/Clear Feature Event
112 //   </h>
113 // </h>
114 */
115
116 #define USB_POWER_EVENT     0
117 #define USB_RESET_EVENT     1
118 #define USB_SUSPEND_EVENT   1
119 #define USB_RESUME_EVENT    1
120 #define USB_WAKEUP_EVENT    0
121 #define USB_SOF_EVENT       0
122 #define USB_ERROR_EVENT     0
123 #define USB_EP_EVENT        0x0005
124 #define USB_CONFIGURE_EVENT 1
125 #define USB_INTERFACE_EVENT 0
126 #define USB_FEATURE_EVENT   0
127
128
129 /*
130 // <e0> USB Class Support
131 //   <e1> Human Interface Device (HID)
132 //     <o2> Interface Number <0-255>
133 //   </e>
134 //   <e3> Mass Storage
135 //     <o4> Interface Number <0-255>
136 //   </e>
137 //   <e5> Audio Device
138 //     <o6> Control Interface Number <0-255>
139 //     <o7> Streaming Interface 1 Number <0-255>
140 //     <o8> Streaming Interface 2 Number <0-255>
141 //   </e>
142 // </e>
143 */
144
145 #define USB_CLASS           1
146 #define USB_HID             0
147 #define USB_HID_IF_NUM      0
148 #define USB_MSC             1
149 #define USB_MSC_IF_NUM      0
150 #define USB_AUDIO           0
151 #define USB_ADC_CIF_NUM     0
152 #define USB_ADC_SIF1_NUM    1
153 #define USB_ADC_SIF2_NUM    2
154
155
156 #endif  /* __USBCFG_H__ */
Note: See TracBrowser for help on using the browser.