AnsweredAssumed Answered

How do I enable ccm_clko1 on the csi0_mclk pin?

Question asked by Jeff Lancaster on Mar 24, 2015
Latest reply on May 9, 2018 by GregT

I want to add a image sensor device with a mipi interface similar to the Sabre SD board's ov5640_mipi. However our hardware the main clock (CCM_CLKO1) that runs the image sensor on the CSI0_MCLK rather than the GPIO_0 pin. I lifted most of the code in the devicetree in imx6qdl-sabre.dtsi where the ov5640_mipi device is defined. In the iomuxc section of the Sabre device tree enables the GPIO_0 pin using MX6QDL_PAD_GPIO_0__CCM_CLKO1 0x130b0.

 

On our design, I am doing something very similar except that since our pin that supplies the main clock (CCM_CLKO1) to our image sensor is on the CSI0_MCLK pin I set the following line in iomuxc section of our devicetree: MX6QDL_PAD_CSI0_MCLK__CCM_CLKO1 0x130b0. As for the driver definition in the device tree, the only difference between the Sabre SD code (below) and mine is the name of the driver, ov5640_mipi.

 

Thus far I have not seen a clock on the CSI0_MCLK pin.

 

Any suggestions?

 

ov5640_mipi: ov5640_mipi@3c { /* i2c2 driver */
compatible = "ovti,ov5640_mipi";
reg = <0x3c>;
clocks = <&clks 201>;
clock-names = "csi_mclk";
DOVDD-supply = <&vgen4_reg>; /* 1.8v */
AVDD-supply = <&vgen3_reg>;  /* 2.8v, rev C board is VGEN3
rev B board is VGEN5 */
DVDD-supply = <&vgen2_reg>;  /* 1.5v*/
pwn-gpios = <&gpio1 19 1>;   /* active low: SD1_CLK */
rst-gpios = <&gpio1 20 0>;   /* active high: SD1_DAT2 */
csi_id = <1>;
mclk = <24000000>;
mclk_source = <0>;
};

Outcomes