Skip to content

Instantly share code, notes, and snippets.

@benediktg
Last active February 6, 2022 22:34
Show Gist options
  • Save benediktg/e351baec1a8159c511c7cc213d70d64f to your computer and use it in GitHub Desktop.
Save benediktg/e351baec1a8159c511c7cc213d70d64f to your computer and use it in GitHub Desktop.
Disable touchscreen on ASUS Zenbook UX360CA
[Unit]
Description=Touchscreen deaktivieren
[Service]
ExecStart=/usr/local/bin/disable-touchscreen.sh
[Install]
Target=multi-user.target
#!/bin/bash
#
# This is the touchscreen ID on a ASUS Zenbook UX360CA. To find your device
# search for "Touch" in /proc/bus/input/devices
DEVICE="FTSC1000:00 2808:5112"
ev_device=$(
awk '
/"'"$DEVICE"'"/{ inside = 1 }
/Handlers=/ { if(split($0,part,"event"))event = part[2]+0 }
/^$/ { if(inside && event!="")print "/dev/input/event" event
inside = 0
event = ""
}' /proc/bus/input/devices)
if [ -n "$ev_device" ]; then
evtest --grab "$ev_device" > /dev/null
fi
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment