Like a lot of Chinese devices, my TEMPer clone creates two HID interfaces. This isn鈥檛 how TEMPer is supposed to work but this unit is a knock-off. It was purchsed from Amazon and I tried to get an authentic part (Got from Amazon. The brand looked right and it wasn鈥檛 the cheapest TEMPer, by far, but turned out to be a junky knock-off).
Right now, the app only works with root permission. I need to get it completely into the user space
Anyway, it creates two HIDRAW dev interfaces. The first one does not work. It responds on the second one. It always seems to show up on /dev/hidraw3 but I understand this cannot be counted on after re-plug, reboot, or other installs.
How can I create a udev rule that will allow my app to find the device (either scan with HIDAPI or libusb) and create symlink under /dev with user space access that my app can interface with?
Or, perhaps there is a better way?
I鈥檓 trying to write a driver that anyone can use with a knock-off TEMPer.
I鈥檝e previously found OpenRGB鈥檚 udev rules to be a really good example since there鈥檚 a bit of everything in there: https://openrgb.org/releases/release_0.9/60-openrgb.rules
But I think you鈥檇 want something like:
SUBSYSTEMS=="usb|hidraw", ATTRS{idVendor}=="REPLACE WITH USB VENDOR", ATTRS{idProduct}=="REPLACE WITH USB PRODUCT", TAG+="uaccess"Thank you. I really appreciate it, on both counts!
Thanks. He has the core done. It could have saved me some time. I鈥檓 quite a bit further along with auto discovery and a couple of minor conveniences.
If I can get it to install with a UDEV rule so it runs at user privilege level, it鈥檒l be all set and I鈥檒l push it into the AUR.