kernel-brax3-ubuntu-touch/arch/arm64/boot/dts/mediatek/cust_mt6985_touch_1080x2400.dtsi
erascape f319b992b1 kernel-5.15: Initial import brax3 UT kernel
* halium configs enabled

Signed-off-by: erascape <erascape@proton.me>
2025-09-23 15:17:10 +00:00

262 lines
7.2 KiB
Text

// SPDX-License-Identifier: (GPL-2.0 OR MIT)
/*
* Copyright (C) 2020 MediaTek Inc.
*/
/* TOUCH start */
&spi6 {
status = "okay";
#address-cells = <1>;
#size-cells = <0>;
pinctrl-names = "default", "gt9896s_int_active",
"gt9896s_reset_active", "gt9896s_int_suspend",
"gt9896s_reset_suspend", "gt9896s_spi_mode";
pinctrl-0 = <&ctp_gt9896s_pins_default>;
pinctrl-1 = <&ctp_gt9896s_int_active>;
pinctrl-2 = <&ctp_gt9896s_reset_active>;
pinctrl-3 = <&ctp_gt9896s_int_suspend>;
pinctrl-4 = <&ctp_gt9896s_reset_suspend>;
pinctrl-5 = <&ctp_gt9896s_spi_mode>;
goodix@0 {
compatible = "novatek,NVT-ts-spi",
"goodix,gt9896s",
"goodix,nottingham",
"st,spi";
reg = <0>; //Same as CS ID
spi-max-frequency = <1000000>;
pinctrl-names = "pmx_ts_active", "pmx_ts_suspend", "pmx_ts_spi_mode",
"pmx_ts_dvdd_enable", "pmx_ts_dvdd_disable";
pinctrl-0 = <&ts_st_reset_active &ts_st_int_active>;
pinctrl-1 = <&ts_st_int_suspend &ts_st_reset_suspend>;
pinctrl-2 = <&ts_st_spi_mode>;
pinctrl-3 = <&ts_dvdd_enable>;
pinctrl-4 = <&ts_dvdd_disable>;
novatek,reset-gpio = <&pio 3 0x00>;
novatek,irq-gpio = <&pio 8 0x00>;
// 525
//novatek,swrst-n8-addr = <0x01f01a>;
// 672a, 525b, 675, 526
novatek,swrst-n8-addr = <0x03f0fe>;
novatek,spi-rd-fast-addr = <0x03f310>;
goodix,avdd-name = "vtouch";
vtouch-supply = <&mt6373_vtp>;
goodix,reset-gpio = <&pio 3 0x0>;
goodix,irq-gpio = <&pio 8 0x0>;
goodix,irq-flags = <2>; /* 1:rising, 2:falling;*/
goodix,panel-max-id = <10>;
goodix,panel-max-x = <1080>;
goodix,panel-max-y = <2400>;
goodix,panel-max-w = <256>;
goodix,panel-max-p = <256>;
goodix,input-max-x = <1080>;
goodix,input-max-y = <2400>;
gt9895,power-voltage = <2800000>;
goodix,panel-key-map = <158 172 217>; /*BACK,HOMEPAGE,SEARCH*/
goodix,power-on-delay-us = <10000>; /*10ms*/
goodix,power-off-delay-us = <5000>;
gt9895,firmware-name = "gt9895_firmware_6985v01.bin";
gt9895,config-name = "gt9895_cfg_6985v01.bin";
goodix,firmware-version = "6983v01";
goodix,config-version = "6983v01";
/*goodix,swap-axis;*/
/*gt9895,x2x;*/
/*gt9895,y2y;*/
goodix,x2x;
goodix,y2y;
goodix,pen-enable;
tpd-filter-enable = <0>;
tpd-filter-pixel-density = <161>;
tpd-filter-custom-prameters = <0 0 0 0 0 0 0 0 0 0 0 0>;
tpd-filter-custom-speed = <0 0 0>;
interrupt-parent = <&pio>;
interrupts = <8 0x2008>;
avdd-supply = <&mt6373_vtp>;
fts,config-array-size = <1>;
fts,pwr-reg-name = "avdd";
//fts,bus-reg-name = "vdd";
fts,irq-gpio = <&pio 8 0x0>;
fts,irq-gpio-name = "fts_irq";
fts,reset-gpio-enable;
fts,reset-gpio = <&pio 3 0x0>;
fts,reset-gpio-name = "fts_rst";
fts,irq-flags = <0x2008>;/* 1:rising, 2:falling;*/
fts,x-max = <14400>;/*Super resolution*/
fts,y-max = <32000>;/*Super resolution*/
fts,screen-x = <1440>;
fts,screen-y = <3200>;
//fts,fod-lx = <4180>;
//fts,fod-ly = <16810>;
fts,support-super-resolution = <1>;
//spi-max-frequency = <12000000>;
fts,default-fw-name = "st_fts_L11a.ftb";
fts,old-fw-name = "st_fts_L11.ftb";
fts,thp-fw-name = "st_fts_L11a_thp.ftb";
/* fts,touch-up-threshold-min = <40>; */
/* fts,touch-up-threshold-max = <120>; */
/* fts,touch-up-threshold-def = <80>; */
/* fts,touch-tolerance-min = <5>; */
/* fts,touch-tolerance-max = <35>; */
/* fts,touch-tolerance-def = <25>;*/
fts,touch-follow-performance-def = <3>;
fts,touch-tap-sensitivity-def = <4>;
fts,touch-aim-sensitivity-def = <3>;
fts,touch-tap-stability-def = <3>;
fts,cornerfilter-area-step1 = <100>;
fts,cornerfilter-area-step2 = <170>;
fts,cornerfilter-area-step3 = <250>;
fts,touch-deadzone-filter-ver = <2 0 0 0 0 0 0 0
2 1 0 0 0 0 0 0
2 2 0 0 0 2399 0 0
2 3 1079 0 1079 2399 0 0>;
fts,touch-deadzone-filter-hor = <2 0 0 0 1079 0 0 0
2 1 0 2399 1079 2399 0 0
2 2 0 0 0 2399 0 0
2 3 1079 0 1079 2399 0 0>;
fts,touch-edgezone-filter-ver = <1 0 0 0 0 0 0 0
1 1 0 0 0 0 0 0
1 2 0 0 40 2339 0 0
1 3 1039 0 1079 2339 0 0>;
fts,touch-edgezone-filter-hor = <1 0 0 0 1079 40 0 0
1 1 0 2359 1079 2399 0 0
1 2 0 0 40 2399 0 0
1 3 1039 0 1079 2399 0 0>;
fts,touch-cornerzone-filter-ver = <0 0 0 0 0 0 0 0
0 1 0 0 0 0 0 0
0 2 0 2099 150 2399 0 0
0 3 929 2099 1079 2399 0 0>;
fts,touch-cornerzone-filter-hor1 = <0 0 0 0 170 170 0 0
0 1 0 0 0 0 0 0
0 2 0 2229 170 2399 0 0
0 3 0 0 0 0 0 0>;
fts,touch-cornerzone-filter-hor2 = <0 0 0 0 0 0 0 0
0 1 909 0 1079 170 0 0
0 2 0 0 0 0 0 0
0 3 909 2229 1079 2399 0 0>;
fts,touch-follow-performance = <10 15 1
8 15 1
6 15 1
4 15 1
2 15 1>;
fts,touch-tap-sensitivity = <150 140 130 120 110>;
fts,touch-aim-sensitivity = <8 6 5 3 2>;
fts,touch-tap-stability = <8 12 15 18 25>;
fts,touch-expert-array = <2 15 1 120 3 15
4 15 1 120 2 15
6 15 1 120 5 15>;
fts,cfg {
fts,tp-vendor = <0x38>;
fts,tp-color = <0x32>;
fts,fw-name = "st_fts_L11a.ftb";
fts,old-fw-name = "st_fts_L11.ftb";
fts,limit-name = "stm_fts_production_limits.csv";
};
};
};
&mt6373_vtp {
regulator-boot-on;
regulator-min-microvolt = <2800000>;
regulator-max-microvolt = <3300000>;
};
&pio {
ctp_gt9896s_pins_default: pins-default {
};
ctp_gt9896s_int_active: int1-active {
pins-cmd-dat {
pinmux = <PINMUX_GPIO8__FUNC_GPIO8>;
input-enable;
};
};
ctp_gt9896s_reset_active: reset1-active {
pins-cmd-dat {
pinmux = <PINMUX_GPIO3__FUNC_GPIO3>;
output-high;
};
};
ctp_gt9896s_int_suspend: int1-suspend {
pins-cmd-dat {
pinmux = <PINMUX_GPIO8__FUNC_GPIO8>;
output-low;
};
};
ctp_gt9896s_reset_suspend: reset1-suspend {
pins-cmd-dat {
pinmux = <PINMUX_GPIO3__FUNC_GPIO3>;
output-low;
};
};
ctp_gt9896s_spi_mode: spimode-default {
pins-cmd-dat {
pinmux = <PINMUX_GPIO164__FUNC_SPI6_B_MI>,
<PINMUX_GPIO165__FUNC_SPI6_B_CSB>,
<PINMUX_GPIO166__FUNC_SPI6_B_MO>,
<PINMUX_GPIO167__FUNC_SPI6_B_CLK>;
drive-strength = <2>;
};
};
ts_st_reset_active: ts-st-reset-active {
pins-cmd-dat {
pinmux = <PINMUX_GPIO3__FUNC_GPIO3>;
output-high;
};
};
ts_st_int_active: ts-st-int-active {
pins-cmd-dat {
pinmux = <PINMUX_GPIO8__FUNC_GPIO8>;
input-enable;
};
};
ts_st_int_suspend: ts-st-int-suspend {
pins-cmd-dat {
pinmux = <PINMUX_GPIO8__FUNC_GPIO8>;
slew-rate = <1>;
bias-pull-down;
};
};
ts_st_reset_suspend: ts-st-reset-suspend {
pins-cmd-dat {
pinmux = <PINMUX_GPIO3__FUNC_GPIO3>;
slew-rate = <1>;
bias-pull-down;
};
};
ts_st_spi_mode: ts-spimode {
pins-cmd-dat {
pinmux = <PINMUX_GPIO164__FUNC_SPI6_B_MI>,
<PINMUX_GPIO165__FUNC_SPI6_B_CSB>,
<PINMUX_GPIO166__FUNC_SPI6_B_MO>,
<PINMUX_GPIO167__FUNC_SPI6_B_CLK>;
drive-strength = <2>;
};
};
ts_dvdd_enable: ts-dvddenable {
pins-cmd-dat {
pinmux = <PINMUX_GPIO118__FUNC_GPIO118>;
output-high;
};
};
ts_dvdd_disable: ts-dvdddisable {
pins-cmd-dat {
pinmux = <PINMUX_GPIO118__FUNC_GPIO118>;
output-low;
};
};
};
&odm {
tc8_touch: tc8-touch {
compatible = "tc8sp-touch";
status = "ok";
touch,name = "tc8sp-touch";
};
};
/* TOUCH end */