How to solve the BluetoothGatt : android.os.DeadObjectException error happened in Android?

前端 未结 4 2004
北恋
北恋 2021-02-13 18:07

I following the page Bluetooth Low Energy for developing in Android 4.3 for Bluetooth Low Energy .

I already can turn on the Bluetooth

4条回答
  •  难免孤独
    2021-02-13 18:32

    I solved this by disconnecting, closing the Gatt and stopping the service and then restart it again:

                mBluetoothLeService.disconnect();
                mBluetoothLeService.close();
                mBluetoothLeService.stopSelf();
                connectBleservice();
    

提交回复
热议问题