libusb0-dll:err

Post here to get support
Post Reply
Danish20
Beginner
Posts: 5
Joined: Wed Dec 30, 2015 9:22 am

libusb0-dll:err

Post by Danish20 »

Hello,
I have Crazyflie 2.0 setup on Windows 7 64bit using client and its working fine. I tried running through python client and it's also working fine.
But when I try to run the example ramp.py it says

Code: Select all

[b]Connection to radio://0/80/250K failed: Couldn't load link driver: [Errno None] b'libusb0-dll:err [set_configuration] could not set config 1: win error: The parameter is incorrect.\r\n'[/b]
I am not getting how to resolve this as the python client from source is working fine and connecting but when running ramp or any other example same error is occurring.

Below is the whole error statement It is able to scan the crazyflie but not connecting

Code: Select all

Scanning interfaces for Crazyflies...
Crazyflies found:
radio://0/80/250K
ERROR:cflib.crazyflie:Couldn't load link driver: [Errno None] b'libusb0-dll:err [set_configuration] could not set config 1: win error: The parameter is incorrect.\r\n'

Traceback (most recent call last):
  File "../lib\cflib\crazyflie\__init__.py", line 218, in open_link
    link_uri, self._link_quality_cb, self._link_error_cb)
  File "../lib\cflib\crtp\__init__.py", line 91, in get_link_driver
    instance.connect(uri, link_quality_callback, link_error_callback)
  File "../lib\cflib\crtp\radiodriver.py", line 116, in connect
    self.cradio = Crazyradio(devid=int(uri_data.group(1)))
  File "../lib\cflib\drivers\crazyradio.py", line 122, in __init__
    self.dev.set_configuration(1)
  File "D:\Python34\lib\site-packages\usb\core.py", line 554, in set_configuration
    self._ctx.managed_set_configuration(self, configuration)
  File "D:\Python34\lib\site-packages\usb\core.py", line 92, in managed_set_configuration
    self.backend.set_configuration(self.handle, cfg.bConfigurationValue)
  File "D:\Python34\lib\site-packages\usb\backend\libusb0.py", line 440, in set_configuration
    _check(_lib.usb_set_configuration(dev_handle, config_value))
  File "D:\Python34\lib\site-packages\usb\backend\libusb0.py", line 387, in _check
    raise USBError(errmsg, ret)
usb.core.USBError: [Errno None] b'libusb0-dll:err [set_configuration] could not set config 1: win error: The parameter is incorrect.\r\n'
Danish20
Beginner
Posts: 5
Joined: Wed Dec 30, 2015 9:22 am

Re: libusb0-dll:err

Post by Danish20 »

Update:

Hey I somehow resolved it. ;) It is not because of crazyradio or libusb it's because of updated python dependencies. It's required to use specific dependencies even if new updates are available.

Below are the details for others who are facing the same details

Windows 7 SP1 64Bit
Python 3.4.3
PySDL2 0.93
Numpy 1.8.1
pip 7.1.2
pyonewire 0.5.1
pyqtgraph 0.9.1.
Pyusb 1.0.0.a3
pyzmq 15.1.0
scipy 0.61.1

and driver was libusbk ,

Because of pyusb and libusb this error occurred I guess.
chad
Expert
Posts: 555
Joined: Sun Sep 28, 2014 12:54 am
Location: New York, USA
Contact:

Re: libusb0-dll:err

Post by chad »

Glad to hear you solved this and thanks for posting the versions of the dependencies that worked for you!
Crazyflier - my CF journal...
4x Crazyflie Nano (1.0) 10-DOF + NeoPixel Ring mod.
3x Crazyflie 2.0 + Qi Charger and LED Decks.
Raspberry Pi Ground Control.
Mac OS X Dev Environment.
Walkera Devo7e, ESky ET6I, PS3 and iOS Controllers.
Post Reply