[go: up one dir, main page]

0% found this document useful (0 votes)
42 views39 pages

PLC CHP 2 Hardware Searchable

Download as pdf or txt
Download as pdf or txt
Download as pdf or txt
You are on page 1/ 39

PLC Hardware: 04 10

Block diagram of PLC, Internal architecture of PLC. Digital and Analog


Input output modules of PLCs. scan cycle and scan time, connections and
wiring of various Inputs and Outputs of Plants with the PLC.
Overall PLC system/Block diagram of PLC

Programming |.
device “m& | Program & data Communications >
Memory interface <_|—_

fy FF
_ 5) Beet ke—| Output

reve
vs inter- Processor inter-
—p| face jt —h face

fe Power t _f
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
inemory,. communicating the decisions as action signals to the
outputs.
The power supply unit is needed to convert the mains a.c. voltage to
ho

the low d.c. voltage (5 V) necessary for the processor and the circuits
in the input and output interface modules.
The programming device is used to enter 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.
The memory unit is where the program is stored that 1s to be used for
the control actions to be exercised by the microprocessor and data
stored from the input for processing and for the output for outputting.
The input and output sections are where the processor receives
information from external devices and commmmicates mformation to
external devices. The inputs might thus be from switches, or
or other sensors such as photo-electric cells, temperature sensors, or
flow sensors, ete. The outputs might be to motor starter coils.
solenoid valves. etc. Input and output devices can be
classified as giving signals which are discrete, digital or analogue
Devices giving discrete or digital signals are ones where
the signals are either off or on. Thus a switch is a device giving a
discrete signal, either no voltage or a voltage. Digifal devices can be
considered to be essentially discrete devices which give a sequence of
on—off signals. Analogue devices give signals whose size 1s
proportional to the size of the variable being monitored. For example,
a temperature sensor may give a voltage proportional to the
te mMper ature.

ah)

£ |
o =
| VAT
(a) a $
Time © Time
a
oh

So |
(c) Time
= =

Signals: (a) discrete, (b) digital, (c) analogue


1
The communications interface is used to recerve and transmit data on
communication networks from or to other remote PLCs (Figure ).
It is concerned with such actions as device verification, data
acquisition, synchronisation between user applications and
connection management.

Supervisory
system

Communications
network

PLC 1 PLO 2

Machine! Machine/
plant plant

Basic communications model


Internal Architecture of PLC
Address bus |
a

