Question
STM32 Memory-to-Memory DMA transfer to 16-bit SRAM
Posted on November 03, 2014 at 10:17
I have an STM32F429 connected via FMC to a 16-bit wide SRAM. I can read and write to the SRAM correctly using simple memory writes.
DMA works correctly too when I configure it with two streams; one to send internal memory words to the half-word memory, and a second stream to read half-words to back to the internal memory.Even though it works, I'm confused about whether I'm configuring my DMA correctly, and a couple of answers would help greatly:- Do I need to specify in the DMA that the memory transfers are from word to half-word, and vice versa? Or does the FMC automatically handle the data-width translation? i.e. can I use DMA with word-transfers even though the SRAM is 16-bit?
- Is there any advantage to using FIFO mode with memory-to-memory transfers?
- Memory-to-Memory transfers do not allow Direct Mode to be used. I can see the FIFO being enabled by hardware (DMDIS = 1). But I'm not configuring BURST sizes and it seems to work fine. Is all this performed by hardware?
