PLC Training

Download as pptx, pdf, or txt
Download as pptx, pdf, or txt
You are on page 1of 67

PLC TRAINING

PLC Hardware
& Software

National Institute of Design & Analysis 1


DAY-1: PLC

• Background to the PLC


 Introduction
 History
 Programmable Logic Controller (PLC)

• Hardware
 PLC Architecture
 The CPU
 Address, Data & Control Bus
 Hardware configuration

National Institute of Design & Analysis 2


Introduction
PLCs are similar to computers except, computers are
optimised for calculation and display, PLCs are optimised for
control tasks and the industrial environment. Thus PLCs are:

• Rugged and designed to withstand vibrations, temperature,


humidity and noise.
• Have interfacing for inputs and outputs already inside the
controller.
• Easily programmed and have an easily understood
programming language which primarily concerned with
logic and switching operations
National Institute of Design & Analysis 3
History
Conventional control
panel
At the outset of industrial
revolution, especially during
sixties and seventies, relays
were used to operate
automated machines, and
these were interconnected
using wires inside the control
panel.

In some cases a control


panel covered an entire wall.

National Institute of Design & Analysis 4


History
Disadvantages of Conventional control panel
 Too many wiring work.
 Difficult to modify and troubleshoot => Long
down time.
 Power consumption can be quite high
 Drawings are usually not updated.
 Lifetime of relay contacts was limited, so some
relays had to be replaced.

National Institute of Design & Analysis 5


History
Disadvantages of Conventional control panel

 If replacement was required, machine had to be stopped


and production too.
 Also, it could happen that there was not enough room for
necessary changes.
 As far as maintenance, electricians had to be very skillful in
finding errors.
 When a problem occurs, hold-up time is indefinite, usually
long.

National Institute of Design & Analysis 6


History
Control Panel with PLC
 Withinvention of
programmable controllers,
much has changed in how an
process control system is
designed. Many advantages
appeared.

 Typicalexample of control
panel with a PLC controller is
given in the picture.
National Institute of Design & Analysis 7
History
Advantages of PLC based control panel

 Compared to a conventional process control system,


number of wires needed for connections is reduced
by 80%
 Diagnostic functions of a PLC controller allow for
fast and easy error detection.

National Institute of Design & Analysis 8


History
Advantages of PLC based control panel
 Change in operating sequence or application of a
PLC controller to a different operating process can
easily be accomplished by replacing a program
through a console or using a PC software (not
requiring changes in wiring, unless addition of some
input or output device is required).
 Needs fewer spare parts.

National Institute of Design & Analysis 9


History
Advantages of PLC based control panel

 It is much cheaper compared to a conventional


system, especially in cases where a large number of
I/O instruments are needed and when operational
functions are complex.
 Reliability of a PLC is greater than that of an electro-
mechanical relay or a timer.

National Institute of Design & Analysis 10


History
 In the late 1960's PLCs were first introduced. The primary reason for
designing such a device was eliminating the large cost involved in
replacing the complicated relay based machine control systems.
Bedford Associates (Bedford, MA) proposed something called a
Modular Digital Controller (MODICON) to a major US car
manufacturer. Other companies at the time proposed computer based
schemes, one of which was based upon the PDP-8. The MODICON
084 brought the world's first PLC into commercial production.

 In the mid70's the dominant PLC were Modicon and A-B PLCs. The
AMD 2901 and 2903 were quite popular in these PLCs

National Institute of Design & Analysis 11


History
 Communications abilities began to appear in approximately 1973. The
first such system was Modicon's Modbus. The PLC could now talk to
other PLCs and they could be far away from the actual machine they were
controlling. They could also now be used to send and receive varying
voltages to allow them to enter the analog world.

 The 80's saw an attempt to standardize communications with General


Motor's manufacturing automation protocol (MAP). It was also a time for
reducing the size of the PLC and making them software programmable
through symbolic programming on personal computers instead of
dedicated programming terminals or handheld programmers.

National Institute of Design & Analysis 12


History
 The 90's have seen a gradual reduction in the
introduction of new protocols, and the
modernization of the physical layers of some of
the more popular protocols that survived the
1980's. The latest standard (IEC 1131-3) has tried
to merge PLC programming languages under one
international standard.

National Institute of Design & Analysis 13


Programmable Logic Controller (PLC)

A programmable logic controller (PLC) is special form of


