Connecting to multiple beacons at the same time

Hi there,
I wrote an Android application that connects to a beacon and then changes a setting every time the user taps a button.

With one beacon, everything works fine: I establish the connection once, and then repeatedly save the setting with a SettingsEditor object.

Now I’m trying to mantain a connection with 2 beacons at the same time: I can connect with the first, but when I try to connect to the second I get the following message in the debug console: “com.estimote.sdk.connection.internal.DeviceConnectionInternal$2.onConnectionError:204 Timeout while connecting to beacon”.

So, my question is: is it possible to keep a connection to two or more beacons at the same time, in order to update their settings?
I would like to avoid closing the first connection and open the second one every time.

I’m testing the app on a Nexus 5X with Android 7.0; the beacons are Location Beacons (hardware revision F3.3 and OS 4.9.0)…

Cheers
Cristiano

No news?
It’s a simple question: can we connect to two or more beacons at the same time, or not?

The Estimote SDK for Android documentation (https://github.com/Estimote/Android-SDK/blob/master/DOC_deviceConnection.md) states that: “Once you have your ConfigurableDevice object, you want to acquire DeviceConnection for it. To do that, you need to be connected to DeviceConnectionProvider. It creates simple service that lets you handle multiple connections at once.”

But, according to my tests, multiple connections don’t work…

Technically you can, but from my experience many devices struggle with that—I don’t know if it’s overwhelming their Bluetooth stack or what. What Android device are you trying this with?

I’m trying on a Nexus 5X, with Android 7.0.
It’s a rather recent and powerful device: if multiple connections don’t work on it, I guess there’s little chance that they are actually feasible… Unless you can do something about it…

Speaking of connection to beacons, I’ve noticed another strange behaviour and I need your opinion, Piotr.

I tried to connect to a beacon (only one), while I’m also doing a BLE scan (using a standard Android BluetoothLeScanner) on the same device: this way, I can connect to my beacon, while I’m also watching for other beacons nearby.
This works fine on the Nexus 5X, but doesn’t work on an older device, a Motorola MotoG: on it, if the BLE scan is in progress, I cannot connect to my beacon (and the ConfigurableDevicesScanner.scanForDevices() also doesn’t report the Estimote beacons nearby).

I know that the Moto G, like many other rather old Android devices, doesn’t support BLE multiple advertisement, while the newer devices support it; I don’t know, though, if this is related to the issue I noticed…

Can you shed some light on this?

Thank you
Cristiano

Actually, I heard from the Google/Physical Web team that Nexus 5X has a terrible BLE stack :stuck_out_tongue: It’s somewhere on the Eddystone/Physical Web GitHub I think :wink:

Moto G, I know we heard from some Android developers from our community about some issues with the 1st and 2ng gen, dunno about the third.

Eh, working within the Android ecosystem is soooo tricky, as you can see!

1 Like