cancel
Showing results for 
Search instead for 
Did you mean: 

ADV7280A-M Driver Issue on STM32MP2 Yocto System

Steven-LIN
Associate III

Hello everyone,

I am currently using the ADV7280A-M with an STM32MP2 YOCTO system. I found the related driver adv7180.c and successfully loaded the driver. Following the instructions in [1], I conducted tests, but I keep encountering the following errors, or the process gets stuck at "New Clock: GstSystemClock". I would like to ask if anyone has experienced similar issues?

Below is the output from running the gst-launch command:

media-ctl -d platform:48030000.dcmipp -r
media-ctl -d platform:48030000.dcmipp -l '"48020000.csi":1->"dcmipp_input":0[1]'
media-ctl -d platform:48030000.dcmipp -l "'dcmipp_input':2->'dcmipp_main_isp':0[1]"
media-ctl -d platform:48030000.dcmipp --set-v4l2 "'adv7180 2-0021':0[fmt:UYVY8_1X16/720x480]"
media-ctl -d platform:48030000.dcmipp --set-v4l2 "'48020000.csi':1[fmt:UYVY8_1X16/720x480]"
media-ctl -d platform:48030000.dcmipp --set-v4l2 "'dcmipp_input':2[fmt:UYVY8_1X16/720x480 field:none]"
media-ctl -d platform:48030000.dcmipp --set-v4l2 "'dcmipp_main_isp':1[fmt:RGB888_1X24/720x480 field:none]"
media-ctl -d platform:48030000.dcmipp --set-v4l2 "'dcmipp_main_postproc':0[compose:(0,0)/720x480]"
media-ctl -d platform:48030000.dcmipp --set-v4l2 "'dcmipp_main_postproc':1[fmt:RGB888_1X24/720x480]"
export main_capture_dev=$(media-ctl -d "platform:48030000.dcmipp" -e "dcmipp_main_capture")

gst-launch-1.0 v4l2src device=$main_capture_dev ! "video/x-raw, format=RGB16, width=720, height=480, framerate=30/1" ! queue ! waylandsink fullscreen=true

Here is the output after running the command:

(gst-launch-1.0:1344): GStreamer-Wayland-CRITICAL **: 05:17:41.603: gst_wl_window_ensure_fullscreen: assertion 'self' failed
Setting pipeline to PAUSED ...
Pipeline is live and does not need PREROLL ...
Pipeline i[   42.741244] dcmipp 48030000.dcmipp: failed to start source subdev streaming (-2)
[   42.748510] dcmipp 48030000.dcmipp: failed to start source subdev streaming (-2)
s PREROLLED ...
Setting pipeline to PLAYING ...
New clock: GstSystemClock

 

Here is my Device Tree:

&csi {
	status = "okay";
	/* USER CODE BEGIN csi */
	vdd-supply = <&scmi_vddcore>;
	vdda18-supply = <&scmi_v1v8>;
	ports{
		#address-cells = <1>;
		#size-cells = <0>;

		port@0{
			reg = <0>;

			csi_sink:endpoint{
				remote-endpoint = <&adv7280am_ep>; 
				bus-type = <4>;
				data-lanes = <0>;
			};
		};

		port@1{
			reg = <1>;

			csi_source:endpoint{
				remote-endpoint = <&dcmipp_0>;
			};
		};
	};
	/* USER CODE END csi */
};

&dcmipp {
	status = "okay";

	/* USER CODE BEGIN dcmipp */
	port{

		dcmipp_0:endpoint{
			remote-endpoint = <&csi_source>;
			bus-type = <4>;
		};
	};
	/* USER CODE END dcmipp */
};

