You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
An alternative to GATT for BLE communication is to use L2CAP. This let's use use a connection-oriented channel towards the peripheral instead of the message-based method GATT uses. Think of this like TCP vs UDP. On an API level we two streams (InputStream and OutputStream), so it makes it much easier to work with.
P.S. Loved your "Bluetooth Low Energy on Android" article series (that were posted on hellsoft); they helped shape Kable and avoid many Android pitfalls in its early development. ❤️
An alternative to GATT for BLE communication is to use L2CAP. This let's use use a connection-oriented channel towards the peripheral instead of the message-based method GATT uses. Think of this like TCP vs UDP. On an API level we two streams (InputStream and OutputStream), so it makes it much easier to work with.
This is supported by both Android and iOS, but doesn't exist for Web.
https://developer.apple.com/documentation/corebluetooth/cbperipheral/openl2capchannel(_:)
https://developer.android.com/reference/kotlin/android/bluetooth/BluetoothDevice?hl=en#createl2capchannel
I suggest this is added as an additional API in Kable. If this sounds good (despite the API missing on Web) I can start on an initial implementation.
The text was updated successfully, but these errors were encountered: