I have trouble setting ADC and Double buffer DMA. I want to sample 9 ADC pins from PORTA1 to PORTA7 and PORTB0 & PORTB1.
I have set timer0 rollover every 44us, and trigger event0 which trigger ADC. It works as should. The samples are spreaded evenly each every 44us apart. So I get individual channel sample every 396us.
But I want to get all 9 samples as close as possible. ADC is capable 2MHz sampling so I wish to get all 9 samples in 4.5us burst and then wait 391us to the next burst as I want as small phase difference between all 9 samples.
So I want to accomplish to set timer to overflow every 396us which trigger event0 and then ADC does sampling on all 9 selected channels.
The catch can be in EVCTRL register (SWEEP) but I can't get it working, or I missunderstant all the thing.
Is it that possible at all?
Device used is XMEGA 128 A3U