Serial bug on USB3?


Since I changed computer, the communications serie bugs in an eratic way after a random number of requests generally between 2000 and 150000.

Spending time trying to understand and solve the problem I never had before with the serial link, if it worked once it would work forever.
Soon enough I realized that all I had to do was to close and re-open the communication on the PC side to get around the problem but without ever finding the source of the problem.

I tested several versions of mbed-os, mbed (LPC1768, K64F), PC side communication interface (LabVIEW, TeraTerm) to isolate the problem as much as possible.

A small TeraTerm script realized to automate the requests and to observe only the stability of the communication allowed me to exclude LabVIEW from my suspects.

; sample macro of Tera Term

connect '/C=x'.
setbaud 230400

while result=1
  sendln 'm?;trig?;pos?;targ?'.

disconnect 0

The script works in conjunction with this test program: DebugUSB3
TeraTerm must be configured in LF for transmission and the script must be a .ttl file.

Stability was found after testing this duo on several PCs including my old one.
each time it was Windows 10 pro 64Bits but on those which did not have a problem there was USB2 contrary to the recent PCs with USB3.

So I come here to share the problem because it’s beyond my skills.
Do you have the same problem?
Is it USB3?
How can I fix it?

Thank you in advance for your help,


This bug is still present and without a solution, would anyone have one, or a lead?

Thank you,


I forgot to come back earlier, but just for information, I finally found the source of my serial communication interruptions.

It’s related to windows 10 which regularly scans the MSD (mass storage device) of the pc.

The solution I used is simply to disable the MSD of the Mbed.

Thank you,