Custom USB driver with libusb-wine does not work anymore since Wine >5

Questions about Wine on Linux
Locked
NarcoticV
Newbie
Newbie
Posts: 1
Joined: Tue Dec 27, 2022 6:32 am

Custom USB driver with libusb-wine does not work anymore since Wine >5

Post by NarcoticV »

Hi there,

I am using Wine to run an application called "Aerodrums", which requires access to a PSEye USB camera device with a custom Windows driver based on libusb.
I have had success in accessing and using the camera in this way using https://github.com/stanson-ch/libusb-wine (a libusb wrapper dll which allows indirect use of the host libusb) and Wine 5.7.

This method does not seem to work anymore on Wine 7.22 (and from what I heard others report, probably also not working since Wine 6.0).

I tried some libusb debugging tools from within a Wine 7.22 session and found that they still work - e.g. libusb can list the camera device and even open it and communicate with it directly. So in principle, libusb-wine still works in Wine 7.22. I suspect that rather, the problem is in loading the custom libusb-based Aerodrums Windows driver when the camera is connected. I suspect this also has to do with the fact that a Wineusb driver implementation has been added to Wine, which was not there yet in Wine 5.7.

I tried removing wineusb service entries from the registry, and also removing the wineusb.sys and wineusb.so to force not loading Wineusb. But the camera is still not detected by Aerodrums.

I was wondering if anyone knows:
  • Some ways I could look into this further? (So far, LIBUSB_DEBUG=4 and WINEDEBUG=+loaddll were useful, but I still don't see any details about which drivers are loaded for an USB device)
  • Any details about the Wineusb implementation which may explain why they may break USB device driver loading of this custom driver?
  • Any way forward? Perhaps I can substitute some files or configuration from Wine 5 to my newer Wine installation to get back to the old USB driver behavior?
Thanks in any case.
Locked