summaryrefslogtreecommitdiff
path: root/overlays/verdin-am62p_ov5640_overlay.dts
diff options
context:
space:
mode:
Diffstat (limited to 'overlays/verdin-am62p_ov5640_overlay.dts')
-rw-r--r--overlays/verdin-am62p_ov5640_overlay.dts81
1 files changed, 81 insertions, 0 deletions
diff --git a/overlays/verdin-am62p_ov5640_overlay.dts b/overlays/verdin-am62p_ov5640_overlay.dts
new file mode 100644
index 0000000..5bffed8
--- /dev/null
+++ b/overlays/verdin-am62p_ov5640_overlay.dts
@@ -0,0 +1,81 @@
+// SPDX-License-Identifier: GPL-2.0-or-later OR MIT
+/*
+ * Copyright (C) 2025 Toradex
+ *
+ * CSI Camera Module OV5640 overlay for Verdin AM62P CSI0
+ */
+
+/dts-v1/;
+/plugin/;
+
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/media/video-interfaces.h>
+
+/ {
+ compatible = "toradex,verdin-am62p";
+};
+
+&{/} {
+ clk_ov5640_osc: ov5640-xclk {
+ compatible = "fixed-clock";
+ #clock-cells = <0>;
+ clock-frequency = <24000000>;
+ };
+
+ regulator_camera: regulator-camera {
+ compatible = "regulator-fixed";
+ /* Verdin GPIO_8_CSI (SODIMM 222) - Camera Connector 24 */
+ gpio = <&main_gpio0 52 GPIO_ACTIVE_HIGH>;
+ enable-active-high;
+ regulator-name = "V_CSI";
+ startup-delay-us = <5000>;
+ };
+};
+
+/* Verdin I2C_4_CSI */
+&main_i2c3 {
+ #address-cells = <1>;
+ #size-cells = <0>;
+ status = "okay";
+
+ camera@3c {
+ compatible = "ovti,ov5640";
+ reg = <0x3c>;
+ clocks = <&clk_ov5640_osc>;
+ clock-names = "xclk";
+ AVDD-supply = <&regulator_camera>;
+ DVDD-supply = <&regulator_camera>;
+ DOVDD-supply = <&regulator_camera>;
+ /* Verdin GPIO6 (SODIMM 218) - Camera Connector 22 */
+ powerdown-gpios = <&main_gpio0 50 GPIO_ACTIVE_HIGH>;
+ /* Verdin GPIO5 (SODIMM 216) - Camera Connector 11 */
+ reset-gpios = <&main_gpio0 49 GPIO_ACTIVE_LOW>;
+
+ port {
+ csi2_cam0: endpoint {
+ remote-endpoint = <&csi2rx0_in_sensor>;
+ clock-lanes = <0>;
+ data-lanes = <1 2>;
+ };
+ };
+ };
+};
+
+&csi0_port0 {
+ status = "okay";
+
+ csi2rx0_in_sensor: endpoint {
+ remote-endpoint = <&csi2_cam0>;
+ bus-type = <MEDIA_BUS_TYPE_CSI2_DPHY>;
+ clock-lanes = <0>;
+ data-lanes = <1 2>;
+ };
+};
+
+&dphy0 {
+ status = "okay";
+};
+
+&ti_csi2rx0 {
+ status = "okay";
+};