(Control bus co
~~ = > Sear Sek SS Program panel
> User x System Data Input! ZN
g program CPU S ROM RAM output =<
3 RAM O unit \—7

Data bus |

OQ system bus

10
| Buffer | |
ab
Latch |
+P SZ
Opto- Driver
coupler interface

TT
Input channels
e.g. relays

Output channels.
The CPU
The internal structure of the CPU depends on the mucroprocessor
concemed. In general they have:

1 <An arithmetic and logic unit (ALU) which 1s responsible tor data
manipulation and carrying out arithmetic operations of addition and
subtraction and logic operations of AND, OR, NOT and
EXCLUSIVE-OR.
Memory. termed registers, located within the microprocessor and
bh

used to store information involved in program execution.


3. A-control unit which 1s used to control the timing of operations.
The buses
The buses are the paths used for commumecation within the PLC. The
information is transmutted in binary form, 1.e. as a group of bits with a bit
being a binary digit of 1 or 0, 1.e. on/off states. The term word is used for
the group of bits constituting some information. Thus an 8-bit word might
be the binary number 00100110. Each of the bits is communicated
sunultaneously along its own parallel wire. The system has four buses:

1 The data bus carries the data used in the processing carried out by the
CPU. A microprocessor termed as being 8-bit has an internal data bus
which can handle 8-bit numbers. It can thus perform operations
between 8-bit numbers and deliver results as 8-bit values.
The address bus is used to carry the addresses of memory locations.
ba

So that each word can be located in the memory, every memory


location is given a unique address. Just like houses in a town are each
given a distinct address so that they can be located, so each word
location is given an address so that data stored at a particular location
can be accessed by the CPU either to read data located there or put.
ie. write, data there. It is the address bus which carries the
information indicating which address is to be accessed. If the address
bus consists of 8 lines, the number of 8-bit words, and hence number
of distinct addresses, is 2° = 256. With 16 address lines. 65 536
addresses are possible.
3. The control bus carries the signals used by the CPU for control, e.g.
to inform memory devices whether they are to receive data from an
input or output data and to carry timing signals used to synchronise
actions.
4 The system bus is used for communications between the input/output
ports and the input/output unit. |
Memory
There are several memory elements in a PLC system:

System read-only-memory (ROM) to give permanent storage for the


operating system and fixed data used by the CPU.
Random-access memory (RAM) tor the user’s program.
hr

Random-access memory (RAM) tor data. This is where information 1s


stored on the status of input and output devices and the values of
timers and counters and other internal devices. The data RAM 1s
sometimes referred to as a data table or register table. Part of this
memory, i.c. a block of addresses, will be set aside tor input and
output addresses and the states of those inputs and outputs. Part will
be set aside for preset data and part for storing counter values. timer
ralues. etc.
Possibly, as a bolt-on extra module, erasable and programmable
read-only-memory (EPROM) tor ROMs that can be programmed and
then the program made permanent.
The programs and data in RAM can be changed by the user. All PLCs
will have some amount of RAM to store programs that have been
developed by the user and program data. However, to prevent the loss of
programs when the power supply is switched off. a battery is used in the
PLC to maimtain the RAM contents for a period of time. After a program
has been developed in RAM it may be loaded into an EPROM memory
chip. often a bolt-on module to the PLC. and so made permanent. In
addition there are temporary buffer stores for the input/output channels.
The storage capacity of a memory unit is determined by the number of
binary words that it can store. Thus. if a memory size 1s 256 words then it
can store 256 x § = 2048 bits if 8-bit words are used and 256 x 16 = 4096
bits if 16-bit words are used. Memory sizes are often specified in terms of
the number of storage locations available with 1K representing the
number 2". ie. 1024. Manutacturers supply memory chips with the
storage locations grouped in groups of 1. 4 and 8 bits. A 4K x 1 memory
has 4 x 1 x 1024 bit locations. A 4K x 8 memory has 4 x § x 1024 bit
locations. The term byte is used for a word of length § bits. Thus the 4K x
§ memory can store 4096 bytes. With a 16-bit address bus we can have 2”°
different addresses and so. with 8-bit words stored at each address. we can
have 2'* x § storage locations and so use a memory of size 2" x 8/2" =
64K x § which we might be as four 16K x 8 bit memory chips.
1 10
Input/output unit
The input/output unit provides the interface between the system and the
outside world, allowing for connections to be made through input/output
channels to input devices such as sensors and output devices such as
motors and solenoids. It is also through the input/output unit that
programs are entered from a program panel. Every input/output point has
a unique address which can be used by the CPU.
PLC housing
There are two common types of mechanical design for PLC systems: a
single box, and the modular/rack types. The single box type (or, as
sometimes termed. brick) is commonly used for small programmable
controllers and is supplied as an integral compact package complete with
power supply. processor, memory, and input/output units. Typically such
a PLC might have 6. 8, 12 or 24 inputs and 4, 8 or 16 outputs and a
memory which can store some 300 to 1000 instructions.
Systems with larger numbers of inputs and outputs are likely to be
modular and designed to fit in racks. The modular type consists of
separate modules for power supply. processor, etc.. which are often
mounted on rails within a metal cabinet. The rack type can be used for all
sizes of programmable controllers and has the various functional units
packaged in individual modules which can be plugged into sockets in a
base rack. The mix of modules required for a particular purpose 1s
decided by the user and the appropriate ones then plugged into the rack.
Thus it is comparatively easy to expand the number of input/output (I/O)
connections by just adding more input/output modules or to expand the
memory by adding more memory units,
12
Oo Oo Oo Oo ial Oo Oo Oo Oo Oo Oo Oo

Power supply The basic form of a rack into which


for the system components of a PLC system can be slotted

Processor Communication module for VO adapter module for connecting WO modules to provide the means
module communication to computers the backplane to a processor at to convert input signals to backplane
VO adapters and other PLC another location levels and backplane signals to
processors output circuit levels.

4A possible assembled system

Power

supply

13
a
Programming PLCs
Programming devices can be a hand-held device, a desktop console or a
computer. Only when the program has been designed on the programming
device and 1s ready 1s it transferred to the memory unit of the PLC.

1 Hand-held programming devices will normally contain enough


memory to allow the unit to retain programs while being carried from
one place to another.
2 Desktop consoles are likely to have a visual display unit with a full
keyboard and screen display.
3. «Personal computers ate widely configured as program development
work-stations. Some PLCs only require the computer to have
appropriate software: others require special communication cards to
interface with the PLC. A major advantage of using a computer is that
the program can be stored on the hard disk or a CD and copies easily
made.

14
Cassette recorder Central processor
for program storage

Programming
cb— Cable linking
terminal
processor to
racks

Interface Rack for


card 1/0 card BIO cards
J /
fo Lf
Power o q | |
supply} °
for rack tT NOOO OI
p— 16 signals per card
Power LELLELL 9 P
supply cable -

