How do I find out which hiddev device belongs to a particular vendor or product id?
The device I need appears as /dev/usb/hiddevX where X depends on the order other devices was plugged in.

lsusb -v -d [vendor]:[product] looked promising, but its hard to tell if anything in the output really points to the device file.

Maybe something under /proc/ could be helpefull, but where to look?

I could read the systemd journal I guess, but that seems kind of dirty..

Any ideas appreciated.

Edit: Just to clarify, I'm looking for a clean, straight forward method that I can call from Python, shell etc. Grepping logs could certainly work, but there has to be something better than that?

  • grep dmesg for /dev/usb/hiddevX, you can grep you way to vendor:product – RiddleMeThis Mar 24 at 9:59

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.