|Version 22 (modified by pbatard, 3 years ago) (diff)|
The aim of this project is to bring a Windows backend to the mainline libusb 1.0 version, so that libusb 1.0 can easily be used on Windows platforms.
The Windows backend is still in alpha stages. As of 2010.01.05, it should include the main libusb v1.0 features, apart from isochronous transfers (which is a limitation from the WinUSB Microsoft API).
The (initial and now dated) Windows backend is available in the winusb git branch.
For those not familiar with git, here are the git commands you can use to work on the winusb branch:
git clone git://git.libusb.org/libusb.git ; retrieve the main branch (if you don't have it already) cd libusb git branch winusb origin/winusb ; add the remote "origin/winusb" branch to your repository under the local name "winusb" git checkout winusb ; select "winusb" as your default development branch git pull ; to keep in sync with the remote tree
A separate svn repository for the more up-to-date work-in-progress (non-reviewed => very alpha) also exists at http://code.google.com/p/libusb-winusb-wip/.
To compile this source, pthread-win32 is also required.
To compile projects using libusb 1.0, you should then add "-lusb-1.0 -lpthread -lsetupapi -lole32" to your library dependencies.
Finally, access to your USB devices with libusb-winusb, you need the WinUSB driver for your device to be configured and installed on your platform.
- For convenience reasons, the development toolchain used for the Windows backend is MinGW and the target for the first stable release is XP and later Windows versions (including 64 bit Windows).
- The method of dealing with USB devices in the first release will be WinUSB only, with provisions for other access modes to be included later.
- Windows' handling of composite devices will be done with multiple WinUSB drivers (VID_####&PID_####&MI_##), descendants of the usbccgp.sys driver (Composite Generic Parent). For more info, see "2. How Windows handles a composite device" at http://www.cygnal.org/ubb/Forum9/HTML/001050.html.
- IOCTL_USB_GET_NODE_CONNECTION_INFORMATION appears to be broken in MinGW-w64 (x64 platforms).
- WinUSB does not support multiple concurrent applications (as per the WinUSB Howto whitepaper).
- WinUSB does not support isochronous transfers.
- automated WinUSB driver installation?
- hotplug detection
- device enumeration
- descriptors retrieval
- composite devices & interface selection
- poll and pipe
- control transfers
- bulk/interrupt transfers
- device reset
- transfer cancellation
Development's status log
- [2009.12.13 and later] Consult the Work-In-Progress Repository (SVN) or the Activity Log.
- Back on track after resubmission of git patches and timer related fixes.
- Paused while the changes below are broken down and incorporated into git. Then you can get latest updates from git.
- matching of libusb enumerated devices with WinUSB GUID devices (WIP)
- WinUSB driver cleanup & documentation.
- WinUSB generic device installation (x86 & x64)
- retrieval of device handles for use with WinUSB
- WinUSB init
- configuration descriptors retrieval
- initial possible API breakdown & more code cleanup
- Added clock_gettime() with hires timer detection for monotonic and GetSystemTimeAsFileTime?() (100 ns resolution) for realtime.
- Moved the USB 2.0 root hub caps detection into set_hcd_device_descriptor()
- First release with working lsusb enumeration
- How to Use WinUSB to Communicate with a USB Device.
Note that the inf file given in the howto has a typo. If you don't change SourceDisksFiles?.NTamd64 to SourceDisksFiles?.amd64, the driver installation will fail to copy the required DLLs on 64 bit systems...
- Using WinUSB for User-Mode to USB Device Communication
- WinUSB User-Mode Client Support Routines
- Microsoft's USB Core Team Blog (including resources on instrumenting the USB stack in Windows 7)
- additional information about Windows Co-Installers
(145.1 KB) -
added by pbatard 3 years ago.
Precompiled version of pthread-win32, for 32 and 64 bit platforms, /MT and /MD versions, with 64 bit patch applied (Orin Eman)
(345.5 KB) -
added by stuge 3 years ago.
libusb-pbatard.git 1ebd8c90 cross-compiled using x86_64-w64-mingw32
Download all attachments as: .zip