Published OnApril 1, 2025October 7, 2019

Our journey to making Android Bluetooth "Behave"

Most people who enter the Bluetooth APIs with Android devices immediately get quite flustered at how hard it is. However, physical android devices are a larger nightmare.

When Tom, our resident network expert, embarked on creating a cross-platform Bluetooth stack, he noticed that while the APIs were relatively similar to comparable platforms, they didn't behave the same. In particular, he noticed incredibly different behaviors even with phones on the same exact Android operating system.

For example, Google Pixel phones could tell the operating system that they've disconnected while at the same time still receive packets of data. In addition, all Android 9 phones also exhibited randomized failure of the entire Bluetooth stack. Since Ditto is primarily building a stream API on top of various operating system, it needs some uniform interface that promised to behave the same. However, we realized that we will need to constantly monitor different devices for unstable APIs, and write adapters, to "coerce" them to work with our streaming API.

Shameless plug (well you're on the company website 😉), I highly recommend that you avoid the Android Bluetooth stack at all costs and just use Ditto instead. The vast majority advisors and companies we've talk to simply have given up on the matter entirely. But as Tom has demonstrated, if you use Ditto you'll have taken our extensive experience in standardizing Android's Bluetooth stack without the headaches that you will run into if you decided to build it yourself.

Read more
Product
Tutorial
April 24, 2025
Engineering with Expo: Expanding Our JavaScript SDK
by
Teodor Ciuraru
In this article, we’ll detail how we introduced Expo Development Builds support for Ditto React Native and how the new Expo plugin helps developers skip several manual setup steps that React Native CLI users typically face.
Updates
Product
April 22, 2025
Flutter for Web Reaches General Availability in Record Time
by
Rae McKelvey
As of Ditto Flutter SDK v4.10.1, Flutter for Web has reached General Availability. In October 2024, when we shipped 4.8, Ditto developers started asking if we could extend Ditto to support Flutter web apps – and we took that challenge to heart. With the GA, let's take a closer look at what's included today, some key considerations, and how you can get started today.