HiveMQ, Opto22, and Ignition

If you saw our post about using the Cirrus Link modules with Ignition and a groov RIO you got a taste of what is possible with MQTT. If you’ve been following anything Opto22 has been doing in the past few weeks, or you have gone through our post on choosing an MQTT broker and went with HiveMQ you are probably ready to get it set up.

Since we have already gone through the process of setting up our groov RIO for MQTT, we figured it was good to walk through how to set it up with HiveMQ. Because you are likely also using Ignition we’ll set it up to talk to the HiveMQ broker as well for a full end-to-end MQTT setup using their cloud broker.

Getting Started With HiveMQ

The first step is to sign up for a HiveMQ account and set up their cloud broker. If you upgrade to the paid plan you will have access to some more functionality. Since we are just getting started for now we’ll use the free trial that works with up to 100 devices. To sign up go here and click the “Sign Up Now” button. This will set up your account and create a cluster for you to use for your HiveMQ broker.

HiveMQ Cloud Sign Up Screenshot

Once you have your account and cluster set up you will want to grab the URL for use in the groov RIO and Ignition when we connect those to the broker.

HiveMQ Broker Configuration

You will also need to click the “Access Management” tab and create a user so you can login to the broker from our MQTT clients.

Here we created “corsohive” and “corsorio”

HiveMQ Cluster Configuration

Configuring the groov RIO for MQTT

Next we will open up our groov RIO configuration page, click “MQTT”, “MQTT Configuration”, then “Add MQTT Broker”.

Now you will enter your HiveMQ information. The free trial version of HiveMQ doesn’t handle mutual certificates so you don’t need to worry about those for now, but you will add your URL, username, password, and port. The one item to note is you will prefix the URL with ssl:// instead of tcp://.

groov RIO MQTT Configuration

Click “OK” then save the configuration.

Next we can go to our Ignition gateway and set up the connection there. Go to the Config->MQTT Engine page, then the “Servers” tab and click “Create new MQTT Server Setting…”. Here you will enter the information in similar to what we did on the groov RIO, leaving the TLS settings at the bottom blank since we are using the trial of HiveMQ.

Ignition MQTT Broker Index Page

Ignition MQTT Broker Index Page

Ignition MQTT Broker Main MQTT Configuration Parameters

Ignition MQTT Broker Main MQTT Configuration Parameters

Ignition MQTT Broker TLS Configuration Parameters

Ignition MQTT Broker TLS Configuration Parameters

Now we can go into our Designer and we will see the data populating from the groov RIO through HiveMQ, into Ignition.

Ignition Edge Nodes Tag Browser Screenshot

Next Steps

From here you have MQTT data coming from the groov RIO into Ignition with HiveMQ as the broker. Now, you can:

  • Add more MQTT devices to your HiveMQ broker to get more data flowing

  • Build some Ignition screens to do something interesting with your data

  • Add more data to the groov RIO so you can have more data populating into Ignition

  • Add something like AWS or Azure to the mix to pull your data into a data lake or AWS Sitewise

  • Integrate with other MQTT systems to use your data in other ways beyond the Ignition platform

If you watched the wonderful Benson Hougland on his webinar HiveMQ: Intro to MQTT & Sparkplug B great, if not you should check it out, you’ll see that while the backend of what is going on here is far from simple, the possibilities and the ease of use of getting MQTT set up are absolutely astounding.

Previous
Previous

How to Increase Pre Roll Machine Efficiency

Next
Next

Gamifying Manufacturing