Skip to main content
risingEdge
Associate II
April 10, 2023
Question

what is the limitation for buffer size in SAI DMA?

  • April 10, 2023
  • 1 reply
  • 1107 views

I am working on the STM32F769 series microcontroller in my project. I am using SAI interface of the mcu. And of course I also use DMA of SAI interface . I adjusted the DMA(DMA2 Stream 1) as listed below in the application :

DMA Request Settings :

Mode Circular, and increment address is memory as "half word"

And, I strongly wonder what is this limitations of DMA circular buffer? So, how many bytes can I kept inside the circular buffer?

This topic has been closed for replies.

1 reply

waclawek.jan
Super User
April 10, 2023

You set up the number of *transfers* in given DMA Stream's NDTR register, which is 16-bits wide, so that's the buffer length limitation.

> So, how many bytes can I kept inside the circular buffer?

65535 * 1 or 2 or 4, depending on how do you set up PSIZE field in given stream's CR register.

Read the DMA chapter in RM.

JW