|
用的是新的例程,可是自举成功后老判断不出usb工作标准
是这句 hshostlink = (Usb2or11 & SX2_HSGRANT) ? TRUE : FALSE;
返回肯定是false
因为自举后Usb2or11=2 SX2_HSGRANT=0x80
是Usb2or11的返回值错误吗
还是因为usb不是直接连在电脑上,又通过另一个usb插口连接的,是这个的问题吗
谢谢
下面是返回的描述符:
the current cy7c68001\'s device descriptor is:
\\par -----------------------------------------------------------
\\par \\tab Vendor ID is: 0x4b4
\\par \\tab Product ID is: 0x82
\\par \\tab Device ID is: 0x0
\\par \\tab Maximum Packet Size is: 0x40
\\par \\tab Device class is: 0x0
\\par \\tab Device sub-class is: 0x0
\\par \\tab Manufacturer string index is: 0x1
\\par \\tab Product string index is: 0x82
\\par \\tab Serial number string index is: 0x0
\\par \\tab Number of configurations is: 0x1
\\par
\\par
\\par *********************************************************************
\\par The current cy7c68001\'s configuration Decriptor is:
\\par \\tab bLength: 0x9
\\par \\tab bDescriptorType: 2
\\par \\tab wTotalLength: 46 (0x2e)
\\par \\tab bNumInterfaces: 1
\\par \\tab bConfigurationValue: 1
\\par \\tab iConfiguration: 0
\\par \\tab bmAttributes: 0x40
\\par \\tab MaxPower: 50
\\par ***********************************
\\par Interface Descriptor:
\\par -----------------------------------
\\par \\tab bLength: 0x9
\\par \\tab bDescriptorType: 4
\\par \\tab bInterfaceNumber: 0
\\par \\tab bAlternateSetting: 0
\\par \\tab bNumEndpoints: 4
\\par \\tab bInterfaceClass: 255 (0xff)
\\par \\tab bInterfaceSubClass: 0 (0x0)
\\par \\tab bInterfaceProtocol: 0 (0x0)
\\par \\tab iInterface: 0
\\par ************************************
\\par Endpoint Descriptor 0
\\par -----------------------------------
\\par \\tab bLength: 0x7
\\par \\tab bDescriptorType: 5
\\par \\tab bEndpointAddress: 0x2
\\par \\tab bmAttributes: 0x2
\\par \\tab wMaxPacketSize: 64
\\par \\tab bInterval: 0
\\par *************************************
\\par Endpoint Descriptor 1
\\par -----------------------------------
\\par \\tab bLength: 0x7
\\par \\tab bDescriptorType: 5
\\par \\tab bEndpointAddress: 0x4
\\par \\tab bmAttributes: 0x2
\\par \\tab wMaxPacketSize: 64
\\par \\tab bInterval: 0
\\par *************************************
\\par Endpoint Descriptor 2
\\par -----------------------------------
\\par \\tab bLength: 0x7
\\par \\tab bDescriptorType: 5
\\par \\tab bEndpointAddress: 0x86
\\par \\tab bmAttributes: 0x2
\\par \\tab wMaxPacketSize: 64
\\par \\tab bInterval: 0
\\par *************************************
\\par Endpoint Descriptor 3
\\par -----------------------------------
\\par \\tab bLength: 0x7
\\par \\tab bDescriptorType: 5
\\par \\tab bEndpointAddress: 0x88
\\par \\tab bmAttributes: 0x2
\\par \\tab wMaxPacketSize: 64
\\par \\tab bInterval: 0
|
|