AnsweredAssumed Answered

Put one Buffer to SRAM1 and One Buffer to SRAM2

Question asked by marjani.razi on Oct 26, 2015
Latest reply on Oct 27, 2015 by Clive One
Hi
The aim of my project is recording stereo audio and send audio data by uart in real time.
My device is STM32F405.
I am using SPI2 as I2S Interface in Master Half Duplex in Receiving Mode.
Sample rate = 8k and Data Width = 16. Channel = 2
So rate of input data is 32 KBps.
I have configured usart1 with 921600 baudrate, So I can about 90 KBps using usart1.
I am using DMA1 for I2s, and DMA2 for usart.
I have two buffer with same size. When I2S DMA is filling one Buffer, USART dma is transmiting another Buffer.
Audio Input is from an audio generator that generate sinoside wave. 
after I plot the data that I receive from uart I find that some sample is missed.
the problem is that two dma are working with same SRAM.
So when uart dma try to read memory, another memory hasn't access to it.
STM32F405 has two SRAM.
How can I put one buffer two SRAM1 and other buffer two SRAM2,
I think this approach can solve my problem,because two dma can work concurrently
thanks

Outcomes