From 237cd1ffb4e210a43b688b428a4fb96e5be415b5 Mon Sep 17 00:00:00 2001 From: Markus Koch Date: Sat, 21 Dec 2024 13:49:31 +0100 Subject: [PATCH] dt: Fix touchscreen For some reason, the ecspi SS1 line appears on the output when selecting GPIO in the pinmux. Also, the x-axis is inverted, and pressure values upon press hover around 250. --- README.MD | 2 +- linux/imx53-amx-mst701.dts | 6 +++++- 2 files changed, 6 insertions(+), 2 deletions(-) diff --git a/README.MD b/README.MD index c5542d2..b7a70a1 100644 --- a/README.MD +++ b/README.MD @@ -60,6 +60,6 @@ For future updates via SSH, look into `scripts/upload_and_flash.sh`. * Backlight (configured active by bootloader for now) * Notification LEDs (not populated on HW anyways) * Broken - * Touchscreen does report any events + * Touchscreen mapping is off (offset and skewed), prossibly fixable in libinput via transformation matrix. * Speaker-amp (gpiochip4,2) not turned on automatically (needs to be activated using gpioset for now) diff --git a/linux/imx53-amx-mst701.dts b/linux/imx53-amx-mst701.dts index 9b4f380..125b199 100644 --- a/linux/imx53-amx-mst701.dts +++ b/linux/imx53-amx-mst701.dts @@ -128,6 +128,10 @@ spi-max-frequency = <1000000>; + touchscreen-min-pressure = <128>; + touchscreen-max-pressure = <512>; + touchscreen-inverted-x; + wakeup-source; }; }; @@ -242,7 +246,7 @@ MX53_PAD_EIM_D16__ECSPI1_SCLK 0x80000000 MX53_PAD_EIM_D17__ECSPI1_MISO 0x80000000 MX53_PAD_EIM_D18__ECSPI1_MOSI 0x80000000 - MX53_PAD_EIM_D19__ECSPI1_SS1 0x80000000 + MX53_PAD_EIM_D19__GPIO3_19 0x80000000 /* Should normally be MX53_PAD_EIM_D19__ECSPI1_SS1, but for some reason ecspi controls the SS via GPIO. */ >; };