microprocessor-based controller that uses a
programmable memory to store instructions and to
implement function such as logic, sequencing, timing,
counting, and arithmetic in order to control machines
and processes.
Program

Inputs Outputs

PLC
National Institute of Design & Analysis 14
PLC Architecture
Typically a PLC system has five
basic components. These are the
Programming processor unit, memory, the power
Device supply unit, input/output interface
section and the programming
Memory device. Figure shows the basic
arrangement.
Input Output
Processor
Interface Interface

Power
Supply National Institute of Design & Analysis 15
PLC Architecture

National Institute of Design & Analysis 16


PLC Architecture
CPU
The processor unit or central processing unit (CPU) is the unit
containing the microprocessor and this interprets the input signals
and carries out the control actions, according to the program stored
in its memory, communicating decisions as a action signals to the
output.

Power Supply Unit


The power supply unit is needed to convert the main a.c. voltage to
the low d.c. voltage (5V,24V etc) necessary for the processor and the
circuits in the input and output interface modules.

National Institute of Design & Analysis 17


PLC Architecture
Programming Device
The Programming device is used to enter/edit the required program into
the memory of the processor. The program is developed in the device
and then transferred to the memory unit of the PLC.

Memory Unit
Program is stored in memory unit, and is used for the control actions to
be exercised by the microprocessor.

Input and Output Sections


The input and output sections are where the processor receives
information form external devices and communicates information to
external devices
National Institute of Design & Analysis 18
The CPU
The essential elements of a CPU are:
Registers
A register is a byte (8 bits), word ( 16 bits ) or long word (32 bits) of memory which is part
of the microprocessor as opposed to general purpose memory. A register is used for
temporary storage of data and addresses within the CPU.

ALU
The ALU performs arithmetic and logical operations such as addition and subtraction on
data stored in registers.

Control Unit
The control unit is basically a set of counters and logic gates which is driven by the block.
Its function is to control the units within the microprocessor to ensure that operations are
carried out in the correct order.

National Institute of Design & Analysis 19


Address, Data and Control Bus
Address

Data

Control

National Institute of Design & Analysis 20


Hardware Configuration

National Institute of Design & Analysis 21


Memory Area Structure

National Institute of Design & Analysis 22


Memory Area Structure

National Institute of Design & Analysis 23


Input/Output Devices
 Input Devices
 Intelligence of an automated system depends largely on
the ability of a PLC controller to read signals from
different types of sensors and input devices.
 In order to detect a working piece, view a mechanism in
motion, check pressure or fluid level you need specific
automatic devices such as proximity sensors, marginal
switches, photoelectric sensors, level sensors, etc.
 Thus, input signals can be logical (on/off) or analogue.

National Institute of Design & Analysis 24


Input/Output Devices
 Intelligent devices such as robots, Input Devices
video systems, etc. often are
capable of sending signals to PLC Push
PushButton
Button
controller input modules (robot,
Limit
LimitSwitch
Switch
for instance, can send a signal to
PLC controller input as Level
LevelSwitch
Switch
information when it has finished
moving an object from one place Flow
FlowSwitch
Switch
to the other.)

National Institute of Design & Analysis 25


Input/Output Devices
 Output Devices
Automated system is incomplete if it is not
connected with some output devices .
Output can be of analogue or digital type
Digital output signal works as a switch; it
connects and disconnects line.
Analogue output is used to generate the analogue
signal (ex. motor whose speed is controlled by a
voltage that corresponds to a desired speed).
National Institute of Design & Analysis 26
Input/Output Devices
 Some of the most Output Devices
frequently used
Motor M
devices are motors, Motor

solenoids, relays, Solenoid


Solenoid
indicators Heater
Heater HEATER

Lamp
Lamp

National Institute of Design & Analysis 27


Input/Output Interface
Input Adjustment Interface

Output Adjustment Interface

National Institute of Design & Analysis 28


How PLC Works

Input Devices Controller Output Devices


Push
PushButton
Button Motor
Motor M

Limit
LimitSwitch
Switch Solenoid
Solenoid
000.00 TIM000
010.00
Level
LevelSwitch
Switch Heater
Heater HEATER
010.00

Flow
FlowSwitch
Switch 010.00
Lamp
Lamp
TIM 000
#0020

National Institute of Design & Analysis 29


How PLC Works
Programmin
Power g Console
Supply
Computer Printer

Signals Central Signals to


