如何让android应用程序在后台运行?

时间:2017-09-08 05:40:27

标签: bluetooth-lowenergy android-bluetooth android-background bluetooth-gatt

我正在研究android应用程序。在这个应用程序中,我必须连接到ble设备。当应用程序在后台时,我希望应用程序连接到ble设备。

1 个答案:

答案 0 :(得分:1)

答案是在您的流程中至少有一个使用BLE的前台服务https://developer.android.com/guide/components/services.html#Foreground。这将使Android让您的流程保持活力。