alexmoon / bluest

Cross-platform Rust crate for working with Bluetooth Low Energy devices.
Apache License 2.0
55 stars 8 forks source link

android: switch from futures-channel to async-channel. #12

Closed Dirbaio closed 6 months ago

Dirbaio commented 6 months ago

futures-channel doesn't support blocking send, so in the callbacks from java (which are not in an async context) we're forced to do try_send, which will lose data if the channel is full because the Rust side is too busy.

This is not a big deal for scanning, but is for stuff like gatt/l2cap responses that are coming next.