Arduino Zero USBCore strange behaviour

Hello,

The history goes like:
I developed a port of U2F to arduino using RawHID library NicoHood/HID 2.5.0. (SAMD21 support)

I have the code working on an Arduino Leonardo tested with this page: Test u2f.

When taking the !exact same code! to my samd21 board: I am able to receive data from usb but when I submit the response to my first request I get no reply.

Healty response from the arduino leonardo:

0000   1b 00 60 ec ba 1b 80 fa ff ff 00 00 00 00 09 00  ..`.............
0010   01 01 00 19 00 84 01 40 00 00 00 ff ff ff ff 86  .......@........
0020   00 11 8d a6 59 86 4c 52 db 35 00 00 00 02 02 01  ....Y.LR.5......
0030   00 01 01 0a 00 0c d6 09 f2 1e 14 86 0a 86 00 00  ................
0040   b9 ff 76 f7 ff ff 0c 6b 07 07 86 62 0a 86 00 00  ..v....k...b....
0050   b9 ff 76 f7 00 0c d6 00 01 1e a8                 ..v........

...
chrome continues with second request ...

Arduino zero replay to first message:


0000   1b 00 f0 f8 eb 12 80 fa ff ff 00 00 00 00 09 00  ................
0010   01 01 00 20 00 84 01 3f 00 00 00 ff ff ff ff 86  ... ...?........
0020   00 11 34 5f d2 00 00 00 00 00 00 00 00 02 02 01  ..4_............
0030   00 01 01 ff ff ff ff b3 47 00 00 a1 47 00 00 a4  ........G...G...
0040   78 00 00 14 08 00 20 23 44 00 00 00 00 00 00 14  x..... #D.......
0050   08 00 20 01 00 00 00 41 44 00                    .. ....AD.






0000   1b 00 10 80 42 13 80 fa ff ff 00 00 00 00 09 00  ....B...........
0010   01 01 00 20 00 84 01 01 00 00 00 00              ... ........

The specification require the messages payload to be 64 bytes, as is the payload size in RawHID. However the Arduino sam core limits the payload to 63?!

Any idea why the host never answer/receives to my response, just on my samd21 board? On Leonardo the code works good so I'm sure I follow the specification.

Wireshark does not display the message as an proper answer?!

Thank you!

Edit: I added a zip with pcaps of the 2 communications. It looks like the samd21 doesn't have the 1.xx.0 out packet?!? I have very little understanding of how usb HID works.

pcap.zip (900 Bytes)