2021-12-28 02:54:26 -06:00
|
|
|
#!/bin/sh
|
2021-11-26 01:46:41 -06:00
|
|
|
|
2022-07-30 20:12:44 -05:00
|
|
|
# Use the official drivers instead. They're available now.
|
|
|
|
# Install the AUR package `huiontablet`
|
|
|
|
|
2022-05-09 23:39:54 -05:00
|
|
|
# **Steps for setting up the drivers of Huion Inspiroy H640P**
|
2021-11-26 01:46:41 -06:00
|
|
|
|
2022-06-13 19:15:54 -05:00
|
|
|
# Install the AUR package digimend-kernel-drivers-dkms-git
|
2021-11-26 01:46:41 -06:00
|
|
|
|
2022-05-09 23:39:54 -05:00
|
|
|
# Create /etc/udev/rules.d/00-usb-huion.rules with this content (to run it whenever the tablet is conencted):
|
2021-11-29 23:23:53 -06:00
|
|
|
# ACTION=="add", ATTRS{idVendor}=="256c", ATTRS{idProduct}=="006d", ENV{XAUTHORITY}="/home/sintan/.Xauthority", ENV{DISPLAY}=":0", OWNER=<user>, RUN+="/usr/local/bin/huion-tablet-mount"
|
2021-11-26 12:12:54 -06:00
|
|
|
|
2022-05-09 23:39:54 -05:00
|
|
|
# Create /usr/local/bin/huion-tablet-mount with this content :
|
2021-12-28 02:54:26 -06:00
|
|
|
# #!/bin/sh
|
2022-01-13 12:04:50 -06:00
|
|
|
#
|
2021-11-26 12:12:54 -06:00
|
|
|
# <location-of-this-script> & exit
|
|
|
|
|
2021-11-26 01:46:41 -06:00
|
|
|
# Make sure to install xf86-input-wacom (might have to restart)
|
2021-11-30 12:23:42 -06:00
|
|
|
# Add this script to autostart of your DE or .profile or somehow make it run at boot (so that it works in case the tablet is connected at boot)
|
2021-11-26 01:46:41 -06:00
|
|
|
|
2022-06-15 17:21:36 -05:00
|
|
|
if [ "$(xsetwacom --list | grep -c 'HID 256c:006d')" -ne "3" ]; then
|
2022-01-13 12:04:50 -06:00
|
|
|
echo "No supported devices found!"
|
|
|
|
exit 1
|
2022-01-10 21:58:08 -06:00
|
|
|
fi
|
|
|
|
|
2021-11-26 12:12:54 -06:00
|
|
|
sleep 1
|
|
|
|
|
2022-06-15 17:21:36 -05:00
|
|
|
xsetwacom --set 'HID 256c:006d stylus' Button 2 "2" # middle mouse button
|
|
|
|
xsetwacom --set 'HID 256c:006d stylus' Button 3 "3" # right mouse button
|
2021-12-02 11:36:32 -06:00
|
|
|
xsetwacom --set 'HID 256c:006d Pad pad' Button 1 "key +ctrl +s -s -ctrl" # save
|
|
|
|
xsetwacom --set 'HID 256c:006d Pad pad' Button 2 "key +alt +c -c -alt" # cycle colors in xournal++
|
|
|
|
xsetwacom --set 'HID 256c:006d Pad pad' Button 3 "4" # scroll up
|
|
|
|
xsetwacom --set 'HID 256c:006d Pad pad' Button 8 "5" # scroll down
|
|
|
|
xsetwacom --set 'HID 256c:006d Pad pad' Button 9 "key +ctrl +z -z -ctrl" # undo
|
|
|
|
xsetwacom --set 'HID 256c:006d Pad pad' Button 10 "key +ctrl +y -y -ctrl" # redo
|