I'm facing two different problems with my USB device that uses WINUSB ( Class 0xFF, Subclass 0x00 )
I have three different small apps, the UWP CustomUsbDeviceAccess from Microsoft samples modified to connect to my Custom USB Device, My UWP App i'm tryng to write, and a WPF sample program I wrote too. The three apps were working without problems, in my two computes, connecting to my WINUSB Custom Device, but in the middle of some windows/vs2017 upgrade, the two UWP Apps stopped working on both computers. The problems are different in both computers.
The first computer, with W10 Pro Fall Creators Update. The problem is, after calling this function:
this.device = await UsbDevice.FromIdAsync(devId);
it always returns null. And if I try to run this:
var deviceAccessStatus = DeviceAccessInformation.CreateFromId(devId).CurrentStatus;
it raises the excpetion
the system cannot find the file specified 0x80070002
The second computer, with W10 Home Insider Preview Build 17025.rs_prerelease.171020-1625, the problem here is that boths UWP App, CustomUsbDeviceAccess from Microsoft and my own UWP App, freeze entering this line:
var DeviceWatcher = DeviceInformation.CreateWatcher(DeviceSelector);
These codes were working, i don´t undertand what´s wrong now. My USB device works in both computer with the small WPF Desktop App I wrote. I tested the same three apps with other similar USB commercial device I have in hand ( same class/subclass, winusb too), and I have the same results, so I discarded the problem is in my device or something wrong in the driver installation process.
I saw another user had a similar problem in this post, but sadly, didn't find the solution.
I solved the problem in the second computer: I re-installed the Windows 10 stable version ( Fall Creators ). In this second computer, my UWP App works and connect to my USB Device as expected.
In the first computer, my main wokstation, I think the problem is due to an error in the installation of the driver or in some permission. I would like to know where my error is; I imagine that this could be a problem in the installation in the clients that I would like to avoid
Related
We are looking to access and use Bluetooth profiles in our WPF application using C# in Visual Studio 2017.
Issue details:
Platform: Windows 10 Pro - version 1803.
Issue brief: We are trying to access Bluetooth profiles via desktop(c#) of connected phones, however on windows 10 the profile show enable but the profiles are not working eg: HFP connects, however, the voice is not heard
We have tested this on following Bluetooth devices:
1.Bluetooth CSR 4.0 Dongle (CSR8510 A10) (Note: this Bluetooth connects and show HFP and works as expected, however, the Bluetooth does not show on the device list and hence we cannot connect programmatically using c#)
2.IOGEAR's Bluetooth 4.0 (Model GBU521W6) (Shows on device list and our application can detect a device, however, HFP is not working as expected both from the application or from normal device section)
Required Profiles:
1.Hands-Free Profile (HFP)
2.Message Access Profile (MAP)
3.Phone Book Access Profile (PBAP)
We have Already Tried with following:
Updating drivers
Tried uninstall install many times
Used android, ios, and windows phone's
Side note: Our application with same code works on windows 7
MAP abd PBAP is not a problem because both are OBEX based (which is RFCOMM).
However there can be some problems with HandsFree. It works great with BlueSoile drivers. But with standard microsoft may not work.
The first step it to use BluetoothSetServiceState with HFP UUID to tell windows to install drivers for your device's HFP profile. If function succeed you should see 2 audio devices appeared in your system: one is Inout and other is Output. You can find them using any media API (DirectSound, legacy API).
To be able to work with PBAP and MAP you need anyhow connect to your device through RFCOMM. WinSock or any other way is good.
Please note that the method above works only with Microsoft Bluetooth drivers. Other drivers (BlueSoleil, Toshiba) have absolutely different API so you have to add it into your application if need to support them.
Or you can simple take a look on BluetoothFramework
My Xamarin.Forms application works on my Nexus 5 device and multiple Android emulators I tested it on. However, when I tried testing it on other real physical devices - Galaxy Note 4 and LG G4, the device restarts the moment I click on the app to open. I don't know what makes this happen or how to find a log/crash report/anything of that sort in order to find out what the issue is and would like to get some help with that.
I'm working on a Windows Universal App that communicates with BluetoothLE heart rate monitors. As of yesterday (related to a windows update, I'm thinking), things appear to be suddenly broken.
Specifically:
When I first pair a HRM device to my computer (in windows settings, not through their API), my app sees the device just fine, and can subscribe to notifications from the GATT Heart Rate Service (through a method close to the code here, in the C# sample.)
In all subsequent connection attempts, the app will detect the device normally, and indicate that it is paired to windows, but the HRM in question has a Device.ConnectionStatus of BluetoothConnectionStatus.Disconnected, and never reports hear rate updates.
If you run the MSDN sample above, you'll see the same thing, even though it's a Windows 8/8.1 sample.
This leaves me in a really sticky spot - I need to be able to communicate with these devices, but as of right now, it appears that I can only do so consistently unpairing the device from windows, and repairing it. That is obviously not acceptable.
I've found a few articles that seem to be tangentially related, but none seem to have found a solution. Help!
I have a Win PC (8.1) and an Android phone (5.1); the phone is locked. I have a C# app on the PC that does sensing, and alerts when one or more of several events occur. I need to see those alerts on my phone, and although some delay is OK, it needs to happen pretty quickly.
I'm not fussy about how the phone handles the alerts - visually, audibly, or whatever - so long as I'm made aware of them somehow. Any thoughts?
Take a look at the app called 'Tasker'. Also, you can connect remotely to your computer using Google's app called Remote Desktop. Hope you find a way, this is very interesting.
Note : I'm using VS2008 and I'm working on windows 7.
I'm developping a Windows CE application which will run on a Motorola MC3000 device with a WinCE 5.0 like OS .
I tried to use ActiveSync in order to make the test with the selected device possible but it doesn't work on win7, so I tried to find another tool and I found Windows Mobile Device Center based on this discussion .
So Now I can browse with the device but unfortunately I can not test with it : The device have a "santech" application installed and can not kill the app. (even when I reboot the machine, the autorun lunch the app. automatically). Also when I try to deploy my application on the device it return error reports ; sometimes "no disc space" sometimes "the .exe can not be found".
I'm really stucked.
Can some one help me with this, I will be really gratefull.
Sounds like the debugger is attaching just fine, it's just unable to either fully copy the app and dependencies, or there's not enough memory to execute it.
If you can browse the device, you can stop the "santech" app from running. You just have to determine what is launching it. It might be a shortcut in the \Windows\Startup folder. It might be through a registry entry at \[HKLM\Init\]. IIRC, Symbol devices also support a *.run file in the \Application\Startup folder, so check that as well.
One of those is launching the app, so you can eliminate that if you desire.
Next, check the available memory on the device by looking in the Control Panel under System->Memory and adjusting the slider to provide more storage space. If there's not enough Storage Memory to store your app, you might try changing the deployment directory (under Project Properties->Device) to push the app binaries to non-volatile storage of some sort (on-board Flash, SD card, etc), if the device has it.
If you don't have enough Program Memory to run your app, you might be out of luck. Try killing processes to free up some space and playing with the memory allocation slider.
You can debug from inside VS2008 as well. You'll need to tell it to connect to a device as it automatically sends it to a emulator. To do that you need to select Windows CE Device from the dropdown list found in the "Devices" toolbar (To enable go to View, Toolbars and select Devices). Then hit F5 and it should start up on your device. You might get a couple of pop-up boxes that contain a list of devices; make sure these are set to Windows CE Device as well.
This handy page on MSDN should provide the information you need also.