2018-12-25 08:46 AM
Hello , is there any way to ready multiple adc channels for adc1 in to multiple buffer with dma parallely ?
In existing configuration i can read circular and continuous 2 adc channel of adc1 in to a single buffer with dma. So buffer's first element is channel1 , second is channel2, third is channel1 again and so on..
but my desire is there would be 2 independent buffers which holding 2 channels data.
i can seperate even or odd indexes after reading but i dont want to do that way. is there any automatic way to swap buffer for each channel ? if there is no , is there any way to memory to memory dma operation which is reading memory with increment 2 each time.
2018-12-25 11:26 AM
Doesn't work that way, fill a larger buffer, and de-interleave periodically.
Alternative is to use two ADC units, each with a DMA assigned, and use a common trigger source.
2018-12-26 09:02 AM
Maybe using another DMA for memory to memory transfer. However, regrouping each channel as contiguous memory area would require bus cycles for possibly no processing value.
create a structure describing the interleaved channel element (2x16 bit) then create the array which you can scan for processing (FFT or else). Otherwise, make it for dual channel a 32 bit element array and mask.