📄 usbdesc.lst
字号:
ARM COMPILER V2.53, usbdesc 03/05/07 22:10:49 PAGE 1
ARM COMPILER V2.53, COMPILATION OF MODULE usbdesc
OBJECT MODULE PLACED IN .\Obj\usbdesc.obj
COMPILER INVOKED BY: C:\Keil\ARM\BIN\CA.exe usbdesc.c THUMB DEBUG PRINT(.\LST\USBDESC.LST) TABS(4) OBJECT(.\Obj\usbdesc.
-obj)
stmt level source
1 /*----------------------------------------------------------------------------
2 * U S B - K e r n e l
3 *----------------------------------------------------------------------------
4 * Name: USBDESC.C
5 * Purpose: USB Descriptors
6 * Version: V1.10
7 *----------------------------------------------------------------------------
8 * This software is supplied "AS IS" without any warranties, express,
9 * implied or statutory, including but not limited to the implied
10 * warranties of fitness for purpose, satisfactory quality and
11 * noninfringement. Keil extends you a royalty-free right to reproduce
12 * and distribute executable files created using this software for use
13 * on Philips LPC2xxx microcontroller devices only. Nothing else gives
14 * you the right to use this software.
15 *
16 * Copyright (c) 2005-2006 Keil Software.
17 *---------------------------------------------------------------------------*/
18
19 #include "type.h"
20
21 #include "usb.h"
22 #include "msc.h"
23 #include "usbcfg.h"
24 #include "usbdesc.h"
25
26
27 /* USB Standard Device Descriptor */
28 const BYTE USB_DeviceDescriptor[] = {
29 USB_DEVICE_DESC_SIZE, /* bLength */
30 USB_DEVICE_DESCRIPTOR_TYPE, /* bDescriptorType */
31 WBVAL(0x0110), /* 1.10 */ /* bcdUSB */
32 0x00, /* bDeviceClass */
33 0x00, /* bDeviceSubClass */
34 0x00, /* bDeviceProtocol */
35 USB_MAX_PACKET0, /* bMaxPacketSize0 */
36 WBVAL(0xC251), /* idVendor */
37 WBVAL(0x1303), /* idProduct */
38 WBVAL(0x0100), /* 1.00 */ /* bcdDevice */
39 0x04, /* iManufacturer */
40 0x20, /* iProduct */
41 0x48, /* iSerialNumber */
42 0x01 /* bNumConfigurations */
43 };
44
45 /* USB Configuration Descriptor */
46 /* All Descriptors (Configuration, Interface, Endpoint, Class, Vendor */
47 const BYTE USB_ConfigDescriptor[] = {
48 /* Configuration 1 */
49 USB_CONFIGUARTION_DESC_SIZE, /* bLength */
50 USB_CONFIGURATION_DESCRIPTOR_TYPE, /* bDescriptorType */
51 WBVAL( /* wTotalLength */
55 1*USB_CONFIGUARTION_DESC_SIZE +
55 1*USB_INTERFACE_DESC_SIZE +
55 2*USB_ENDPOINT_DESC_SIZE
55 ),
56 0x01, /* bNumInterfaces */
57 0x01, /* bConfigurationValue */
58 0x00, /* iConfiguration */
ARM COMPILER V2.53, usbdesc 03/05/07 22:10:49 PAGE 2
59 USB_CONFIG_BUS_POWERED /*|*/ /* bmAttributes */
60 /*USB_CONFIG_REMOTE_WAKEUP*/,
61 USB_CONFIG_POWER_MA(100), /* bMaxPower */
62 /* Interface 0, Alternate Setting 0, MSC Class */
63 USB_INTERFACE_DESC_SIZE, /* bLength */
64 USB_INTERFACE_DESCRIPTOR_TYPE, /* bDescriptorType */
65 0x00, /* bInterfaceNumber */
66 0x00, /* bAlternateSetting */
67 0x02, /* bNumEndpoints */
68 USB_DEVICE_CLASS_STORAGE, /* bInterfaceClass */
69 MSC_SUBCLASS_SCSI, /* bInterfaceSubClass */
70 MSC_PROTOCOL_BULK_ONLY, /* bInterfaceProtocol */
71 0x62, /* iInterface */
72 /* Bulk In Endpoint */
73 USB_ENDPOINT_DESC_SIZE, /* bLength */
74 USB_ENDPOINT_DESCRIPTOR_TYPE, /* bDescriptorType */
75 USB_ENDPOINT_IN(2), /* bEndpointAddress */
76 USB_ENDPOINT_TYPE_BULK, /* bmAttributes */
77 WBVAL(0x0040), /* wMaxPacketSize */
78 0, /* bInterval */
79 /* Bulk Out Endpoint */
80 USB_ENDPOINT_DESC_SIZE, /* bLength */
81 USB_ENDPOINT_DESCRIPTOR_TYPE, /* bDescriptorType */
82 USB_ENDPOINT_OUT(2), /* bEndpointAddress */
83 USB_ENDPOINT_TYPE_BULK, /* bmAttributes */
84 WBVAL(0x0040), /* wMaxPacketSize */
85 0, /* bInterval */
86 /* Terminator */
87 0 /* bLength */
88 };
89
90 /* USB String Descriptor (optional) */
91 const BYTE USB_StringDescriptor[] = {
92 /* Index 0x00: LANGID Codes */
93 0x04, /* bLength */
94 USB_STRING_DESCRIPTOR_TYPE, /* bDescriptorType */
95 WBVAL(0x0409), /* US English */ /* wLANGID */
96 /* Index 0x04: Manufacturer */
97 0x1C, /* bLength */
98 USB_STRING_DESCRIPTOR_TYPE, /* bDescriptorType */
99 'K',0,
100 'e',0,
101 'i',0,
102 'l',0,
103 ' ',0,
104 'S',0,
105 'o',0,
106 'f',0,
107 't',0,
108 'w',0,
109 'a',0,
110 'r',0,
111 'e',0,
112 /* Index 0x20: Product */
113 0x28, /* bLength */
114 USB_STRING_DESCRIPTOR_TYPE, /* bDescriptorType */
115 'K',0,
116 'e',0,
117 'i',0,
118 'l',0,
119 ' ',0,
120 'M',0,
121 'C',0,
122 'B',0,
123 '2',0,
124 '1',0,
ARM COMPILER V2.53, usbdesc 03/05/07 22:10:49 PAGE 3
125 '4',0,
126 '0',0,
127 ' ',0,
128 'M',0,
129 'e',0,
130 'm',0,
131 'o',0,
132 'r',0,
133 'y',0,
134 /* Index 0x48: Serial Number */
135 0x1A, /* bLength */
136 USB_STRING_DESCRIPTOR_TYPE, /* bDescriptorType */
137 'D',0,
138 'E',0,
139 'M',0,
140 'O',0,
141 '0',0,
142 '0',0,
143 '0',0,
144 '0',0,
145 '0',0,
146 '0',0,
147 '0',0,
148 '0',0,
149 /* Index 0x62: Interface 0, Alternate Setting 0 */
150 0x0E, /* bLength */
151 USB_STRING_DESCRIPTOR_TYPE, /* bDescriptorType */
152 'M',0,
153 'e',0,
154 'm',0,
155 'o',0,
156 'r',0,
157 'y',0,
158 };
ARM COMPILER V2.53, usbdesc 03/05/07 22:10:49 PAGE 4
ASSEMBLY LISTING OF GENERATED OBJECT CODE
*** PUBLICS:
PUBLIC USB_DeviceDescriptor
PUBLIC USB_ConfigDescriptor
PUBLIC USB_StringDescriptor
*** DATA SEGMENT '?CON?usbdesc':
00000000 USB_DeviceDescriptor:
00000000 BEGIN_INIT
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -