Setting up a station to connect to ClearBlade MQTT

To set up a station to connect to Clearblade MQTT broker, use the GCP authenticator.

Make a note of project, location, registry ID, and device ID because you will need them in this procedure.

  1. In Workbench, from the abstractMqttDriver palette, add the AbstractMqttDriverNetwork and the AbstractMqttDevice to your station.
  2. From the same palette, drag the GcpAuthenticator to the AbstractMqttDriverNetwork .
  3. Update the GCP Iot Parameter noted in the Prerequisites section.
  4. Update the Broker Endpoint based on selected region.
    For more information, see "MQTT (regional)" at https://docs.clearblade.com/iotcore/retargeting-devices#Retargetingdevices-MQTT(regional):
    • us-central1-mqtt.clearblade.com

    • europe-west1-mqtt.clearblade.com

    • asia-east1-mqtt.clearblade.com

  5. Update the Broker Port to 8443.
  6. In the Niagara User Key Store, create a new certificate or import a certificate, and select the certificate that you want to use to sign the JWT token.
    In Niagara 4.13 and earlier, the RSA key pair is generated automatically for the device.
  7. Export the public key PEM from the User Key Store and in the ClearBlade console add the public key as RS256_X509.


  8. Update the Public key expiration date (optional) using the same date that is displayed in Expiration Date of Rsa Keys property in the GcpAuthenticator component.
    Note: The expiration date provides the date when the certificate will expire and when it is not supposed to be used by ClearBlade to authenticate the device.