LibUsbDotNet 2.2.8
MonoLibUsb - [Libusb 1.0 API Library]
LibUsbDotNet on SourceForge

The MonoLibUsb Libusb-1.0 low-level API library is a complete implementation of Libusb-1.0.

Windows Requires the Libusb-1.0 windows backend driver. Uniux-like platforms Requires the Libusb-1.0 driver.
Getting Started with MonoLibUsb

Much of the official Libusb-1.0 API Documentation also applies to the .NET MonoLibUsb low-level API library. This is an excellent reference for both novice and advanced users. Users unfamiliar with Libusb-1.0 are encouraged to review the official documentation upon getting started.

Before using MonoLibUsb a MonoUsbSessionHandle must be created. A session handle is required for many of the library functions.

The MonoUsbProfileList is your starting point for discovering, querying and opening USB devices. See the Show Info Console Application Example.

The MonoLibUsb source code can be built as a standalone library, seperate from LibUsbDotNet. See the [BaseDir]\LibWinUsb\MonoLibUsb\MonoUsb.sln in the LibUsbDotNet source.

Migrating from the Libusb-1.0 C API to the MonoLibUsb .NET API

The MonoUsbApi functions have no "libusb_" prefix.and the naming convention is UpperCamelCase. For example, MonoUsbApi.GetConfiguration() instead of libusb_get_configuration().

Functions that deal with freeing, opening and closing (with the exception of asynchronous tranfers) are managed by a SafeContextHandle class. This ensures all unsafe Libusb-1.0 memory pointers get closed/freed.

The user is required to Free()()()() asynchronous transfers. Failure to do so will result in memory leaks.

The following functions do not exist in the MonoUsbApi:

Asynchronous transfers must be freed by the user with the Free()()()() method. Failure to do so will result in memory leaks.