Having used this code myself, I can say it's not for the faint at heart. But if you need your ControlLogix to communicate Modbus RTU, it might be worth your time to check out this free sample code to see if it'll meet your needs.

What if my ControlLogix doesn't have a serial port? Or if this sample code doesn't support enough data for my app?

If you're using one of the new 5570 ControlLogix processors, you've probably noticed you have a nifty new USB port in place of the legacy DB9 serial port.

And since these new processors don't have a built-in serial port, you obviously won't be able to use the above mentioned sample code.

But even with a processor that has a serial port, you may still find the free sample code too limiting for demanding applications.

In those cases you may wish to consider using a 1756 Modbus RTU communications module.

ControlLogix support for Modbus TCP

The new 1756-EN2Tx and EN3TR have been updated to support open sockets like the 1756-EWEB had in the past.

And on the Rockwell's sample code website you'll find an sample application which uses the open sockets to give ControlLogix processors the ability to be either a master or slave on a Modbus TCP network.

Note: According to Rockwell's public Tech N0te 470365, you'll need and 1756-EN2Tx or EN3TR version 5.007 or greater, or an EWEB version 4.006 or greated.

Having used this code recently, I can say it's well documented and fairly easy to use.

That said, unfortunately it's not quite as easy as using the MicroLogix 1400 on Modbus TCP (I really wish the wizards in the MicroLogix group would share their secretes of putting these protocols into firmware with the ControlLogix folks!)

What if I have the older 1756-ENBT?

If you're not using one of the new 1756 Ethernet modules, or the 1756-EWEB, your Ethernet port doesn't support open sockets, and therefore the above sample code isn't going to work for you.

In that case, or in the case where the capabilities of the sample code is too limited for your application, we again have the option of adding Modbus TCP capabilities by using one of the Prosoft communications module listed below: