


If someone can please just tell that on what operating system he is using what USB Library and what version of PyUSB I think it will solve my problems. Now the pyusb library should be installed in Python Version 3.4 instead of (or in addition to) the default version, which is version 2. python pyusb.3 answers Top answer: There are several more fields available in the device objects (in your code these are named.
#Pyusb get file path install#
That's why I get Device (dev.filename) string empty. Step 3: Install the pyusb library into Python version 3.4 command line: sudo pip3.4 install pyusb. :slightsmile: Im trying to get a device connected by USB (an indoor rower. How do I get these informations is it a query to the USB device using pyUSB or is it a query to sys Thanks for any help. Second, I guess there was some UID of every USB device, or I should use both Vendor or Product id?ĮDIT: Apparently I have some setup issues, I think I am using wrong USB Library. I am assuming it is the /dev/ttyACM0 etc part. The problem is I don't get desired output, will paste one example: įirst I don't get filename, it's most important to me. Print " idProduct: %d (0x%04x)" % (dev.idProduct, dev.idProduct) Printcap printers filename is the full path to the device file name. Print " idVendor: %d (0x%04x)" % (dev.idVendor, dev.idVendor) I want to get UID Device Name (ex: SonyEricsson W660), path to device (ex: /dev/ttyACM0)Īnd also what would be the best Parameter out of above info to be used as identifying the device whenever it's connected again? (UID?)ĪTM I have this code (using pyUSB) busses = usb.busses() How can we query connected USB devices info in Python?
