cancel
Showing results for 
Search instead for 
Did you mean: 

How to capture image from OV7670 (No FIFO version) in snapshot mode after user define exposure time using HAL_DCMI_Start_DMA in snapshot mode to external SRAM?

EMari.1104
Associate

Dear Friends,

I would like to appreciate the effort of STM for providing user friendly software tools and documents support to customers.

I am entry level to STM32 MCU, Now I would like to bring my problem statement:

I am doing design with STM32H743 device, here my task is to capture camera raw pixel data to external SRAM for image processing.

I need to capture a single frame from camera after predefined user exposure time and it will be used for computation. Here we should have full control of exposure time and capturing exposed frame without missing even a single pixel data.

I purchased cost effective Nucleo-743ZI development board and configured all interface requirements of camera using STMcubeMX in CubeIDE tool. I have installed HAL library packages for STM32H7 (V1.4) and used those HAL library files.

The following problems are faced:

1. To configure camera registers, I used I2C1 peripheral using HAL_I2C_Master_Transmit function. It was transmitting only device address and returns HAL_Error. The camera does not return ACK bit, it is dont care/NACK as per camera datasheet. In such devices, how to transmit all I2C data to camera registers?

2. I used HAL_DCMI_Start_DMA function to capture the image in snapshot mode. Synchronization signals VSYNC and HSYNC are configured as per camera requirements and it responds to dark and light conditions. The HAL_DCMI_Start_DMA function captures the image only in valid VSYNC signal.

Here my doubts are:

  1. I should not miss the exposed frame and whether my exposed frame can be captured by HAL_DCMI_Start_DMA function during sequential execution of software lines between two software functions, completion of exposure time and HAL_DCMI_Start_DMA ? or
  2. Shall I run the HAL_DCMI_Start_DMA function before completion of exposure time to capture that frame? (to get VSYNC signal valid)

At present I am using internal SRAM, how to configure the DCMI DMA to external SRAM using FMC and how to resolve I2C issues for this camera module?

I am looking for support from this forum to go ahead with my design and implementation.

Thanks in advance.

0 REPLIES 0