2015-06-12 11:15 GMT-03:00 Matthias Grabowski <em...@mailbox.org>: > I don't know what you want me to do with > export PYUSB_DEBUG=debug >
This is an environment variable to define before running your script. You can also define inside your Python code before you import the pyusb modules. If you need further details, you might want to give a look in the tutorial [1] [1] https://github.com/walac/pyusb/blob/master/docs/tutorial.rst > > Am 12. Juni 2015 15:36:52 MESZ, schrieb Wander Lairson Costa > <wander.lair...@gmail.com>: >> >> 2015-06-12 9:20 GMT-03:00 Matthias Grabowski <em...@mailbox.org>: >>> >>> Hello guys, >>> >>> I'm new to this mailing list, pyusb and Linux in general. So sorry, if >>> some >>> of my questions may be a little stupid. I know my way around python, >>> though. >>> >>> Anyways, I got a raspberry pi with raspbian installed and I'm writing a >>> python script to read data from an air quality sensor that identifies >>> itself >>> as a HID to the OS. When I try to read or write data to/from the device >>> I >>> get a USBError: >>> Could not claim interface 0: device or resource busy. >>> >>> I think that happens because the os attaches a kernel driver to the >>> device. >>> Correct? >>> >>> In that case I found some code that tries to claim the interface: >>> if dev.is_kernel_driver_active (0): >>> dev.detach_kernel_driver(0) >>> >>> >>> usb.util.claim_interface (dev, 0) >>> >>> But there I get a NotImplementedError. Why? Whats wrong and what can I >>> do? >> >> >> >> Hi, >> >> Could you please run with logs (export PYUSB_DEBUG=debug) and post the >> result? >> > > ------------------------------------------------------------------------------ > > _______________________________________________ > pyusb-users mailing list > pyusb-users@lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/pyusb-users > -- Best Regards, Wander Lairson Costa ------------------------------------------------------------------------------ _______________________________________________ pyusb-users mailing list pyusb-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/pyusb-users