&i2c4 {
	pinctrl-names = "default", "sleep";
	pinctrl-0 = <&i2c4_pins_mx>;
	pinctrl-1 = <&i2c4_sleep_pins_mx>;
	status = "okay";

	/* USER CODE BEGIN i2c4 */
	i2c-scl-rising-time-ns = <108>; //108
	i2c-scl-falling-time-ns = <12>;
	clock-frequency = <400000>;
	/delete-property/ dmas;
	/delete-property/ dma-names;

	// adv7280am
	adv7280am: adv7280am@21 {      
	    compatible = "adi,adv7280-m";
	    reg = <0x21>;
		status = "okay";
		reset-gpios = <&gpioi 4 GPIO_ACTIVE_LOW>;
		powerdown-gpios = <&gpioi 3 GPIO_ACTIVE_LOW>;
		interrupts = <6 IRQ_TYPE_LEVEL_LOW>;
		interrupt-parent = <&gpioz>;
		interrupt-names = "adv7280m_intrq";

		port {
			adv7280am_ep: endpoint {
				remote-endpoint = <&csi_sink>;
				data-lanes = <1>;
				clock-lanes = <0>;
				link-frequencies = /bits/ 64 <270000000>;
			};
		};
    };
	/* USER CODE END i2c4 */
};

 

i2c:

     0  1  2  3  4  5  6  7  8  9  a  b  c  d  e  f
00:                         -- -- -- -- -- -- -- --
10: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
20: -- UU -- -- -- -- -- -- -- -- -- -- -- -- -- --
30: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
40: -- -- UU -- UU -- -- -- -- -- -- -- -- -- -- --
50: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
60: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
70: -- -- -- -- -- -- -- --

media-ctl:

Media controller API version 6.6.48

Media device information
------------------------
driver          dcmipp
model           DCMIPP MDEV
serial
bus info        platform:48030000.dcmipp
hw revision     0x30
driver version  6.6.48

Device topology
- entity 1: dcmipp_input (4 pads, 5 links, 0 routes)
            type V4L2 subdev subtype Unknown flags 0
            device node name /dev/v4l-subdev0
        pad0: Sink
                [stream:0 fmt:RGB565_2X8_LE/640x480 field:none colorspace:rec709]
                <- "dcmipp_tpg":0 []
                <- "48020000.csi":1 [ENABLED]
        pad1: Source
                [stream:0 fmt:RGB565_2X8_LE/640x480 field:none colorspace:rec709]
                -> "dcmipp_dump_postproc":0 []
        pad2: Source
                [stream:0 fmt:RGB565_2X8_LE/640x480 field:none colorspace:rec709]
                -> "dcmipp_main_isp":0 []
        pad3: Source
                [stream:0 fmt:RGB565_2X8_LE/640x480 field:none colorspace:rec709]
                -> "dcmipp_aux_postproc":0 []

- entity 6: dcmipp_dump_postproc (2 pads, 2 links, 0 routes)
            type V4L2 subdev subtype Unknown flags 0
            device node name /dev/v4l-subdev1
        pad0: Sink
                [stream:0 fmt:RGB565_2X8_LE/640x480 field:none colorspace:rec709
                 compose.bounds:(0,0)/640x480
                 compose:(0,0)/640x480]
                <- "dcmipp_input":1 []
        pad1: Source
                [stream:0 fmt:RGB565_2X8_LE/640x480 field:none colorspace:rec709
                 crop.bounds:(0,0)/640x480
                 crop:(0,0)/640x480]
                -> "dcmipp_dump_capture":0 [ENABLED,IMMUTABLE]

- entity 9: dcmipp_dump_capture (1 pad, 1 link)
            type Node subtype V4L flags 0
            device node name /dev/video0
        pad0: Sink
                <- "dcmipp_dump_postproc":1 [ENABLED,IMMUTABLE]

- entity 13: dcmipp_main_isp (4 pads, 5 links, 0 routes)
             type V4L2 subdev subtype Unknown flags 0
             device node name /dev/v4l-subdev2
        pad0: Sink
                [stream:0 fmt:RGB565_2X8_LE/640x480 field:none colorspace:rec709
                 crop.bounds:(0,0)/640x480
                 crop:(0,0)/0x0
                 compose.bounds:(0,0)/0x0
                 compose:(0,0)/0x0]
                <- "dcmipp_input":2 []
        pad1: Source
                [stream:0 fmt:RGB888_1X24/640x480 field:none colorspace:rec709]
                -> "dcmipp_main_postproc":0 [ENABLED,IMMUTABLE]
                -> "dcmipp_aux_postproc":0 []
        pad2: Sink
                [stream:0 fmt:unknown/0x0]
                <- "dcmipp_main_isp_params_output":0 [ENABLED,IMMUTABLE]
        pad3: Source
                [stream:0 fmt:unknown/0x0]
                -> "dcmipp_main_isp_stat_capture":0 [ENABLED,IMMUTABLE]

