Just wanted to share this information

I have been working with the Raspberry Pi 4B and Node Red. I have configured this unit to read with Modbus/Tcp a Automation Direct Brx Plc, Siemens Logo Plc, AB Micro820 Plc. All 3 of these Plc's are on the same network but different machines that I needed to get the Tag Values back to my Ignition Server with Mqtt Sparkplug b protocol.

This Raspberry Pi 4B works like a champ, I was spending 4 times what the Pi cost for my Mqtt gateway.

2 Likes

Can we get a more in depth how you did it? lol

Node Red has all kinds of IIOT nodes that can be downloaded and used for creating your "Flows". This is how I created my Flow.

I have a project that is using 3 different bands of Plcs each plc runs it's own piece of equipment, we also have 2 40hp Schneider Altivar 630 drives running blowers. I wanted to get different data tags from each piece of equipment and get it to my Ignition server, because once on my server I can store to Sql Database, create Trends, Graphs, and all kinds of various reports.

So using the Node Red Modbus node and setting up the different configuration needed to communicate with all the devices, I programmed the driver to poll all device at a 90s cycle. Once this has been polled I publish these tags using Mqtt Sparkplug B (Also a Node that can be downloaded). back to my Ignition server and store into Sql Database.

So I am polling data from both Vfd's, 3 different Plcs and publish this data with the Mqtt Sparkplug B node. And only changed data get published.

This was very easy to setup and works very well. This is what it cost me.
Raspberry Pi 4B ($135.00)
Mean Well PS 120vac to 5vdc din rail mount ($22.00)
Din rail mount for Raspberry Pi ($14.00)

All this get mounted into my existing enclosure.

P.S. I also use the Pi to run several different Api's for various kinds of DATA I retrieve from the WEB.

Super simple to setup and it works.

1 Like

PS. You should change the topic title to be more relevant to the content

4 Likes

What device did you use to connect the modbus to the PI ? a HAT or USB device ? I'm trying to come up with a way for the PI to read a modbus GPS device but pass it straight to edge so hopeing edge can find the modbus device through the PI.

How did you find setting up the spark plug flow ? I found it a copy/paste chore setting up the birth message unless you found a easier way? especially compared to drag and drop like the maple systems device I think you were using ? Albeit, 4 x the cost.

It is certainly a versatile device. I used it for Edge, reading data from a siemens 1200 series PLC. Also use them in my home reading temps around the AC system and reading all my Z wave and zigbee devices from hubitat though node red.

All devices are ethernet based.

I have the Pi setup to poll each of these Modbus/Tcp devices (Siemens Logo, AB Micro820, Automation Direct Brx, (2)Schneider Altivar 630 Vfd) my poll rate is every 90s, actually the poll rate is 5 s apart . I do have 5 different configuration for the Modbus/Tcp Client. I merge all the tags returned into a single Mqtt sparkplug b node that is triggered the same time as the modbus poll. (Keep in mind Sparkplug B will only publish changed data). The Sparkplug B node was very easy to setup, I pointed it to my Mqtt Broker, I have a special "Group" that it can connect to, from there everything was really simple. I did create a "Function Node" that I formated my msg.payload with the Tag name I wanted Ignition to see.

My question to you would be does your GPS device offer a Cloud Based Dashboard? If so, could you not retrieve that data from their web site by running an Api call from the Pi.

Within my same flow I call two Api's, one retrieves stock market data and the other retrieves weather data.