Search code examples
androidbluetooth-lowenergyrx-javarxandroidble

Implemented Peripheral 1 with Native Android API and implemented Peripheral 2 with RxAndroidBle Possible Conflicts


I'm working with code that's programmed using the Native BLE APIs. It has its own queue implementation for sending/writing characteristics. But I've also had the need to implement a second peripheral which I did use RxAndroidBle. Since it has its own queue(ClientOperationQueue) for connections and sending/writing, do I need to worry about any conflicts or commands being lost? These peripherals need to be connected at the same time as well and perform reads/writes. I'd like to avoid touching the working code if possible.


Solution

  • The restriction of only allowing one operation at a time is per BluetoothGatt/BluetoothGattServer object. So you should be fine using two separate Bluetooth codes in your app.