cancel
Showing results for 
Search instead for 
Did you mean: 

STM32H7B0 DMA locked after first start

OGhis
Senior

Hi,

I use a STM32H7B0 100 pins and we would use a DMA to transfer data from 1 memory location to another.
Therefore we use DMA1 stream 3 with a datasize of "Half word".
What is very strange is that we cannot disable the option "Use Fifo" in stm32Cube.

Now when we start the DMA with:

 

 

HAL_DMA_Start_IT(&hdma_memtomem_dma1_stream3,
                 (uint32_t)&srcBuffer,
                 (uint32_t)&DestBuffer,
                 1000);

 

The transfert is done and we seen the data in de destination buffer, but when we restart the
DMA again there isn't no transfert more to the destination buffer.

When we look in the registers of the DMA, we seen that the DMA was locked / HAL_DMA_STATE_BUSY and no error status
The HAL_DMA_Start_IT() was called from the HAL_ADC_ConvCpltCallback() (~ every 1 ms)


We had also tried to start the DMA only when he was unlocked, but with the same issue

 

if (hdma_memtomem_dma1_stream3.Lock == HAL_UNLOCKED) {
  HAL_DMA_Start_IT(&hdma_memtomem_dma1_stream3,
                   (uint32_t)&srcBuffer,
                   (uint32_t)&DestBuffer,
                   1000);​
}

 


Why stops the DMA after the first transfer?

btw: The CPU iCache / CPU Dcache and MPU control mode are disable.

1 ACCEPTED SOLUTION

Accepted Solutions
OGhis
Senior

Hi,

Issue resolved.
forgot to enable the Interrupt of the DMA

OGhis_0-1723986180662.png

 

View solution in original post

2 REPLIES 2
OGhis
Senior

Hi,

Issue resolved.
forgot to enable the Interrupt of the DMA

OGhis_0-1723986180662.png

 

Nice to see you fixed it !