from Input Processing Unit Output solenoid,
Switches, Interface (CPU) Interface motor, etc
Sensors,
etc Memory

National Institute of Design & Analysis 30


What is a Scan Time?
The process of reading the status of inputs,
executing the program and updating the outputs
is known as a SCAN

Reading Updating
Inputs Outputs

Executing Program
National Institute of Design & Analysis 31
Factors Influencing Scan Time

1) CPU’s processing
speed

2) Length of user’s
program 4) Monitoring of
control
program

3) Use of remote I/O


subsystems
National Institute of Design & Analysis 32
Systematic Approach of Control System
Design using PLC

 Determine the Machine Sequence of operation


 Assignment of Inputs and Outputs (e.g. sensors,
switches, indicators, valves, motors and etc)
 Writing of the Program
 Programming into Memory
 Running the system

National Institute of Design & Analysis 33


Programming
 Ladder Diagram
 A graphical representation use by engineers for
their relay logic.
 Adopted by PLC makers as a programming
language due to its simplicity. Thus the term
Ladder Programming
 Fatek PLC programmer
WinProLadder

National Institute of Design & Analysis 34


Programming Using Fatek PLC
 Physical Input Contacts()-
These are the external physical inputs
contacts of the PLC. Its Address in Fatek is
X0….Xn.

 Physical Output Coils()-


These are the external physical Outputs
Coils/Relays of the PLC. Its Address in Fatek
is Y0….Yn.

National Institute of Design & Analysis 35


Programming Using Fatek PLC
 Internal Relay ()-
Do not have any specific function, and they can be
freely used within the program (except those
assigned to Input or Output Cards and Special I/O
Cards). Known as M area in Fatek PLC.
Retentive M(M800-1399), Internal Relay(M0-799)
and Special relays (M1912-2001)
 Work Area/Data Register (D) –
can be used only in the program;
not for I/O exchange with external I/O terminals.
D (D0-D4095), R(R0-4168)
National Institute of Design & Analysis 36
Programming Using Fatek PLC

 Step Relays (S) –


These are the step relays of PLC. Known as
Retentive S(S500-999) and S(0-499) of Fatek
PLC.

 Timers(T)/ Counters(C)-

National Institute of Design & Analysis 37


Symbols Used in Ladder Program

This is a representation of a relay coil. The


Y0 number represents the relay.

X0 This is a normally open contact symbol. It will


be closed if the coil of the same number is
energised.
X0
This is a normally closed contact symbol. It
will open upon the energising of the coil of the
same number
National Institute of Design & Analysis 38
WinProLadder By Fatek

Please sit infront of Individual PCs and


Open WinProLadder placed on DeskTop.

Practice on Simple Ladder Logic


Programming

National Institute of Design & Analysis 39


Review on Logic Gates

OR Gate, Nor Gate, And Gate, Nand


Gate, XOR Gate, Multiplexers Etc.

Equation & Truth Table of Gates

Practice Session

National Institute of Design & Analysis 40


DAY-2
Programming Techniques

• Latches
• 1-Cycle differential Circuit
• Push-on/ Push-off Circuit
• Single Shot Pulse
• Timers and Creating Delays

National Institute of Design & Analysis 41


Latches
Latch circuit is used to maintain the status of output based on two
execution conditions. These conditions are SET & RESET. When
SET condition is true, output turns ON and stay ON, until reset
condition is true. When RESET condition is true, output turns
OFF and stay OFF, until SET condition is true.

SET condition

RESET condition

Output
National Institute of Design & Analysis 42
Latches

National Institute of Design & Analysis 43


1-Cycle Differentiation Circuit
 Differentiation up circuit
operates for only one cycle Input Signal
time when an input signal
turns on(i.e. at the rising Differentiation T
edge of the input signal). Output

 Differentiation down circuit


operates for only one cycle
Input Signal
time when an input signal
turns off(i.e. at the falling
Differentiation
edge of the input signal). Output
T

National Institute of Design & Analysis 44


Differentiate UP

Ladder Symbol Operand Data Areas


B: Bit
DIFU B IR, SR, AR, HR, LR

Description
DIFU(13) is used to turn the designated bit ON for one cycle only. Whenever
executed, DIFU(13) compares its current execution with the previous
execution condition. If the previous execution condition was OFF and the
current one is ON, DIFU(13) will turn ON the designated bit. If the previous
execution condition was ON and the current execution condition is either ON
or OFF, DIFU(13) will either turn the designated bit OFF or leave it OFF
National Institute of Design & Analysis 45
Differentiate Down

