AnsweredAssumed Answered

STM32 USB FS Bulk In speed tuning

Question asked by kravitz.abner on Sep 10, 2014
Latest reply on Sep 11, 2014 by kravitz.abner
Using STM32Cube_FW_F4_V1.1.0 on STM32F401

I am trying to maximize data from host to stm on FS bulk endpoint.  Using a 64 byte Rx buffer, I can only get about 5 MBps, as the interrupt and setup for next Rx buffer and restart of Rx takes a large amount of time. 

If I used a much larger buffer, I can get 9 MBps, but I don't get an Rx complete interrupt unless the host sends a short packet.  I need to use the bigger buffer for speed, but I can't count on the host sending non-64 byte packets, and if the host sends less than an Rx buffer-full the app doesn't get an int.

Is there some way to stop the Rx in the middle and recover the existing data (and count) in the Rx operation as if if filled, and not drop any in-process data (nak of it is OK)?  Or is there some other solution?

Outcomes