Universal Windows Platform (UWP)
A Microsoft platform for building and publishing apps for Windows desktop devices.
2,522 questions
This browser is no longer supported.
Upgrade to Microsoft Edge to take advantage of the latest features, security updates, and technical support.
I tried to connect USB devices in uwp according to the instructions in MSDN, and also tried to download the sample provided by MSDN to connect devices, but I still couldn't connect to usb devices.
What is the possible cause of this problem? Any directions or suggestions?
Here is part of my code:
Package.appxmanifest:
<Capabilities>
<DeviceCapability Name="usb">
<Device Id="vidpid:1532 0a14">
<Function Type="name:vendorSpecific"/>
<!--The following statement also tries-->
<!--<Function Type="classId:ff * *"/>-->
</Device>
</DeviceCapability>
</Capabilities>
C# code:
string aqs = UsbDevice.GetDeviceSelector(0x1532, 0x0A14);
var finder = DeviceInformation.FindAllAsync(aqs).GetResults();
//finder.Count always equals 0
About the registry for this device:
Additional, This is actually an Xbox gamepad, and I can see the device on the device manager. The device path is: \?Usb#vid 1532&pid 0a14#0000c96c27402af7#{guid}. but what makes me confused is that the driver is dc1-controller.sys, not Winusb.sys, and the inf is dc1-controller.inf.
And I can get the device ID using
DeviceInformation.FindAllAsync(string.Empty)
, but usingUsbDevice.FromIdAsync(item.Id)
always returns null, I don't know why.Hi, I have replied you on stackoverflow, please check it.
anon@userSanon@useroanon@userranon@userranon@useryanon@USER ,anon@USER anon@userianon@USER anon@userfanon@useroanon@userranon@userganon@useroanon@usertanon@USER anon@usertanon@useroanon@USER anon@usercanon@userhanon@usereanon@usercanon@userkanon@USER anon@userianon@usertanon@USER ,anon@USER anon@userIanon@USER &anon@USER #anon@user3anon@user9anon@USER ;anon@userlanon@userlanon@USER anon@userranon@usereanon@userpanon@userlanon@useryanon@USER anon@useryanon@useroanon@useruanon@USER anon@usertanon@userhanon@usereanon@userranon@usereanon@USER
Sign in to comment