On 2012.10.29 18:47, Peter Stuge wrote:
> While the Windows-specific HID class code for emulating USB transfers
> over HID in libusbx does use the same OS-native API as HIDAPI (maybe
> even some code from HIDAPI?)

 From the copyright notice: "HID Reports IOCTLs inspired from HIDAPI by 
Alan Ott".
That's the only part of HIDAPI we "reused". Instead, the bulk of the HID 
code came from libusb-win32 v1, where Stephan Meyer had added support 
for the HID driver.

> it isn't (currently) as portable.

It's only meant for Windows, so of course it's not meant to be portable, 
even more so as it isn't needed on Linux. Windows adds a limitation for 
HID device access in libusbx so we work around it. As an OS specific 
workaround, portability is a non-issue.

> I don't know what the longer-term plan in libusbx is regarding HID
> class support. One idea would be to integrate HIDAPI wholesale in
> order to emulate USB transfers over HID also on Linux and OS X.

Except libusb/libusbx has no need to emulate USB transfer over HID on 
Linux. It can just perform generic USB transfers against the device. 
*This* is the behaviour we are bringing to Windows, because this is what 
we expect our users to want, and no matter how much HIDAPI is being 
promoted, past records indicate that it is indeed the case.

> I
> don't believe there were suggestions in any direction so far, but
> I think using more of HIDAPI in libusbx would be a logical extension.

Considering that libusbx is the lower level library here, theoretically, 
the most logical thing would be for HIDAPI to rely on libusbx rather 
than the opposite (though there are some challenges, but those will 
manifest themselves either way).

Anyway, HID support for libusbx Windows, as a means of emulating generic 
USB access for HID devices, is here to stay. Just as we did in the past, 
we will fix issues as we discover them on the grounds that, unlike 
libusb, we don't see it as beneficial to force users to go through 2 
libraries when one should do.

Regards,

/Pete

------------------------------------------------------------------------------
The Windows 8 Center - In partnership with Sourceforge
Your idea - your app - 30 days.
Get started!
http://windows8center.sourceforge.net/
what-html-developers-need-to-know-about-coding-windows-8-metro-style-apps/
_______________________________________________
libusbx-devel mailing list
libusbx-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/libusbx-devel

Reply via email to