|
From: <ti...@pr...> - 2009-07-26 06:16:02
|
On Fri, Jul 24, 2009 at 12:25:52PM -0400, Rick Lamanna wrote:
>
> Hello,
>
> On Windows, I can get a device path from
> SetupDiGetDeviceInterfaceDetail() and the path looks something like...
>
> \\\\?\\usb#vid_09db&pid_00f2#00000001#{e9c37f82-214c-4ede-afff-6b0c2c014
> 6ef}
>
> Can I get this device path from Libusb 1.0? I need to extract the
> 00000001 from this path
That device path is strictly a Windows implementation detail. The
parts of it have never been documented (although they can be reverse
engineered), and they might change at any time. You are making a mistake
by relying on it for any purpose.
In this particular case, that's the device's serial number, in the
serial number descriptor. You can fetch that using standard requests
on both Windows and Linux. In Linux, in fact, you can fetch this from
the sysfs files without using a driver of any kind.
--
Tim Roberts, ti...@pr...
Providenza & Boeklheide, Inc.
|