cancel
Showing results for 
Search instead for 
Did you mean: 

Is it possible to use MDMA with DCMI instead of the normal DMA?

MSale.1
Senior

My design consisits of STM32H743 runs at 480 MHZ with live video from camera at (960*540) RGB565. DCMI pixel clock is 78 MHZ. frame rate is 29 FPS. external memory runs at 132 MHZ. Data flow is DCMI->DMA->SDRAM->DMA2D->SDRAM->LTDC->SDRAM. I am also using TouchGFX for GUI but only on small window and its frame buffer in in the internal memory. 2 layers of the display are used. the system work fine but i always have DMA FIFO error. i am synchronizing every thing except the part of the display because touchgfx take control of the display. the only solution to get rid of the DMA FIFO error is by reducing the camera pixel clock wich affect the frame rate ofcourse. when i disable the display access to the external memory the DMA FIFO error dissapear. I dont know if the DMA is not fast enough to transfer the data while the LTDC also access the memory or its because the memory bandwidth and the concurrent access to it.

3 REPLIES 3
MSale.1
Senior

Problem is solved

Martin KJELDSEN
Chief III

Glad you solved it. Sounds like it was probably some memory contention issue. Potentially you could have LTDC, DMA2D, DMA accessing the SDRAM all at once. TouchGFX offers a "lockDMAToFrontPorch()" function to at least dis-allow DMA2D to access SDRAM while LTDC is doing so.

MSale.1
Senior

@Martin KJELDSEN​ 

You are right i had to synchronize all access to the SDRAM.

Do you think if camera output is configured as YUV it will be possible to encode the frames with hardware jpeg encoder as motion jpeg then to sd card?

and do you know how to create AVI header for jpeg or what kind of header should i use?

Thanks in advance!