Você está na página 1de 122

PLC, SCADA, & System

I t
Integration
ti Intensive
I t i
Training
g for TI-Clark
- Part 1 = Principles of PLC Program Development -

By: Engr. Chuck Ebalo

Rev-2
Part 1 = Principles of PLC Program Development
Contents
1. What does PLC mean?
2. What is a PLC?
3 Historical
3. Hi i l development
d l
4. Hardware Components
5. Software Components
6. Configuration/Programming Methods
7. Electrical Ladder Diagram Development
8. Interpreting the E-Ladder with Actual Wiring
9. PLC Ladder Diagram Development – Logic Control
(Interpreting the E
E-Ladder
Ladder as a PLC
PLC-Ladder)
Ladder)
10. Interpreting the PLC-Ladder with Actual Wiring
11. Function Block Programming Method
12. Program Development Procedure
Part 1 = Principles of PLC Program Development
DAY 1
1. What does PLC mean?
2. What is a PLC?
3 Historical
3. Hi i l development
d l
4. Hardware Components
5. Software Components
6. Configuration/Programming Methods
7. Electrical Ladder Diagram Development
8. Interpreting the E-Ladder with Actual Wiring
9. PLC Ladder Diagram Development – Logic Control
(Interpreting the E-Ladder
E Ladder as a PLC
PLC-Ladder)
Ladder)
10. Interpreting the PLC-Ladder with Actual Wiring
11. Function Block Programming Method
12. Program Development Procedure
Meanings of the term PLC
In Medicine:
Phospholipase C
In Technology:
P
Power Li
Line Carrier
C i / Communication
C i i
In Business:
Product Life Cycle
In Education:
Presbyterian Ladies College
In the Philippines:
Philippine League of Councilors
Definition of the term PLC
1. Meaning:
Programmable Logic Controller
2. Function:
It is an electronic device designed
g to perform
p
logic functions that are previously performed
by electro-mechanical relays and timers.
3 Original
3. O i i l Concept
C off a PLC:
PLC
To replace the hard-wired, electrical relay-logic
control system with an electronic system capable
of changing the logic sequence by being
p g
programmable.
O i i l PLC Meanings
Original M i

PC “Programmable Controller”
UK origin

PLC “Programmable Logic Controller”


USA origin

PBS “Programmable Binary System”


g
Swedish origin
Definitions of the term PLC
Definition 1: NEMA (adopted from Capiel, 1962)
It is a digital electronic device that uses a programmable
memory to store instructions & to implement specific
functions such as logic, sequence, timing, counting, &
arithmetic to control machines & processes
processes.
Definition 2: IEC 1131 Part 1
A ddigitally
g ta y operating
ope at g eelectronic
ect o c system,
syste , des
designed
g ed for
o use
in an industrial environment, which uses a
programmable memory for the internal storage of user-
oriented instructions for implementing specific functions
such as logic, sequence, timing, counting, & arithmetic
t control,
to t l through
th h digital
di it l or analog
l inputs
i t & outputs,
t t
various types of machines & processes.
PLC Historical Development

1969 = GM engineers & Bedford Associates


conceptualized the PLC.
1970 = They released the first PLC, Modicon 084,
made of discrete electronic components,
components
128 I/O (not yet uP-based)
1974 = Matsushita released their first PLC, with
internal memory
1977 = Allen Bradley released the first uP-based PLC
1983 = Low-cost PLCs were introduced by several
manufacturers for OEMs, mostly Japanese
1984 = Si
Siemens released
l d th
their
i PLC
PLC, S5
Basic Advantages of the PLC

1. Eliminates hard-wiring changes for changes in machine


operation
2. Smaller space requirement in panels
3. Reliability due to solid
solid-state
state electronics
4. Low power consumption
5. Ease of expandability - modular
6. Easy maintenance due to fewer equipment
7. Lower cost for medium & large scale applications
8 Versatile-
8. V til capable bl off ttasks
k nott possible
ibl with
ith relays
l
before like: calculation, information exchange, text and
graphic display
display, data processing
processing, etc
etc.
Basic Disadvantages of the PLCis
1. High initial cost ( for a simple process or operation )
2. Application must be made by qualified personnel
3. Repair must be made by qualified personnel
4. Sensitive to dust, high humidity, & very high temperatures
5. No uniform programming language
(slowly corrected today by regulations from organizations)
6 Limited
6. Li it d diagnostics
di ti for
f large-scale
l l applications
li ti comparedd
to a DCS
7 Limited PID capability compared to process control
7.
systems
8. Non-integrated
g control & visualization (HMI)
( ) softwares
compared to a DCS
The PLC as Part of the Instrumentation & Control Loop

