Differences
This shows you the differences between two versions of the page.
Next revision | Previous revision | ||
en:mervis-scada:80-mqtt [2018/05/17 14:44] m.kulvejt created |
en:mervis-scada:80-mqtt [2024/05/08 10:42] (current) |
||
---|---|---|---|
Line 4: | Line 4: | ||
===== Basic properties and requirements ===== | ===== Basic properties and requirements ===== | ||
- | * Any device must be registered in the Mervis cloud. Connection parameters are provided upon the registration (DeviceID, user name and password) | + | |
+ | | ||
+ | * Contact [[en: | ||
* possibility of a dynamic variable set (devices can specify what variables they publish) | * possibility of a dynamic variable set (devices can specify what variables they publish) | ||
* only built-in types are supported (bool, integers, floating point numbers, string) | * only built-in types are supported (bool, integers, floating point numbers, string) | ||
Line 25: | Line 27: | ||
===== Supported formats ===== | ===== Supported formats ===== | ||
- | ==== Mervis | + | ==== Wago compatible |
=== Registration of available variables === | === Registration of available variables === | ||
Line 89: | Line 91: | ||
</ | </ | ||
- | Variable values | + | === Variable values |
- | • Publishes values of variables | + | |
- | • Publish message with “At least once delivery” | + | |
- | • Topic: deviceId/ | + | |
- | • Payload: UTF-8 JSON document | + | |
- | o /FormatId: (string), message ID | + | |
- | o / | + | |
- | o / | + | |
- | o /TagData (Array of value items) | + | |
- | /Time (datetime), timestamp in ISO format, ideal is a UTC form | + | |
- | /Values (Collection of Tag and value tuples) | + | |
- | • Example | + | |
+ | **Example** | ||
+ | <code json> | ||
{ | { | ||
" | " | ||
Line 116: | Line 119: | ||
} | } | ||
+ | </ | ||
+ | ==== Weintek compatible format ==== | ||
+ | * We assume that all datetime values are in **UTC** | ||
+ | * Print screens are from EasyBuilder Pro SW | ||
+ | === Variable values === | ||
+ | * Publishes values of variables | ||
+ | * Publish message with “At least once delivery” | ||
+ | * Topic: $deviceId/ | ||
+ | * Payload: UTF-8 JSON document | ||
+ | * /d: root element | ||
+ | * " | ||
+ | * metadata format: | ||
+ | * " | ||
+ | * " | ||
+ | * " | ||
+ | **Example** | ||
+ | <code json> | ||
+ | { | ||
+ | " | ||
+ | " | ||
+ | " | ||
+ | " | ||
+ | "My array" : [ 0, 10, 20 ] | ||
+ | }, | ||
+ | " | ||
+ | } | ||
+ | |||
+ | </ | ||
+ | {{ : | ||
+ | === Command registration === | ||
+ | * Topic: $deviceId/ | ||
+ | * Format: | ||
+ | * /d root element | ||
+ | * " | ||
+ | * " | ||
+ | * " | ||
+ | * " | ||
+ | * " | ||
+ | * " | ||
+ | * " | ||
+ | * " | ||
+ | < | ||
+ | { | ||
+ | " | ||
+ | " | ||
+ | }, | ||
+ | " | ||
+ | } | ||
+ | </ | ||
+ | choose/ | ||
+ | {{ : | ||
+ | set general tab by screenshot | ||
+ | {{ : | ||
+ | add commands | ||
+ | {{ : | ||
+ | ===Our supported types=== | ||
+ | * " | ||
+ | * " | ||
+ | * " | ||
+ | * " | ||
+ | * " | ||
+ | * " | ||
+ | * " | ||
+ | * " | ||
+ | * " | ||
+ | * " | ||
+ | * " | ||
+ | * " | ||
+ | * " | ||
+ | ===Create a subcribe topic for executing command=== | ||
+ | * for previous command example | ||
+ | * create topic $deviceId/ | ||
+ | * with two addresses: | ||
+ | * temperature(32-bit float) | ||
+ | * date(string) | ||
+ | {{ : |