Unable to discover the BLE device which is in range

We have iOS application to connect and monitor the Wiser smart devices. This application supports WiFi access point change as well. When there is change in the WiFi, wiser devices supports for 3mins BLE mode for re-pairing. When BLE devices are newly commissioning, all devices are being able to discover by CoreBluetooth. But when we try to change the WiFi, Previously connected BLE devices are not being discoverable though they are in pairing mode.

How are you identifying these particular devices? And is your app in the foreground when you are not able to identify?

This problem sounds like one of the two typical cases we see,

1- The advertised name and the GAP name of the devices are different. When the device has never been seen before, CoreBluetooth will report the advertised name. Once connected, the GAP name of the device will be cached, and the next encounter, CoreBluetooth will report the cached GAP name instead of the advertised name. If these names are different, and you are specifically looking for a match in the peripherals name, this could be the mismatch.

I would suggest to either make both names the same, or look for either of the possible names.

2- what is the advertising rate of the Wiser device? When your app is not in the foreground, the scan rate will dramatically drop down, and if the peripheral is not advertising fast enough, 3 minutes may not be enough to reliably detect the advertising.

To reliably detect the device under all adverse conditions, it should be advertising at 20ms, 152.5 ms, 211.25 ms, 318.75 ms, 417.5 ms, or 546.25ms intervals.

Anything more sparse or in between values will increase the time to discovery. I would suggest to try with 20ms to see if this would be the problem, and adjust accordingly.


Argun Tekant /  DTS Engineer / Core Technologies

Thanks for the reply Argun,

For first case - As you mentioned advertised name and the GAP name of the devices are different, so we are handling Both the possible names here. And we even checked in Third party app Light blue to check whether the issue is with our app, but BLE devices are not even discoverable there.

For second case you mentioned - We are discovering when app is in foreground.

Note- User can have multiple sessions in different iPhones. When user is logged in with the same iPhone which they try to discover later is having 90% chance of BLE devices are discoverable but when it comes to sessions on other iPhones BLE devices not discoverable. This issue is very random.

Unable to discover the BLE device which is in range
 
 
Q