Skip to main content
Associate II
Jul 23, 2024 11:00 UTC
Question

STM32MP135F-DK OV5650

Hello

 

I have stm32mp135f-dk board and OV6540 camera how can I connect them

This topic has been closed for replies.

9 replies

Erwan SZYMANSKI
ST Technical Moderator
Jul 31, 2024 21:04 UTC

Hello @kagan_senkeser,
You need to change the device tree of stm32mp135f-dk board in the Linux kernel : https://github.com/STMicroelectronics/linux/blob/4c4175804a542f40c50d091cc694bb0b186728a0/arch/arm/boot/dts/stm32mp135f-dk.dts#L4

Please modify the i2c5 node :

 

gc2145: gc2145@3c {
		compatible = "galaxycore,gc2145";
		reg = <0x3c>;
		clocks = <&clk_ext_camera>;
		IOVDD-supply = <&scmi_v3v3_sw>;
		AVDD-supply = <&scmi_v3v3_sw>;
		DVDD-supply = <&scmi_v3v3_sw>;
		powerdown-gpios = <&mcp23017 3 (GPIO_ACTIVE_LOW | GPIO_PUSH_PULL)>;
		reset-gpios = <&mcp23017 4 (GPIO_ACTIVE_LOW | GPIO_PUSH_PULL)>;
		status = "disabled";

		port {
			gc2145_ep: endpoint {
				/*remote-endpoint = <&mipid02_0>;*/
				clock-lanes = <0>;
				data-lanes = <1 2>;
			};
		};
	};

	ov5640: camera@3c {
		compatible = "ovti,ov5640";
		reg = <0x3c>;
		clocks = <&clk_ext_camera>;
		clock-names = "xclk";
		DOVDD-supply = <&scmi_v3v3_sw>;
		status = "okay";
		powerdown-gpios = <&mcp23017 3 (GPIO_ACTIVE_LOW | GPIO_PUSH_PULL)>;
		reset-gpios = <&mcp23017 4 (GPIO_ACTIVE_LOW | GPIO_PUSH_PULL)>;

		port {
			ov5640_0: endpoint {
				remote-endpoint = <&mipid02_0>;
				clock-lanes = <0>;
				data-lanes = <1 2>;
			};
		};
	};

 

Do not hesitate to follow wiki information for configuration and other steps to do : https://wiki.st.com/stm32mpu/wiki/STM32MP13_V4L2_camera_overview

Kind regards,
Erwan.

In order to give better visibility on the answered topics, please click on 'Accept as Solution' on the reply which solved your issue or answered your question.
Associate II
Aug 1, 2024 04:58 UTC

Hello thank you but I mean the physical part because camera has pins. not camera cable socket like gc2145.

Erwan SZYMANSKI
ST Technical Moderator
Aug 1, 2024 05:51 UTC

Hello @kagan_senkeser ,
Do you have a link or a photo of the camera you use ? 

Kind regards,
Erwan.

In order to give better visibility on the answered topics, please click on 'Accept as Solution' on the reply which solved your issue or answered your question.
Associate II
Aug 1, 2024 05:58 UTC

ov5640-camera-board-b-3.jpg

ov5640-camera-board-b-2.jpg

debugging
Lead
Sep 5, 2024 13:36 UTC

https://www.waveshare.com/wiki/OV5640_Camera_Board_(B)

I have a similar same board that came with an ST based board but never go to use it. The waveshare link May have more info. Such board use I2C (SCCB) to control and DCMI or DVP to get the pixel data and often used with FPGAs. It's is popular used with M4/M7 boards. Not sure how or if it can be used with the A7 or M4 on STM32MP lines.  Perhaps with SPI and DMA, but there is VSYNC and HSYNC /

https://community.st.com/t5/stm32-mpus-products/dear-experts-can-i-use-the-dcmi-on-the-stm32mp15x-with-the/td-p/136465

https://community.st.com/t5/stm32-mcus-products/will-dvp-camera-interface-support-stm32h747-mcu/td-p/668802

https://community.st.com/t5/stm32cubemx-mcus/stm32h723-ov5640-dcmi-hal-dcmi-frameeventcallback-missing/td-p/623589