PROCESS
& EQP’T.

FINAL CONTROL MEASURING


ELEMENT ELEMENT

RECEIVING
ELEMENT
Stand-alone Controller
DCS
CS
PLC
PLC System Components
Power Supply

I/O SYSTEM

es
Input Modules
s

ut Module
Sensors CPU
Solenoids
Pushbuttons Contactors
Limit Switches Logic Solver Valves
Feedback Switches
Pumps

Outpu
Transmitters
Motors
RTD
Thermocouples Memory
((User Program)
g )

Programing Device
PLC Hardware Components
1. PROCESSOR MODULE (CPU)
It typically has a microprocessor chip, and is the “brain”
of the PLC. It implements the logic and communication
among the modules. It contains a memory to store the
user program,
program and the results of the logical operations
performed by the microprocessor. The memory consists
oof thee RAM and
a d EPROMO oro EEPROM.O . Modern
ode PLCs Cs
have removable memory media.
PLC Hardware Components
2. INPUT MODULE (DI, AI)
It is the interface between the field input devices & the
controller.
ll It conditions
di i the
h signals
i l received
i d to the
h format
f
used by the processor. The field input devices are hard-
wired to the input modules
modules. Typical input signals are:
5Vdc, 24Vdc, 110Vac, 220Vac, & mAdc
PLC Hardware Components
3. OUTPUT MODULE (DO, AO)
It is the interface between the field output devices & the
controller.
ll ItI conditions
di i the
h signals
i l fromf the
h processor to
be converted into that required by the devices. The field
output devices are hard
hard-wired
wired to the output modules
modules. The
typical signals are: dry contact, transistor, SCR, Triac, &
mAdc.
PLC Hardware Components
I/O System Types:
1. Direct I/O = This gets the I/O to and from the CPU directly.
H
However, th
the CPU can only l supportt a limited
li it d number
b off direct
di t
I/O’s, typically less than 64. Only very small-scale PLC’s use
this system.
2. Parallel Bus I/O = A parallel bus is connected to the CPU’s
I/O interface, and individual I/O modules are plugged into this
bus. The modularity of this system vary from 4, 8, 16, or 32
points per module. The disadvantage of parallel I/O is the
limited distance over which one can extend the bus, typically
50 ft
ft. or 15 meters
t
3. Serial Bus I/O = Typically, the serial bus is connected to the
CPU through the parallel bus, using a serial-to-parallel
converter. The use of 2 or 4 wires contributes to reduced
wiring costs. It can extend to 10,000 ft. or 3 km.
PLC Hardware Components – I/O Types
Direct I/O

Parallel Bus I/O Serial Bus I/O


PLC Hardware Components
4. POWER SUPPLY MODULE
It receives an AC or DC supply voltage and converts this
into the DC voltage required by the modules. It does not
supply power to the field devices (an external power
supplyl unit
it is
i used).
d)
PLC Hardware Components
5. SPECIAL MODULES
These are modules that have specific and specialized
purposes that the other standard modules do not perform.
Examples are:
1 Pulse counting
1.
2. Interfacing or Special Communications
3. Decoder
4. Servo
5. Load Cells
6. PID
7. Others
PLC Module Mounting Accessories
1. SURFACE Mounting
It is used by small-scale PLC’s and incorporates
mounting holes on the module for screws.
2. RACK (or Chassis) Mounting
It uses a special
i l housing
h i containing
t i i a mother
th
board where the modules are plugged-in. A
typical rack may have 4 to 20 slots for the I/O.
I/O
3. RAIL Mounting
It uses an industry-standard
y DIN rail where each
module is attached. However, each module has
connectors which attach to adjoining modules.
This
hi makes
k theh system cheaper
h than
h having
h i a
rack.
PLC Programming Device

1. HAND-HELD PROGRAMMER
This is the PLC manufacturer’s
manufacturer s device used
specifically for their own PLC.
2. COMPUTER-BASED POGRAMMER
This may be a Laptop, a Desktop PC, or a PDA with
the PLC manufacturer’s software and cable
3. REMOVABLE MEMORY
These are memory devices such as memory cards,
flash memories
memories, etc.,
etc that already contain the user
user’ss
control program. The program will then be copied
into the PLC memory, when plugged
plugged-in
in and the
PLC restarted or rebooted.
PLC Hardware & Memory Sizes

1. Small-scale
128 I/O, 2K memory.

2. Medium-scale
2,048
, I/O,, 32K memory.
y

