Skip to main content
G_A.
Associate III
August 27, 2021
Question

Is it possible to check whether Dma interrupt or only global interrupt is enabled in Cubemx

  • August 27, 2021
  • 1 reply
  • 897 views

Is there any register or flag to check whether Dma interrupt or only global interrupt is enabled in Cubemx?

ı am writing an uart driver and ı would like for driver to be arranged automatically according to selections in cubemx.For example, if uart5 dma is selected, this driver uses dma_start function or if global interrupt is selected for uart7, the driver uses hal receive uart it function.

I searched datasheet and hal library. But can not find any register or flag inside code to be able to check which way the uart used, dma or interrupt.

This topic has been closed for replies.

1 reply

TDK
Super User
August 27, 2021

You can check for valid hdmatx/hdmarx pointers. Although if you don't use DMA, they are uninitialized. Typically this means they will be null pointers unless reprogrammed without removing power.

"If you feel a post has answered your question, please click ""Accept as Solution""."