MQTT driver
This driver allows the communication between Simumatik and an MQTT broker to subscribe and modify the different variables.
Parameters
Aside from the common parameters described in the communication_driver docs, this driver includes:
-
ip: IP address of the MQTT broker. Default = '127.0.0.1'.
-
port: Port number used by the MQTT broker. Default = 1883.
-
retain: Retain published topics by the driver in the MQTT Broker. Default = True.
Setup data
The setup data will give values to the parameters required and will specify the I/O variables info.
{
"parameters": {
"ip": "1921.168.1.23",
},
"variables": {
"workspace/light_sensor": {
"datatype": "str",
"size": 1,
"operation": "write"
},
"workspace/lamp": {
"datatype": "str",
"size": 1,
"operation": "read"
}
}
}