Android Things Brings TensorFlow-Based Machine Learning and Computer Vision to IoT Devices

| by Sergio De Simone Follow 18 Followers on Feb 13, 2017. Estimated reading time: 1 minute |

Recently released Developer Preview 2 (DP2) for Android Things makes it easier to use TensorFlow for machine learning and computer vision on IoT devices. Additionally, it extends USB audio for several IoT platforms, adds Intel Joule support, and enables direct use of native drivers through a new Native PIO API.

A ready-to-use TensorFlow library pre-built for ARM and x86 is now provided with DP2 and can be used by just adding a single line to the build.gradle file. A sample included in DP2 demonstrates how to build a TensorFlow-enabled app to classify images captured from an attached camera and speak out the result if a speaker is available. The sample feeds TensorFlow with an inference model built using Google Inception deep convolutional neural network architecture.

DP2 also enables the use of existing native C/C++ drivers, which many developers have already written to communicate with peripherals such as lights, door locks, etc., through the new Native PIO API. The Native PIO API allows developers to extend Java-based Android Things app with C or C++ code which can be bound back to the Android Things framework. For example, a driver could generate a regular Android KeyEvent in response to a pin activation, or feed a GPS location into the Android location API. The new API also allows developers to write their Android Things apps entirely in C/C++, if they wish so, by calling the Native PIO API inside a NativeActivity.

As a final note, DP2 brings USB audio support to Intel Edison and Raspberry Pi 3, and introduces support for the Intel Joule platform, which brings to four the number of supported hardware platforms.

Android Things is Google’s IoT platform aimed to allow developers to write IoT applications similarly to how they write mobile apps by integrating the usual Android API and Google’s cloud services with a specific Things Support Library aimed to provide access to sensors and actuators, and to allow developers to inject custom hardware events into their apps through user drivers. Android Things uses Google Weave as its communication platform.

Rate this Article

Adoption Stage

Hello stranger!

You need to Register an InfoQ account or or login to post comments. But there's so much more behind being registered.

Get the most out of the InfoQ experience.

Tell us what you think

Allowed html: a,b,br,blockquote,i,li,pre,u,ul,p

Email me replies to any of my messages in this thread
Community comments

Allowed html: a,b,br,blockquote,i,li,pre,u,ul,p

Email me replies to any of my messages in this thread

Allowed html: a,b,br,blockquote,i,li,pre,u,ul,p

Email me replies to any of my messages in this thread


Login to InfoQ to interact with what matters most to you.

Recover your password...


Follow your favorite topics and editors

Quick overview of most important highlights in the industry and on the site.


More signal, less noise

Build your own feed by choosing topics you want to read about and editors you want to hear from.


Stay up-to-date

Set up your notifications and don't miss out on content that matters to you