On Sat, Sep 21, 2013 at 7:21 AM, Kano <libu...@iporg.org> wrote:
> Hi,
> I've been using usb for about a year on many devices but only using a
> single interface.
> Finally got some hardware that has 2 interfaces and the code I've written
> works on linux but fails on windows.
> Anyone know if there are special rules required for windows?
>
> Of course I'm using Zadig to set the windows driver to WinUSB.
> The first interface open is of course working.
>
> The code is basically:
> For a single interface chip (that always works on many linux/windows) it is:
>  libusb_get_device_list
>  libusb_get_device_descriptor
>  libusb_open
>  libusb_claim_interface 0
>
> Instead for a chip with multiple interfaces I am:
>  libusb_get_device_list
>  libusb_get_device_descriptor
>  libusb_open
>  libusb_claim_interface 0
>  libusb_get_device(interface 0 handle)
Why?
>  libusb_open
Why?

What if you remove the above two?

>  (libusb_claim_interface 1) <- never gets here
>
> This works on linux but fails on windows on the 2nd open (before claiming
> the 2nd interface) with:
> [ 1.209821] [00000f94] libusbx: debug [libusb_open] open 2.2
> [ 1.209821] [00000f94] libusbx: error [winusbx_open] could not open device
> \\.\USB#VID_0403&PID_8350&MI_00#6&2CE4DD9F&0&0000#{C8D1AB34-4B5C-488A-8194-08C26C1A05DA}
> (interface 0): [5] Access is denied.
>
> The code is in a github git and the pull request that has the changes for
> multiple interfaces is:
> https://github.com/ckolivas/cgminer/pull/492/
>
> I've tried this with libusbx-1.0.17.tar.bz2
> (and also with libusb-1.0.16-rc10.tar.bz2 that is in that git)
> Both give the same open fail - working on linux but failing on windows
>
> A full log up to the failures (at the bottom) can be seen here:
> pastebin.com/Rx9jmMnU
>


-- 
Xiaofan

------------------------------------------------------------------------------
LIMITED TIME SALE - Full Year of Microsoft Training For Just $49.99!
1,500+ hours of tutorials including VisualStudio 2012, Windows 8, SharePoint
2013, SQL 2012, MVC 4, more. BEST VALUE: New Multi-Library Power Pack includes
Mobile, Cloud, Java, and UX Design. Lowest price ever! Ends 9/22/13. 
http://pubads.g.doubleclick.net/gampad/clk?id=64545871&iu=/4140/ostg.clktrk
_______________________________________________
libusbx-devel mailing list
libusbx-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/libusbx-devel

Reply via email to