From e0f688b25fd961c84f02fdeab022a8419e09dbaf Mon Sep 17 00:00:00 2001 From: uigormarshall Date: Thu, 26 Mar 2026 21:43:27 -0300 Subject: [PATCH] =?UTF-8?q?feat(rk3326):=20eeclone=20640x480=20overlay=20?= =?UTF-8?q?=E2=80=94=20fix=20panel,=20amp,=20and=20HP=20routing?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../eeclone-mipi-panel-640x480.dts | 109 ++++++++++++++++++ 1 file changed, 109 insertions(+) create mode 100644 config/archr-dts/R36S-clone-plugin-overlays/eeclone-mipi-panel-640x480.dts diff --git a/config/archr-dts/R36S-clone-plugin-overlays/eeclone-mipi-panel-640x480.dts b/config/archr-dts/R36S-clone-plugin-overlays/eeclone-mipi-panel-640x480.dts new file mode 100644 index 0000000000..51e49c4df4 --- /dev/null +++ b/config/archr-dts/R36S-clone-plugin-overlays/eeclone-mipi-panel-640x480.dts @@ -0,0 +1,109 @@ +// SPDX-License-Identifier: (GPL-2.0+ OR MIT) +/* + * MIPI panel overlay for RK3326 EE-clone handhelds with 640x480 (HVGA) panel + * and ST7703-style init via archr,generic-dsi. + * + * Applied on top of rk3326-gameconsole-eeclone.dtb (clone image). + * Contributors: community (Arch R) + */ + +/dts-v1/; + +/ { + + fragment@0 { + target-path = "/"; + + __overlay__ { + + dsi@ff450000 { + + panel@0 { + compatible = "archr,generic-dsi"; + panel_description = "G size=153,85 delays=20,20,20,120,20 format=rgb888 lanes=4 flags=0xe03\0M clock=30000 horizontal=640,150,50,150 vertical=480,20,6,12 default=1\0M clock=30000 horizontal=640,150,61,150 vertical=480,20,88,12\0M clock=30000 horizontal=640,150,60,150 vertical=480,20,88,12\0M clock=30010 horizontal=640,150,72,150 vertical=480,20,81,12\0M clock=30130 horizontal=640,150,60,150 vertical=480,20,12,12\0M clock=35920 horizontal=640,150,59,150 vertical=480,20,90,12\0M clock=31440 horizontal=640,150,61,150 vertical=480,20,12,12\0M clock=31080 horizontal=640,150,60,150 vertical=480,20,6,12\0M clock=32750 horizontal=640,150,96,150 vertical=480,20,14,12\0M clock=45250 horizontal=640,150,66,150 vertical=480,20,84,12\0M clock=46620 horizontal=640,150,60,150 vertical=480,20,6,12\0M clock=62160 horizontal=640,150,60,150 vertical=480,20,6,12\0I seq=b9f11283\0I seq=b1000000da80\0I seq=b2001370\0I seq=b31010282803ff00000000\0I seq=b480\0I seq=b50a0a\0I seq=b68282\0I seq=b82662f063\0I seq=ba338105f90e0e2000000000000000442500900a0000014f01000037\0I seq=bc47\0I seq=bf021100\0I seq=c0737350500000125000\0I seq=c15300323277d1cccc77773333\0I seq=c68200bfff00ff\0I seq=c7b8000a000000\0I seq=c810401e02\0I seq=cc0b\0I seq=e000070d37353f4144060c0d0f111012141a00070d37353f4144060c0d0f111012141a\0I seq=e307070b0b0b0b00000000ff00c010\0I seq=e9c810020000b0b11131232880b0b127080004020000000004020000008888ba60240888888888888888ba713518888888888800000001000000000000000000\0I seq=ea970a820203070000000000008188ba17538888888888888088ba0642888888888888230000028000000000000000000000000000000000000000000000\0I seq=efffff01\0I seq=11 wait=200\0I seq=29 wait=20"; + reset-gpios = <0xffffffff 0x1b 0x01>; + }; + }; + + pinctrl { + + gpio-lcd { + + lcd-rst { + rockchip,pins = <0x03 0x1b 0x00 0xffffffff>; + }; + }; + + vcc18-lcd { + + vcc18-lcd-n { + rockchip,pins = <0x03 0x03 0x00 0xffffffff>; + }; + }; + }; + + vcc18-lcd0 { + gpio = <0xffffffff 0x03 0x00>; + }; + }; + }; + + fragment@1 { + target-path = "/"; + + __overlay__ { + + adc-keys { + status = "okay"; + }; + }; + }; + + fragment@2 { + target = <0xffffffff>; + + __overlay__ { + invert-absx = <0x01>; + invert-absy = <0x01>; + }; + }; + + fragment@3 { + target-path = "/"; + + __overlay__ { + + audio-amplifier { + enable-gpios = <0xffffffff 0x07 0x00>; + }; + + pinctrl { + + speaker { + spk-amp-enable-h { + rockchip,pins = <0x03 0x07 0x00 0xffffffff>; + }; + }; + + headphone { + hp-det { + rockchip,pins = <0x02 0x16 0x00 0xffffffff>; + }; + }; + }; + + rk817-sound-amplified { + status = "okay"; + simple-audio-card,hp-det-gpio = <0xffffffff 0x16 0x00>; + }; + }; + }; + + __fixups__ { + gpio3 = "/fragment@0/__overlay__/dsi@ff450000/panel@0:reset-gpios:0\0/fragment@0/__overlay__/vcc18-lcd0:gpio:0\0/fragment@3/__overlay__/audio-amplifier:enable-gpios:0"; + pcfg_pull_none = "/fragment@0/__overlay__/pinctrl/gpio-lcd/lcd-rst:rockchip,pins:12\0/fragment@0/__overlay__/pinctrl/vcc18-lcd/vcc18-lcd-n:rockchip,pins:12\0/fragment@3/__overlay__/pinctrl/speaker/spk-amp-enable-h:rockchip,pins:12"; + joypad = "/fragment@2:target:0"; + gpio2 = "/fragment@3/__overlay__/rk817-sound-amplified:simple-audio-card,hp-det-gpio:0"; + pcfg_pull_up = "/fragment@3/__overlay__/pinctrl/headphone/hp-det:rockchip,pins:12"; + }; +};