题意:连接到 IoT Core MQTT
问题背景:
I am trying to connect to Google's MQTT server but I am getting errors I created all the certificates and registered my device (Adafruit huzzah32)
我正在尝试连接到 Google 的 MQTT 服务器,但遇到了错误。我已经创建了所有证书并注册了我的设备(Adafruit Huzzah32)
and the documentation says you connect to mqtt.googleapis.com:8883
文档中说你需要连接到 mqtt.googleapis.com:8883
So I do
WiFiClientSecure wifi;
MQTTClient client;
client.begin("mqtt.googleapis.com", 8883, wifi);
When I try to connect I use the device path
当我尝试连接时,我使用设备路径
const