Using Firestore with Cloud IoT Core for Device Configuration
Cloud IoT Core provides a way to send configuration to devices over MQTT or HTTP. The structure of this payload is unspecified and delivered as raw bytes. This means that if you have different parts of your IoT system wanting to write parts of the configuration, each has to parse, patch, then re-write the configuration value in IoT Core.
If you want a payload delivered to a device in a binary format, such as CBOR, that means each of these participating components of your system also need to deserialize and re-serialize the structured data.
By using Cloud Firestore to serve as a layer in between the systems that update a device's configuration and IoT Core, you can take advantage of Firestore's structured data types and partial document updates.
Únase a Qwiklabs para leer este lab completo… y mucho más.
- Obtenga acceso temporal a Google Cloud Console.
- Más de 200 labs para principiantes y niveles avanzados.
- El contenido se presenta de a poco para que pueda aprender a su propio ritmo.
Create a Firebase project
Create a Pub/Sub a Pub/Sub topic
Create a Cloud IoT core Registry
Deploy relay function
Create your device
Create a database
Create another device