cancel
Showing results for 
Search instead for 
Did you mean: 

STM32G484 - DMA TIM5->CNT to MEM using TIM2_UP request not working

klopcic
Associate II

DMA transfer is not working, despite everyhing being setup correctly at first glance. Does anyone know what else could be wrong?

DMA1->CCR5: is enabled (EN), MSIZE is 32bit, PSIZE is 32bit, mem. inc enabled, per. inc disabled, circ mode enabled, DIRection is per -> mem,

DMA1->CNDTR5: 1 (transfer one unit)

DMA1->CPAR5: set to the TIM5->CNT address

DMA1->CMAR5: set to uint32_t variable in ram

DMAMUX->C4CR: DMAREQ_ID is 60 (TIM2_UP as per RM, table 91),

DMA1->CCR5

0693W00000WJtByQAL.png 

DMA1->CNDTR5

0693W00000WJtCSQA1.pngDMA1->CPAR5

0693W00000WJtCXQA1.pngDMA1->CMAR5

0693W00000WJtCcQAL.pngDMAMUX->C4CR0693W00000WJtCmQAL.png 

TIM20693W00000WJtDQQA1.png

1 ACCEPTED SOLUTION

Accepted Solutions
klopcic
Associate II

It was an oversight on my part - forgot to enable DMA requests. Now everything is functioning properly.

__HAL_TIM_ENABLE_DMA(&htim2, TIM_DMA_UPDATE or TIM_DMA_CC3);

View solution in original post

1 REPLY 1
klopcic
Associate II

It was an oversight on my part - forgot to enable DMA requests. Now everything is functioning properly.

__HAL_TIM_ENABLE_DMA(&htim2, TIM_DMA_UPDATE or TIM_DMA_CC3);