Re: [pyusb-users] pyusb and root permissions "ValueError: The device has no langid"

2016-08-23 Thread Karl Palsson
Tormod Volden wrote: > On Tue, Aug 23, 2016 at 3:05 PM, Jay Aurabind wrote: > > > > I just managed to get it working. Simply added an exception for the > > try block for ValueError: continue > > > > Is this an acceptable solution generally? Is there a point in asking > > pyOCD to take it ? > > I

Re: [pyusb-users] pyusb and root permissions "ValueError: The device has no langid"

2016-08-23 Thread Jay Aurabind
On 23 August 2016 at 21:08, Tormod Volden wrote: > On Tue, Aug 23, 2016 at 3:05 PM, Jay Aurabind wrote: >> >> I just managed to get it working. Simply added an exception for the >> try block for ValueError: continue >> >> Is this an acceptable solution generally? Is there a point in asking >> pyOC

Re: [pyusb-users] pyusb and root permissions "ValueError: The device has no langid"

2016-08-23 Thread Tormod Volden
On Tue, Aug 23, 2016 at 3:05 PM, Jay Aurabind wrote: > > I just managed to get it working. Simply added an exception for the > try block for ValueError: continue > > Is this an acceptable solution generally? Is there a point in asking > pyOCD to take it ? I would try to filter on vid/pid first. Ar

Re: [pyusb-users] pyusb and root permissions "ValueError: The device has no langid"

2016-08-23 Thread Tormod Volden
On Tue, Aug 23, 2016 at 3:02 PM, Jay Aurabind wrote: > On 23 August 2016 at 16:40, Tormod Volden wrote: >> It usually shouldn't try to retrieve descriptor strings from other >> devices than the ones targeted. The device descriptor (retrieved and >> cached by the OS) is usually enough to filter out

Re: [pyusb-users] pyusb and root permissions "ValueError: The device has no langid"

2016-08-23 Thread Jay Aurabind
On 23 August 2016 at 18:32, Jay Aurabind wrote: > On 23 August 2016 at 16:40, Tormod Volden wrote: >> On Tue, Aug 23, 2016 at 8:31 AM, Jay Aurabind wrote: >>> On 23 August 2016 at 02:18, Tormod Volden wrote: I am a bit confused here, did you really want to manipulate the root hub with p

Re: [pyusb-users] pyusb and root permissions "ValueError: The device has no langid"

2016-08-23 Thread Jay Aurabind
On 23 August 2016 at 16:40, Tormod Volden wrote: > On Tue, Aug 23, 2016 at 8:31 AM, Jay Aurabind wrote: >> On 23 August 2016 at 02:18, Tormod Volden wrote: >>> I am a bit confused here, did you really want to manipulate the root >>> hub with pyusb, or did something go wrong here? >>> >> >> Absolut

Re: [pyusb-users] pyusb and root permissions "ValueError: The device has no langid"

2016-08-23 Thread Tormod Volden
On Tue, Aug 23, 2016 at 8:31 AM, Jay Aurabind wrote: > On 23 August 2016 at 02:18, Tormod Volden wrote: >> I am a bit confused here, did you really want to manipulate the root >> hub with pyusb, or did something go wrong here? >> > > Absolutely not, only reason I wanted to try giving write permissi

Re: [pyusb-users] pyusb and root permissions "ValueError: The device has no langid"

2016-08-22 Thread Jay Aurabind
On 23 August 2016 at 02:18, Tormod Volden wrote: > On Mon, Aug 22, 2016 at 8:19 AM, Jay Aurabind wrote: >> Hi Tormod and Steve, >> >> Thanks for your responses. I tried running the pyocd-gdbserver with >> LIBUSB_DEBUG=9, and got the following[snipped]: >> >> libusb: debug [libusb_open] open 2.1 >>

Re: [pyusb-users] pyusb and root permissions "ValueError: The device has no langid"

2016-08-22 Thread Tormod Volden
On Mon, Aug 22, 2016 at 8:19 AM, Jay Aurabind wrote: > Hi Tormod and Steve, > > Thanks for your responses. I tried running the pyocd-gdbserver with > LIBUSB_DEBUG=9, and got the following[snipped]: > > libusb: debug [libusb_open] open 2.1 > libusb: error [_get_usbfs_fd] libusb couldn't open USB dev

Re: [pyusb-users] pyusb and root permissions "ValueError: The device has no langid"

2016-08-21 Thread Jay Aurabind
On 20 August 2016 at 21:53, Tormod Volden wrote: > On Sat, Aug 20, 2016 at 3:46 PM, Steven Michalske wrote: >> Here is a general answer for Linux. >> http://unix.stackexchange.com/questions/44308/understanding-udev-rules-and-permissions-in-libusb > > IMHO that link doesn't have the greatest answer

Re: [pyusb-users] pyusb and root permissions "ValueError: The device has no langid"

2016-08-20 Thread Tormod Volden
On Sat, Aug 20, 2016 at 3:46 PM, Steven Michalske wrote: > Here is a general answer for Linux. > http://unix.stackexchange.com/questions/44308/understanding-udev-rules-and-permissions-in-libusb IMHO that link doesn't have the greatest answer (or question). Probably the asking user failed to use gr

Re: [pyusb-users] pyusb and root permissions "ValueError: The device has no langid"

2016-08-20 Thread Steven Michalske
Permissions deal with your Linux configuration. Here is a general answer for Linux. http://unix.stackexchange.com/questions/44308/understanding-udev-rules-and-permissions-in-libusb You can google for libusb permissions for your distribution if this doesn't lead to a solution. > On Aug 20, 201

[pyusb-users] pyusb and root permissions "ValueError: The device has no langid"

2016-08-20 Thread Jay Aurabind
Hi, I am a user of pyOCD, and I am having an issue related to pyusb which is what the former uses for talking to the USB device. The situation is that I need to use pyOCD through an eclipse plugin. Eclipse launches pyocd-gdbserver and normal user. But it will only work if launched as root. My que