I am having a problem with Google Nearby and WiFi Direct.I am developing an Android application which will run on two Android devices simultaneously.
These devices are connected via Google Nearby and in the same time both Android devices need to be connected to Internet for some API calls.
But sometimes,Google Nearby enables Wifi Direct automatically and in that case the devices are unable to access the Internet for API calls,hence the requests are failing.
I am unable find a way to prevent Nearby API from using WiFi Direct as connection medium in Lenovo Tab 7 Essentials devices.
How to programmatically control Nearby connection like "not to use" WiFi Direct?
Kind regards..
Use P2P_CLUSTER; P2P_STAR is inherently disruptive.
P2P_CLUSTER will use Bluetooth and LAN to connect your devices, so expect slower speeds if you're not both connected to the same router.
P2P_STAR will use Bluetooth, LAN, and Hotspots to connect your devices, so it gets higher bandwidth but it can cause devices to disconnect from their Wifi network.