By plugging in a PNP device to a Windows PC I want to know if the device supports a feature of data transferring. I am majoraly interested in pushing some content to device. So, for example when I am plugging in a Windows Phone I can see over windows managment query that 5 new devices are added
Name: Windows Phone
CompartibleId: USB\MS_COMP_MTP, USB\Class_06&SubClass_01&Prot_01, USB\Class_06&SubClass_01, USB\Class_06
Name: WinUsb Device
CompartibleId: USB\MS_COMP_WINUSB, USB\Class_ff&SubClass_ff&Prot_ff, USB\Class_ff&SubClass_ff, USB\Class_ff
Name: WinUsb Device
CompartibleId: USB\MS_COMP_WINUSB, USB\Class_ff&SubClass_ff&Prot_ff, USB\Class_ff&SubClass_ff, USB\Class_ff
Name: WinUsb Device
CompartibleId: USB\MS_COMP_WINUSB, USB\Class_ff&SubClass_ff&Prot_ff, USB\Class_ff&SubClass_ff, USB\Class_ff
Name: USB Composite Device
CompartibleId: USB\DevClass_00&SubClass_00&Prot_00, USB\DevClass_00&SubClass_00, USB\DevClass_00, USB\COMPOSITE
How can I now get a glue that:
I will appreaciate any help even if you could just tell me a focused direction where I should continue my study/investigation.
I am looking at a generic way to work with devices. Desired implementation language is C#.
Firstly You can consult this codeproject it gives you details of Windows Device Drivers.
SharpUSBLib and HidLibrary are two widely used libraries you can even get a tutorial project with implementation here.
SharpUsbLib earlier version used to screw up systems.
Would prefer libusbdotnet.
If you have to work with an USB device (send requests, process responses), this library was the best solution I could find.
Pros:
Has all methods you need to work in synch or asynch mode.
Source code provided
Enough samples to start using it straight away.
Cons:
Poor documentation (it's common problem for open source projects). Basically, you can find just common description of methods in the CHM help file and that's it. But I still find provided samples and source code is enough for coding. Just sometimes I see a strange behaviour and want to know why it was implemented in this way and can't get even a hint... Seems unsupported any more. Last version was issued in Oct 2010. And it's hard to get answers sometimes.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With