This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

MSPM0G3507: Fast Parallel data acquisition with GPIOs on MSPM0G-devices

Part Number: MSPM0G3507

Tool/software:

Hi experts,

i'm looking for a solution to read in parallel data (e.g. 12- to 16-bit from SAR ADC) over the GPIO pins as fast as possible, the M0G M0+ core will run @ 80 MHz (derived from 20MHz Clock signal input).

Two questions:

  1. Is there an option to use DMA with GPIO pins (data input) to SRAM Memory? - reading the TRM it seems only DMA to DOUT is supported
  2. Can you, please, provide a simple code example to read parallel data as fast as possible?

- 16-bits parallel data (GPIOs) read in and store into SRAM buffer (max 2KB total or 1KB x 2 Bytes)

- read in execution loop (the fastest possible)?

- what would be the max. data rate (in MHz or MCU cycles) for data acquisition in such manner? - teh GPIOs can switch 

Thanks and regards,

Milen

  • Hi Milen,

    From your description, you are using 12-16 GPIO pins of MSPM0 for an external ADC output, right?

    1. As you said, our DMA could not transfer data from GPIO input register to SRAM memory.

    2. I think there are two ways to get GPIO data without DMA:

    - Polling in main loop: This is the most fast way. But the drawback is the "sampling" time is not in a const period. It is not controllable of the time gap of two times of reading. And it may impacted by other interrupt task.

    - Sampling by timer interrupt: This way could keep a const sampling period. But will introduce extra time for interrupt responding.

    The max data rate I think may be around MHz level for 80MHz frequency if no other task executed.