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: Multiple questions regarding DMA transfer

Part Number: MSPM0G3507

Dear Supportteam,

I'm actually trying to use the DMA not just in Transfer Mode single. As my transfer size, source address and destination address is always the same, I thought using Repaet single would be the right mode. 

Using the DMA channel 0, means full-feature channel. But when trying to use in this mode, Iget several suspicous behaviour. 

First Problem when setting enable, transfer never stops. Or address is never set to original value. 

I try to use the DMA in combination with SPI. When working in pure single mode everything works fine. 

Is their a special sequence needed of setting config bits in CTL Register, or is the problem caused by the trigger?

I set first Transfer size and transfer mode. Afterwards when setting enable, or enable in combination with trigger, transfer will never stop. 

not what I expected to be honest.

Now second question, do I understand the documentation correctly, that an running DMA transfer could not be interrupted by an other DMA?

I think here especially on an running DMA via SPI, and starting a second DMA transfer for some ADC channels. 

What will happen with DMA transfer by using the four byte depth FIFO of the SPI Interface, will this mean the transmit is immediate ended and and receicve dma successfull when four bytes received?
The fifo size is limited to a depth of four. 

My aim is using six channels of ADC with nearly 100kHz sampling rate and transfering 800 times pers second 9 Bytes via SPI from an external sensor.

Three DMA's running but pauses when transfering the SPI data at 8MHz, kills my wished sampling rate for the adc, first by preparing transfer, and secondly by the running transfer.

Thanks for any suggestion or other helpful response.

  • Hi,

    As my transfer size, source address and destination address is always the same, I thought using Repaet single would be the right mode. 

    TRM has told you:

    This is the same for all transfer mode.

    First Problem when setting enable, transfer never stops.

    When enable, it never stops. It should set single mode to automatically stop when the size of datat for setting has been transferred.

    Now second question, do I understand the documentation correctly, that an running DMA transfer could not be interrupted by an other DMA?

    Nope, DMA transfer will start tansfer when the trigger comming.

    I think you should prepare all the data from ADC result [9 Bytes]

    Then, start DMA transfer by enable DMA Channel [Before enable channel, user should set DMA trigger is SPI TX FIFO empty, tansfer size is 9, use single transfer mode]

    B.R.

    Sal

  • Main error was SPI TX FIFO >= 1 entries, when setting to empty as suggested by you, I get expected behaviour.