Description
As I have mentioned on the forum:
https://forum.arduino.cc/t/can-not-find-examples-for-usbhostserial/1182486/17
I am trying to hack up some code similar to the USBHostSerial code that works with other USB to Serial adapters other than those which are CDC ACM devices. Ones like FTDI, Prolific...
On the forum thread: I posted an example sketch which reproduces this, but just about any sketch that will print out the
wrong IDS. VID: 0103 PID: 0000
Where other code bases on some other Arduinos, plus Windows and Ubuntu return the IDs:
vid=403 pid=6001
Note: I just tried plugging it in to the GIGA board, with my Logic Analyzer hooked up to it, with my modified USB Analyzer and HLA, which helps reduce the data down...
The Packets that I received on the GIGA:
16.308830162 ; SETUP ; 0x0 ; 0x0 ; [GET_DESCRIPTOR - DEVICE #:0 I:0x0 L:0x8] ; 0x80 0x6 0x0 0x1 0x0 0x0 0x8 0x0
16.308907428 ; IN ; 0x0 ; 0x0 ; ; 0x12 0x1 0x0 0x2 0x0 0x0 0x0 0x8
16.308963208 ; SETUP ; 0x0 ; 0x0 ; SET_ADDRESS I:0x0 L:0x0] ; 0x0 0x5 0x1 0x0 0x0 0x0 0x0 0x0
16.317414284 ; SETUP ; 0x0 ; 0x1 ; [GET_DESCRIPTOR - DEVICE #:0 I:0x0 L:0x8] ; 0x80 0x6 0x0 0x1 0x0 0x0 0x8 0x0
16.317496376 ; IN ; 0x0 ; 0x1 ; ; 0x12 0x1 0x0 0x2 0x0 0x0 0x0 0x8
20.478046968 ; SETUP ; 0x0 ; 0x1 ; [GET_DESCRIPTOR - DEVICE #:0 I:0x0 L:0x12] ; 0x80 0x6 0x0 0x1 0x0 0x0 0x12 0x0
20.478125602 ; IN ; 0x0 ; 0x1 ; ; 0x12 0x1 0x0 0x2 0x0 0x0 0x0 0x8
20.478314948 ; IN ; 0x0 ; 0x1 ; ; 0x3 0x4 0x1 0x60 0x0 0x6 0x1 0x2
20.478336022 ; IN ; 0x0 ; 0x1 ; ; 0x3 0x1
20.502892408 ; SETUP ; 0x0 ; 0x1 ; [GET_DESCRIPTOR - CONFIG #:0 I:0x0 L:0x9] ; 0x80 0x6 0x0 0x2 0x0 0x0 0x9 0x0
20.503027744 ; IN ; 0x0 ; 0x1 ; ; 0x9 0x2 0x20 0x0 0x1 0x1 0x0 0xa0
20.50305689 ; IN ; 0x0 ; 0x1 ; ; 0x2d
20.510192198 ; SETUP ; 0x0 ; 0x1 ; [GET_DESCRIPTOR - CONFIG #:0 I:0x0 L:0x20] ; 0x80 0x6 0x0 0x2 0x0 0x0 0x20 0x0
20.510326864 ; IN ; 0x0 ; 0x1 ; ; 0x9 0x2 0x20 0x0 0x1 0x1 0x0 0xa0
20.510358858 ; IN ; 0x0 ; 0x1 ; ; 0x2d 0x9 0x4 0x0 0x0 0x2 0xff 0xff
20.510387752 ; IN ; 0x0 ; 0x1 ; ; 0xff 0x2 0x7 0x5 0x81 0x2 0x40 0x0
20.510416558 ; IN ; 0x0 ; 0x1 ; ; 0x0 0x7 0x5 0x2 0x2 0x40 0x0 0x0
I don't have time today, but it almost looks like the device is still only returning a max of something like 8 bytes at a time...
And You are probably indexing off the end of the data, and maybe not waiting for the additional data packets to be returned.
If I remember correctly on the Teensy USBHost code, we first asked for the device descriptor, for its first 8 bytes, and then update the control endpoint to the size specified in those first 8 bytes and then asked for the whole endpoint...