2015-07-30 11:55 PM
Hi Everyone,
Does STM32 DMA controller provide options to perform following copy procedureSay the data in the source memory as follows. (x, y are 16 bit each)Source Memory:x1 ,y1,x2,y2.,.,xn ,ynI want to copy to destination memory just (alternate source data)Destination Memory:x1,x2,.,.,xnThanks #adc_dual #adc #dma2015-07-31 09:33 AM
Which STM32 specifically? They make like hundreds of variants, from dozens of families.
I think it should be able to take a 32-bit value (2x 16-bit pair) and copy out only one 16-bit value, repeating over the count. Can't say I've tried it, but it should take you more than 10 minutes of so to prove to yourself one way or the other.2015-08-11 06:35 PM
Thanks clive,
I am using STM32F4xTried configuring different word size for source and destination. It is not copying data to destination in an interleaved fashion as expected.Basically I am trying to use DMA to transfer data from two ADCs (adc1 & adc2) in dual mode (synchronized).In dual mode if I am not wrong adc samples are stored in interleaved fashion. Can it be redirected to two different buffers, so that reshuffling can be avoided?BRhgs2015-08-11 09:26 PM
Ideally you'd just process the data in place.
You could alternatively use two ADC, with two DMA, independently, but triggered via the same timer, at the same instant. This would be less of a circus than trying to reorganize the array with an independent DMA operation.