🔧 AI Nachrichten Major AI platforms go down in unprecedented simultaneous outage(03.09.2026 um 17:34 Uhr)
🔧 AI Nachrichten ChatGPT, Claude, and Grok Down? Users Report Widespread Outages(03.09.2026 um 19:14 Uhr)
🔧 AI Nachrichten OpenAI Launches GPT-6 Astra, Says We May Have Entered the AGI Era(03.09.2026 um 22:08 Uhr)
🔧 AI Nachrichten Claude Comes to CarPlay as Fifth Major AI Chatbot App(05.09.2026 um 05:31 Uhr)
🔧 AI Nachrichten OpenAI’s GPT-6 Astra Is AGI, Says NVIDIA CEO Jensen Huang(07.09.2026 um 06:31 Uhr)
🔧 AI Nachrichten Blame AI companies for Mac mini and Mac Studio shortage(31.08.2026 um 10:32 Uhr)
🔧 AI Nachrichten Major AI platforms go down in unprecedented simultaneous outage(03.09.2026 um 17:34 Uhr)
🔧 AI Nachrichten ChatGPT, Claude, and Grok Down? Users Report Widespread Outages(03.09.2026 um 19:14 Uhr)
🔧 AI Nachrichten OpenAI Launches GPT-6 Astra, Says We May Have Entered the AGI Era(03.09.2026 um 22:08 Uhr)
🔧 AI Nachrichten Claude Comes to CarPlay as Fifth Major AI Chatbot App(05.09.2026 um 05:31 Uhr)
🔧 AI Nachrichten OpenAI’s GPT-6 Astra Is AGI, Says NVIDIA CEO Jensen Huang(07.09.2026 um 06:31 Uhr)
🔧 AI Nachrichten Blame AI companies for Mac mini and Mac Studio shortage(31.08.2026 um 10:32 Uhr)
1 Tag Serie
🤖 Android Tipps 🕛 kürzlich 4 Min Lesezeit
0

Android Things client library for Google Cloud IoT Core

↗ Quelle (feedproxy.google.com)
🗣️ Stimme:
📑 Inhaltsübersicht


Posted by Wayne Piekarski, Developer Advocate for IoT



We're releasing a client library to make it easy to use Google Cloud IoT Core from Android Things devices. With just a few lines of code, you can 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.




What is Cloud IoT Core?




that allows you to easily and securely connect, manage, and ingest data from millions of globally dispersed devices. Cloud IoT Core, in combination with other services which make up Google's Cloud IoT platform, provides a complete solution for collecting, processing, analyzing, and visualizing IoT data in real time, to support improved operational efficiency, compliance, or revenue management. Android Things is designed to support everything from collecting telemetry data to powerful computer vision, audio processing, and machine learning applications, all on device, and using Cloud IoT Core, push your data into Google Cloud Platform for further analysis.



that keeps track of approved devices, and each device uses a public key to authenticate with the server. Android Things provides many features to support secure IoT applications, including a hardware-backed , as well as report their internal state to a separate published from Cloud IoT Core.



Because IoT devices operate in the real world with poor wireless conditions, the client library provides extensive support for handling errors, and for caching and retransmitting events later. For developers requiring custom offline behavior, the library's queue is configurable and even replaceable. This provides detailed control over which events to save and the order in which they are sent when back online.




Device provisioning and authentication with Android Things




The Cloud IoT Core client library is part of our overall vision for device provisioning and authentication with Android Things. To learn more about this, watch the video of our presentation from Google I/O 2018:






Sample code




Getting started with the Cloud IoT Core client library is simple. You can simply add the following to the build.gradle file in your Android Things project:





implementation 'com.google.android.things:cloud-iot-core:1.0.0'




The library is also available as open source on 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.



It is easy to start using the client library in your own code. The following Kotlin example demonstrates how to create a new configuration and client based on your project.





var configuration = IotCoreConfiguration.Builder().
.setProjectId("my-gcp-project")
.setRegistry("my-device-registry", "us-central1")
.setDeviceId("my-device-id")
.setKeyPair(keyPairObject)
.build()

var iotCoreClient = IotCoreClient.Builder()
.setIotCoreConfiguration(configuration)
.setOnConfigurationListener(onConfigurationListener)
.setConnectionCallback(connectionCallback)
.build()

iotCoreClient.connect()




Next, you can publish telemetry information or device state, using the following Kotlin examples.





private fun publishTelemetry(temperature: Float, humidity: Float) {
// payload is an arbitrary, application-specific array of bytes
val examplePayload = """{
|"temperature" : $temperature,
|"humidity": $humidity
|}""".trimMargin().toByteArray()
val event = TelemetryEvent(examplePayload, topicSubpath, TelemetryEvent.QOS_AT_LEAST_ONCE)
iotCoreClient.publishTelemetry(event)
}

private fun publishDeviceState(telemetryFrequency: Int, enabledSensors: Array<String>) {
// payload is an arbitrary, application-specific array of bytes
val examplePayload = """{
|"telemetryFrequency": $telemetryFrequency,
|"enabledSensors": ${enabledSensors.contentToString()}
|}""".trimMargin().toByteArray()
iotCoreClient.publishDeviceState(examplePayload)
}





Additional resources




You can learn more about building for Android Things at the and on Google+ to let us know what you're building with Android Things and Cloud IoT Core!






Vollständiger Original-Bericht
Ausführliche Details, Code-Beispiele & Hersteller-Stellungnahme auf feedproxy.google.com.
↗ Original-Artikel auf feedproxy.google.com lesen
Wie bewertest du diesen Beitrag?
1 Klick Feedback
Teilen mit Netzwerk & Team:

Community-Analysen & Experten-Meinungen 0

Verfasse deine eigene Analyse, teile Workarounds oder diskutiere diesen Vorfall im Blog.
Noch keine Community-Analyse verfasst. Markiere einen Textabschnitt oder klicke oben auf Eigene Analyse verfassen“!
Community Pulse: Relevanz-Einschätzung
1 Klick Experten-Votum
🔴 Akute Relevanz 0%
🟡 In Evaluierung 0%
🟢 Keine Auswirkung 0%
Spannende Innovation 0%
Verwandte Story-Cluster & Quellen (Vektor-KI)
Port 8095 Engine
3 Quellen
GPT-6 Astra Release Today? OpenAI’s Next Major AI Model Is Almost Here
1 Quelle
Apple accuses OpenAI of destroying evidence as trade-secrets fight intensifies
1 Quelle
Major AI platforms go down in unprecedented simultaneous outage