Lf.
| Connections
° SN to plant
and operator
CT [ controls

Ltt
1 2 3 4 5 6 7 8
a
DC Dc @ AC) AC| AC ]/AC |) AC
in }out| w@ lin | in | in |out| out

15
Pump
running
Ci
Fwd
lenoid
Oo Rev. Fwd

al!
/ N LSS
AC
AC Hydraulic i —
PLC output
input valve
card
card

Rev.
solenoid

16
Inputs/Output devices:

OUTPUTS

INPUTS

— A
oF

si
PUSHBUTTONS

17
Input / Output modules in PLC
(1) Digital |1/O0 module
(2) Analog I/O module
Digital 1/0 module

(1) Digita DC input module


(2) Digita AC input module
(3) Digita DC output module
(4) Digita AC output module
|/O connections
|/O cards
Internally a computer usually operates at 5 V DC. ‘The external devices
(solenoids, motor starters, limit switches, etc.) operate at voltages up to
110V AC. The mixing of these two voltages will cause severe and
possibly irreparable damage to the PLC electronics. Less obvious
problems can occur from electrical ‘noise’ introduced into the PLC from
voltage spikes on signal lines, or from load currents lowmg in AC
neutral or DC return lines. Differences in earth potential between the
PLC cubicle and outside plant can also cause problems.

This is achieved by optical isolators


Optical-isolator

L2
Plant 4k L1
supply —F PLC
supply

PLC
central
processor

N2 ——
i f N1

Barrier

Na

Input card

21
DC input module:

IS NEEDED TO:
USE TO e Prevent voltage
transients from
DROP THE
VOLTAGE damaging the
TO LOGIC processor.
LEVEL eHelps reduce the
effects of
electrical noise

FROM TO
INPUT PROCESSOR
DEVICE

22
Single channel DC input card

Plant
DC +

Protection (
breaker
or fuse
PLC
internal
+ve supply

Signal
to PLC cantral
Processor

PLC
internal
-ve supply
AC input module:

IS NEEDED TO:
CONVERTS THE AC e Prevent voltage
INPUT TO DC AND transients from
DROPS THE damaging the
VOLTAGE TO LOGIC processor.
LEVEL eHelps reduce the
effects of
electrical noise

FROM TO
INPUT PROCESSOR
DEVICE

24
Single channel AC input card

Plant AC supply
| L
Protection
breaker (
or fuse Pe
o—+ +ve supply
|
Plant signal |
To other |
| ipl Signal to
Input signals Signal PLC cantral
indicator ~ processor
|
Plant AC supply -ve supply
|
| —— eS ee ee eee ie aia
DC/AC Output module:

IS NEEDED TO:
e Prevent voltage
transients from
damaging the
processor.
eHelps reduce the
effects of
electrical noise

FROM TO
DEVICE
Single channel DC output card

I Plant
PLC T DC+
internal — =. Load |
supply switching | Output
| ¥~ transistor Current flow load
| ———»
| Plant
Energize “Opto- ~ Fuse eX) pe.
DI . 4 4
PLC _ indication
internal | Plant
Supply LED! | Dc-
Single channel AC output card

| Plant
+
| supply
Fi |
|
PLC |
internal
——- c | |
supply — !

|
yak |l
| load
Fuse |
Energize iJ
Plant
output Opto-isolator
| N
PLC
internal
~ Output
indication

supply * Plant
| N

28
Sourcing and Sinking
The temms sourcing and sinking are used to desembe the way m which dc.
devices are connected to a PLC. With sourcing. usimg the conventional
current flow direction as from positive to negative, an input device
recerves current from the input module, 1-2. the input module is the source
of the current If the current flows from the output
module to an output load then the output module 1: referred to as sourcing
With smkmz. usme the conventonal current flow
dmechon as from positive to negative, an mput device supplies current to
the input module, 1.¢ the mut module 1s the smk for the current
If the current flows to the output module from an output load
then the output module 1s referred to as sinking

+
Input rept
module module
Qo
=> ah -
Inport
fa} device (b) ti
Sourcing

