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.

Multiple GPIO interrupt whilst DMA is active?

We are using a GPIO interrupt to count a number of pulses into a given input on our device, if DMA is active whilst we receive one pulse I understand the interrupt will queue up ready for when DMA has finished and all is well.

What happens if we get multiple pulses on the input whilst DMA is active? Will the ISR only be queued once for the duration of the DMA, effectively missing the pulses?

Our DMA is set up in repeated single transfer byte mode.

  • I think multiple IRQs from different pins will still be queued. But multiple IRQs from the same pin will have only one remain in the queue. because there is only one IFG bit per pin.

    The same thing may happen with or without DMA. Repeated DMA, prolonged ISR, as well as no GIE can all increase the probability of this problem.
  • I figured as much but couldn't work out from the datasheets whether this was the case or not.

    I fixed the issue, thankfully not due to DMA utilisation but because we had turned off a particular interrupt on the wrong variant of our hardware, whoops :)

**Attention** This is a public forum