cancel
Showing results for 
Search instead for 
Did you mean: 

Enabling USB FS device Internal IP DMA make device not recognized by windows

HAlzo
Senior

Hello,

When I try to Enable Ineternal DMA Option , Winodws gives "USB Device not recognized message"

I am using Winodws 10 and every thing works fine if I disable this option

0693W000008xLFgQAM.pngHow I can use this option?

and could it offload the controller?

Best Regards

Hossam Alzomor

6 REPLIES 6
Lubos KOUDELKA
ST Employee

Hello,

as you tagged also STM32H7 I expect your problem will be used RAM memory. By default DTCM RAM memory is used (0x20000000) in examples generated by CubeMX and this memory is not accessible by DMA. So you need to change in linker to use different RAM region. I'm attaching linker file example for STM32CubeIDE (and STMH743).

With that I had no issue with internal USB DMA enabled. General condition is, that memory accessed by DMA need to be aligned.

Best regards,

Lubos

HAlzo
Senior

Thanks Lubos,

I have 2 Questions

1-After enabling this option, I didn't notice that it improves the speed of USB or offloads the processor, what is the effect of this option?

2-is there any difference in performance/speed between DTCM RAM and RAM1?

best regards

Hossam Alzomor

HAlzo
Senior

One more question,

Should I move stack to RAM_D1 as well?

my applications couldn't run without moving stack to RAM_D1 !!!

Lubos KOUDELKA
ST Employee

Hello Hossam,

if your MCU core is not loaded enough or USB has high priority, you won't observe any speed up as core is capable to handle with same speed. DMA is handling data transfers to and from USB FIFO, but still you will get interrupts, which need to be handled by core. TCM bus has direct access to DTCM RAM, so there is no wait state. Please check reference manual for more details about STM32H7 architecture

Are you referring to MCU stack or USB stack. But be careful, that MCU stack get space location in linker file, but it's value is then defined in startup file

HAlzo
Senior

I mean MCU stack

Ons KOOLI
Senior III

Hi Hossam,

For more info, you maybe can refer to this FAQ.

Best Regards,

Ons.