2 min read

Google has released the Android Things client library for making it easy for Android Things users to utilize Google Cloud IoT core. Last month, Google announced the developer preview release of Android Things, solidifying the chances of it becoming the official IoT platform for Google.

Google IoT core is a complete managed service on the Google Cloud Platform. The client library will help the system to collect, process, analyze, and visualize IoT data in real time. It will provide powerful computer vision, audio processing, and machine learning applications, all on devices. It will also work with Cloud IoT Core, to push data into GCP for further analysis. The Android Things client library will also provide means for developers to easily connect to the IoT Core MQTT bridge, authenticate the device, publish device telemetry and state, subscribe to configuration changes, and handle errors and network outages.

The client library completely handles the networking, threading, and message handling enabling Android Things developers to get started with just a few lines of code.

Authentication and Security

Android Things library provides a hardware-backed Android Keystore that ensures cryptographic key material is protected. The client library supports both RSA and ECC keys and implements the generation of JSON Web Tokens (JWTs) for authentication with Cloud IoT Core.

Device provisioning and Error handling

IoT devices generally operate in poor wireless conditions in the real world. The Android things client library will provide support for handling errors, and for caching and retransmitting events later. The library’s queue is configurable and replaceable for developers requiring custom offline behavior. Developers are provided with detailed control over which events to save and the order in which they are sent when back online.

Wayne Piekarski, Developer Advocate for IoT notes that “The Cloud IoT Core client library is part of our overall vision for device provisioning and authentication with Android Things.

A more detailed report of notable features can be read on the Google developer blog. The library is also available as open source on GitHub for developers who want to build it themselves. Google has also provided a sample that shows how to implement a sensor hub on Android Things, collecting sensor data from connected sensors and publishing them to a Google Cloud IoT Pub/Sub topic.

Read Next

Getting Started with Android Things
Top 5 Google I/O 2018 conference Day 1 Highlights: Android P, Android Things, ARCore, ML kit and Lighthouse
Google updates biometric authentication for Android P, introduces BiometricPrompt API


Subscribe to the weekly Packt Hub newsletter. We'll send you this year's Skill Up Developer Skills Report.

* indicates required

LEAVE A REPLY

Please enter your comment!
Please enter your name here