AnsweredAssumed Answered

STM32F407 Memory to Peripheral (GPIO) Transfer with ext. DMA Trigger

Question asked by Zaher on Jan 10, 2018
Latest reply on Jan 11, 2018 by Zaher

Hello everyone!


I had to postpone this for some time as I had reached a deadlock with the previous legacy ASIC I picked up for a project, and after spending some time researching my other options, I dropped that ASIC for a much better, relatively newer (not in today's terms) ASIC. 


Instead of a native DMA interface, my new device provides dual bus access to the chip. PAD[7:0] for access to internal registers, and DB[7:0] for DMA data-transfer transactions. I have interfaced the device with the FSMC peripheral of the STM32F407 and I can now read/write registers perfectly. 


So far, I have found a lot of interesting resources that I can build upon. AN4666 seems to be the solution to my problem on how to simulate a DREQ/DACK handshake. The solution provided by Mr. Clive on the following thread is a great starting point, too, to learn a lot from:


DMA MemoryToMemory using Timer for delivery rate? 


Because I'm building my firmware based on the Cube/HAL libs, I believe this one has the best solution for my situation:


STM32F103 How do I DMA Transfer Memory to GPIO with external Clock 


However, I noticed that the GPIO has been configured as output for transfer from Memory (Buffer)  to GPIO. What if I want to receive data back from GPIO to the memory buffer, also utilizing the DMA and external trigger? By then, I will have to re-configure the GPIO before initiating the transfer transaction?