From 840e7514613ab36d5231129446f6b2e4fa2de2ee Mon Sep 17 00:00:00 2001 From: Super Liu Date: Wed, 4 May 2022 11:15:45 +0800 Subject: [PATCH 1/2] Initial touch sysfs config. Bug: 231385413 Test: check the property work corrently. Signed-off-by: Super Liu Change-Id: Ic062fc046a4c8b5186b0081bdbf69c0cab63f661 --- conf/init.tangorpro.rc | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+) diff --git a/conf/init.tangorpro.rc b/conf/init.tangorpro.rc index 47f813a..6534386 100644 --- a/conf/init.tangorpro.rc +++ b/conf/init.tangorpro.rc @@ -37,6 +37,25 @@ on property:vendor.mfgapi.touchpanel.permission=1 chmod 0600 /sys/devices/virtual/sec/tsp/cmd chown system system /sys/devices/virtual/sec/tsp/cmd +# Touch +on property:vendor.device.modules.ready=1 + chown system system /sys/devices/platform/10d10000.spi/spi_master/spi0/spi0.0/input/nvt_touch/force_touch_active + chown system system /sys/devices/platform/10d10000.spi/spi_master/spi0/spi0.0/input/nvt_touch/nvt_dttw_mode + chown system system /sys/devices/platform/10d10000.spi/spi_master/spi0/spi0.0/input/nvt_touch/nvt_fw_history + chown system system /sys/devices/platform/10d10000.spi/spi_master/spi0/spi0.0/input/nvt_touch/nvt_high_sensi_mode + +on property:vendor.all.modules.ready=1 && property:persist.sys.tap_gesture= + write /sys/devices/platform/10d10000.spi/spi_master/spi0/spi0.0/input/nvt_touch/nvt_dttw_mode 1 + write /sys/devices/platform/exynos-drm/primary-panel/force_power_on 1 + +on property:vendor.all.modules.ready=1 && property:persist.sys.tap_gesture=1 + write /sys/devices/platform/10d10000.spi/spi_master/spi0/spi0.0/input/nvt_touch/nvt_dttw_mode 1 + write /sys/devices/platform/exynos-drm/primary-panel/force_power_on 1 + +on property:vendor.all.modules.ready=1 && property:persist.sys.tap_gesture=0 + write /sys/devices/platform/10d10000.spi/spi_master/spi0/spi0.0/input/nvt_touch/nvt_dttw_mode 0 + write /sys/devices/platform/exynos-drm/primary-panel/force_power_on 0 + # Fingerprint on post-fs-data chown system system /dev/goodix_fp From 05dbf737a7de03d2239fe5ccf800e1955d394937 Mon Sep 17 00:00:00 2001 From: Super Liu Date: Mon, 23 May 2022 08:56:22 +0800 Subject: [PATCH 2/2] Add touchscreen and stylus input configuration file. Flip 270 degrees by design. Bug: 231385413 Test: TreeHugger build pass. Signed-off-by: Super Liu Change-Id: Ie43c354cf284d2e14ba47be24073a167e15d4229 --- NVTCapacitivePen.idc | 2 ++ NVTCapacitiveTouchScreen.idc | 1 + device-tangorpro.mk | 5 +++++ 3 files changed, 8 insertions(+) create mode 100644 NVTCapacitivePen.idc create mode 100644 NVTCapacitiveTouchScreen.idc diff --git a/NVTCapacitivePen.idc b/NVTCapacitivePen.idc new file mode 100644 index 0000000..39f5158 --- /dev/null +++ b/NVTCapacitivePen.idc @@ -0,0 +1,2 @@ +touch.orientationAware = 1 +touch.orientation = ORIENTATION_270 diff --git a/NVTCapacitiveTouchScreen.idc b/NVTCapacitiveTouchScreen.idc new file mode 100644 index 0000000..bcfcb54 --- /dev/null +++ b/NVTCapacitiveTouchScreen.idc @@ -0,0 +1 @@ +touch.orientation = ORIENTATION_270 diff --git a/device-tangorpro.mk b/device-tangorpro.mk index dde0741..cc46041 100644 --- a/device-tangorpro.mk +++ b/device-tangorpro.mk @@ -33,6 +33,11 @@ DEVICE_PACKAGE_OVERLAYS += device/google/tangorpro/tangorpro/overlay PRODUCT_SOONG_NAMESPACES += device/google/tangorpro PRODUCT_PACKAGES += WifiOverlayT6pro +# Touch files +PRODUCT_COPY_FILES += \ + device/google/tangorpro/NVTCapacitiveTouchScreen.idc:$(TARGET_COPY_OUT_VENDOR)/usr/idc/NVTCapacitiveTouchScreen.idc \ + device/google/tangorpro/NVTCapacitivePen.idc:$(TARGET_COPY_OUT_VENDOR)/usr/idc/NVTCapacitivePen.idc + # Init files PRODUCT_COPY_FILES += \ device/google/tangorpro/conf/init.tangorpro.rc:$(TARGET_COPY_OUT_VENDOR)/etc/init/hw/init.tangorpro.rc