GoogleCloudPlatform / google-cloud-iot-arduino

Google Cloud IOT Example on ESP8266

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

ESp32-S2 compatibility?

lloydrichards opened this issue Β· comments

Hey, and firstly thanks for all the wonderful work on this library πŸ‘

I'm in the process of replacing my REST API for receiving IoT data with the Google Cloud IOT Core. I have some simple sensors and am just dumping it into pubsub to be dealt with by BigQuery and Firebase. I've spent the morning trying to get the google-cloud-iot-arduino example to work with my latest board using an ESP32-S2 and am running into some issues with the Certificate.

Right now I'm just using the ESP32-mqtt example to get things working and am getting this message when the mqtt->connect()

Connecting to MQTT
checking wifi...
Wifi connected.
Connecting...
Refreshing JWT
not connected
Settings incorrect or missing a cyper for SSL
Connect with mqtt.2030.ltsapis.goog:8883
ClientId: projects/mimir-app-dev/locations/europe-west1/registries/mimir-iot-registry/devices/mimirOpen-01
Waiting 60 seconds, retry will likely fail

As far as I can tell all the configs are correct to my IoT Core so my ideas are either that i'v messed up and need to start taking the system apart, piece by piece. or maybe the library isn't compatible with the ESP32-S2 or requires some tweaking. I thought I would check first before spending the whole weekend on this only to find out I need to go back to my REST APi. much appreciate any feedback!

could you please post your code?

I recently got this working on some older ESP32 models. Ive not opened the repo yet as I still need to clean out some private keys from older versions. Some examples though that really helped were from @alvarowolfx and his repo on IoT Core:

https://github.com/alvarowolfx/gcloud-iot-core-device-provisioning
https://github.com/alvarowolfx/google-cloud-iot-arduino

Hope those help and once I've got my repo in order i can share it here