Dr: Gamal Gouda
Course Contents
Definition of PLC & its importance to Control
Structure and main components of PLC
PLC Wiring diagram
PLC Programming Languages
Ladder Programming
Basics of Ladder Programming
Ladder from Relay diagram
Function Block Diagram FBD
Ladder diagram and equivalent FBD
Equivalent Ladder, Function Block & Boolean Equation
Counters in PLC
Industrial Examples
PLC definition & its importance to Control
PLC definition A digitally operating electronic apparatus which
uses a programming memory to store instructions to implement
specific functions such as logic, sequencing, timing, counting and
arithmetic to control an industrial process.
Importance to Control circuits
• Less wiring in control
• Wiring between devices and relay contacts are done in PLC
program.
• Easier and faster to make changes in control.
• Reliable components make these likely to operate for years
before failure
Structure and main components of PLC
Structure and main components of PLC
POWER SUPPLY
Provides the voltage needed to run the primary PLC components
I/O MODULES
Provides signal conversion and isolation between the internal
logic- level signals inside the PLC and the high level signal.
PROCESSOR
Provides logical operations to command the activities of the PLC
systems
PROGRAMMING DEVICE
Provides the desired program which determines the sequence of
operation and control of process equipment
Input / Output connections of PLC unit
PLC Wiring Diagram
PLC Output Wiring
• TheRelay is turned on if output 03 is true
•The Lamp is turned on if output 07 is true
PLC Programming Languages
Structure of a PLC program
A PLC program consists of rules that make logic relation
between inputs and outputs of the controller.
Basically it uses logic operands: AND, OR, negation
The structure of the rules is IF…THEN…ELSE…
•Inputs
•Outputs
• Switches and Pushbuttons
• Valves
•Limit Switches
• Motor Starters
• Photoelectric Sensors
• Solenoids
• Proximity Sensors
• Pressure Switches
• Actuators
• Level Switches • Control Relays
• Temperature Switches • Horns & Alarms
•Encoders •Indicators
PLC Programming Languages
Text based Graphical based
•Statement List SL • Ladder Diagram LD
• Instruction List IL • Function Block Diagram FBD
• Sequential Function Chart SFC
Functions and function blocks Graphic programming language derived
are represented graphically from the circuit diagram of directly
and interconnected into wired relay controls
networks
Ladder Programming
Basic Ladder Logic Symbols
Normally open contact Power (ON) if the contact is ON (closed)
Normally closed contact Power (OFF) if the contact is off (open)
Output or coil If any left-to-right path of inputs passes
power, output is energized
If any left-to-right path of inputs passes
Not Output or coil
power, output is de-energized
Input-Output Wiring
Input wiring
Operation Program
Output wiring
Basic Ladder Logic Symbols
Function Block Instructions
Power Rails, Rungs and Power
Flow
• Power Rails - Pair of Vertical
Lines
• Rungs - Horizontal Lines
• Contacts A, B, C, D… arranged on
rungs
Note in PLC Ladder Logic:
• No Real Power Flow (like in relay
ladder)
• There must be continuous path
through the contacts to energize
the output
Ladder Diagram
Correct Current Basics
Ladder Flow
logic follows a left to
right principle. current flows
through paths started from
either X0 or X3.
Reverse Current
When a current flows from
right to left, which makes a
reverse current logic, an error
will be detected
•Y0 is energized from paths
•x0x1x2 or x0x1x5 or x3x4x2
Or x3x4x5 or x3x6 but path
x0x1x4x6 is impossible
Ladder Diagram
Basics
•Reverse Current
•If the programmer wants to
energize Y0 by the contacts of
the path x0x1x4x6, he has to
modify the program
Correction
A correct path is now
developed such that there is
no reversed current flow
Ladder Diagram
Current Flow
Basics
Example
Correct the circuit with reverse current flow
•To energize coil PL1
•3 paths are possible
• Path ABC
•Path ADE
• Path FE
•One path is wrong (reverse)
FDBC
Correction