Pyusb on windows 8.1 – no backend available – how to install libusb?
Question:
Working on pyinstaller 3.1, python 2.7.9, and tkinter.
Try to use pyusb instead of pyserial, but no backend available. Looking into Pyusb on windows – no backend available, PyUSB ValueError: No backend available, USB interface in Python, and so on, it seems that I need to install libusb. But when I run “import usb” and “import usb.core” under python, no errors. I have no idea how to install it and how to use it in my project, how to tell my project where libusb is.
what I did:
(1) download libusb-win32-bin v1.2.6.0 (01/17/2012)
(2) x86libusb0_x86.dll renamed to libusb0.dll
(3) On 64 bit, put it to Windowssyswow64libusb0.dll.
On 32 bit, Installs to Windowssystem32libusb0.dll.
Still not working…
By the way, I would like to finish one standalone python-based windows app. I do not hope others to install libusb to run my app. What to do?
Answers:
I downloaded latest libusb windows binaries from here:
http://sourceforge.net/projects/libusb/files/libusb-1.0/libusb-1.0.20/libusb-1.0.20.7z/download
then I copied libusb1.dll according to this: when you are on 64-bit Windows,
MS64dlllibusb-1.0.dll must be copied into C:WindowsSystem32 and
(for running 32-bit applications that use libusb)
MS32dlllibusb-1.0.dll must be copied into C:WindowsSysWOW64.
and then I copied libusb1.lib from binaries to lib dir in python directory and now pyusb works for me. hope it helps.
No need to copy and paste the libusb-1.0.lib file to your C drive, just do the things with libusb-1.0.dll file. It works for me.
Working on pyinstaller 3.1, python 2.7.9, and tkinter.
Try to use pyusb instead of pyserial, but no backend available. Looking into Pyusb on windows – no backend available, PyUSB ValueError: No backend available, USB interface in Python, and so on, it seems that I need to install libusb. But when I run “import usb” and “import usb.core” under python, no errors. I have no idea how to install it and how to use it in my project, how to tell my project where libusb is.
what I did:
(1) download libusb-win32-bin v1.2.6.0 (01/17/2012)
(2) x86libusb0_x86.dll renamed to libusb0.dll
(3) On 64 bit, put it to Windowssyswow64libusb0.dll.
On 32 bit, Installs to Windowssystem32libusb0.dll.
Still not working…
By the way, I would like to finish one standalone python-based windows app. I do not hope others to install libusb to run my app. What to do?
I downloaded latest libusb windows binaries from here:
http://sourceforge.net/projects/libusb/files/libusb-1.0/libusb-1.0.20/libusb-1.0.20.7z/download
then I copied libusb1.dll according to this: when you are on 64-bit Windows,
MS64dlllibusb-1.0.dll must be copied into C:WindowsSystem32 and
(for running 32-bit applications that use libusb)
MS32dlllibusb-1.0.dll must be copied into C:WindowsSysWOW64.
and then I copied libusb1.lib from binaries to lib dir in python directory and now pyusb works for me. hope it helps.
No need to copy and paste the libusb-1.0.lib file to your C drive, just do the things with libusb-1.0.dll file. It works for me.