Basics of PLC Programming
By Habtamu M.
Mechanical Eng’g Dep’t
1
PLC Programming Languages
Ladder diagram Functional chart
Boolean Language
2
Comparing Programming Languages
Relay Schematic
•
Equivalent Ladder Diagram
Boolean Language
3
Relay -Type Instructions
These ladder instruction symbols are arranged to obtain
the desired control logic.
4
Relay -Type Instructions…
Symbol is analogues to Normally open relay
contact.
Represents any input . It can be any switch
The status bit will or pushbutton, a contact from a connected
be either 1 or 0. output, or a contact from an internal output.
5
Normally Open (NO) Instruction
The status bit is 0 means no input
Contact is open The instruction is FALSE
6
Normally Open (NO) Instruction…
The status bit is 1 means input is given
Input makes contact to close The instruction is TRUE
7
Relay Type Instruction…
Symbol is analogous to normally closed relay
contact.
Represents any input. It can be a switch or a
pushbutton, a contact from connected output or
a contact from an internal output.
The status bit will be either 1 or 0.
8
Normally Closed (NC) Instruction
The status bit is 0 means no input
Contact is closed the instruction is TRUE
9
Normally Closed (NC) Instruction…
The status bit is 1 means input is given
Input makes the contact to open the instruction is FALSE
10
Output Energize (OE) Instruction
Represents output. Analogous to the relay coil.
The processor makes this instruction true (analogous to energizing
a coil) when there is path of true NO and NC instructions in the
rung.
That is, If any left-to-right path of input conditions is TRUE, the
output will be energized (turned ON).
It can be a connected device or an internal output (internal relay).
11
Output Energize (OE) Instruction …
Output energize instruction-TRUE
12
Output Energize (OE) Instruction …
Output energize instruction-FALSE
13
Status Bit Examples
A Input module Bit status for A
14
Status Bit Examples…
A Input module Bit status for A
15
Ladder Rung
A ladder rung consists of a set input conditions, represented by
contact instructions, and an output instruction at the end of the
rung, represented by the coil symbol.
16
Ladder Rung…
For an output to be activated or energized, at lest one left-to-right
path of contacts must be closed. A complete path is referred to as
having logic continuity.
When logic continuity exists, the rung condition is said to be TRUE.
17
Ladder Rung…
18
Parallel Output Branching
On most PLC modes, branches can be established at both the
input and output portion of the rung. With output branching ,
we can program parallel outputs on the rung to allow a true
logic path to control multiple outputs.
19
Internal Control relay
The internal output operates just as any other output that is
controlled by programmed logic; however, the output is used
strictly for internal purpose.
The internal output does not directly control an output device.
The advantage of using internal outputs is that there are many
situations where an output instruction is required in a program,
but no physical connection to a field device is needed. Their use
in this type of instance can minimize output card requirements.
20
Extending the Number of Series Contacts Using
an Internal Control Relay
21
Operation of NO and NC instructions
Status of output as obtained by changing the status of the
inputs in the rung.
22
Operation of NO and NC instructions
23