cancel
Showing results for 
Search instead for 
Did you mean: 

Is there a maximum buffer size For ADC DMA Length is stated as Uint32

Puzamoya
Associate II

Hi

I am doing an ADC DMA sample using HAL_ADC_Start_DMA. Using ADC1

Setup in multimode with 2 channels Rank1 and Rank2. Using STM32H750

I have a buffer Uint16 buffer [131072] setup in RAM_D2

When i set the length in the HAL_ADC_Start_DMA

HAL_ADC_Start_DMA(&hadc1, (uint32_t *)&buffer, 32768 ) This works

HAL_ADC_Start_DMA(&hadc1, (uint32_t *)&buffer, 65536 ) THis does not work it never comes back to get called by the DMA complete. However if I read the status of the DMA is says busy and the DMA counter counts down to 0.

Thanks

Robin

1 ACCEPTED SOLUTION

Accepted Solutions
TDK
Guru

Max value of NDTR is 65535, so that's the limit of the number of transfers you can do per DMA call.

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

View solution in original post

1 REPLY 1
TDK
Guru

Max value of NDTR is 65535, so that's the limit of the number of transfers you can do per DMA call.

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