Dear all,
I am currently doing some transfer performance tests between a HID device and a WinXP PC and I don't manage to reach transfer rate above about 260kBytes/sec.
The device under test is based on a ARM926 evaluation board and is configured as a HID device and is defined as 'vendor specific' usage. For the considered throughput tests, it constantly sends data to the host via the interrupt IN endpoint. On the WinXp host PC, I am using the Windows DDK API to read the data coming from the USB device.
The device is correctly recognized as a generic HID device by Windows. Via a USB packet sniffer, I could see that the sizes of exchanged packets match the size defined in the HID report descriptor. However, the bus is polled only with a period of 1ms while the 'bInterval' field is set to 1 (for a high speed device).
I suspect that the problem comes from wrong descriptors definition. Would anyone have already met similar problem with HID devices?
Would this problem be a limitation of the 'vendor defined” usage?
Would this problem be connected to any particular Windows settings?
How can I be sure that the device is well operating in high-speed mode (and not in full speed mode)?
The USB descriptors have been added hereafter, maybe this can give more insight to the problem.
Thanks in advance for any help or information concerning this problem.
Best regards
Adrien
USB sniffer snapshot:
Type Seq Elapsed Duration Request Request Details I/O Driver Name Status
URB 39559 103.642837 s Bulk or Interrupt Transfer 255 bytes buffer in hhdusbh32
URB 39560 103.642840 s Bulk or Interrupt Transfer 255 bytes buffer in usbccgp
URB 39561 103.642842 s Bulk or Interrupt Transfer 255 bytes buffer in usbccgp
URB 39562 103.642845 s Bulk or Interrupt Transfer 255 bytes buffer in hhdusbh32
URB 39563 103.642847 s Bulk or Interrupt Transfer 255 bytes buffer in ACPI
URB 39564 103.642849 s Bulk or Interrupt Transfer 255 bytes buffer in usbhub
URB 39565-39564 103.643946 s 1.097 ms Bulk or Interrupt Transfer Input Report len:255 in usbhub Success (Success)
URB 39566-39563 103.643949 s 1.102 ms Bulk or Interrupt Transfer Input Report len:255 in ACPI Success (Success)
URB 39567-39562 103.643951 s 1.106 ms Bulk or Interrupt Transfer Input Report len:255 in hhdusbh32 Success (Success)
URB 39568-39561 103.643953 s 1.111 ms Bulk or Interrupt Transfer Input Report len:255 in usbccgp Success (Success)
URB 39569-39560 103.643956 s 1.116 ms Bulk or Interrupt Transfer Input Report len:255 in usbccgp Success (Success)
URB 39570-39559 103.643958 s 1.121 ms Bulk or Interrupt Transfer Input Report len:255 in hhdusbh32 Success (Success)
URB 39571 103.643962 s Bulk or Interrupt Transfer 255 bytes buffer in hhdusbh32
URB 39572 103.643964 s Bulk or Interrupt Transfer 255 bytes buffer in usbccgp
URB 39573 103.643967 s Bulk or Interrupt Transfer 255 bytes buffer in usbccgp
URB 39574 103.643969 s Bulk or Interrupt Transfer 255 bytes buffer in hhdusbh32
URB 39575 103.643972 s Bulk or Interrupt Transfer 255 bytes buffer in ACPI
URB 39576 103.643974 s Bulk or Interrupt Transfer 255 bytes buffer in usbhub
URB 39577-39576 103.644946 s 972 us Bulk or Interrupt Transfer Input Report len:255 in usbhub Success (Success)
URB 39578-39575 103.644948 s 977 us Bulk or Interrupt Transfer Input Report len:255 in ACPI Success (Success)
URB 39579-39574 103.644950 s 981 us Bulk or Interrupt Transfer Input Report len:255 in hhdusbh32 Success (Success)
URB 39580-39573 103.644953 s 986 us Bulk or Interrupt Transfer Input Report len:255 in usbccgp Success (Success)
URB 39581-39572 103.644955 s 991 us Bulk or Interrupt Transfer Input Report len:255 in usbccgp Success (Success)
URB 39582-39571 103.644958 s 996 us Bulk or Interrupt Transfer Input Report len:255 in hhdusbh32 Success (Success)
HID report descriptor (as seen by USBLyzer):
Interface 1 HID Report Descriptor Vendor-Defined 1
Item Tag (Value) Raw Data
Usage Page (Vendor-Defined 1) 06 00 FF
Usage (Vendor-Defined 1) 09 01
Collection (Application) A1 01
Usage (Vendor-Defined 1) 09 01
Logical Minimum (0) 15 00
Logical Maximum (255) 26 FF 00
Report Count (8) 95 08
Report Size (255) 75 FF
Input (Data,Var,Abs,NWrp,Lin,Pref,NNul,Bit) 81 02
Usage (Vendor-Defined 1) 09 01
Logical Minimum (0) 15 00
Logical Maximum (255) 26 FF 00
Report Count (8) 95 08
Report Size (255) 75 FF
Output (Data,Var,Abs,NWrp,Lin,Pref,NNul,NVol,Bit) 91 02
End Collection C0
USB descriptors (as seen by USBLyzer):
Device Descriptor BIDULE
Offset Field Size Value Description
0 bLength 1 12h
1 bDescriptorType 1 01h Device
2 bcdUSB 2 0200h USB Spec 2.0
4 bDeviceClass 1 00h Class info in Ifc Descriptors
5 bDeviceSubClass 1 00h
6 bDeviceProtocol 1 00h
7 bMaxPacketSize0 1 40h 64 bytes
8 idVendor 2 0525h Netchip Technology, Inc.
10 idProduct 2 A4A4h
12 bcdDevice 2 0100h 1.00
14 iManufacturer 1 01h "Licensed to Code, LLC"
15 iProduct 1 02h "BIDULE"
16 iSerialNumber 1 03h "gb7pzguz7eafahyd22ya2dmt2tlmf5jf3yp2ntw1md065owkywphbrcr5xj7y89"
17 bNumConfigurations 1 01h
Device Qualifier Descriptor
Offset Field Size Value Description
0 bLength 1 0Ah
1 bDescriptorType 1 06h Device Qualifier
2 bcdUSB 2 0200h USB Spec 2.0
4 bDeviceClass 1 00h Class info in Ifc Descriptors
5 bDeviceSubClass 1 00h
6 bDeviceProtocol 1 00h
7 bMaxPacketSize0 1 40h 64 bytes
8 bNumConfigurations 1 01h
9 bReserved 1 00h
Configuration Descriptor 3 Self Powered
Offset Field Size Value Description
0 bLength 1 09h
1 bDescriptorType 1 02h Configuration
2 wTotalLength 2 0040h
4 bNumInterfaces 1 01h
5 bConfigurationValue 1 03h
6 iConfiguration 1 04h "The Configuration"
7 bmAttributes 1 C0h Self Powered
4..0: Reserved ...00000
5: Remote Wakeup ..0..... No
6: Self Powered .1...... Yes
7: Reserved (set to one)
(bus-powered for 1.0) 1.......
8 bMaxPower 1 01h 2 mA
Interface Descriptor 0/0 HID, 2 Endpoints
Offset Field Size Value Description
0 bLength 1 09h
1 bDescriptorType 1 04h Interface
2 bInterfaceNumber 1 01h
3 bAlternateSetting 1 00h
4 bNumEndpoints 1 02h
5 bInterfaceClass 1 03h HID
6 bInterfaceSubClass 1 00h
7 bInterfaceProtocol 1 00h
8 iInterface 1 05h "Source/Sink"
HID Descriptor
Offset Field Size Value Description
0 bLength 1 09h
1 bDescriptorType 1 21h HID
2 bcdHID 2 0101h 1.01
4 bCountryCode 1 00h
5 bNumDescriptors 1 01h
6 bDescriptorType 1 22h Report
7 wDescriptorLength 2 0022h 34 bytes
Endpoint Descriptor 83 3 In, Interrupt, 125 us
Offset Field Size Value Description
0 bLength 1 07h
1 bDescriptorType 1 05h Endpoint
2 bEndpointAddress 1 83h 3 In
3 bmAttributes 1 03h Interrupt
1..0: Transfer Type ......11 Interrupt
7..2: Reserved 000000..
4 wMaxPacketSize 2 0400h 1024 bytes
6 bInterval 1 01h 125 us
Endpoint Descriptor 04 4 Out, Interrupt, 125 us
Offset Field Size Value Description
0 bLength 1 07h
1 bDescriptorType 1 05h Endpoint
2 bEndpointAddress 1 04h 4 Out
3 bmAttributes 1 03h Interrupt
1..0: Transfer Type ......11 Interrupt
7..2: Reserved 000000..
4 wMaxPacketSize 2 0400h 1024 bytes
6 bInterval 1 01h 125 us