Skip to content

Commit

Permalink
feat: add radxa cm3j rpi cm4 io 7inch touchscreen overlays
Browse files Browse the repository at this point in the history
  • Loading branch information
Radxa-Alvin committed Jun 17, 2024
1 parent 70328be commit 3ee4841
Show file tree
Hide file tree
Showing 3 changed files with 234 additions and 0 deletions.
2 changes: 2 additions & 0 deletions arch/arm64/boot/dts/rockchip/overlays/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -299,6 +299,8 @@ dtb-$(CONFIG_CPU_RK3568) += \
radxa-cm3i-io-radxa-camera-8m-cam1.dtbo \
radxa-cm3i-io-radxa-camera-8m-cam2.dtbo \
radxa-cm3i-io-sata.dtbo \
radxa-cm3j-rpi-cm4-io-7inch-touchscreen-disp0.dtbo \
radxa-cm3j-rpi-cm4-io-7inch-touchscreen-disp1.dtbo \
radxa-cm3j-rpi-cm4-io-radxa-camera-8m-cam0.dtbo \
radxa-cm3j-rpi-cm4-io-radxa-camera-8m-cam1.dtbo \
radxa-cm3j-rpi-cm4-io-rpi-camera-v1p3-ov5647-cam0.dtbo \
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,116 @@
/dts-v1/;
/plugin/;

#include <dt-bindings/gpio/gpio.h>
#include <dt-bindings/pinctrl/rockchip.h>

/ {
metadata {
title = "Enable Raspberry Pi 7-inch Touchscreen on disp0";
compatible = "radxa,cm3j-rpi-cm4-io";
category = "display";
exclusive = "vp1";
description = "Enable Raspberry Pi 7-inch Touchscreen on disp0.";
};
};

&dsi0 {
status = "okay";
#address-cells = <1>;
#size-cells = <0>;
rockchip,lane-rate = <600>;

dsi0_panel: dsi-panel@0 {
compatible = "raspits,tc358762";
reg = <0x0>;
status = "okay";

display_timings0: display-timings {
native-mode = <&dsi0_timing>;

dsi0_timing: timing0 {
clock-frequency = <26000000>;
hactive = <800>;
vactive = <480>;

hsync-len = <75>;
hback-porch = <65>;
hfront-porch = <50>;

vsync-len = <12>;
vback-porch = <7>;
vfront-porch = <10>;

hsync-active = <0>;
vsync-active = <0>;
de-active = <0>;
pixelclk-active = <0>;
};
};

ports {
#address-cells = <1>;
#size-cells = <0>;

port@0 {
reg = <0>;
panel_in_dsi0: endpoint {
remote-endpoint = <&dsi0_out_panel>;
};
};
};
};

ports {
#address-cells = <1>;
#size-cells = <0>;

port@1 {
reg = <1>;
#address-cells = <1>;
#size-cells = <0>;

dsi0_out_panel: endpoint@0 {
reg = <0>;
remote-endpoint = <&panel_in_dsi0>;
};
};
};
};

&i2c5 {
status = "okay";
pinctrl-names = "default";
pinctrl-0 = <&i2c5m0_xfer>;
#address-cells = <1>;
#size-cells = <0>;

rockpi_mcu: rockpi-mcu@45 {
compatible = "rockpi_mcu";
reg = <0x45>;
};

raspits_ft5426: raspits-ft5426@38 {
compatible = "raspits_ft5426";
reg = <0x38>;
};

chipone_icn8952: chipone_icn8952@30 {
compatible = "chipone_icn8505";
reg = <0x30>;
};

};

&dsi0_in_vp1 {
status = "okay";
};

&route_dsi0 {
status = "okay";
connect = <&vp1_out_dsi0>;
};

&video_phy0 {
status = "okay";
};
Original file line number Diff line number Diff line change
@@ -0,0 +1,116 @@
/dts-v1/;
/plugin/;

#include <dt-bindings/gpio/gpio.h>
#include <dt-bindings/pinctrl/rockchip.h>

/ {
metadata {
title = "Enable Raspberry Pi 7-inch Touchscreen on disp1";
compatible = "radxa,cm3j-rpi-cm4-io";
category = "display";
exclusive = "vp1";
description = "Enable Raspberry Pi 7-inch Touchscreen on disp1.";
};
};

&dsi1 {
status = "okay";
#address-cells = <1>;
#size-cells = <0>;
rockchip,lane-rate = <600>;

dsi1_panel: dsi-panel@0 {
compatible = "raspits,tc358762";
reg = <0x0>;
status = "okay";

display_timings0: display-timings {
native-mode = <&dsi0_timing>;

dsi0_timing: timing0 {
clock-frequency = <26000000>;
hactive = <800>;
vactive = <480>;

hsync-len = <75>;
hback-porch = <65>;
hfront-porch = <50>;

vsync-len = <12>;
vback-porch = <7>;
vfront-porch = <10>;

hsync-active = <0>;
vsync-active = <0>;
de-active = <0>;
pixelclk-active = <0>;
};
};

ports {
#address-cells = <1>;
#size-cells = <0>;

port@0 {
reg = <0>;
panel_in_dsi1: endpoint {
remote-endpoint = <&dsi1_out_panel>;
};
};
};
};

ports {
#address-cells = <1>;
#size-cells = <0>;

port@1 {
reg = <1>;
#address-cells = <1>;
#size-cells = <0>;

dsi1_out_panel: endpoint@0 {
reg = <0>;
remote-endpoint = <&panel_in_dsi1>;
};
};
};
};

&i2c0 {
status = "okay";
pinctrl-names = "default";
pinctrl-0 = <&i2c0_xfer>;
#address-cells = <1>;
#size-cells = <0>;

rockpi_mcu: rockpi-mcu@45 {
compatible = "rockpi_mcu";
reg = <0x45>;
};

raspits_ft5426: raspits-ft5426@38 {
compatible = "raspits_ft5426";
reg = <0x38>;
};

chipone_icn8952: chipone_icn8952@30 {
compatible = "chipone_icn8505";
reg = <0x30>;
};
};

&dsi1_in_vp1 {
status = "okay";
};

&route_dsi1 {
status = "okay";
connect = <&vp1_out_dsi1>;
};

&video_phy1 {
status = "okay";
};

0 comments on commit 3ee4841

Please sign in to comment.