Relay Ladder Logic

04/01/1998


Ladder diagrams, or Relay Ladder Logic (RLL), are the primary programming language for programmable logic controllers (PLCs). Ladder logic programming is a graphical representation of the program designed to look like relay logic. This convention goes back to the early days of PLCs when electricians and technicians were trained in relay logic and expected to troubleshoot these new devices as well.

The drawings show both the similarities and differences in the two types of programs. The relay logic drawing shows switches electrically connected to coils-solenoids, pilot lights, etc. The ladder diagram uses contacts to represent the switches, or any input, and the coil symbol to represent an output. A line showing an input or several inputs and an output is known as a rung.

The relay diagram used electrical continuity to show a rung as electrically closed. Ladder logic programming shows the results of a status check of the inputs and outputs where the conditions are true or not true. The original intent of RLL was to provide a way for the controller to solve logic sequences involving discrete signals.

Basic and function block rungs
The top rung of the ladder diagram shown represents a basic rung of logic. It consists of a set of input condition instructions, represented by contact symbols, and an output instruction, represented by a coil symbol. Condition instructions are placed on the left side of the rung and may be in series, parallel, or a combination of the two to determine the desired control logic. The output instruction is placed on the right side of the rung.

The line on the left side of the rung represents the imaginary 'hot' power trail while that on the right side is the imaginary 'neutral.' If any left to right path on a rung is 'closed' or 'made,' then the rung is said to be 'true' and the output is energized. This is also known as logic continuity.

As the computer chip used in the PLC became more powerful, engineers saw that there were many more uses for these controllers. The PLC became more of a computer and not just a 'relay replacer.' To take advantage of this power, additions to the instruction set were necessary. Thus were born 'function blocks.'

In most controllers, operations such as timing, counting, arithmetic, data transfer, and other advanced operations are represented by a block diagram (see the second rung in the example). Since these instructions are performed when a certain set of input conditions are true, these are considered output instructions even though sometimes there is no 'output' performed.

In the example there are outputs following the block. When the conditions are true to enable the block instruction (EN), then the block instruction will perform its operation. Upon completion of that operation the output will be energized. Sometimes the data in the block must be reset so that the operation can begin again. A rung of logic can be constructed so that when certain input condition instructions are true the block is reset (R).

This article draws upon information from Programmable Logic Controllers: The Complete Guide to the Technology, by C.T. Jones, published by Patrick-Turner Publishing Co., Atlanta, Ga. Telephone number (770)956-7992.





No comments
The Engineers' Choice Awards highlight some of the best new control, instrumentation and automation products as chosen by...
The System Integrator Giants program lists the top 100 system integrators among companies listed in CFE Media's Global System Integrator Database.
The Engineering Leaders Under 40 program identifies and gives recognition to young engineers who...
This eGuide illustrates solutions, applications and benefits of machine vision systems.
Learn how to increase device reliability in harsh environments and decrease unplanned system downtime.
This eGuide contains a series of articles and videos that considers theoretical and practical; immediate needs and a look into the future.
Save energy with automation; Process control system upgrades; Dispelling controll myths; Time-sensitive networking; Control system integration; Road to IANA
Additive manufacturing advancements; Machine vision enhances robotics; Fieldbus evolution; Process safety; Advice from System Integrators of the Year; Road to IANA
Salary and career survey: Benchmarks and advice; Designing controls; Remote data collection, historians; Control valve advances; Hannover Messe; Control Engineering International
This article collection contains several articles on the Industrial Internet of Things (IIoT) and how it is transforming manufacturing.

Find and connect with the most suitable service provider for your unique application. Start searching the Global System Integrator Database Now!

The digital oilfield: Utilizing Big Data can yield big savings; Virtualization a real solution; Tracking SIS performance
Getting to the bottom of subsea repairs: Older pipelines need more attention, and operators need a repair strategy; OTC preview; Offshore production difficult - and crucial
Digital oilfields: Integrated HMI/SCADA systems enable smarter data acquisition; Real-world impact of simulation; Electric actuator technology prospers in production fields
click me