3. Large-scale
Large scale
16,000 I/O, 2M memory.
PLC Software Components
1. PROCESSOR SOFTWARE or FIRMWARE
It is executive software, a program that manufacturers
pre-load
l d to theh CPU . IIt ddetermines
i what
h functions
f i are
available to the user’s program, how the program is
solved how the I/O is serviced
solved, serviced, how the PLC reacts to
power-on & fault conditions.
2. USER SOFTWARE
It is is the software that the engineer writes & stores in
memory in order to perform the required control over the
machine. There are generally 4 types of user softwares:
1. Configuration or Programming Software,
2. HMI or Visualization software,
3. Network Software,
4. Special Application Softwares
Configuration or Programming Methods

1. Basic Methods
Ladder Diagram
Instruction List ( Mnemonic, Boolean)

2. IEC 61131-3 (Initially IEC1131, in 1992)


Ladder Diagram (LD)
Instruction List (or Statement List) (IL)
Function Block Diagram
g (FB)
( )
Sequence Function Chart (SFC)
Structured Text (ST)
Configuration or Programming Methods

What is IEC 61131-3 ?

The 6 parts of the IEC 61131 Standard

-1 General overview, definitions IS


-2 Hardware IS
-3 Programming Languages IS
-4 User Guidelines IS
-5 Messaging Service Specification IS
-7 Fuzzy Logic IS

IS = International Standard
Configuration or Programming Methods

