Question
USB, DMA, CDC and Speed ... Is it possible?
Posted on June 25, 2012 at 23:05
Hi all,
I have a fair bit of experience with the STM32 now and have got most peripherals working as I want on multiple projects but I am yet to master the USB. I would like to transfer data collected by a series of sensors over USB to a host PC. The key details are:- Data load is not flat but event driven Peak data load is around 160Mbit/s Average data load is 60Mbit/s So far I have managed 20Mbits/s using a modified version of the CDC example for the STM32F2x7 series (increased buffer sizes, changed output fifo to handled wrap around etc). However 20Mbit/s seems to be my limit. Looking at the packets it looks as if the device is wasting time starting and ending transactions rather than sending continous packets during peak flow. I am not too sure why this is as data is alwasy in the output buffer. Does anyone have any experience with such a project or recomendations of how I should proceed? Has anyone ported the example to work with the DMA and got better results? Discussions welcome, I would just like to learn more on this. Many Thanks, Gareth #stm32