Skip to main content
LWei.1
Associate
October 4, 2020
Solved

UART DMA Rx, IDLE interrupt is triggered, but doesn't look correctly.

  • October 4, 2020
  • 3 replies
  • 1009 views

Hi,

I am trying to use DMA to realize uncertain length uart message receiving on STM32H745i-DISCO board (on core CM7). My idea is to used IDLE interrupt and then disable the DMA_stream, get the NDTR register and abort the transfer to trigger the DMA TC interrrupt to get the data. I send a string at once, but looks like everytime the IDLE interrupt triggered after receive the first byte. And the the UART_DMAReceiveCplt() function never get chance to be called. Can anyone help me with that?

Thanks!

This topic has been closed for replies.
Best answer by LWei.1

I moved the code from CM7 to CM4, it works. I think it shall be related to DMA_MEM accessibility issue for M7 core. I will try to figure out it by myself.

Also, Tilen Majerle's github repo also used IDLE interrupt instead of RTO interrupt.

3 replies

LWei.1
LWei.1Author
Associate
October 6, 2020

Can anyone give me some hint what is wrong with my implementation? Thanks!

Pavel A.
October 6, 2020

IMHO for this better to use RTO interrupt (RX timeout) rather than IDLE.

Example can be found in Tilen Majerle's github repo.

-- pa

LWei.1
LWei.1AuthorBest answer
Associate
October 9, 2020

I moved the code from CM7 to CM4, it works. I think it shall be related to DMA_MEM accessibility issue for M7 core. I will try to figure out it by myself.

Also, Tilen Majerle's github repo also used IDLE interrupt instead of RTO interrupt.