Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

How does it compare to RxAndroidBle? #40

Closed
mzgreen opened this issue Dec 3, 2019 · 4 comments
Closed

How does it compare to RxAndroidBle? #40

mzgreen opened this issue Dec 3, 2019 · 4 comments

Comments

@mzgreen
Copy link

mzgreen commented Dec 3, 2019

Thank you for open sourcing this library, it looks very nice and polished.
There is a popular reactive Android bluetooth library https://github.com/Polidea/RxAndroidBle
I'm wodering how does RxCentralBle compare to RxAndroidBle and why/when should I pick which.
Maybe you could add this comparison to readme/wiki? Thanks!

I know you're planning to release iOS version of RxCentralBle and there is a popular iOS reactive library called RxBluetoothKit so it would be great to have a comparison of those two as well :)

@kbabcockuf
Copy link
Collaborator

Yup! Well aware of Polidea's excellent libraries.

At Uber, it's critical our systems reflect similar, if not the same, architecture on both Android and iOS. Polidea's libraries are drastically different between both mobile platforms and would have required a shim library to apply a platform-agnostic design, along with a great deal of additional iOS work to build this out. This was one of the main drivers to build our own library.

Also, RxAndroidBle is a heavyweight repository, with approximately 3x the lines of code of RxCentralBle. It's our hope to produce the same degree of functionality with cleaner, simpler interfaces, and ultimately with less code to manage and maintain.

@mzgreen
Copy link
Author

mzgreen commented Dec 6, 2019

That makes sense, thanks. Android BLE stack is known for its bugs (especially on older Android versions). Does RxCentralBle try to fix some of those issues under the hoods?

@kbabcockuf
Copy link
Collaborator

Yes, thanks for these excellent questions!

The library was developed out of years of Bluetooth LE experience drawn from experiences beyond Uber. For example, the library makes no attempt to support Bluetooth 4.x specified pairing & bonding, as this is notoriously unreliable on Android. It ensures all GATT operations are performed in a serial manner to avoid known conflicts with concurrent operations. All GATT writes are automatically chunked into MTU-sized segments and performed in sequence. It does not support use of Android's ScanFilter due to known issues on Android 6 and certain Samsung devices. Etc, etc. The goal is the library should be good to go as-is for 95%+ of central use cases.

Though KitKat is supported, we do not optimize for it as we no longer support KitKat on Uber's primary Rider and Driver apps.

@mzgreen
Copy link
Author

mzgreen commented Dec 6, 2019

That's great, thank you for the response! I think the info from both of your posts should be included in the readme or posted on wiki :)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants