USB3.0 Compatibility in VMWARE

Discussions about technology in general
Post Reply
leonana69
Beginner
Posts: 21
Joined: Wed Apr 27, 2016 9:43 am

USB3.0 Compatibility in VMWARE

Post by leonana69 »

I found that if I set the usb compatibility of the vmware to usb 3.0 (for a ubuntu 18.04), the process for close link will too slow (~20 seconds) compared to the usb2.0 compability (~3 seconds). After tracing the execution of the crazyflie-lib-python, I found it is the close() function for class Crazyradio that takes so long. The self.dev.reset() will take tens of seconds to return. I want to know how to solve this problem. :)
arnaud
Bitcraze
Posts: 2538
Joined: Tue Feb 06, 2007 12:36 pm

Re: USB3.0 Compatibility in VMWARE

Post by arnaud »

You can try to remove the div.reset() call. It was mostly done as a precaution and should not be required.
leonana69
Beginner
Posts: 21
Joined: Wed Apr 27, 2016 9:43 am

Re: USB3.0 Compatibility in VMWARE

Post by leonana69 »

arnaud wrote: Wed Nov 27, 2019 8:26 am You can try to remove the div.reset() call. It was mostly done as a precaution and should not be required.
It doesn't works, if I remove the reset(), the scripts like scan.py or ramp.py will work but I can't flash the firmware. During the flash, it shows the "usb.core ... Resource busy". But I finally find the solution: replace the

Code: Select all

self.dev.reset()
by

Code: Select all

usb.util.dispose_resources(self.dev)
, now it works.
arnaud
Bitcraze
Posts: 2538
Joined: Tue Feb 06, 2007 12:36 pm

Re: USB3.0 Compatibility in VMWARE

Post by arnaud »

That sounds great, thanks for writing back the solution!

I am creating an issue in the lib's github project (https://github.com/bitcraze/crazyflie-l ... issues/130) . If you want to do a pull-request please do! Otherwise, when I have time to look at it I can test and change it myself.
Post Reply