Ladder Symbol Operand Data Areas


B: Bit
DIFD B IR, SR, AR, HR, LR

Description
DIFD is used to turn the designated bit ON for one cycle only. Whenever
executed, DIFD(14) compares its current execution with the previous
execution condition. If the previous execution condition was ON and the
current one is OFF, DIFD(14) will turn ON the designated bit. If the previous
execution condition was OFF and the current execution condition is either
ON or OFF, DIFD(14) will either turn the designated bit OFF or leave it OFF.
National Institute of Design & Analysis 46
Push-ON/Push-OFF Circuit
 This circuit toggles the output every time, when
input signal is applied.

1 2 3 4 5 6
Input
Signal

Output

National Institute of Design & Analysis 47


Push-ON/Push-OFF Circuit

National Institute of Design & Analysis 48


DAY-2
Timers and Creating Delay

A timer is activated when its execution condition goes ON. If


the execution condition remains ON long enough for TIM to
time down to zero, the output for the TC number used will
turn ON and will remain ON, until TIM is reset. TIM
measures in units of 0.1 second from the Set Value.

Input
Condition

Output
T1
National Institute of Design & Analysis 49
Timers and Creating Delay

National Institute of Design & Analysis 50


Single-Shot Circuit
 This circuit is used to keep the ON time of an
input signal.

Input
Signal

Output
T1 T1

National Institute of Design & Analysis 51


Single-Shot Circuit

National Institute of Design & Analysis 52


Programming Techniques

 Flicker Circuit
 Long-time Timer Circuit
 Shift Register
 Data Movement
 Interlocks

National Institute of Design & Analysis 53


ON/OFF Delay Circuit
 This circuit is used to delay the ON/OFF time of
a signal for a given time.

Input
Signal

Output
T1 T2

T1 = ON delay timer
T2 = OFF delay timer

National Institute of Design & Analysis 54


ON/OFF Delay Circuit

National Institute of Design & Analysis 55


Flicker Circuit
 This circuit causes outputs at specified ON/OFF
intervals when a input signal is applied. In the
following fig. Output is ON for T1 time and is
OFF for T2 time.

Input
Signal

Output
T1 T2 T1 T2 T1 T2 T1 T2

National Institute of Design & Analysis 56


Flicker Circuit

National Institute of Design & Analysis 57


Long-time Timer Circuit
 Timer instruction (TIM) can generate a maximum delay of
999.9 seconds. To use it as a long-time timer, a combination
of a timer and a counter can be used.

Timer on
condition

Output
T1

National Institute of Design & Analysis 58


Long-time Timer Circuit

National Institute of Design & Analysis 59


Shift Register
 This circuit is used, where user wants to perform several
steps in series. After completion of one step, data is shifted
to left by 1 bit, and execution condition for next step is
turned ON

National Institute of Design & Analysis 60


Shift Register

National Institute of Design & Analysis 61


Data Movement (MOV)

Ladder Symbol MOV(21)


S
D

Source S: Source Word


IR, SR, AR, DM, HR, TC, LR,
#
Destination D: Destination Word
IR, SR, AR, DM, HR, LR
National Institute of Design & Analysis 62
Data Movement (MOV)

This instruction is used to copy to contents of one memory location


to other memory location.

Limitations
DM 6144 to DM 6655 cannot be used for D.

Description
When the execution condition is OFF, MOV(21) is not executed.
When the execution condition is ON, MOV(21) copies the content
of S to D.

EQ: ON when all zeros are transferred to D.


National Institute of Design & Analysis 63
Data Movement (Example)

National Institute of Design & Analysis 64


Interlocking (IL)

The IL instruction must always be used in conjunction with


an ILC instruction. When the IL condition is logical 1, the
programs between the IL and ILC instructions are executed
according to the ladder diagram. when the IL condition is
logical 0, all the output relays, internal relays and timers in
the programs between IL and ILC instructions are turned
OFF, and any counters, shift registers, holding relays and
data memory relays in the same programs are held in their
present status.

National Institute of Design & Analysis 65


Interlocking (IL)

Ladder Symbol IL(02) ILC(03)

National Institute of Design & Analysis 66


National Institute of Design & Analysis 67

You might also like