MQTT Auto Publish Data or MQTTPublishTable()
The data logger has a feature that enables automatic publishing to CampbellCloud. To enable this feature:
On the MQTT tab, set MQTT Auto-Publish Data to Enabled. Data tables intended for publishing must include a DataInterval()
instruction. By default, the fastest auto-publish interval is 10 minutes. Data is published as follows:
-
If the
DataInterval()
is less than 1 minute, the table is excluded from publishing. -
If the
DataInterval()
is between 1 and 10 minutes, data stored in the data table is published every 10 minutes. -
If
DataInterval()
is greater than 10 minutes, data is published at the specified interval. -
To publish data more frequently than the 10-minute auto-publish interval, use the
MQTTPublishTable()
instruction in the data table and set the desired publish rate. TheOutputFormat
parameter in theMQTTPublishTable()
instruction must be set to 2, GeoJSON.
Once MQTTPublishTable()
is included in a data table in a CRBasic program, Auto-Publish is no longer applicable.
The auto-publish feature is not available for these data loggers. To publish data, use the MQTTPublishTable()
instruction in the data table and set the desired publish rate. The OutputFormat
parameter in the MQTTPublishTable()
instruction must be set to 2, GeoJSON.