Expanding your IoT Impact with the TOP Server MQTT Client Driver

7 min read

Jun 20, 2024 2:00:00 PM

Welcome back to our Summer of IoT blog series! In this third installment, we continue our journey through the fascinating world of IoT, delving deeper into the transformative technologies Software Toolbox has to offer for shaping our connected future. Today, we will be highlighting the TOP Server MQTT Client driver and demonstrating how it can effortlessly integrate real-time data from MQTT brokers into your existing industrial automation systems, such as your HMI, SCADA, MES, or Historian.

The TOP Server MQTT Client driver includes a depth of functionality and features that will ensure secure data acquisition with robust encryption and authentication options, including SSL/TLS support, username/password authentication and user-configurable Client IDs. It also includes flexible support for JSON name/value pairs (read-only), configurable port numbers, and client certificate validation. The driver offers the standard ease of use that TOP Server is known for by configuring the MQTT Broker information at the channel level, accommodating up to 60 brokers per instance, while MQTT Topic information is set at the device level, supporting up to 1024 topics per broker connection. This driver also offers the sought-after automatic tag generation feature allowing for ease of data point acquisition and implementation with just a few clicks.

In this demonstration, we’ll build off of last week’s video tutorial where we learned how to integrate weather data from a RESTful API endpoint and publish to the HiveMQ broker. Now, we’ll show how the TOP Server MQTT Client driver facilitates real-time data transfer into your automation environment by tapping into the weather data from that same HiveMQ Broker. Using the TOP Server Advanced Tags plug-in, we will manipulate the raw data values into more user-friendly visualizations, and by leveraging the SuiteLink Client interface, we will establish a reliable connection between the HiveMQ Broker and a simple AVEVA InTouch Application. So, let’s get started as we highlight TOP Server’s capabilities of bringing together diverse data sources for improved interoperability and data accessibility.

Connecting to the HiveMQ Broker

MQTT Broker information is configured at the channel level, including:

  • Desired connection name
  • Host address
  • Port
  • Security and Authentication
  • MQTT Server version (Auto, 3.1.0, 3.1.1)
  • Subscription QoS (0, 1, 2)
  • Communication Timeout Properties

TOP Server Hive MQ Channel Config

In this example, the TOP Server MQTT Client connection to the HiveMQ Broker was established remotely, resulting in the host address to have the IP Address specified. We have left Security and Client Certificate disabled with no authentication, but this is for demonstration purposes only, and as always, we highly recommend leveraging TOP Server’s secure functionality wherever possible, as outlined in our TOP Server Secure Deployment Guide.

Connecting a Topic and Generating Tags

Once the connection to the MQTT Broker is established by configuring a Channel, the Device configuration wizard only requires a Device Name and specified Scan Mode. For example, the device was named "Weather" because we are tracking weather data from the OpenWeatherAPI via the HiveMQ MQTT Broker. After the Device configuration wizard is complete, the user can go back into the Device Properties, where the Tag Generation options are now available, including the Topic field.

TOP Server Hive MQ Device Config

Before we automatically generate the tags from HiveMQ, we can see that in the screenshot above, Tag1 was manually created with the address "local/weather#Payload" to view the entire MQTT payload string.

TOP Server MQTT Payload OPC Quick Client

For more information on how to manually address MQTT topics and data values, please reference the TOP Server MQTT Client driver help file.

For Automatic Tag Generation, it's recommended to configure each MQTT Topic to its own device. In our example, once we click “Create Tags”, 29 tags were obtained from the topic "local/weather" in HiveMQ. If the data was being published at a slower rate to our broker, increasing the Discovery Duration setting may be necessary.

TOP Server Auto Tag Generation

TOP Server MQTT Data_OPC Quick Client

A 3rd party test tool like MQTT Explorer can help determine the required topic for generating tags.

TOP Server MQTT Explorer Topic

Data Manipulation

Another benefit of integrating MQTT data through TOP Server is the ability to manipulate data using Advanced Tags. This feature allows us to convert raw values into meaningful, user-friendly data. For instance, we converted temperature values from Kelvins to Celsius and Fahrenheit using simple equations, making the data more applicable in industry settings.

TOP Server Advanced Tags Temperature Conversion

TOP Server Advanced Tags OPC Quick Client

The Advanced Tags configuration window shows one of the Expressions we used to accomplish this, and the Quick Client shows that we are able to retrieve our temperature readings in our desired units. The Advanced Tags Plug-In could also be used to bridge or link the data from your MQTT Broker with another device, OPC Server, or even another MQTT Broker that is connected through TOP Server. With TOP Server’s extensive list of supported drivers, the possibilities are endless! We have a great blog on Using TOP Server’s Advanced Tags Plug-In if you would like to learn more.

Integrating with AVEVA and Other Clients

With HiveMQ data now defined in TOP Server, it becomes available to many other platforms and applications. While we chose to create a simple AVEVA InTouch Application to illustrate this capability, this could also be accomplished with AVEVA System Platform, AVEVA Historian, or any other HMI, SCADA, MES, or Historian that supports OPC DA, OPC UA, or SuiteLink. This demonstrates the seamless integration of MQTT data into industrial applications. This setup not only simplifies data visualization, but also enhances situational awareness and decision-making processes. 

TOP Server InTouch Application


In conclusion, our exploration of the TOP Server MQTT Client driver within this installment of this blog series has highlighted the great potential of integrating real-time MQTT data into your industrial automation systems. We demonstrated the seamless configuration and robust security features of the TOP Server MQTT Client driver, as well as its useful data manipulation capabilities using the Advanced Tags Plug-in. By introducing a simple AVEVA InTouch application, we showcased the ease of transforming raw data into valuable insights, enhancing operational efficiency and decision making in all your various systems. As we continue to delve deeper into IoT technologies, TOP Server should stand out as a crucial tool for optimizing data accessibility and interoperability in an increasingly connected world. 

Be sure to subscribe to our blog for more tips, tricks, and how to videos. If you have any questions or need assistance, don’t hesitate to reach out to our support team.

Want to get started integrating real time MQTT data with your industrial systems? Download a free trial of TOP Server today!

New Call-to-action

John Gonzalez
Written by John Gonzalez

Software Toolbox Technical Blog

We're engineers like you, so this blog focuses on "How to" appnotes, videos, tech team tips, product update announcements, user case studies, and other technical updates.  Subscribe to updates below. Your feedback and questions on posts are always welcomed - just use the area at the bottom of any post.

Subscribe to our Blog

Recent Posts

Posts by Topic

See all