PLCs Embedded
Drives
DCS IEC 61131-3
PC based LON nodes
Control
SoftLogic
Configuration or Programming Methods
Instruction List (IL)
» Mnemonic or Boolean based method,
using instructions such as LOAD, OR,
AND, NOT
» Single Accumulator based execution
model, based upon the German
“Anweisungsliste” (AWL)
» Popularly used in small PLCs
LD A
ANDN B
ST C
Configuration or Programming Methods
Ladder Diagram (LD)
» Standardized, rationalized set of
relay ladder programming symbols
» Based
B d on well-known
ll k N
North
th A
American
i
style of programming, resembling US-
type of electrical drawing standard,
standard
using contacts & coils
» Popularly used in a PLC
A B C
-|| |--|/|----------------(
| || ( )
Configuration or Programming Methods
Function Block Diagram (FBD), CFC
» Graphical language,
language widely used in Europe
» Allows program elements which appear as blocks
to be "wired" together by CAD-based drawing in a
form similar to a circuit diagram
» Used in many applications that involve the
fl off information
flow i f i or data
d between
b controll
components in process control applications
» Popularly used in a DCS
AND
A C
Process Industry
Ind str
B
Configuration or Programming Methods
Sequential Function Chart (SFC)
» Typically used for batch or
sequence & recipe control
applications
pp
» Uses a graphical flowchart
format consisting of steps &
transitions
» Each step incorporates a
program using any of the 4
other methods
» Popularly used in a DCS
Configuration or Programming Methods
Structured Text (ST)
» High level language, block structured
syntax, resembling PASCAL
» Complex statements and nested
instructions
» Possible
oss b e support
suppo t for
o
Iteration loops (REPEAT-UNTIL;
WHILE-DO)
C di i l execution
Conditional i (IF-THEN-
(IF THEN
ELSE; CASE)
Functions (SQRT(), SIN()) C:= A AND NOT B
Electrical Ladder Diagram Development
Symbols for
Input & Output
Devices:
Electrical Ladder Diagram Development
Symbols for
Input & Output
Devices:
Electrical Ladder Diagram Development
Logic Fundamentals
1. The BINARY Concept
There are onlyy 2 logic
g states and are defined as High
g or
Low, On or Off, Yes or No, On or Off, 1 or 0, and True
or False. These are called binary or discrete signals.
2 The AND Function
2.
It has 2 or more inputs and only 1 output. The output is
True only if all inputs are True. In electrical wiring logic,
it is a series connection of contacts.
3. The OR Function
It has 2 or more inputs
p and onlyy 1 output.
p The outputp is
True if any inputs are True. In electrical wiring logic, it is
a parallel connection of contacts.
4 The NOT Function
4.
It has only 1 input and 1 output. The output is the inverse
of the input. It is therefore an inverter.
Difference between Analog, Digital, & Discrete Signals
1. DISCRETE Signal
This is also called BINARY or BOOLEAN. There are only
2 values
l andd are defined
d fi d as High
i h or Low, On or Off,
ff Yes
or No, On or Off, 1 or 0, and True or False.

30
1 - signal
11

5
0 - signal 0 t
-3
3
Difference between Analog, Digital, & Discrete Signals
2. ANALOG Signal
It has many possible values. It is generated as a result of
process variable
i bl measurement & control. l The
h industry
i d
standard is the 4 to 20 mAdc and 1 to 5 Vdc ranges.

mA

100°C 20

0 4 t
Difference between Analog, Digital, & Discrete Signals
3. DIGITAL Signal
It has many possible values. These are referred to as value
stages or steps. A digital
di i l signal
i l isi defined
d fi d by
b a number
b off
value steps. It is formed inside a computer from an analog
signal
g conversion.
V

100°C 20 A
20mA 10

0 4 0 t
Difference between Analog, Digital, & Discrete Signals
ANALOG to DIGITAL Conversion Resolution
= accuracy of representing analog values in a computer-based
measurement & control system.

Specifications
p for A/D or D/A Resolution = “Bits”
Example: 8 Bits Resolution ?
28 or 256
2 6 value steps

Wh t iis th
What the resolution
l ti off measurementt for
f a range off 0 to
t 100°C?

28 or 256 value steps


100°/256 = 0.39° steps
Difference between Analog, Digital, & Discrete Signals

A/D & D/A Resolutions

8 Bits = 256
12 Bits
i = 4,096
4 096
16 Bits = 65,536
32 Bits = 4.295 x 109
Example of an
Electrical
Ladder Diagram Logic
Flow

Power Line

Rung
Exercise 1
Making an Electrical Ladder Diagram
Exercise 1: Making an Electrical Ladder Diagram
A. 1 Lamp controlled by 2 NO pushbuttons. Only one must be
pressed at a time
time. If both are pressed
pressed, the lamp will not
operate.
B. 1 pushbutton controlling forward motor rotation and 1
pushbutton controlling reverse rotation. When 2 are pushed
the motor will not operate.
C. Make a motor start-stop circuit using a NC stop button and
a NO start button to control a relay. The relay will energize
the motor.
motor Pilot lights for both ON and OFF status must be
energized using separate contacts from the relay. A
temperature switch (NC) for the bearing is added as a safety
f
feature andd must dde-energize
i the
h relay
l andd also
l energizei an
alarm lamp.
Answer for Exercise 1A:
Answer for Exercise 1B:
Answer for Exercise 1C:
Interpreting the E-Ladder with Actual Wiring
Exercise 2
Making a Wiring Layout Diagram
from an Electrical Ladder
Exercise 2A - Wiring Layout Diagram from an Electrical Ladder
(use Exercise 1C with SPDT Temp Sw)

Relay
START ON

PB PL R

STOP OFF

PB PL

Temp Sw
ALARM

PL

L1 L2
Exercise 2A - Wiring Layout Diagram from an Electrical Ladder
(use Exercise 1C with SPDT Temp Sw) - Answer

Relay
START ON

PB PL R

STOP OFF

PB PL

Temp Sw
ALARM

PL

L1 L2
Exercise 2B - Wiring Layout Diagram from an Electrical Ladder
(use Exercise 1C with SPDT Temp Sw)
R l 1
Relay

START ON R
PB PL

STOP OFF

PB PL
Relay 2

Temp Sw
ALARM R
PL

L1 L2
Exercise 2B - Wiring Layout Diagram from an Electrical Ladder
(use Exercise 1C with SPDT Temp Sw) = Answer
R l 1
Relay

R
START ON

PB PL

STOP OFF

PB PL
Relay 2
Temp Sw
R
ALARM

PL

L1 L2
Part 1 = Principles of PLC Program Development
DAY 2
1. What does PLC mean?
2. What is a PLC?
3 Historical
3. Hi i l development
d l
4. Hardware Components
5. Software Components
6. Configuration/Programming Methods
7. Electrical Ladder Diagram Development
8. Interpreting the E-Ladder with Actual Wiring
9. PLC Ladder Diagram Development – Logic Control
(Interpreting the E
E-Ladder
Ladder as a PLC
PLC-Ladder)
Ladder)
10. Interpreting the PLC-Ladder with Actual Wiring
11. Function Block Programming Method
12. Program Development Procedure
PLC Ladder Diagram Development – Logic Control
Interpreting the E-Ladder as a PLC Ladder

Logic Input Symbols


X Normally Open – an active input X will close
the
h contact & allow
ll power to flow
fl

X Normally Closed – power flows when the input


X is not open
open. An active input X will open the
contact and stops power to flow.

Logic Output Symbols

N
Normally
ll De-energized
D i d or Off
Off: N
Normally
ll Energized
E i d or On:
O
Energized when the logic input is true De-energized when the logic input is true
Exercise 3
Making a PLC Ladder from an Electrical Ladder
(Logic or Discrete Control)
Exercise 3: Making the PLC Ladder Diagram from an
Electrical Ladder Diagram.
Diagram
A. 1 Lamp controlled by 2 NO pushbuttons. Only one must be
pressed at a time
time. If both are pressed
pressed, the lamp will not
operate.
B. 1 pushbutton controlling forward motor rotation and 1
pushbutton controlling reverse rotation. When 2 are pushed
the motor will not operate.
C. Make a motor start-stop circuit using a NC stop button and
a NO start button to control a relay. The relay will energize
the motor.
motor Pilot lights for both ON and OFF status must be
energized using separate contacts from the relay. A
temperature switch (NC) for the bearing is added as a safety
f
feature andd must dde-energize
i the
h relay
l andd also
l energizei an
alarm lamp.
(continuation) Exercise 3: Making the PLC Ladder
from an Electrical Ladder
Electrical Ladder: (from exercise 1C)
Make a motor start-stop
start stop circuit using a NC stop button and
a NO start button to control a relay. The relay will energize
the motor. Pilot lights for both ON and OFF status must be
energized using separate contacts from the relay. A
temperature switch (NC) for the bearing is added as a safety
ffeature and must de-energize
g z the relayy and also energize
g z an
alarm lamp.
PLC Ladder:
The 2 pushbuttons & the temperature switch are connected
to the PLC input module. The relay or contactor that
energizes the motor and the pilot lights are connected to the
output module. (no I/O addressing yet)
Answer for Exercise 3A:
Answer for Exercise 3B:
Answer for Exercise 3C:
Interpreting the PLC Ladder with Actual Wiring
PLC Addressing or I/O Numbering
> It is assigning
g g all p physical
y inputs
p & outputs
p with
an operand (address) suitable to the PLC used.
> The address coding is related to the physical
location of the point and differs between
manufacturers
> It is also called a “tag” and can be associated
with a descriptive name called an “alias”
alias

Manufacturer Input Code Output Code


Allen Bradley I O
Siemens I Q
Matsushita X Y
Omron 00000 00100
Examples of Data Types (AB)
No. Identifier Type
External:
0 O Output
1 I I
Input
t
Internal:
2 S Status Bit ((Faults)
S l )
3 B Bit (4,096 as a scratch pad)
4 T Timer (256)
5 C Counter (256)
7 N Integer (256, -32,768 to +32,767)
Examples of PLC Ladder Instruction & Addressing
for External Data

I:1/3
File or Data Type Terminal No / Channel

Ladder Slot No
Rung
I:1 O:3
O 3
I1
I:1
3 6 7

Logical signal flow direction,


Left to right, top to bottom
Basic Data Types according to IEC 61131
61131-33

Identifier Type
I Input
Q Output
M Memory (Flag)
Bool 1 Bit
Byte 8 Bits
Word 16 Bits
Other Data Types according to IEC 61131
61131-33

Identifier Type Range of Values


SINT Short Integer 0 to 256
INT Integer -32,768 to +32,767
-2,147,483,648 to
DINT Double Integer
+ 2,147,483,647
UINT Unsigned Integer 0 to 65,535
REAL Floating Point No. ±2.9E-39 to ±3.4E+38
Examples of PLC Ladder Instruction & Addressing
for Internal Data
B3:1/0
File Type
Bit #

File # Word #

T4:0
File Type
Timer #

File #

C5:4
File Type
Counter #
File #
Examples of PLC Ladder Instruction & Addressing
for Internal Data

N7 1/3
N7:1/3
File Type
Bit #

File # Word #

Bit 15 Bit 0

16 bit Word
W d = 0000 0000 0000 0000
PLC Input
p
Addressing
& Wiring
Example
PLC Output
p
Addressing
& Wiring
Example
Exercise 4
Making a PLC Ladder Logic with Addressing
Exercise 4: Making the PLC Ladder Diagram from an
Electrical Ladder Diagram,
Diagram with Addressing.
Addressing
A. 1 Lamp controlled by 2 NO pushbuttons. Only one must be
pressed at a time
time. If both are pressed
pressed, the lamp will not
operate.
B. 1 pushbutton controlling forward motor rotation and 1
pushbutton controlling reverse rotation. When 2 are pushed
the motor will not operate.
C. Make a motor start-stop circuit using a NC stop button and
a NO start button to control a relay. The relay will energize
the motor.
motor Pilot lights for both ON and OFF status must be
energized using separate contacts from the relay. A
temperature switch (NC) for the bearing is added as a safety
f
feature andd must dde-energize
i the
h relay
l andd also
l energizei an
alarm lamp.
(continuation) Exercise 4: Making the PLC Ladder Logic
with Addressing

Using exercise 4C, assign the start button to the first


channel of the first module (DI). The stop button is on
the second channel of the first module. module The
temperature switch contact is on the first channel of
the second module (DI).
The relay or contactor is then assigned to the first
channel of the third module (DO).
(DO) Similarly,
Similarly the start
pilot light is on the second channel, the stop pilot light
is on the third channel,, & the alarm ppilot light
g is on
the fourth channel.
Answer for Exercise 4A:
Answer for Exercise 4B:
Answer for Exercise 4C:
Exercise 5
Making a Wiring Layout Diagram
from a PLC Ladder with I/O Address
Exercise 5A - Wiring Layout Diagram from a PLC Ladder w/ Address
((use Exercise 4))
Contactor
DI DI DO
START C
0 0 0
PB
1 1 1 ON

2 2 2 PL
STOP
3 3 3
PB
4 4 4 OFF
5 5 5 PL
Temp Sw
6 6 6
7 7 7 ALARM

Com Com Com PL

+ PS -
Exercise 5B - Wiring Layout Diagram from a PLC Ladder w/ Address
((use Exercise 4))
Contactor
DI DI DO
START C
0 0 0
PB
1 1 1 ON

2 2 2 PL
STOP
3 3 3
PB
4 4 4 OFF
5 5 5 PL
Temp Sw
6 6 6
7 7 7 ALARM

Com Com Com PL

+ PS -
Exercise 5C - Wiring Layout Diagram from a PLC Ladder w/ Address
((use Exercise 4))
Contactor
DI DI DO
START C
0 0 0
PB
1 1 1 ON

2 2 2 PL
STOP
3 3 3
PB
4 4 4 OFF
5 5 5 PL
Temp Sw
6 6 6
7 7 7 ALARM

Com Com Com PL

+ PS -
E ercise 6
Exercise
Makingg an Electrical & PLC Ladder Diagram
g
with I/O Address based on a Described Process
Operation
Exercise 6 - Making a PLC Ladder Diagram based
on the process operation shown.
1. When the level is at LSL or lower, the SV
SV opens to fill the tank. P1 is off.
2. When the level reaches LSH, the SV
closes.
LSH 3. After 5 seconds, P1 operates to drain the
tank
tank.
4. When the level goes down to LSL, P1
stops.
LSL 5. After 3 seconds, SV will open to fill again.
6. A manual-auto switch permits manual
operation of the SV and P1P1. However
However, SV
P1
cannot open if the level is at LSH or higher,
and P1 will not operate when the level is at
Note: LSH & LSL contacts LSL or lower
lower.
are N.O. when the level is
low 7. Include pilot lights for SV-open, P1-on, and
for Auto or Manual operation
Answer for Exercise 6A: - Electrical Ladder
Answer for Exercise 6B: - PLC Ladder
Exercise 7 - PLC Ladder Diagram Programming
P&ID for Reference

FAL FAH
03 03

FSL FSH FI FQ
03 03 03 03
INV
FY FT
03A 03
LAL LALL FE
TAL TAH 17 17 03
08 08
LALL LAL LSL LI LSLL
TSL TI TSH 01 01 17 17 17
08 08 08
FAL LSLL LSL
02 01 01
L/L LIC LT LT BOILER
I/P
FSL FIC FY FY 01 01 17 STEAM DRUM
02 02 03B 02
TT
08
FT TE PI TI
02 08 11 12
FE
P1 02
FY FO
02 ATC
Exercise 7 - PLC Ladder Diagram Programming with Addressing
Make an Electrical Ladder for the level alarm & interlock system y
based on the P&ID and sequence description below. Then convert
your logic diagram in your PLC Ladder Program.
1 If a Low Level condition is detected by
1. b any
an of the two
t o LSL
limits, an audio-visual (flashing) alarm is activated for operator
warning. The Level switch contact closes on alarm condition.
2. An ACK (NO) momentary pushbutton is pressed to acknowledge
& silence the audible device.
3 If a Very
3. V L
Low LLevell condition
diti isi detected
d t t d byb any off the
th two
t LSLL
limits, an audio-visual alarm is generated. The ACK pushbutton is
used in the same way.
4. For maintenance purposes, an alarm BYPASS selector switch is
used to defeat the alarm & interlock functions. If this switch is
activated (Sw Contact to Close),
Close) an audio-visual
audio visual alarm is also
generated to remind the operator.
Note: The audible device (horn, buzzer, chime, etc., is common to all alarms
Answer for Exercise 7-1:
Answer for Exercise 7-2:
Answer for Exercise 7-3:
Answer for Exercise 7-4:
Exercise 7 - Wiring Layout Diagram from a PLC Ladder w/ Address
ffor ALARMS Low
LSL Level
DI DO DI DO

0 0 0 0 PL
1 1 1 1
LSL Horn
2 2 2 2
H
3 3 3 3
4 4 4 4
ACK yp
Bypass
5 5 5 5 ON
PB
6 6 6 6 PL
BYPASS 7 7 7 7
SW Com Com Com Com

+ PS -
PLC Ladder Diagram with Vertical
connection between rungs
g
A D
Ladder Logic w/ Y
Vertical Contact
B C E

A D

Y
B C D
Reprogrammed Logic

B E

A C E
Part 1 = Principles of PLC Program Development
DAY 3
1. What does PLC mean?
2. What is a PLC?
3 Historical
3. Hi i l development
d l
4. Hardware Components
5. Software Components
6. Configuration/Programming Methods
7. Electrical Ladder Diagram Development
8. Interpreting the E-Ladder with Actual Wiring
9. PLC Ladder Diagram Development – Logic Control
(Interpreting the E-Ladder
E Ladder as a PLC
PLC-Ladder)
Ladder)
10. Interpreting the PLC-Ladder with Actual Wiring
11. Function Block Programming Method
12. Program Development Procedure
Function Block Diagram Programming Method
F
Function
i Block
Bl k Diagram
Di (FBD),
(FBD) also
l called
ll d CFC
» A graphical programming language or method,
popularly used in DCS,
DCS which is consistent with
the ISA Binary Logic Diagram and the IEC617
standards.
» A network is formed by interconnected blocks, &
signal flow is from left to right. Networks are
processed from top to bottom.
ISA BLD Symbols IEC BLD Symbols

