使用 CloudIotCore 文档,我可以在我的 Google 云平台项目中运行 Quickstart 示例和 EndtoEnd 示例。
使用 MQTT.fx 工具我无法连接到同一个 Google 云项目
Username : unused
Password : Generated from cretae_jwt function using code in cloudiot_pubsub_example_mqtt_device.py
Broker Address: mqtt.googleapis.com
Broker Port: 8883
Client ID: projects/myprojectid/locations/us-central1/registries/myregistryid/devices/mydeviceid
{ 在上面的行中,我更改了我的项目和设备详细信息}
错误:MQTTException 错误
2017-12-21 17:42:51,785 INFO --- Start App : Style: LIGHT /styles/mqttfx_theme_light.css
2017-12-21 17:42:52,137 INFO --- Start App : An update is availabe.
2017-12-21 17:42:55,668 INFO --- ScriptingManager : Found action with name: Switch Fountain Test
2017-12-21 17:43:30,034 INFO --- BrokerConnectorController : onConnect
2017-12-21 17:43:30,086 INFO --- MqttFX ClientModel : MqttClient with ID projects/myprojectid/locations/us-central1/registries/myregistryid/devices/mydeviceid assigned.
2017-12-21 17:43:30,500 ERROR --- MqttFX ClientModel : Error when connecting
org.eclipse.paho.client.mqttv3.MqttException: MqttException
at 2017-12-21 17:43:30,505 ERROR --- MqttFX ClientModel : Please verify your Settings (e.g. Broker Address, Broker Port & Client ID) and the user credentials!