Skip to content

Instantly share code, notes, and snippets.

@ardera
Last active May 24, 2025 12:07
Show Gist options
  • Save ardera/ae9e887dd88ec99b2f90306c742aa7b0 to your computer and use it in GitHub Desktop.
Save ardera/ae9e887dd88ec99b2f90306c742aa7b0 to your computer and use it in GitHub Desktop.
Setup Chalkboard Electronics 7" hwdb properties
#!/bin/sh
set -eu
if [ $(id -u) -ne 0 ]; then
echo "Script must be run as root."
exit 1
elif [ ! -d "/etc/udev/hwdb.d" ]; then
echo "Directory /etc/udev/hwdb.d was not found. Check your system is running hwdb."
exit 1
fi
cat <<EOF >/etc/udev/hwdb.d/61-evdev-local.hwdb
evdev:input:b0003v04D8pF723*
EVDEV_ABS_00=::8
EVDEV_ABS_01=::8
EOF
systemd-hwdb update
udevadm trigger
@ardera
Copy link
Author

ardera commented May 21, 2025

Usage:

curl --proto '=https' --tlsv1.2 -sSf https://gist.githubusercontent.com/ardera/ae9e887dd88ec99b2f90306c742aa7b0/raw/973bd300b7365f325fa130c0ce90c9eadea7147e/setup-chalkboard-hwdb.sh \
  | sudo sh

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment