2025-05-09 7:51 AM
To test a USB implementation, I have implemented a USB loopback on a Nucleo-144 Development Board (MB1404C). Testing is showing a strange result that I have been unable to isolate:
The code is very basic: it creates a thread for USB data handling. In that thread, ux_device_class_cdc_acm_read is used to block until data is received from USB. When it is received, it is send back out USB using ux_device_class_cdc_acm_write.
This works great if I send up to 6 bytes of data. As soon as I send 7 or more bytes, the transmitted data is junk (though it is repeatable).
Things I have tried and seemingly ruled out:
Any ideas?