cancel
Showing results for 
Search instead for 
Did you mean: 

STM32F429 DCMI -> DMA -> SDRAM

rokko
Associate II
Posted on February 03, 2016 at 17:46

Im trying to get image via DCMI, everything works fine, except DCMI frame received interrupt. When im receiving 320x240 rgb565 image, HAL_DCMI_FrameEventCallback is never triggering, so I redefined dma callback with my own function:

HAL_DCMI_Start_DMA(&hdcmi, DCMI_MODE_SNAPSHOT, SDRAM_BANK_ADDR, (uint32_t)(IMG_ROWS*IMG_COLUMNS*2/4));

hdcmi.DMA_Handle->XferCpltCallback = DMA_TransferComplete;

But it works only for 320x240 (because it less than DMA buffer size 0xFFFF).

When Im sending 640x480 image, DMA XferCpltCallback is triggered after the part of the data transfered, not the whole, but HAL_DCMI_FrameEventCallback works as it must. How can I trigger HAL_DCMI_FrameEventCallback with 320x240 image?

#discovery #lcd #dcmi #stm32f429
2 REPLIES 2
rokko
Associate II
Posted on February 03, 2016 at 18:21

Found problem in camera config, works now.

Nesrine M_O
Lead II
Posted on February 03, 2016 at 18:24

Hi soroka.andrey,

Thank you for posting your findings and how you fixed the issue, it is good to hear that it was solved. 

-Syrine-