Arduino DUE and ADC configuration

Hello guys,

as my post name states I have received my Arduino DUE, which I wanted to use for reading my analog signals out of ultrasonic microphone (ultrasonic mic with amplifier plugged into analog pin). I use DUE, because it is way more powerful and, I believe, more suitable for capturing ultrasonic frequencies.

I have done a lot of tests and readings for lower freq. sounds using Arduino UNO, Arduino MEGA, and basic principles of ADC reading are the same for these microcontrollers (registers, functions etc), so you could basically upload the same program (in most cases) and it would run fine. However, when it comes to DUE everything is different...

My task is to read analog signals from each analog pin (I plan to use up to 3-5 mics) at ~80-90Khz in order to capture 40Khz ultrasonic frequencies.

Could you recommend some sort of article, reading or whatever else, where I could find code samples that would help me to configure Arduino DUE ADC at these specific frequencies, configure its ADC ISR and so on (like in UNO or MEGA we usually do with free running mode, auto trigger mode etc. [I KNOW THAT DUE MIGHT NOT HAVE THE SAME MODES, BUT I JUST SAID THAT TO MAKE THINGS CLEARER :)).

Maybe there is some sort of library for this?

Thanks a lot guys for any kind of help or recommendation how to achieve this.

Try this:

Here is an example sampling ADC over DMA (PDC):

Hi, Magician.

Thanks a lot for your links. Really helpful and appreciate that.