Hi, I'm test the MQTT connection for my project. I looking for information how to connect & read my PLC tags using MQTT instead of OPC-UA. Please refer the picture below, The connection between Ignition to Ignition I'm clear but I want know is there any way to connect the PLC to Ignition using MQTT communication.
I go through the 12 quick lessons topics but, that more discuss about connection between the Ignition.
Please give me your suggestion Thanks.
Only if your PLC supports MQTT. What brand/make/model of PLC are you working with? MQTT direct to/from PLCs isn't common. You would also need MQTT Engine and an MQTT broker (or MQTT Distributor) on the Ignition server, which I'm assuming you already know. There's always that middle piece in an MQTT system where Ignition or any system isn't talking directly to the other. MQTT clients always talk to a broker (even if the broker is installed on the same computer/server as Ignition), and Ignition is no different. Both the PLC and Ignition in this case are clients.
Thanks for the information. I have few question to clarify the MQTT using Ignition.
With the Ignition can we achieve the redundancy communication with clients.
If so, what is use of the Chariot MQTT server here.
You can't connect MQTT directly to PLCs, you need an Ignition Edge device in between the Ignition main server and PLCs. At the most you can connect multiple PLCs to an Edge Device if physically close,
Thanks lot. Can you please tell me how to connect my Primary Host to MQTT server#1 and MQTT Server#2. Also I have confusion on edge Client how to make automatically transfer my client to server#2 when Server#1 get failed.
You don't have to use Chariot MQTT. There are lots of MQTT brokers that work (including free ones). I personally use EMQx, some use Mosquitto, but whatever you use, just make sure it's secured properly and not publically exposed with no security at all or else you'll end up on Shodan with an exposed system with anyone able to read/write to your devices.
Hi, I try to setup test environment for MQTT communication, Please refer the picture below for architecture. I have trouble from my transmission gateway, I couldn't connect to primary server. I have attached the log screen-shot. Please give me your suggestions.
Make sure that you've got firewall ports open for 1883/tcp and 8883/tcp, as a "Connection timed out" error could be a result of dropped inbound packets on your MQTT Distributor gateways. Also keep in mind that at your .102 Transmission gateway, you'll want to define two servers, one for the Primary (.100) and one for the Backup (.101). You'll add those two servers to a server "set", and then point your transmitter at that server set. This will then allow Transmission to failover to the Backup when it takes over (and starts listening on port 1883/tcp).
Hi, Thanks for the reply, it's working fine now. I have attached pic of my settings at transmission side. I have one more questions, In case my Primary, Secondary & transmission in different location how can I make this communication. Please share your experience.
I'm not sure I understand your question. One thing that you'll want to do is to make sure that your Primary Host ID matches the setting that you configure in MQTT Engine.
If you're just saying they're in different networks, you just need to be sure you have a VPN or some network connecting them. One of our clients we have set up to go across VPN as the primary connection, but the secondary server on transmission is set to go across encrypted MQTT on port 8883 as the secondary if the VPN ever goes down. In this way all communications are encrypted no matter what, and we're covered by a VPN outage to allow it to connect across the internet (their MQTT server is open on the internet, but we have it pretty locked down between individual user accounts with like 20-character passwords, topic security using ACLs (each device only has write permissions to their own topic), and encryption.
If you're devices are in different locations, you'll want to setup TLS certificates and use secure MQTT over port 8883/tcp, as @michael.flagler described above
That really depends on how you set it up. If you're going over the internet, you may want to use a domain name instead of an IP. If you have a static IP you should be OK, but I've also seen where if you're hosting it yourself on your own servers, and you change ISPs, you'll get a new IP address and everything will break. I would consult with your IT department to make sure your network is figured out on how you'll be connecting so that you don't set it all up to only find out things aren't going to be networked the way you thought they would be.