Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

embed HIDAPI directly MVS #377

Open
ulao opened this issue Feb 1, 2018 · 8 comments
Open

embed HIDAPI directly MVS #377

ulao opened this issue Feb 1, 2018 · 8 comments

Comments

@ulao
Copy link

ulao commented Feb 1, 2018

How is this done in MVS? I currently must have the hidapi.dll in my execute folder. How can I built it directly in to my application. Idea being to avoid winusb. winusb is interfering in some way and I'm hoping this will fix that.

@mcuee
Copy link

mcuee commented Apr 8, 2018

What is MVS? And HIDAPI has nothing to do with WinUSB.

@ulao
Copy link
Author

ulao commented Apr 8, 2018

MVC = Microsoft visual studio.
Winusb on window 10 some how gets attached to a hid driver. I do not understand this at all, nor do I understand how it occurs. All I know is when you look at the install drivers with a program called Zadig you can see what driver has hidusb and what has winusb. Whenever its winusb the feature report just do not work right. The hope here was that embedding it would force it. Though as it turns out zadig allow one to switch and thus fixing the issue. So this topic can be left alone if unless anyone can provide details on how to embed with visual studio, that is still helpful even though it does not address my concern.

@mcuee
Copy link

mcuee commented Apr 8, 2018

Maybe you can name a few device behave this way. Are they USB composite device (HID + WinUSB)? If it is WinUSB, then you can not use HIDAPI.

As you mentioned, Zadig can switch driver. Technically you can use WinUSB driver for HID device but then it will lose the function as an HID device and not able to use HIDAPI.

@mcuee
Copy link

mcuee commented Apr 8, 2018

To use with visual studio, you can add the header file and the library to your project.

@ulao
Copy link
Author

ulao commented Apr 8, 2018

"As you mentioned, Zadig can switch driver. Technically you can use WinUSB driver for HID device but then it will lose the function as an HID device and not able to use HIDAPI." - Yes that is what I see. In my case this is a HID device not winusb. I'm not sure why win10 is using winusb with it but it does not in all cases.

@mcuee
Copy link

mcuee commented Apr 8, 2018 via email

@ulao
Copy link
Author

ulao commented Apr 8, 2018

Just a game pad with a huge force feedback descriptor almost identical to the ms side winder.

@mcuee
Copy link

mcuee commented Apr 11, 2018

I believe Windows will not use WinUSB for an HID device unless user switch the driver to WinUSB.

There is also a possibility that the device has two interfaces, one is HID and use the HID driver. The other is a custom interface using WinUSB.

erikolofsson pushed a commit to Malterlib/hidapi that referenced this issue May 14, 2022
`kIOMasterPortDefault` is deprecated since macOS 12.0.
One alternative is to use named constant `kIOMainPortDefault` which is not available before macOS 12.0.

Both named constants are just an alias for `NULL`, so it is simpler to use it directly instead.

Fixes: signal11#377
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants