These scripts, written in Python and automated with Selenium, automatically apply a performance profile (including motion sync, polling rate, DPI, etc.) when launching a Steam game on Linux, and switch to a power-saving profile when closing it.
yay -S chromium python python-seleniumlsusbnano /etc/udev/rules.d/99-mouse-mchose.rulesPaste the following line into the file, making sure to change your specific mouse Vendor ID and Product ID in the appropriate fields:
KERNEL=="hidraw*", ATTRS{idVendor}=="3837", ATTRS{idProduct}=="100b", MODE="0666", TAG+="uaccess"udevadm control --reload && udevadm triggerchromium --user-data-dir=$HOME/.config/chromium_profileOpen the MCHOSE webdriver website, pair your mouse and create two profiles, one called "Performance" and one called "Powersave":
www.mchose.com.cnCopy the URL you see in the address bar for your mouse and edit it in your scripts (example from MCHOSE A7 V2 ULTRA):
URL = "https://www.mchose.com.cn/#/detail?deviceName=MCHOSE+A7+V2+Ultra"python3 ~/Scripts/mouse.py Performance %command%; python3 ~/Scripts/mouse.py Powersave