bobwki
bobwki

Reputation: 954

iOS device seems to stay connected to Bluetooth-LE device even after app is closed, so another device cannot connect

This is driving us crazy. We have an app that connects to a BLE device, and stays connected even when the app goes to the background. This has been working fine for us for years. If we close the app (swipe it away), the device disconnects and it is available for another iOS device to connect to it.

Recently (it seems), we've seen this "swiping away" seemingly not release the BLE device -- it does not show up on other iOS devices until Bluetooth is turned off on the orginal device. Unfortunately, we have not found the exact recipe yet to repeat this.

Update - We've also found that when we get into this state (app closed, but BLE devices unavailable on other iOS devices), the Bluetooth "status" page in Setup shows these devices as CONNECTED on the first device. We found that this state will go away if the app is deleted from the device (or Bluetooth turned off).

We've recently added support for an addtional bluetooth accessory (a label printer), and at that time changed our background modes. Current settings from info.plist: (The external-accesory string is new for us.)

    <array>
        <string>audio</string>
        <string>external-accessory</string>
        <string>bluetooth-central</string>
    </array>

How can this be happening? Has there been some recent change in iOS that could look like this? Or was it adding the "external-accessory" to background modes?

Upvotes: 1

Views: 106

Answers (0)

Related Questions