开发者

.NET API for HID (USB)? [closed]

开发者 https://www.devze.com 2022-12-29 23:48 出处:网络
Closed. This question does not meet Stack Overflow guidelines. It is not currently accepting answers.
Closed. This question does not meet Stack Overflow guidelines. It is not currently accepting answers.
开发者_如何转开发

We don’t allow questions seeking recommendations for books, tools, software libraries, and more. You can edit the question so it can be answered with facts and citations.

Closed 4 years ago.

Improve this question

Is there an API in .NET (C#) for using USB HID (human interface) devices?


HidLibrary wraps up all the P/Invoke calls for you. But no, it doesn't look there are any nice framework APIs for dealing with USB devices.


Here's mine little library for dealing with HID devices.

It might be useful, especially when you are trying to communicate using raw HID reports. I've also included a simple demonstration of how to use it.


There's nothing direct or high-level. There are some things you can do through the managed WMI API, but I've personally found a lot of WMI interaction with hardware to be cryptic at best and requiring a lot of trial-and-error to get it to do what you want.

Someone on The Code Project has developed a .NET component for USB HID you can try out that's probably going to fit the bill better than WMI.


I would suggest you follow this example instead. It was invaluable in getting me up and running with HiD dev in C#.


I suggest you start here: http://wiimotelib.codeplex.com/


Try looking at this: Simple HID Library. The main page has a list of other open source libraries.


Take a look at this library on Google Code:

C# USB HID driver


I was also searching for it. I'm using the code I found here: http://janaxelson.com/hidpage.htm

0

精彩评论

暂无评论...
验证码 换一张
取 消

关注公众号