AND &
A
Gate

OR >=1
OR
Gate
Function Block Diagram Programming Method
Interpreting the Instrumentation Binary Logic Diagram

Basic Logic Timers Memory, Flip-Flop, Latch


Standard
Delay to Initiate
AND A S Q
DI
# R Q

With Override/Priority
Delay to Terminate
OR OR
DT S
# R

Pulse Output Retained after power loss


Invert INV
PO MS
#
R
Function Block Diagram Programming Method
BLD Equivalent
E i l t off L
Ladder
dd DiDiagram

L1 Electrical Ladder Logic L2

PB 10 Start TS-101
PB 11 Stop
M6
M6

BLD Equivalent

PB 10 Start PB (NO) S Q Motor (M6)


PB 11 Stop PB (NC) R Q
OR
TS-101 (NC)
Function Block Diagram Programming Method
FBD Example
Function Block Diagram Programming Method
FBD Example
Function Block Diagram Programming Method
FBD Example
Function Block Diagram Programming Method
FBD Example
PLC Ladder with Function Block Equivalent – 1/5

Ladder Logic Function Block Logic

A B A
And Y
Y
B

A A
OR Y
Y
B
B
PLC Ladder with Function Block Equivalent – 2/5
L dd Logic
Ladder L i F
Function
ti Block
Bl k Logic
L i

