Hello:
I have read through quite a few posts and I'm not sure of the best way to handle this scenario. I have (2) Nvidia Shields connecting to the same PC. They will never connect at the same time. Ideally, I'd like to be able to use a game controller on either of the Shields and the PC. Here is where I am now:
1) 2 Licenses for the Shields
2) Separate Bluetooth dongles for each Shield and the PC
3) Separate controllers for each Shield and the PC
4) Everything has been paired on the PC 1 to 1 (1 specific controller to a specific Bluetooth adapter).
5) I am running the client as a service and, at the moment, "auto-use all devices" is enabled (but I have tried with this disabled too).
Everything works perfectly if only one Bluetooth adapter is plugged in at a time. Is there any way to make this work without having to constantly plug in and out the Bluetooth adapters? It's actually rather difficult for one of the Shields. There will never be more than one controller paired and in-use at the same time.
I thought I had this figured out through batch files on the PC (which could be run from the Shields) using the USE and STOP USING commands and this worked great in testing until I started rebooting machines, as the addresses being assigned changed. At the moment, both of my Shield adapters are actually assigned the same address (they are now both localhost.1002).
Any suggestions or ideas on how to create a more functional system? Although not ideal, I am OK with unplugging the adapter on the PC and starting/stopping the VH service if that is the only option (to use a controller on the PC itself), but I need to figure out something better with the Shields.
Thank you.
.
No its physically impossible to have more than one bluetooth adapter active in windows at a time.
Windows will either fail to see the new bluetooth adapter or it will disable the active one before enabling the new one.
its a limitation of windows. I noticed that a few years ago.
.
Michael:
I understand I can only have one active Bluetooth adapter at a time in Windows, but isn't there any method to change between them from the servers (Nvidia Shields in my case)? I only will be using one adapter at a time.
I think I was close, at one point the adapter plugged into Shield #1 had the address, localhost.1002 and the adapter plugged into Shield #2 had the address, localhost.1004. I was able to use a batch file that did a "STOP USING" the first adapter and USE the second adapter and it seemed to work fine (going back and forth).
Alternatively, if I have the client setup to "auto-use all devices" could I use the Android app manually and "turn it off" when done using the controller so that I could then go to the 2nd Shield and start using it?
.
In windows device manager, go to the bluetooth adapter and right click Properties->Disable. Does that allow the other to work ok?
.
Michael:
Yes, that works. However, I can also do the same thing from within the VirtualHere Client by right-clicking a device and making it in use or not. Only one device will work at a time, of course.
I'm just searching for a way to do the same thing I can do from the client interface (through batch files or from the Android server app's) so that I don't have to physically go to the computer every time I want to change from using one Shield to another. As I said before, it initially worked perfectly. I created batch files to change the in use device to Shield #1 or Shield #2 and added them to Nvidia GFE (so I can easily click them from the Shield). It worked fine too until the addresses changed. The fact that it worked leads me to believe that it's certainly possible to do this.
Is there a way to maybe address the hubs via their addresses instead of the devices plugged into the USB ports?
.
Thats weird then because if the bluetooth adapter is plugged into the same usb port on the shield the address should stay the same. Could you try putting the adapter in a different port on each shield so they arent using the same port on both.
Also the shield should have a unique hostname and not "localhost" so thats also incorrect, nvidia should have set that up on their android image but seems they didnt bother for some reason.
It looks like the hostname on android cant be set anymore directly by the user ( https://superuser.com/questions/408539/how-to-set-friendly-network-nameā¦ )
The device address is the server hostname and the numeric port. Since the sheild is changing the port number and doesnt have its hostname set correctly its causing trouble with the scripting with the duplicate address.
There is a way to override the hostname in virtualhere by using the "hostname" setting in the server config.ini file https://www.virtualhere.com/configuration_faq but i havent provided access to do that via the android app. I could add that i think in the next build in e.g a week or so.
First try the bluetooth adapter in the different port and see if that basically resolves the issue.
.
Hello Michael:
I did as you suggested and it did assign a different port number this time, but it doesn't actually work via command line or batch. I think having both servers called, "localhost" is causing the failure (on one of the two). Here is the result of vhui64.exe -t list.
Bedroom (localhost:7575)
--> BCM20702A0 (localhost.1002)
Family Room (localhost:7575)
--> BCM20702A0 (localhost.1003) (In-use by you)
Bedroom has the IP Address 192.168.1.110 (with port 7575) and Family Room is 192.168.1.105 (with port 7575). I think I will wait until you enable selection of server name for Android and try this again. For now I will can a Remote PC App and go into the VH Client on windows and manually enable/disable what I need to. It's not ideal but it is workable.
It is weird that I can easily toggle them on/off from the client GUI but not the client command line, so having the same server name doesn't cause an issue using the GUI.