USB_Descriptors.LST
上传用户:gxz1972
上传日期:2019-09-13
资源大小:323k
文件大小:7k
源码类别:

传真(Fax)编程

开发平台:

C/C++

  1. C51 COMPILER V7.02b   USB_DESCRIPTORS                                                      11/30/2007 14:07:12 PAGE 1   
  2. C51 COMPILER V7.02b, COMPILATION OF MODULE USB_DESCRIPTORS
  3. OBJECT MODULE PLACED IN USB_Descriptors.OBJ
  4. COMPILER INVOKED BY: C:KeilC51BINc51.exe USB_Descriptors.c DB OE
  5. stmt level    source
  6.    1          //-----------------------------------------------------------------------------
  7.    2          // USB_Descriptors.c
  8.    3          //-----------------------------------------------------------------------------
  9.    4          // Copyright 2007 Vson Technology, Inc.
  10.    5          // http://www.usbmcu.com
  11.    6          //
  12.    7          // Program Description:
  13.    8          //
  14.    9          //
  15.   10          //
  16.   11          //
  17.   12          //
  18.   13          // MCU:            C8051F347
  19.   14          // Tool chain:     Keil C51 7.50 / Keil EVAL C51
  20.   15          //                 Silicon Laboratories IDE version 2.6
  21.   16          // Command Line:   
  22.   17          // Project Name:   TR1000
  23.   18          //
  24.   19          //
  25.   20          // Release 1.0
  26.   21          //    -All changes by Brin Cai
  27.   22          //    -24 JUL 2007
  28.   23          //
  29.   24          //
  30.   25          
  31.   26          //-----------------------------------------------------------------------------
  32.   27          // Includes
  33.   28          //-----------------------------------------------------------------------------
  34.   29          
  35.   30          #include "Include_H.h"
  36.   31          
  37.   32          //-----------------------------------------------------------------------------
  38.   33          // Global Constants
  39.   34          //-----------------------------------------------------------------------------
  40.   35          
  41.   36          // All descriptors are contained in the global structure <gDescriptorMap>.
  42.   37          // This structure contains BYTE arrays for the standard device descriptor
  43.   38          // and all configurations. The lengths of the configuration arrays are
  44.   39          // defined by the number of interface and endpoint descriptors required
  45.   40          // for the particular configuration (these constants are named
  46.   41          // CFG1_IF_DSC and CFG1_EP_DSC for configuration1).
  47.   42          //
  48.   43          // The entire gDescriptorMap structure is initialized below in
  49.   44          // codespace.
  50.   45          
  51.   46          DESCRIPTORS code gDescriptorMap = {
  52.   47          
  53.   48          //---------------------------
  54.   49          // Begin Standard Device Descriptor (structure element stddevdsc)
  55.   50          //---------------------------
  56.   51             18,                        // bLength
  57.   52             0x01,                      // bDescriptorType
  58.   53             0x00, 0x02,                // bcdUSB (lsb first)
  59.   54             0x00,                      // bDeviceClass
  60.   55             0x00,                      // bDeviceSubClass
  61. C51 COMPILER V7.02b   USB_DESCRIPTORS                                                      11/30/2007 14:07:12 PAGE 2   
  62.   56             0x00,                      // bDeviceProtocol
  63.   57             64,                        // bMaxPacketSize0
  64.   58             //0xC4, 0x10,                // idVendor (lsb first)
  65.   59             //0x03, 0x00,                // idProduct (lsb first)
  66.   60          
  67.   61             0x38, 0x01,                // idVendor (lsb first)
  68.   62             0x38, 0x01,                // idProduct (lsb first)
  69.   63             0x00, 0x00,                // bcdDevice (lsb first)
  70.   64             0x00,                      // iManufacturer
  71.   65             0x00,                      // iProduct
  72.   66             0x00,                      // iSerialNumber
  73.   67             0x01,                      // bNumConfigurations
  74.   68          
  75.   69          //---------------------------
  76.   70          // Begin Configuration 1 (structure element cfg1)
  77.   71          //---------------------------
  78.   72          
  79.   73             // Begin Descriptor: Configuration 1
  80.   74             0x09,                      // Length
  81.   75             0x02,                      // Type
  82.   76             0x20, 0x00,                // TotalLength (lsb first)
  83.   77             0x01,                      // NumInterfaces
  84.   78             0x01,                      // bConfigurationValue
  85.   79             0x00,                      // iConfiguration
  86.   80             0x80,                      // bmAttributes (no remote wakeup)
  87.   81             0x0F,                      // MaxPower (*2mA)
  88.   82          
  89.   83             // Begin Descriptor: Interface0, Alternate0
  90.   84             0x09,                      // bLength
  91.   85             0x04,                      // bDescriptorType
  92.   86             0x00,                      // bInterfaceNumber
  93.   87             0x00,                      // bAlternateSetting
  94.   88             0x02,                      // bNumEndpoints
  95.   89             0x00,                      // bInterfaceClass
  96.   90             0x00,                      // bInterfaceSubClass
  97.   91             0x00,                      // bInterfaceProcotol
  98.   92             0x00,                      // iInterface
  99.   93          
  100.   94             // Begin Descriptor: Endpoint1, Interface0, Alternate0
  101.   95             0x07,                      // bLength
  102.   96             0x05,                      // bDescriptorType
  103.   97             0x81,                      // bEndpointAddress (ep1, IN)
  104.   98             0x02,                      // bmAttributes (Bulk)
  105.   99             0x40, 0x00,                // wMaxPacketSize (lsb first)
  106.  100             0x05,                      // bInterval
  107.  101          
  108.  102             // Begin Descriptor: Endpoint2, Interface0, Alternate0
  109.  103             0x07,                      // bLength
  110.  104             0x05,                      // bDescriptorType
  111.  105             0x02,                      // bEndpointAddress (ep2, OUT)
  112.  106             0x02,                      // bmAttributes (Bulk)
  113.  107             0x40, 0x00,                // wMaxPacketSize (lsb first)
  114.  108             0x05,                      // bInterval
  115.  109          
  116.  110          //---------------------------
  117.  111          // End Configuration 1
  118.  112          //---------------------------
  119.  113          
  120.  114          };
  121.  115          
  122.  116          //-----------------------------------------------------------------------------
  123.  117          // End Of File
  124. C51 COMPILER V7.02b   USB_DESCRIPTORS                                                      11/30/2007 14:07:12 PAGE 3   
  125.  118          //-----------------------------------------------------------------------------
  126. MODULE INFORMATION:   STATIC OVERLAYABLE
  127.    CODE SIZE        =   ----    ----
  128.    CONSTANT SIZE    =     50    ----
  129.    XDATA SIZE       =   ----    ----
  130.    PDATA SIZE       =   ----    ----
  131.    DATA SIZE        =   ----    ----
  132.    IDATA SIZE       =   ----    ----
  133.    BIT SIZE         =   ----    ----
  134. END OF MODULE INFORMATION.
  135. C51 COMPILATION COMPLETE.  0 WARNING(S),  0 ERROR(S)