0

As a user, I need to be able to read the langid of a USB device.

Run as my user, the output of lsusb -v it gives me limited information on all USB devices (note second line)

Bus 001 Device 002: ID f4ec:ee3a Atten Electronics / Siglent Technologies 
Couldn't open device, some information will be missing
Device Descriptor:
  bLength                18
  idVendor           0xf4ec Atten Electronics / Siglent Technologies
... etc, edited for clarity, this is the exact device I am trying to control

When run as root, the output is more complete

Bus 001 Device 002: ID f4ec:ee3a Atten Electronics / Siglent Technologies 
Device Descriptor:
  bLength                18
  idVendor           0xf4ec Atten Electronics / Siglent Technologies
... etc

It is now able to open the device and gives much more info. I'd like to understand, what are the required permissions are so that I am able to open this device as my own user?

Currently, my user has been added to the dialout and tty groups but that doesn't seem to have helped. I have found solutions that involve simply opening up all ports to read/write access but this is insecure and I know there has to be a proper way of accomplishing this.

The further goal, if it helps, is to use Python and PyVISA to communicate with lab instruments over USB and that's where this requirement is from.

I'm currently on Ubuntu 18.04, the final code will be running on Raspbian. If that might change things, I'd like to understand why if possible.

  • Who are owner/group of files under /dev/bus/usb/? Try to have your user in a group owning those files. – Patrick Mevzek Jun 5 at 17:28
  • They are owned by root, which might explain why I am having so much trouble. It's hard to believe that you need root to open a USB device, I feel like there is still be something I am missing. Thank you for the tip, it does move me a little farther through my mystery. – M Barnard Jun 6 at 20:56

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.