+ —L_H>
Input lngpart lingourt

a HO-:
device nmeodule module

(a) (bi Output load

Sinking
Input / Output Identification/Addressing

Input Output _h an
X400 rs 10.
HE CHgee

(a)
(

Input Output Input Output


:001/01 ©:010/01 10,0 00,0
a L / +
() 4 | iw Sea
(a) Mitsubishi, (b) Siemens, (c) Allen-Bradley, (d) Telemecanique
Remote I/O
So far we have assumed that a PLC consists of a processor unit and
a collection of I/O cards mounted in local racks. Early PLCs did tend to
be arranged like this, but in a large and scattered plant with this arrange-
ment, all signals have to be brought back to some central point in
expensive multicore cables. It will also make commissioning and fault
finding rather difficult, as signals can only be monitored effectively at
a point possibly some distance from the device being tested.
In all bar the smallest and cheapest systems, PLC manufacturers
therefore provide the ability to mount I/O racks remote from the
processor, and link these racks with simple (and cheap) screened single
pair or fibre optic cable. Racks can then be mounted up to several
kilometres away from the processor.
There are many benefits from this. It obviously reduces cable costs as
racks can be laid out local to the plant devices and only short multicore
cable runs are needed. The long runs will only need the communication
cables (which are cheap and only have a few cores to terminate at each
end) and hardwire safety signals
31
PLC
processor a Rack 1

» Rack 2

0:26/05
Y}—n
Output 5
—* of card 6
T/P2 in rack 2
Rack 3

1:35/02
aOL
Input 2
of card 5
in rack 3
Program Scan / Scan Cycle

(oN Read all


inputs

Y
Program

Update
all outputs
The PLC program can be considered to behave
as a permanent running loop. The’ user’s
instructions are obeyed sequentially, and when
the last instruction has been obeyed the
operation starts again at the first instruction. A
PLC does not, therefore, communicate
continuously with the outside world, but acts
rather by taking snapshots.
The action in figure is called program scan or
scan cycle of PLC. And the period of the loop is
called the program scan time. This depends on
the size of the PLC program and the speed of the
processor, but is typically 2-5 ms per K of
program. Average scan time are usually around
10-50 ms.
PLC Communications:
Common Uses of PLC Communications Ports

¢ Changing resident PLC programs - uploading/downloading from a


supervisory controller (Laptop or desktop computer).

° Forcing I/O points and memory elements from a remote terminal.

¢ Linking a PLC into a control hierarchy containing several sizes of PLC


and computer.

eMonitoring data and alarms, etc. via printers or Operator Interface Units
(OlUs).
PLC Communications:
Serial Communications

PLC communications facilities normally provides serial transmission of


information.

Common Standards

RS 232

¢ Used in short-distance computer communications, with the majority of


computer hardware and peripherals.
¢ Has a maximum effective distance of approx. 30 m at 9600 baud.
PLC Communications:
Local Area Network (LAN)

Local Area Network provides a physical link between all devices plus
providing overall data exchange management or protocol, ensuring that each
device can “talk” to other machines and understand data received from them.

LANs provide the common, high-speed data communications bus which


interconnects any or all devices within the local area.

LANs are commonly used in business applications to allow several users to


share costly software packages and peripheral equipment such as printers
and hard disk storage.
PLC Communications:
RS 422/RS 485

Used for longer-distance links, often between several PCs in a distributed


system. RS 485 can have a maximum distance of about 1000 meters.
PLC Communications:
Programmable Controllers and Networks

Dedicated Network System of Different Manufacturers

Manufacturer Network
Allen-Bradley Data Highway

Gould Modicon Modbus


General Electric GE Net Factory LAN
Mitsubishi Melsec-NET
Square D SY/NET

Texas Instruments | TIWAY

You might also like