Back from vacation and back to the problem.
I think I need to explain the problem in more detail.We are currently developing a HID device which should send 1024 bytes in a report.
Later we want to send 4 reports in one microframe. At the moment only one to figure out the issues.
The USB descriptor tells me the following.
+++++++++++++++++ Device Information ++++++++++++++++++
Device Description : USB-Eingabegerät
Device ID : USB\VID_07C0&PID_2000\7&3188F4DA&0&2
Driver KeyName : {745a17a0-74d3-11d0-b6fe-00a0c90f57da}\0057
Driver : C:\WINDOWS\System32\drivers\hidusb.sys (Version: 6.2.17134 Date: 2018-04-12)
Legacy BusType : PNPBus
Class : HIDClass
Service : HidUsb
Enumerator : USB
Location Info : Port_#0002.Hub_#0006
Manufacturer Info : (Standardsystemgeräte)
Capabilities : Removable, SurpriseRemovalOK
Address : 2
Problem Code : 0
Power State : D0 (supported: D0, D2, D3, wake from D0, wake from D2)
Child Device 1 : HID-konformes Gerät
Device ID : HID\VID_07C0&PID_2000\8&C2AE1C9&1&0000
Class : HIDClass
---------------- Connection Information ---------------
Connection Index : 0x02
Connection Status : 0x01 (DeviceConnected)
Current Config Value : 0x01
Device Address : 0x06
Is Hub : 0x00 (no)
Number Of Open Pipes : 0x02 (2)
Device Bus Speed : 0x02 (High-Speed)
Pipe0ScheduleOffset : 0x00 (0)
Pipe1ScheduleOffset : 0x00 (0)
------------- Device Qualifier Descriptor -------------
bLength : 0x12 (18 bytes)
bDescriptorType : 0x01 (Device Qualifier Descriptor)
bcdUSB : 0x200 (USB Version 2.00)
bDeviceClass : 0x00 (defined by the interface descriptors)
bDeviceSubClass : 0x00
bDeviceProtocol : 0x00
bMaxPacketSize0 : 0x40 (64 bytes)
idVendor : 0x07C0
idProduct : 0x2000
bcdDevice : 0x10
iManufacturer : 0x01
Language 0x0409 : "Code Mercenaries"
iProduct : 0x02
Language 0x0409 : "FlickerMeter"
iSerialNumber : 0x00
bNumConfigurations : 0x01
-------------- Configuration Descriptor ---------------
bLength : 0x09 (9 bytes)
bDescriptorType : 0x02 (Configuration Descriptor)
wTotalLength : 0x0029 (41 bytes)
bNumInterfaces : 0x01
bConfigurationValue : 0x01
iConfiguration : 0x04
Language 0x0409 : "Standard Setup"
bmAttributes : 0x80 (Bus Powered)
MaxPower : 0x32 (100 mA)
---------------- Interface Descriptor -----------------
bLength : 0x09 (9 bytes)
bDescriptorType : 0x04 (Interface Descriptor)
bInterfaceNumber : 0x00
bAlternateSetting : 0x00
bNumEndpoints : 0x02
bInterfaceClass : 0x03 (HID - Human Interface Device)
bInterfaceSubClass : 0x00 (None)
bInterfaceProtocol : 0x00 (None)
iInterface : 0x05
Language 0x0409 : "Interface0"
------------------- HID Descriptor --------------------
bLength : 0x09 (9 bytes)
bDescriptorType : 0x21 (HID Descriptor)
bcdHID : 0x0111 (HID Version 1.11)
bCountryCode : 0x00 (00 = not localized)
bNumDescriptors : 0x01
Descriptor 1:
bDescriptorType : 0x22 (Class=Report Descriptor=0x02)
wDescriptorLength : 0x0023 (35 bytes)
----------------- Endpoint Descriptor -----------------
bLength : 0x07 (7 bytes)
bDescriptorType : 0x05 (Endpoint Descriptor)
bEndpointAddress : 0x81 (Direction=IN EndpointID=1)
bmAttributes : 0x03 (TransferType=Interrupt)
wMaxPacketSize : 0x400 (1 transactions per microframe, max 1024 bytes)
bInterval : 0x01 (1 ms)
----------------- Endpoint Descriptor -----------------
bLength : 0x07 (7 bytes)
bDescriptorType : 0x05 (Endpoint Descriptor)
bEndpointAddress : 0x01 (Direction=OUT EndpointID=1)
bmAttributes : 0x03 (TransferType=Interrupt)
wMaxPacketSize : 0x40 (1 transactions per microframe, max 64 bytes)
bInterval : 0x01 (1 ms)
--------------------------------------------------------------
Only no data arrives and I can't receive it with the example project. There the input report length of 1025 is displayed and if I want to read the data, no data arrive (Handle Error) and on the second try the tool hangs up. In my test project I already tried it with the OVERLAPPED flag and the timeout is always reached.
If we change the firmware to wMaxPacketSize : 0x40 (for endpoint 0x81 for tests), then everything works fine and the data comes through.
Now the question arises, why do the 1024 bytes arrive?
I have looked again with various USB sniffers and the data is sent over the USB (USBlyzer)