A
A C
OR
Y B And Y

B C

A
A C OR
Y B
And Y
B D C
OR
D
PLC Ladder with Function Block Equivalent – 3/5
L dd Logic
Ladder L i F
Function
ti Block
Bl k Logic
L i

A
A B
And
Y B OR Y

C C

A
A B And

Y B
OR Y
C D C
And
D
PLC Ladder with Function Block Equivalent – 4/5
L dd Logic
Ladder L i F
Function
ti Block
Bl k Logic
L i

A B A
Y And Y
B

A
A B And

Y B
Or Y
C D C
And
D
PLC Ladder with Function Block Equivalent – 5/5

Ladder Logic Function Block Logic


NC Stop NO Start
Pushbuttons Pushbuttons
C D A

M
B

A OR
B

C And M

D
Exercise 8
Making a Function Block Diagram (FBD) Program
Exercise 8: Making a Function Block Diagram
A 1 Lamp controlled by 2 NO pushbuttons
A. pushbuttons. Only one must
be pressed at a time. If both are pressed, the lamp will not
operate.
B. 1 NO pushbutton controlling forward motor rotation and
1 NO pushbutton controlling reverse rotation. The motor
h 2 windings.
has i di Wh 2 are pushed
When h d th
the motor
t will
ill nott
operate.
C Make a motor start-stop circuit using an NC stop button
C.
and an NO start button to control a relay. The relay will
energize the motor. Pilot lights for both ON and OFF
status must beb energized
i d using
i separate contacts ffrom the
h
relay. A temperature switch (NC) for the bearing is added
as a safetyy feature and must de-energize
g the relayy and also
energize an alarm lamp. Lastly, an NO emergency stop
button near the motor can also stop the motor.
Answer for Exercise 8A:
Answer for Exercise 8B:
Answer for Exercise 8C:
E
Exercise
i 9
Making a Function Block Diagram (FBD) Program
For Alarm Function
Exercise 9 = Function Block Diagram Programming
P&ID for Reference

