IOT Android Things

Android Things for IoT developers

Android Things™ was revealed by Google on December 13, 2016. Formerly know as Brillo, which was announced during Google IO 2015, Android Things now is available as a developer preview. The Android Things SDK documentation basically says that developers can use almost the full Android stack for mobile. On top of that there is the “Things Support Library” offering APIs to interact with peripherals and “user drivers”. Both expose a Java API, so “user drivers” are not that close to the metal as the name might suggest.

Android Things & Hardware

Developers can download Android Things for currently three hardware boards (Raspberry Pi 3, Intel® Edison, and NXP Pico i.MX6UL). There is no software emulator yet, so you really need hardware to get started. Fortunately, the boards are very affordable. A plain Raspberry Pi 3 board is available at around US $40.

The page Hardware 101 is a nice introduction for Android developers that did not touch hardware and sensors before. This is a good help because doing I/O with Android Things quickly gets low level with the Peripheral I/O APIs.

If you want to improve performance, e.g. because your app runs on a low end hardware (cheap), you can still use JNI to avoid the ART overhead. Nevertheless, native-only apps do not seem to be supported yet. The Things Support Library is Java based, so you would need to call into Java from the native code via JNI.

Things Support Library, Weave

Another interesting aspect of the Things Support Library is that it resides inside the device itself. Its Maven artifact just contains abstract classes and stubs throwing runtime exceptions, and the Gradle dependency is marked “provided”.

Weave is an important ingredient for Google’s IoT strategy. Interestingly, it is not part of Android Things (yet). Weave is a communication protocol, and its most visible part is libiota, a C library. This contrasts the Java/ART centric approach of Android Things. Nevertheless, it seems highly likely that Weave will be built into Android Things in the future.

Size and Hardware Requirements

Android Things builds upon Android 7.0 – without the core apps that you find on a phone/tablet. Bringing a full Android to the table has two sides: While this allows Android developers a quick start, this also means that Android Things is not exactly small. The firmware image for Raspberry Pi 3 is well over 4 GB. Thus, it probably won’t power cheap toasters, but rather high end devices that can afford the hardware to run Android Things.


Spread the love
Posted in Android and tagged , , , , , .