MQTT (Message Queuing Telemetry Transport) is an open, lightweight, publish-subscribe network protocol that transports messages between devices. The protocol usually runs over TCP/IP and is designed for connections with remote locations where a ‘small code footprint’ is required or the network bandwidth is limited.
The MQTT protocol defines two types of network entities: a message broker and a number of clients. An MQTT broker is a server that receives all messages from the clients and then routes the messages to the appropriate destination clients. An MQTT client is any device that connects to an MQTT broker over a network.
Brodersen RTUs use MQTT Client protocol to interact with field devices and MQTT brokers within IIOT (Industrial Internet of Things) networks.
Overview – creating an MQTT client application
The slideshow below shows how to create a MQTT client application in a Brodersen RTU.
Note: preliminary testing has proven that the RTU is also able to run an emmbedded MQTT broker application.
The example application above has fixed Client ID and topic names that are embedded within the logic application. In large systems, multiple RTU sites may have a common/similar logic application and need each site to be uniquely identified. The Client ID and/or group and variable topic names can be updated from logic using the RTU32_MQTT function blocks shown below. These function blocks allow alternate names to be ‘passed’ to the driver from the RTU logic application. Typically the new names/values will be read from a text file and invoked at the next RTU restart.