Reliable Bluetooth LE Comms Between Arduino and MIT App Inventor (AI2)

MIT_AI2_IconIn a previous post, I looked at creating reliable communications using Classic Bluetooth. While that approach works well, and is a reliable way to connect devices, there may be circumstances when a Bluetooth Low Energy (BLE) connection is preferable.

As it turns out, Bluetooth and BLE are about as similar as apples and oranges. The change in transmission protocol technology is more than a trivial change in the code and its structure.

In this article I explore the difference between BT and BLE and how the previous BT AI2 app needs to be adapted.

Continue reading “Reliable Bluetooth LE Comms Between Arduino and MIT App Inventor (AI2)”

Advertisements

Reliable Bluetooth Comms Between Arduino and MIT App Inventor (AI2)

MIT_AI2_IconI recently needed to develop a Bluetooth application between an Arduino and a controlling App running on Android. App Inventor 2 was used to simplify development of the Android App .

MIT App Inventor (AI2) is a web-based online graphical mobile application development environment for Android devices, where you can create an application by simply dragging and connecting a series of function blocks.

When researching the task, I found a lot of disparate information about how to write the Bluetooth management code for AI2. This information (some good, some wrong, and a lot repetitive) was synthesized it into a set of functions, described here, that provide a reliable communications interface to my project.

Continue reading “Reliable Bluetooth Comms Between Arduino and MIT App Inventor (AI2)”