Larger USB transfer window caused more retransmissions without any speed gain
A developer's ESP32 display pulls half-gigabyte image files from a Mac over USB in packets, and a bigger in-flight window triggered repeated checksum-failed retransmissions. Tests on the board showed a window of 8 produced 23 rewinds, 22 of them CRC failures, while a window of 4 ran clean, yet both achieved about the same throughput of 0.365 MB/s. The default was reverted to 4 as the quick fix. Investigation traced the cause to the firmware's 4 KB USB receive ring buffer, which overflows when the task that receives data stalls during periodic 16 KB SD card writes. The vendor driver silently discards packets whose insertion fails, so the buffer overflow goes unnoticed.
This is an AI-generated summary. ShortSingh links to the original source for the complete article.
Discussion (0)
Log in to join the discussion and vote.
Log in