<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
<meta name="Generator" content="Microsoft Exchange Server">
<!-- converted from text --><style><!-- .EmailQuote { margin-left: 1pt; padding-left: 4pt; border-left: #800000 2px solid; } --></style>
</head>
<body>
<div>
<div>If you're trying to rewrite the Linux tools for the ultimarc u360, I've already done it- posted on github under andrewsil1/ultrastik tools.<br>
<div class="x_acompli_signature"><br>
_____________<br>
Andy</div>
<br>
</div>
<br>
<br>
<br>
<div class="x_gmail_quote">On Sun, Apr 19, 2015 at 9:15 PM -0700, "christopher.alan.becker@gmail.com"
<span dir="ltr"><<a href="mailto:christopher.alan.becker@gmail.com" target="_blank">christopher.alan.becker@gmail.com</a>></span> wrote:<br>
<br>
</div>
</div>
<font size="2"><span style="font-size:10pt;">
<div class="PlainText">Thanks Andrew and Charles for the responses.<br>
<br>
@Andrew: At least now I know I'm not crazy :)<br>
<br>
I'm working with a USB driver for a joystick that uses libhid. If I ever <br>
have to rewrite it, I will definitely go down the HIDAPI route.<br>
<br>
Much appreciated!<br>
<br>
<br>
~ Chris<br>
<br>
On 4/19/2015 9:18 PM, Andrew Silverman wrote:<br>
> My recollection is that this is already a known bug that was never officially patched, as evidently libhid has long since been considered obsolete in favor of newer HID libraries (<a href="http://www.signal11.us/oss/hidapi/">http://www.signal11.us/oss/hidapi/</a>).
I have the same change in my own code that still works with the existing library.<br>
><br>
> -----Original Message-----<br>
> From: libhid-discuss [<a href="mailto:libhid-discuss-bounces+andrewsi=microsoft.com@lists.alioth.debian.org">mailto:libhid-discuss-bounces+andrewsi=microsoft.com@lists.alioth.debian.org</a>] On Behalf Of christopher.alan.becker@gmail.com<br>
> Sent: Sunday, April 19, 2015 7:15 PM<br>
> To: libhid-discuss@lists.alioth.debian.org<br>
> Subject: [libhid-discuss] LIBHID: Latest SVN Trunk: hid_opening.c: hid_compare_usb_device(): product_id matched incorrectly<br>
><br>
> Hi:<br>
><br>
> I ran into a situation with libhid where a USB product ID of 0x0501 was matching on a USB device with a product ID of 0x0503. I narrowed it down in hid_compare_usb_device() to the line below:<br>
> -----<br>
> ((dev->descriptor.idProduct & match->product_id) == match->product_id)<br>
> -----<br>
><br>
> Tracing the values of the above, both match and dev descriptor, the values were showing correct (0x0501, 0x0503), but still evaluating as matched.<br>
><br>
> If I change the above code to just:<br>
> -----<br>
> (dev->descriptor.idProduct == match->product_id)<br>
> -----<br>
><br>
> Then the product ID's match correctly, and only 0x0501 matches 0x0501.<br>
> Any ideas on why 0x0503 would match 0x0501 on the original code?<br>
><br>
> Actual hex codes were set/used in the passed HIDInterfaceMatcher struct.<br>
><br>
> As a side note, the vendor ID did not experience this problem. Latest SVN trunk (2015-04-19).<br>
><br>
> Thanks.<br>
><br>
><br>
> ~ Chris<br>
><br>
> _______________________________________________<br>
> libhid-discuss mailing list<br>
> libhid-discuss@lists.alioth.debian.org<br>
> <a href="http://lists.alioth.debian.org/cgi-bin/mailman/listinfo/libhid-discuss">
http://lists.alioth.debian.org/cgi-bin/mailman/listinfo/libhid-discuss</a><br>
> <a href="http://libhid.alioth.debian.org/">http://libhid.alioth.debian.org/</a><br>
<br>
</div>
</span></font>
</body>
</html>