How to Autoconnect to a paired device (BLE) withou

2019-06-07 21:08发布

问题:

We are developing a BLE application and we need a low power consumption. We need to connect devices in background processes so we are scanning all the time. This means that the power consumption is huge.

We know that Android OS connects automatically to some bluetooth devices as headsets or car free-hands devices and the power consumption of the phone keeps low.

Is there any way to use the same method that Android OS use?

We need to connect to the device as soon as it appears near the phone, and we need to measure the RSSI value constantly.

Is possible to reduce the Bluetooth power consumption with a constant search for BLE devices?

回答1:

I think my solution for similar question (of me) might help for autoconnection. Just save the MAC address of the BLE device into DB or something, and connect by using the MAC address when it needed. You can call connectGatt() periodically, when the app starts, or when it initializes something. But I don't have any idea for constant RSSI checking part. It might need constant scanning.