Skip to main content
Aahai.1
Visitor II
December 7, 2021
Question

Use one DMA channel with 2 different IPs ?

  • December 7, 2021
  • 2 replies
  • 995 views

Hello.

The project I am actually working on uses several peripherals such as USART ADC SPI etc.

I am trying to use as much DMA as I can, but there is something that I miss in the reference manual and on the internet.

Can I use ONE channel with TWO streams of TWO independant IPs ?

Can I use ONE channel with TWO streams of ONE IP ?

For instance with a STM32F427:

UART4 uses dma1 stream2 with channel4 and dma1 stream4 with channel 4

and

USART2 uses dma1 stream6 with channel4 and dma1 stream0 with channel 4

In this example :

Could I use the two streams for UART4 or only one stream at a time ?

Could I use every streams that I quoted for UART4 and USART2 (D1S2C4, D1S4C4, D1S6C4 and D1S0C4) at the same time ?

Thank you,

Have a nice day.

This topic has been closed for replies.

2 replies

TDK
December 7, 2021

There is no restriction on using the same channel on multiple independent streams.

You can't use multiple channels within a single stream, and you can't have the same request mapped to multiple streams.

"If you feel a post has answered your question, please click ""Accept as Solution""."
waclawek.jan
Super User
December 7, 2021

"Stream" in the DMA in 'F4 is one element of the DMA which performs the transfer.

"Channel" is only the setting of a stream's request multiplexer.

Read the DMA chapter in RM0090.

JW