Setting Up Redundant PLCs with Modbus RTU for System Backup

Question:

Hello everyone, I'm seeking help on setting up a redundant master on Modbus to enable a backup PLC in my system. I aim to implement a system with two PLCs (primary and redundant) running the same program. In case the primary PLC fails, the redundant PLC will take over. I plan to utilize Modbus RTU (specifically Carel Modbus RTU) as the communication protocol, with the Carel cPCO Mini as the controller. Each controller boasts two Modbus ports. Given that Modbus is a single master protocol, my idea is to use the first Modbus port to establish a connection between the primary and redundant controllers to monitor the primary's status. The primary controller will function as the master on the second Modbus port, connecting to all sensors and devices. Similarly, the redundant controller will also act as a master on its secondary Modbus port, which will be inactive as long as the heartbeat signal between the controllers on the first Modbus port is consistent. In the event of a heartbeat error, the primary PLC's Modbus port 2 would be disabled, and the redundant PLC's Modbus port 2 would be activated. This setup would ensure redundancy with only one active master communicating with the sensors and devices at any given time. Will this approach be effective? Are there any crucial details I may have overlooked? While I have experience with Ethernet IP over the past four years, my knowledge of Modbus is more limited. Best regards, Wirelessliquid

Top Replies

While I am not familiar with that specific controller, it is crucial for the backup RTU master to stay inactive when not handling communication tasks and to have a distinct Station ID on the RTU network. However, these conditions can pose challenges. Certain PLCs may not allow the configuration of a port as a Modbus Master and the assignment of a Station ID. It is important to ensure that the Station ID numbers of both RTU masters are unique to prevent them from both becoming active simultaneously when a slave responds to a poll. This scenario could lead to communication interference.

Are you limited to using Modbus as your only communication protocol? While it may seem like a convenient choice, it may not be the best option for setting up redundancy. It could be challenging to ensure a smooth transition between the primary and secondary controllers, especially when it comes to controlling the outputs effectively. Without proper synchronization, the PLC not in control of the I/O devices may struggle to accurately track the states of the devices. To address this issue, you may consider using three ports on each controller. One port can be dedicated to I/O communication, with both PLCs connected on the same network wire as masters. However, only one PLC should send Modbus commands at a time to avoid conflicts. The other two ports can be configured differently - one with the primary PLC as master and the secondary as slave, and the other with the secondary as master and the primary as slave. Through these ports, status data can be exchanged, and the PLC managing the I/O devices can transmit the current states to the secondary controller, ensuring synchronization between the programs.

Hi Wirelessliquid, That's indeed a workable strategy to implement redundancy within a Modbus RTU system. However, you need to consider certain aspects. The switchover process from the primary to the secondary PLC must be seamless to ensure there is no loss in communication with the devices and sensors. It would be beneficial to devise a mechanism to track the 'state' of the primary controller so that the secondary controller can 'pick up from where the primary left off,' avoiding any hiccups in the process. More importantly, testing is paramount. Once your redundant system is up and running, subjecting it to various failure simulations will help you identify and iron out any flaws in your switchover strategy. As you refine the process, your system will become progressively robust and reliable. While your Modbus knowledge might be limited at present, you seem to be on the right path. As with any new paradigm, familiarity comes with exploring and handling real-world challenges. Best of luck with your project! Cheers!

Hello Wirelessliquid, Your plan seems robust on the surface and it adheres to the single master protocol of Modbus RTU, but one area where you might face issues is with the switchover time between the primary and redundant PLCs in case of failure. This is dependent on how fast your controllers can detect a heartbeat failure and transfer control to the redundant PLC. You may also want to consider adding redundancy for your sensors and devices, because even if you have a redundant PLC, a single sensor failure can still bring system operations down. For additional robustness, you could include an independent party to monitor both PLCs and manage the active-passive roles, like a watchdog system, but this would add complexity. Lastly, it's worth drafting a clear failure recovery protocol, detailing how your system would recover from the primary PLC going down and the redundant PLC taking over. Understanding and planning for these scenarios in advance is crucial in a redundancy setup. Hope this helps and all the best!

Hi Wirelessliquid, Your approach seems logical, but keep in mind that Modbus does have some challenges when it comes to redundancy. One of those challenges is its lack of a defined heartbeat, however, if you have a custom solution for that, it might work. It's also essential to consider how the devices will handle the switch from one master to another; they could experience a pause in data transfer during the switch. One alternative approach might be to use an "Active-Standby" method where your primary PLC constantly sends the status or data changes to the redundant PLC while remaining inactive. This keeps the redundant PLC updated with the status of the primary PLC and protects against any potential loss of data during the switch. Remember, testing is crucial before implementation especially considering Modbus' lack of native support for redundancy. Make sure to thoroughly test your setup to ensure that all devices respond well to the switching of masters. Best of luck with your project!

Hey Wirelessliquid! Your approach sounds quite solid, especially since you're leveraging the heartbeat signal to manage the master status dynamically. Just one thing to consider: ensure that your heartbeat signal is robust enough to handle any noise or delays in communication, as Modbus RTU can be a bit sensitive to timing issues. You might also want to think about how you'll handle any potential data discrepancies between the two PLCs when switching masters. It could be helpful to implement a mechanism for status synchronization right before a failover happens. Good luck with your setupβ€”it's great that you're prioritizing redundancy!

More Replies β†’

Streamline Your Asset Management
See How Oxmaint Works!!

βœ…   Work Order Management

βœ…   Asset Tracking

βœ…   Preventive Maintenance

βœ…   Inspection Report

We have received your information. We will share Schedule Demo details on your Mail Id.

You must be a registered user to add a comment. If you've already registered,
sign in. Otherwise, register and sign in.

Frequently Asked Questions (FAQ)

FAQ: 1. How can I set up redundant PLCs with Modbus RTU for system backup?

Answer: You can implement a system with two PLCs running the same program, where the primary PLC functions as the master on one Modbus port while the redundant PLC monitors the primary's status and takes over in case of failure.

FAQ: 2. Is Modbus RTU suitable for establishing communication between redundant PLCs?

Answer: Yes, Modbus RTU can be used for communication between redundant PLCs, ensuring a backup system is in place to maintain continuous operation.

FAQ: 3. Are there any specific considerations when using the Carel cPCO Mini controller for this setup?

Answer: The Carel cPCO Mini controller offers two Modbus ports, making it suitable for establishing connections between the primary and redundant PLCs while also communicating with sensors and devices.

FAQ: 4. What happens in case of a heartbeat error between the primary and redundant controllers?

Answer: In the event of a heartbeat error, the primary PLC's Modbus port 2 will be disabled, and the redundant PLC's Modbus port 2 will be activated, ensuring continuous operation and redundancy.

Ready to Simplify Maintenance?

Join hundreds of satisfied customers who have transformed their maintenance processes.
Sign up today and start optimizing your workflow.

Request Demo  β†’