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.

MSP430F2619S-HT: Feature request : Auto reload of DMA source pointer (if enabled)

Part Number: MSP430F2619S-HT

This is more of a feature request than a question. My apologies if this is not the correct location for such a request.

Here is what I would like to do.

We have applications that use LVDTs/RVDTs. To excite the primary of the sensor, we would load a sinusoidal table into Flash or RAM, then send the table contents to the onboard DAC using a timer to trigger the DMA to send the values. Beyond initial setup, this requires no CPU intervention. However, when we get to the end of the table (DMA counter = 0), then an interrupt will fire, and the CPU will have to reload the DMA source pointer to the beginning of the table. If there is another higher priority task going on, the interrupt may be blocked, and the pointer may not be reset in time for the next value to be transferred (causing a glitch in the output waveform).

It would be a nice feature if the DMA controller could reload the DMA source pointer automatically when the DMA counter reached 0. This way, values could be written from the circular buffer continuously under DMA control without any further CPU intervention.

This seems like something that would be easy to implement, and would be a great help for waveform generation applications.

Thanks.

  • It sounds like you're using DMADT=0 (Single). If so, DMADT=4 (Repeat-single) should provide what you want. After re-loading the pointers it will re-start at the next trigger, so any end-of-cycle intervention will have to be quick. (If you're using DMADT=1 (Block) you'll want DMADT=5 (Repeat-block).)

  • Hi Bruce. Thanks for the reply. Yes, Repeat-single is what I would be using (that is a single transfer on every trigger event). The source pointer will increment through the circular buffer, and the destination pointer would remain fixed at the DAC data register.

    It's what happens when we reach the end (DMA counter = 0) that I'm I would like to improve. If the DMA source pointer could get automatically reloaded to it's starting position when the DMA counter reached 0, then no CPU intervention would be needed (other than initialization). Once setup, it would just run.

    I don't want to transfer the entire block with one trigger event. Instead, I want to transfer one value each trigger event. Then repeat once all values have the transferred out of the circular buffer.

    Thanks again.

  • With DMADT=4, when SZ=0, SZ, DA and SA are re-loaded and it continues at the next trigger. [Ref User Guide (SLAU144J) Fig 6-3.] No CPU intervention is required, though you can get an interrupt if you want it.

    Maybe I'm not understanding what you want it to do.

  • Ahhhhh. Now I see.

    Sorry, it was right in front of me the whole time !

    Thanks Bruce !

**Attention** This is a public forum