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.

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.
Each year, a panel of Control Engineering and Plant Engineering editors and industry expert judges select the System Integrator of the Year Award winners in three categories.
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.
Additive manufacturing benefits; HMI and sensor tips; System integrator advice; Innovations from the industry
Robotic safety, collaboration, standards; DCS migration tips; IT/OT convergence; 2017 Control Engineering Salary and Career Survey
Integrated mobility; Artificial intelligence; Predictive motion control; Sensors and control system inputs; Asset Management; Cybersecurity
Featured articles highlight technologies that enable the Industrial Internet of Things, IIoT-related products and strategies to get data more easily to the user.
This article collection contains several articles on how automation and controls are helping human-machine interface (HMI) hardware and software advance.
This digital report will explore several aspects of how IIoT will transform manufacturing in the coming years.
Infrastructure for natural gas expansion; Artificial lift methods; Disruptive technology and fugitive gas emissions
Mobility as the means to offshore innovation; Preventing another Deepwater Horizon; ROVs as subsea robots; SCADA and the radio spectrum
Future of oil and gas projects; Reservoir models; The importance of SCADA to oil and gas
Automation Engineer; Wood Group
System Integrator; Cross Integrated Systems Group
Jose S. Vasquez, Jr.
Fire & Life Safety Engineer; Technip USA Inc.
This course focuses on climate analysis, appropriateness of cooling system selection, and combining cooling systems.
This course will help identify and reveal electrical hazards and identify the solutions to implementing and maintaining a safe work environment.
This course explains how maintaining power and communication systems through emergency power-generation systems is critical.