Modbus TCP vs. Modbus RTU

I went to one of those yogurt shops the other day, you know what I’m talking about, right? You walk in, get a cup and select from the 10 or 20 different yogurt flavors. Some are labeled “fat-free.” I find it interesting that the others don’t say “fat added” or “lots of fat in this one” or “really tasty with all the added fat.”

Once you’ve filled your cup with one of the fatty yogurts, there’s a bunch of different fruit you can put on top along with a huge selection of nuts and copious toppings that all could just be labeled “sugar.” In the end, you end up with three times more yogurt and twice as much sugar as you usually have in a week, all for a price you’d be ashamed to admit you paid.

Now, Modbus might not have as many options as the yogurt shop, but you have to start with a choice: Ethernet or Serial. Ethernet is, of course, a lot faster and a bit easier to troubleshoot but it’s not a slam dunk that you want to use Ethernet for your Modbus communications.

For one thing, the Modbus frame that travels inside an Ethernet TCP packet is the same size (about 220 bytes) as the frame for a serial message. They didn’t change that frame one lick when moving from serial to Ethernet.

With Ethernet, you need to get an expensive switch involved. With serial, you can just daisy chain all the devices together. Devices with old 8-bit processors and a tiny bit of memory can easily handle Modbus serial but you’ll need a more expensive platform to do Ethernet.

What about troubleshooting and configuration?

It’s true that with serial you have to set the serial baud rate, parity and data bits, but with Ethernet, you need to set an IP Address. And since Dynamic Host Configuration Protocol isn’t really used on the factory floor, you have to find a way for the user to get an IP Address into the device. I will give you that it’s much easier to troubleshoot.

The biggest benefit of Modbus TCP vs. Modbus RTU is that you’re not limited to one polling device. In Modbus RTU, you have one single master device. Any additional masters would destroy the network communications. That’s not a big deal at first: you have a simple machine with a dozen devices and a single controller, so all is well. But inevitably down the road, you’ll need to pass data from one or more of those devices to a new SCADA system, HMI or other control protocol. With RTU you either have to replace the controller or alter its configuration. Any data access needs to be directed through the existing master. That means you are likely digging into controller code written decades ago. Not as fun as making a frozen yogurt sundae.  With Modbus TCP/IP, multiple client devices can poll end devices. The new HMI or SCADA can simply add the devices requested to its scan list without altering the current machine network.

What About Speed?

I can hear a bunch of readers out there screaming “Throughput” or “Speed” or “100 Meg Networking” followed by “you moron.” Of course, the Ethernet devices are going to be faster, but the question is: how fast do you really need to go? I had a customer once with an injection molding machine that dropped a new part every 6 seconds. Every six freakin’ seconds he would send 125 bytes of data back to his controller. He had that baby hooked up to a 1-Gig Ethernet network when a 150-baud serial would have been perfectly fine.

And it’s like that with a lot of Modbus devices. All these level sensors, temperature sensors, energy meters, and the like? None of them really need to report data very fast. Getting data every few seconds is almost always just fine. Throughput is rarely a requirement to use RTU over Ethernet.

Now Modbus Serial is no tea party. I’m not saying it is. You can have a lot of issues trying to get the RS-485 network to work right. You have to deal with wire termination issues, network termination issues, and more configuration issues than Ethernet devices. Today, we also have a labor market that didn’t grow up using anything but Ethernet communications.

What’s Better?

Call me a dinosaur, but overall, I still would take Modbus RTU devices over Modbus TCP. Their simplicity, wiring and cost offer efficiency and nostalgia that I appreciate. However, absent my old soul, the more prudent choice, when a choice is presented, is to go with Modbus RTU. The small premium you pay upfront will be well worth it as you or those that come after you troubleshot and maintain the system.

And if you want to move devices from other networks to Modbus, the Enginerd® I’ve locked in the Engineering lab (they do get access to the pool table once a day) have delivered a whole bunch of RTU gateways that are pretty impressive. Take a look at the list below.

Connect Modbus RTU Slaves to a Modbus TCP/IP Client

Connect DeviceNet Slaves to a Modbus RTU Master

Connect Modbus RTU Slaves to a BACnet/IP Client

Connect a Modbus RTU Master to an EtherNet/IP Scanner

Connect Modbus RTU Slaves to a DeviceNet Master

Move Modbus TCP Servers to a Modbus RTU Master

Connect Modbus RTU Slaves to an Allen-Bradley PLC

Connect a Modbus RTU Master to a BACnet/IP Client

Connect a Modbus RTU Slaves to an ASCII Device

Modbus RTU Master to a Modbus TCP/IP Client

Connect a Modbus RTU Slaves to a TCP/IP Device

Modbus RTU Master to ASCII

Connect Modbus RTU Slaves to BACnet MS/TP

Modbus RTU Master to EtherNet/IP Adapter

Modbus RTU Slaves to an Allen-Bradley PLC

Modbus RTU Master to DeviceNet Master

Modbus RTU Slaves to Modbus TCP/IP Server

Modbus RTU Master to Ethernet TCP/IP

Modbus RTU Slaves to EtherNet/IP Scanner

Modbus RTU Master to PLC

Modbus RTU Slaves to Profinet IO Controller

Modbus RTU Master to Profinet IO Controller

Modbus RTU Slaves to Profibus DP Master

 

And here’s a list of similar TCP/IP gateways.

Modbus TCP/IP Server to BACnet/IP Client

Modbus TCP/IP Client to ASCII

Modbus TCP/IP Server to EtherNet/IP Scanner

Modbus TCP/IP Client to ASCII Four Port

Modbus TCP/IP Server to Modbus RTU Master

Modbus TCP/IP Client to Modbus RTU Slave

Modbus TCP/IP Server to ASCII

Modbus TCP/IP Client to DeviceNet Slave

Modbus TCP/IP Server to ASCII Four Port

Modbus TCP/IP Client to Modbus RTU Master

Modbus TCP/IP Server to Allen-Bradley PLC

Modbus TCP/IP Client to BACnet/IP Client

Modbus TCP/IP Server to DeviceNet Master

Modbus TCP/IP Client to EtherNet/IP Adapter

Modbus TCP/IP Server to BACnet MS/TP Master

Modbus TCP/IP Client to Ethernet TCP/IP

Modbus TCP/IP Server to Modbus RTU Slave

Modbus TCP/IP Client to DeviceNet Master

Modbus TCP/IP Server to Profinet IO Controller

Modbus TCP/IP Client to Allen-Bradley PLC

Modbus TCP/IP Client to EtherNet/IP Scanner

Modbus TCP/IP Client to Profinet IO Controller

Give the RTA sales team a call at 800-249-1612 and someone will be glad to help you figure out what you need for your specific application. Don’t call me. I’ll be over at the yogurt shop: lots of “fat added” yogurts I haven’t tried yet.

John