[Libusbx-devel] Linux patches for 1.0.9 release
Xiaofan Chen
xiaofanc at gmail.com
Thu Mar 29 08:32:58 EDT 2012
On Thu, Mar 29, 2012 at 8:09 PM, Xiaofan Chen <xiaofanc at gmail.com> wrote:
> On Thu, Mar 29, 2012 at 3:32 PM, Hans de Goede <hdegoede at redhat.com> wrote:
>> I don't think we should worry about having a HID backend
>> for platforms which have a proper way to get full access
>> to USB devices from userspace. AFAIK the windows HID
>> backend was done to allow easy access to HID devices
>> through libusb without the need to mess with a driver,
>> under Linux for example messing with a driver is never
>> needed, and AFAIK the same goes for *BSD* and Mac OS X.
>>
>
> Not true for Mac OS X. There is no way to detach the
> kernel driver using a program. You can use a code-less
> kext to achieve the goal though but it is ugly.
>
> +++++
> http://www.libusb.org/#CurrentAPIversion:libusb-1.0
>
> On Mac OS X, if an interface driver included with the
> OS matches the characteristics of a device, that driver
> will seize the interface, and the driver cannot be detached
> by libusb, so libusb will not be able to use that interface.
> +++++
More details here. Nathan did not like the idea
and closed the ticket as invalid.
http://www.libusb.org/ticket/33
Also here.
http://www.libusb.org/wiki/FAQ#CanIcreateadriverlessdeviceusingHIDclass
"On Mac OS X you must install a codeless kext kernel driver and
then reboot, before you can communicate with the device."
On certain Mac OS X version, the code-less kext may
not work well.
> I believe it is not true for OpenBSD either. You may
> have to rebuild the kernel to disable HID (but enable
> mouse and keyboard). That was needed for older
> version of FreeBSD to access HID device using
> libusb. FreeBsd 8/9 may change that already but
> I am not that sure now.
For OpenBSD the price you pay is to lose your
USB mouse and keyboard in order to use libusb
(based on ugen driver).
http://www.apcupsd.com/manual/manual.html#platform-support
++++++
OpenBSD
(you will lose use of USB keyboard and mouse):
Disable: uhidev, ums, wsmouse, ukbd, wskbd, uhid
Enable: ugen
+++++
--
Xiaofan
More information about the libusbx
mailing list