cancel
Showing results for 
Search instead for 
Did you mean: 

Are there in-depth ways to investigate why HAL_DCMI_Start_DMA() is not putting data into the"*pdata" pixel buffer?

KM.8
Associate III

I am getting pixel data to the stm32. I am reaching the "end of frame flag clearing" at:

stm32l4xx_hal_dcmi.c ----> HAL_DCMI_IRQHandler() ----> (line 811)__HAL_DCMI_CLEAR_FLAG(hdcmi, DCMI_FLAG_FRAMERI);

I am simply checking cameraBuffer[] pixel array using SNAPSHOT and CONTINUOUS modes without success.

I am working on a DCMI camera interface between the NUCLEO-L496ZG board and a MT9V024 10-bit monochrome camera sensor used in 8-bit configuration. I have successfully been able to set the MT9V024 sensor to "capture mode" to retrieve a single pulse and give me 8 bits of data (using MT9V024 D2 through D10 and skipping two LSB pins B0 and B1). This will omit the two LSB data, but keep the upper eight bits. The MT9V024 is using 752x480 8-bit parallel frames, which use the HAL_DCMI_ConfigCROP() function in order to reduce the size of the image to 376x240. I set HAL_DCMI_Start_DMA(WIDTH*HEIGHT/4) since there are 32-bit words for DMA and 8-bits per pixel, so 4 pixels per word. I included the schematics and the images of the Digilent logic analyzer for the debugging process. Please let me know if more information is required. I am using the onboard 27MHz clock on the MT9V024 development board. I was not able to get a fully functioning project using an OV7670 RBG565 camera sensor, but I was able to at least get 16-bit pixel data as values in cameraBuffer[] using the same code structure I am using presently. If anyone is able to help, it will be greatly appreciated.

MT9V024 development board (schematic attached with overview with diagrams in next link): 

https://www.onsemi.com/PowerSolutions/evalBoard.do?id=MT9V024IA7XTMD-GEVK

MT9V024 datasheet: 

https://www.onsemi.com/PowerSolutions/product.do?id=MT9V024

stm32CubeMX project generation and code is included as a .zip file.

11 REPLIES 11

Thanks for coming back with the solution.

> I am not sure how to close this thread.

Mark your post as "Best".

JW

KM.8
Associate III

thank you!