ClearBlade IoT Core is a cloud IoT service compatible with the former Google Cloud IoT Core (projects, registries, devices and gateways, MQTT bridge with JWT authentication). It is used in particular by projects that follow UDMI, the Universal Device Management Interface data model for buildings. The Weble IoT Universal Gateway Clearblade IoT Core driver connects the box as a gateway device, attaches the devices bound to it, creates their points from the UDMI configuration sent by the cloud, and publishes the point values as UDMI pointset telemetry.
Driver key:
clearblade— listed as Clearblade IoT Core under IoT in Gateway driver. Licence: required, contact support@weble.ch. Platforms: Linux and Windows.
In ClearBlade IoT Core:
gateway.proxy_ids.pointset.points).On the box:
europe-west1-mqtt.clearblade.com) on TCP port 8883.europe-west1-mqtt.clearblade.com) and keep MQTT Port = 8883.The driver connects, receives the configuration of the gateway device, attaches the bound devices and creates their addresses.
For each point created by the driver, route a field value (BACnet, Modbus, KNX…) to %ci:<device>/points/<point>/presentValue. The values are published to the cloud at the rate defined in the UDMI configuration (see 4.2).
Name, Cluster ID and Description are common to all drivers: see Gateways.
| Label | JSON key | Default | Description |
|---|---|---|---|
| Project ID | json.projectId |
weble-1234 |
ClearBlade project ID. Required. |
| Registry ID | json.registryId |
webleregistry |
Registry of the gateway device. Required. |
| Device ID | json.deviceId |
gateway1 |
ID of the gateway device (the box) in the registry. Required. |
| Cloud region | json.cloudRegion |
europe-west1 |
Region of the registry. Required. Must match the region of MQTT Host. |
| Algorithm | json.algorithm |
RS256 |
Algorithm of the gateway device key: RS256, ES256, RS256_X509 or ES256_X509. Must match the public key registered on the device. |
| Private key | json.privateKey |
(empty) | Private key of the gateway device (PEM content). Required. It signs the token (JWT) used to log in; it is never sent. |
| MQTT Host | json.mqttBridgeHostname |
europe-west1-mqtt.clearblade.com |
MQTT bridge of the region. Required. |
| MQTT Port | json.mqttBridgePort |
8883 |
Port of the bridge (MQTT over TLS). Required. |
The seven fields marked Required must all be filled. Saving the gateway restarts the driver.
{
"projectId": "acme-buildings",
"registryId": "geneva-hq",
"deviceId": "wbox-geneva-01",
"cloudRegion": "europe-west1",
"algorithm": "ES256",
"privateKey": "-----BEGIN EC PRIVATE KEY-----\n…",
"mqttBridgeHostname": "europe-west1-mqtt.clearblade.com",
"mqttBridgePort": 8883
}
%ci:<device>[/<topic or points>[/<point>[/<field>]]] — <device> is a device ID of the registry.
| Address | Role |
|---|---|
%ci:<device> |
The device (gateway or bound device). Its value is the last configuration received from the cloud (UDMI). |
%ci:<device>/commands |
Commands received from the cloud. |
%ci:<device>/state |
State published by the box. |
%ci:<device>/events |
Last telemetry message published by the box. |
%ci:<device>/errors |
Errors reported by the cloud. |
%ci:<device>/points |
Pointset of the configuration, with the telemetry rates (sample_rate_sec, sample_limit_sec). |
%ci:<device>/points/<point> |
One point of the configuration. |
%ci:<device>/points/<point>/presentValue |
Value of the point, to feed with a route. Number. |
%ci:<device>/points/<point>/cov |
Change threshold of the point (cov_threshold of the configuration). |
%ci:<device>/points/<point>/units |
Unit of the point. |
All these addresses are created by the driver from the configuration sent by the cloud.
Examples:
%ci:AHU-1/points/supply_air_temperature_sensor/presentValue — supply air temperature of AHU-1, routed from BACnet.%ci:AHU-1/points — pointset of AHU-1, with its telemetry rates.| Label | JSON key | Default | Description |
|---|---|---|---|
| Name | name |
Address, after the %ci: prefix. |
|
| Description | description |
(empty) | Free text. |
| Log | log |
never | Logging policy, see Log and Store value policies. |
| (JSON only) | json.algorithm |
no auth |
On a bound device address (%ci:<device>): algorithm of the device key, or no auth to attach the device without its own credentials. |
| (JSON only) | json.privateKey |
(empty) | On a bound device address: private key of the device, when the registry requires device credentials. |
| Property | Value |
|---|---|
| Readable | No — values are kept by the driver |
| Writable | …/points/<point>/presentValue (number), …/cov (number) and …/units only |
| Created automatically | Yes — from the cloud configuration |
| Routable | Yes |
| Loggable | Yes |
gateway.proxy_ids are attached to the gateway, and their configuration is received in turn.pointset.points become addresses.A device removed from proxy_ids keeps its addresses, with the status not in config. A device that cannot be attached (for example because its credentials are refused) shows not attached. A point that disappears from the configuration shows not in config.
For each device, the driver publishes UDMI pointset events (/events) with the present_value of each point:
sample_rate_sec seconds (600 s when the configuration does not set it);sample_limit_sec seconds (5 s when not set), with only the points whose value changed by more than their cov threshold;sample_limit_sec stops the updates of the device.These rates come from the UDMI configuration of each device, set in the cloud: they are not settings of the box.
See Security for the settings of the box itself.
| Symptom | Cause | What to do |
|---|---|---|
Gateway restarts in a loop; log missing license |
No licence for the driver. | Add the licence in Gateways › License manager. |
Log incomplete gateway config, missing required field(s): … |
One of the seven required fields is empty. | Fill the field named in the log. |
| Gateway restarts in a loop at connection | Wrong project, registry, region or device ID, key that does not match the registered public key, or region of MQTT Host different from Cloud region. | Check the IDs and the key in ClearBlade; use the bridge of the region of the registry. |
| No device address | The configuration of the gateway device has no gateway.proxy_ids, or the devices are not bound to the gateway. |
Bind the devices and update the configuration in the cloud. |
Device status not attached |
The cloud refused the attachment. | Check the binding, and the device credentials if the registry requires them. |
Write fails with read only |
Only presentValue, cov and units can be written. |
Route the value to …/presentValue. |
Write fails with not a number |
presentValue and cov accept numbers only. |
Convert the value in a route function. |
To read the driver log: open the gateway log (see Gateways). The log shows starting client - bridge:… projectId:… region:… registry:… deviceId:… at start.
Keep this gateway on Cluster ID
0: the driver restarts its process when the MQTT connection is lost, which would restart every gateway of a shared cluster.
ClearBlade IoT Core took over the projects of Google Cloud IoT Core, which Google has discontinued. The box also has a Google Cloud IoT driver (addresses %gi:), which uses the same configuration fields.
%ci: addresses, then stop the old gateway.