NAME
mouse-udev - USB access for the mouse software
DESCRIPTION
G-Wolves has no Linux driver. The mouse is configured through a web app, mouse.xyz (alternate: mouse.fit). The app uses WebHID, so the browser opens the device node /dev/hidraw* directly. By default those nodes are root:root 0600 and the app finds no device. One udev rule fixes that.
NOTES
WebHID only exists in Chromium based browsers. No Firefox sadly.
For a wireless mouse the USB receiver is the device the browser talks to, not the mouse. The rule below matches on the vendor ID only, so it covers receivers, the mouse in cable mode and any other G-Wolves device.
TAG+="uaccess" makes logind (or elogind) put an ACL for the currently logged in user on the node. No group membership needed, and the access goes away when you log out.
Credit: Reddit post in r/MouseReview
EXAMPLES
Step 1: Check that the device is a G-Wolves one (vendor ID 33e4)
$ lsusb | grep -i wolves Bus 001 Device 007: ID 33e4:0017 G-Wolves G-Wolves 8K Receiver Bus 001 Device 008: ID 33e4:6817 G-Wolves G-Wolves HSK Pro 2.0 8K Receiver-N
Step 2: Create the udev rule
$ sudo vim /etc/udev/rules.d/70-g-wolves.rules
SUBSYSTEMS=="usb", ATTRS{idVendor}=="33e4", MODE="0660", TAG+="uaccess"
Step 3: Apply without reboot
$ sudo udevadm control --reload $ sudo udevadm trigger --subsystem-match=hidraw --action=add
The trigger must target hidraw. Triggering usb re-runs the rules for the receiver only, not for its hidraw child nodes, and nothing changes.
Step 4: Verify
$ ls -l /dev/hidraw* crw-rw----+ 1 root root 243, 9 Sep 3 13:45 /dev/hidraw9 $ getfacl -p /dev/hidraw9 user:marc:rw-
Nodes belonging to the receiver show mode 0660 with a + (ACL present) and your user in the ACL. Now open mouse.xyz in Chromium, click connect and pick the receiver in the browser's device picker.
SEE ALSO
mouse-accel(1), gwolves-battery(1)