FAL FAH
03 03

FSL FSH FI FQ
03 03 03 03
INV
FY FT
03A 03
LAL LALL FE
TAL TAH 17 17 03
08 08
LALL LAL LSL LI LSLL
TSL TI TSH 01 01 17 17 17
08 08 08
FAL LSLL LSL
02 01 01
L/L LIC LT LT BOILER
I/P
FSL FIC FY FY 01 01 17 STEAM DRUM
02 02 03B 02
TT
08
FT TE PI TI
02 08 11 12
FE
P1 02
FY FO
02 ATC
Exercise 9 = Function Block Diagram Programming – Alarm Function
Make a complete BLD for the level alarm & interlock system based
on the P&ID and sequence
seq ence description below.
belo Enter your o r logic
diagram in your FBD Configuration.
1. If a Low Level condition is detected byy anyy of the two LSL limits,,
an audio-visual (flashing) alarm is activated for operator warning.
An ACK (NO) pushbutton is used to acknowledge & silence the
audible device.
device
2. If a Very Low Level condition is detected by any of the two LSLL
limits, an audio-visual alarm is generated. The ACK pushbutton is
used in the same way. The fuel flow is stopped immediately and
the air flow is stopped after a 1 minute delay.
3 For maintenance purposes,
3. purposes an alarm BYPASS switch is used to
defeat the alarm & interlock functions. If this switch is activated
(Contact Closure), an audio-visual alarm is generated to remind the
operator.
Note: The audible device (horn, buzzer, chime, etc.) is common to all alarms
Answer for Exercise 9-1:
Answer for Exercise 9-2:
Answer for Exercise 9-3:
Reminders when drawingg the Program
g
» Status of contacts for input devices in the
Electrical Ladder Diagram
g are shown when
the coils for these contacts are not
energized.
» Status of contacts for input devices in the
PLC Ladder Diagram are shown when the
PLC is not energized. The contact status will
be equivalent to the electrical diagram only
when the PLC is already energized and the
input modules have been scanned by the
CPU.
CPU
» Status of contacts for input devices in the
Function Block Diagram
g are the same as
connected to the input modules.
Steps
p in PLC Program
g Development
p
Understand & Document
the Machine or Process Specification
O
Operation
i & Design
Stage
Validate with the End
End-user
user