- entity 18: dcmipp_main_postproc (2 pads, 2 links, 0 routes)
             type V4L2 subdev subtype Unknown flags 0
             device node name /dev/v4l-subdev3
        pad0: Sink
                [stream:0 fmt:RGB888_1X24/640x480@1/30 field:none colorspace:rec709
                 crop.bounds:(0,0)/640x480
                 crop:(0,0)/640x480
                 compose.bounds:(0,0)/640x480
                 compose:(0,0)/640x480]
                <- "dcmipp_main_isp":1 [ENABLED,IMMUTABLE]
        pad1: Source
                [stream:0 fmt:RGB888_1X24/640x480@1/30 field:none colorspace:rec709]
                -> "dcmipp_main_capture":0 [ENABLED,IMMUTABLE]

- entity 21: dcmipp_main_capture (1 pad, 1 link)
             type Node subtype V4L flags 0
             device node name /dev/video1
        pad0: Sink
                <- "dcmipp_main_postproc":1 [ENABLED,IMMUTABLE]

- entity 25: dcmipp_aux_postproc (2 pads, 3 links, 0 routes)
             type V4L2 subdev subtype Unknown flags 0
             device node name /dev/v4l-subdev4
        pad0: Sink
                [stream:0 fmt:RGB888_1X24/640x480@1/30 field:none colorspace:rec709
                 crop.bounds:(0,0)/640x480
                 crop:(0,0)/640x480
                 compose.bounds:(0,0)/640x480
                 compose:(0,0)/640x480]
                <- "dcmipp_input":3 []
                <- "dcmipp_main_isp":1 []
        pad1: Source
                [stream:0 fmt:RGB888_1X24/640x480@1/30 field:none colorspace:rec709]
                -> "dcmipp_aux_capture":0 [ENABLED,IMMUTABLE]

- entity 28: dcmipp_aux_capture (1 pad, 1 link)
             type Node subtype V4L flags 0
             device node name /dev/video2
        pad0: Sink
                <- "dcmipp_aux_postproc":1 [ENABLED,IMMUTABLE]

- entity 32: dcmipp_main_isp_stat_capture (1 pad, 1 link)
             type Node subtype V4L flags 0
             device node name /dev/video3
        pad0: Sink
                <- "dcmipp_main_isp":3 [ENABLED,IMMUTABLE]

- entity 36: dcmipp_main_isp_params_output (1 pad, 1 link)
             type Node subtype V4L flags 0
             device node name /dev/video4
        pad0: Source
                -> "dcmipp_main_isp":2 [ENABLED,IMMUTABLE]

- entity 40: dcmipp_tpg (1 pad, 1 link, 0 routes)
             type V4L2 subdev subtype Sensor flags 0
             device node name /dev/v4l-subdev5
        pad0: Source
                [stream:0 fmt:RGB565_1X16/640x480 field:none colorspace:rec709]
                -> "dcmipp_input":0 []

- entity 64: 48020000.csi (2 pads, 2 links, 0 routes)
             type V4L2 subdev subtype Unknown flags 0
             device node name /dev/v4l-subdev6
        pad0: Sink
                [stream:0 fmt:RGB565_1X16/640x480 field:none colorspace:rec709]
                <- "adv7180 2-0021":0 [ENABLED,IMMUTABLE]
        pad1: Source
                [stream:0 fmt:RGB565_1X16/640x480 field:none colorspace:rec709]
                -> "dcmipp_input":0 [ENABLED]

- entity 69: adv7180 2-0021 (1 pad, 1 link, 0 routes)
             type V4L2 subdev subtype Decoder flags 0
             device node name /dev/v4l-subdev7
        pad0: Source
                [stream:0 fmt:UYVY8_1X16/720x480@1001/30000 field:none colorspace:smpte170m]
                -> "48020000.csi":0 [ENABLED,IMMUTABLE]

[1] STM32MP2 V4L2 camera overview - stm32mpu

0 REPLIES 0