A better way to get OPC data into Microsoft Azure
Aron Semle
is the Chief Technology Officer of HighByte, focused on guiding the company’s product strategy through research and development and technical evangelism. Aron has served in a variety of roles in his 15-year career in industrial technology, including software engineer, product manager, R&D lead, and director of solutions management, building innovative software solutions for the manufacturing operations market. Aron received a Bachelor of Science in Computer Engineering from the University of Maine.
Let’s talk about getting OPC data into Microsoft Azure. When you search this phrase in Google, 90% of results provide this use case: streaming sensor data to the Cloud.
If your Industry 4.0 solution is streaming sensor data to the Cloud, you're doing it wrong. Now let me explain.
On the factory floor, we have machines driven by PLCs, and we typically have an OPC server connected to those PLCs that feeds data into an HMI. OPC servers and HMIs work with tags, which are discrete streams of data. For example, one tag might be for pressure and another might represent the on and off state of the machine. When cloud technology like Microsoft Azure first entered the scene, vendors created IoT gateways to connect to the OPC server and send tag streams to the Cloud in a JSON format. It was the easiest thing to do, and once that connection was made, we thought we were done.
If your Industry 4.0 solution is streaming sensor data to the Cloud, you're doing it wrong. Now let me explain.
On the factory floor, we have machines driven by PLCs, and we typically have an OPC server connected to those PLCs that feeds data into an HMI. OPC servers and HMIs work with tags, which are discrete streams of data. For example, one tag might be for pressure and another might represent the on and off state of the machine. When cloud technology like Microsoft Azure first entered the scene, vendors created IoT gateways to connect to the OPC server and send tag streams to the Cloud in a JSON format. It was the easiest thing to do, and once that connection was made, we thought we were done.
The Problem
But here’s the problem: we never tried to build anything in the Cloud. It turns out that 80% of use cases in the Cloud do not want to deal with tag streams; they want well-modeled data.
Picture this: You want to visualize plant floor data in Microsoft Power BI for an analytics initiative you’re working on, and you have a machine with a rich data model on the factory floor. Instead of sending this data model, you connect an IoT gateway and start publishing the tags to Azure IoT Hub. From IoT Hub, the data goes to Azure Stream Analytics, and from here you pipe it into Power BI and start building dashboards. But then you see a problem. What’s tag “D32.HH.102” or “D32.HH.103”? You quickly realize you need to model this data, otherwise you don’t know what the tags are, and you have tens, hundreds, or even thousands of tags.
So now you go back to Stream Analytics and find out you can’t do the modeling there with only the tag names. So you temporarily store the tag streams in Azure Cosmos DB and spend a significant amount of time writing Azure Functions in C#, Java, or NodeJS to manipulate these tag streams and build them back into the data models.
And here's the problem: You might figure it out for one machine, but when you move on to the next, the tag names are different. Those tag names were created to share information between an OPC server and the HMI, and they were never intended to be used to re-model data in the Cloud.
You end up with a solution that doesn’t scale and is expensive to maintain. There needs to be a more efficient way to visualize modeled information in Power BI, or your analytics initiative will never get off the ground.
Picture this: You want to visualize plant floor data in Microsoft Power BI for an analytics initiative you’re working on, and you have a machine with a rich data model on the factory floor. Instead of sending this data model, you connect an IoT gateway and start publishing the tags to Azure IoT Hub. From IoT Hub, the data goes to Azure Stream Analytics, and from here you pipe it into Power BI and start building dashboards. But then you see a problem. What’s tag “D32.HH.102” or “D32.HH.103”? You quickly realize you need to model this data, otherwise you don’t know what the tags are, and you have tens, hundreds, or even thousands of tags.
So now you go back to Stream Analytics and find out you can’t do the modeling there with only the tag names. So you temporarily store the tag streams in Azure Cosmos DB and spend a significant amount of time writing Azure Functions in C#, Java, or NodeJS to manipulate these tag streams and build them back into the data models.
And here's the problem: You might figure it out for one machine, but when you move on to the next, the tag names are different. Those tag names were created to share information between an OPC server and the HMI, and they were never intended to be used to re-model data in the Cloud.
You end up with a solution that doesn’t scale and is expensive to maintain. There needs to be a more efficient way to visualize modeled information in Power BI, or your analytics initiative will never get off the ground.
The Solution
Allow me to propose a better way.
Instead of breaking down your rich factory data into tag streams and then rebuilding these models in the Cloud, what if you could send contextualized data models to Microsoft Azure?
Imagine for a moment you have an injection molding machine and you want to move specific data from this asset (like cycle time and max temp) into Microsoft Azure. You send the structured, contextualized data model to IoT Hub and then on to Stream Analytics, which can easily work with this data type. With four lines of code or less, you are able to send this rich information to Power BI for visualization—which automatically populates your dashboard with this model.
So how does it work? Allow me to introduce HighByte Intelligence Hub. This lightweight application enables you to establish connections, build data models, and create flows to send information to Microsoft Azure—or wherever else it needs to go. HighByte Intelligence Hub is platform- and system-agnostic and runs at the Edge, near your data sources.
With HighByte Intelligence Hub, you don’t need to do the work of putting tags back together in the Cloud. The data model is already there, filled with all the rich information you have on the factory floor. That’s the benefit of sending structured, contextualized data to the Cloud.
Watch this demo to see how I was able to connect, model, and flow OPC data to Microsoft Azure and populate my Power BI dashboard in just 3 minutes.
If you’ve ever tried to take tag stream data and re-build models in the Cloud, I hope you’ll agree this is a better way. If you’re ready to try it for yourself, please request a free trial of HighByte Intelligence Hub.
Get started today!
Join the free trial program to get hands-on access to all the features and functionality within HighByte Intelligence Hub and start testing the software in your unique environment.