Make the Electrical Ladder Diagram Implementation


Stage
Convert to PLC Logic Program

Debug & Test the Program Commissioning


St
Stage
Download the Program
Steps
p in PLC Program
g Development
p
» Formulate a precise & detailed
description of the control task Specification
» A formalized description reveals any & Design
conflicting requirements & misleading Stage
or incomplete
i l specifications
ifi i
» A solution is developed based on the
description This is described by both Implementation
description.
graphic & process oriented description Stage
detailingg the function & behavior of the
control system.
Commissioning
St
Stage
Steps
p in PLC Programg Development
p
» The solution concept is translated into a
control program using the appropriate Specification
methods. & Design
* Determine the necessary I/O modules Stage
& assign to the proper slot position
position.
* Assign the field devices to the
corresponding I/O terminals, Implementation
then make the program.
Stage
» Depending on the PLC manufacturer,
the program or parts of it is simulated
before commissioning. This permits Commissioning
early detection and elimination of St
Stage
errors.
Steps
p in PLC Programg Development
p
» Test the interaction of the automation
system with the connected plant, Specification
process, or machine. & Design
» For complex tasks, commission the Stage
system systematically,
i ll step byb step.
Faults, both in the system and the
program can be easily found and
program, Implementation
eliminated using this method. Stage
» One important
p component
p of the system
y
is documentation, which is needed for
maintenance & future expansion. It Commissioning
must be available both in hard copy & St
Stage
soft copy forms.
Steps
p in PLC Program
g Development
p

Components of the Documentation

1. Problem description
2. Validated description & technical patterns
3. Circuit & loop diagrams
4. Termination diagrams
5. Printout of control programs
6
6. I
Inputs
t & Outputs
O t t allocation
ll ti list
li t
7. Other documentation
Part 1 = Principles of PLC Program Development

Questions

Você também pode gostar