|
Devices compatible with the MQTT protocol
Module Configuration
This document has only information about the device connection settings and its address syntax.
For further Information, see:
DrvParams[0] = TimePublishRate (integer, milliseconds): Minimum publish rate for MQTT messages. Minimum value: 50ms. Default: 500ms.DrvParams[1] = StoreAndForward (boolean): Enables store-and-forward mode for reliable message delivery. Default: false.Station syntax: <BrokerURL>; <Port>; <ClientID>; [Username]; [Password]; [NetworkSecurity]; [X509Certificate]; <Qos>; <KeepAlive>
Where:
Use QoS 0 when:
Use QoS 1 when:
Use QoS 2 when:
|
When creating solutions that the PrimaryStation IP will be set by script, using the Node properties, you can set the Broker URL to 1.1.1.1 to force it to try establish a connection, avoiding timeouts. |
One of the easiest ways to install the certificate on client computer is to use the wizard to import the certificates is through the "Internet Options" to import the certificate in the "Trusted Root Certification Authorities”. You need to import the certificate in DER format. |
Station Configuration
BrokerURL: test.mosquitto.org
Port: 1883
ClientID: MyClient1
Username: <empty>
Password: <empty>
NetworkSecurity: None
X509Certificate: <empty>
QoS: AtLeastOnce
KeepAlive: 10
Station Configuration
BrokerURL: MSI
Port: 1883
ClientID: MyClient1
Username: Guest
Password: 1234
NetworkSecurity: None
X509Certificate: <empty>
QoS: AtLeastOnce
KeepAlive: 10
Station Configuration
BrokerURL: MSI
Port: 8883
ClientID: MyClient1
Username: <empty>
Password: <empty>
NetworkSecurity: TLSv1.0
X509Certificate: C:/Certificates/mqtt_ca.der
QoS: AtLeastOnce
KeepAlive: 10
Station Configuration
BrokerURL: MSI
Port: 8883
ClientID: MyClient1
Username: Guest
Password: 1234
NetworkSecurity: TLSv1.2
X509Certificate: C:/Certificates/mqtt_ca.der
QoS: AtLeastOnce
KeepAlive: 10
The syntax for the MQTT communication points is called Topic:
E.g.: USA/Houston/Station1/Level
MQTT Revision History | |
|---|---|
Version | Notes |
3.0.3.5 | TLS 1.1 and 1.2 connections now work and connection failures report a plain-language cause; invalid broker credentials no longer cause high CPU or leave the device process running after stop; the broker user name is read from the correct field; new Tag Provider option Disable Rebirth Request; client certificates can be picked from the station editor and are found in MachineSettings/Certificates on the runtime host; password fields support Secrets and the Tag Provider password is stored encrypted; Tag Provider branches without a payload no longer log read errors; Test Connection in remote engineering states it ran on the Designer machine. |
3.0.0.3 | Initial release on new documentation standards. |