Overview

When you communicate with a ControlLogix PLC, the protocol is not as efficient as the older PLC 5 style N7:0 addressing. This is the price you pay for the convenience of using tag names in a PLC.

With the ControlLogix PLC, you actually have to give it the complete tag name of each tag that you want. The PLC has to go find that tag in its database and return the data to you.

When ControlLogix first came out, you could only get one item in each packet, which meant performance was quite slow. Years later, Rockwell added what they call the CIP (Controller Interface Protocol) Multi-Item Request Packet.

ControlLogix Multi-Item Request Packet sizes are about 500 bytes and can contain the names of multiple PLC tag names that you would like to read. Every character in a tag name takes up about 1 byte.

Some of the 500 bytes are needed for the PLC command and general communication overhead. The point remains the same though: there are less than 500 bytes available to stuff tag names into a request packet.



Maximizing System Throughput

As with any programmable controller, there are a variety of ways to enhance the performance and system communications.

In this document, we will discuss the following items:

  • Set the PLC CPU time slice to 40%-50%
  • Use Array Tags
  • Use Global Tags only
  • Simultaneous Connections

Set the PLC CPU time slice to 40%-50%

One of the first things you should check in your system is the CPU time slice setting in your ControlLogix PLC. This is set using your RS Logix 5000 programming software. This value represents the percentage of available CPU time that is dedicated to communications activities by the PLC CPU.

It should be noted that the time slice settings for the CPU communications defaults to 10%.  For every 10 ms program scan that occurs, the controller spends 1 ms processing driver requests.

If the communication tasks are high priority, the time slice should be set at or above 30%. Set the slice from 10% to 40% to achieve the best balance of communication, performance, and CPU utilization. Values greater than 50% start to reach diminishing returns.

Use Array Tags

The best way to communicate with ControlLogix is through the use of Arrays and short PLC tag addresses. Arrays may have a long tag address name in the PLC. If there are numerous tags in the array, great gains in performance can be achieved due to the ability of a single request for all the tags within the 500-byte packet size.

One hundred tags can be read or written to in a single command. For example: If the Array is of size 100 (e.g.: MyTag is an array MyTag[0] to MyTag[99]), under 200ms would be reasonable yet still dependent on the number of other requests required to be serviced by the system and demands on ControlLogix.

Boolean arrays are treated differently: in protocol, a Boolean array is a 32-bit array. Thus, requesting element 0 is requesting bits 0 through 31.

Use Global Tags Only

In PLCs, the use of short tag names for tags other than arrays is also of great benefit. This is because the TOP Server packs the PLC tag addresses into the Multi-Item Request packet sent to ControlLogix. The 500-byte limit is what makes the shortness of the tag addresses so critical.

Creating all required PC communications tags under the Global file is one way of shortening the names because Global tags require the least amount of space in the Multi-Item Request Packet.

Local (e.g.: Program) tags may seem nice, but in the ControlLogix to get at a program tag (vs. a Global) we also have to put the text: Program:ProgramName in the packet. Plus, we have to add the tag name. You can see how 500 bytes can go fast.

Since we can import L5K file tag descriptions, it is not hard to then change the Server tag names to something more descriptive which would make HMI project creation easier. The key is that the ControlLogix PLC tag name be as short as possible, not the tag name used in the SCADA database.

Simultaneous Connections

In general, the limit on the number of Ethernet connections that can be made to a ControlLogix PLC is high. The default ControlLogix driver opens one TCP socket or connection to the PLC’s Ethernet module for each channel that is defined in the SCADA. However, in the ControlLogix Channel > Settings Column, you can change the number of the NodeConnections and Simultaneous Connections (default 1 and 1 respectively).

For example: If a user created a ControlLogix Channel with 15 node connections and 15 simultaneous connections, 15 TCP socket connections would be made. It means that you have 15 messages going to the PLC at the same time. It is 15 time faster than only one connection. In theory, if the PLC’s Ethernet module had a limit of 64 simultaneous TCP sockets, users could connect 64 simultaneous connection at the same time to the PLC.

As more connections are made to a controller, communication performance will begin to degrade based on the amount of data being acquired and the rate of acquisition. To refine the ratio of CPU time spent on processing and communications, refer to the PLC’s System Overhead Time Slice (SOTS) parameter description.

In summary, this can greatly increase the performance of your communication, but you need to balance it with the PLC’s Time Slice.


  • No labels