Download File - Learning@NDGTA

Survey
yes no Was this document useful for you?
   Thank you for your participation!

* Your assessment is very important for improving the workof artificial intelligence, which forms the content of this project

Document related concepts

Microprocessor wikipedia , lookup

Immunity-aware programming wikipedia , lookup

IBM System/360 architecture wikipedia , lookup

Random-access memory wikipedia , lookup

Bus (computing) wikipedia , lookup

Transcript
NDGTA
Programmable Logic
Controllers
LO1: Understand the design and
operational characteristics of a PLC
system
Learning Outcome 1
NDGTA
• LO1: Understand the design and operational
characteristics of a PLC system
– 1.4 describe the internal architecture and operational
characteristics of the CPU of a typical programmable
logic device
Agenda
NDGTA
• At the end of this session the
students will be able to…
1. Describe the architecture of a PLC.
2. Describe the function of each of the
main system elements of the
architecture.
The Programmable
Logic Controller
NDGTA
PROGRAMME
INPUTS
PLC
OUTPUTS
The Functional
Components of a PLC
NDGTA
• The typical PLC has the basic functional
components of…
– Processor unit (CPU)
– Memory
– Power supply unit
– Input / output interface section
– Communications interface
– Programming device
Relationship between the
Functional Components of a PLC
NDGTA
Programming
Device
Programme &
Data Memory
Input
interface
Communications
interface
Processor
Unit (CPU)
Power Supply
Output
interface
The
Central Processor Unit (CPU)
NDGTA
• The processor unit or central processor
unit (CPU) is the unit containing the
microprocessor.
• This unit interprets the input signals and
carries out the control actions according to
the programme stored in its memory,
communicating the decisions as action
signals to the outputs.
The
Power Supply Unit (PSU)
NDGTA
• The power supply unit is needed to
convert the mains AC voltage (230V
r.m.s.) to low DC voltage (5V) necessary
for the processor and the circuits in the
input and output interface modules.
The
Programming Device
NDGTA
• The programming device is used to enter
the required programme into the memory
of the processor.
• The programme is developed in the device
and then transferred to the memory unit of
the PLC
The
Programming Device
• A programming device could be…
– A handheld device
– A desktop console
– A personal computer
NDGTA
The Memory Unit
NDGTA
• The memory unit is where the programme
containing the control actions to be
exercised by the microprocessor is stored
and where the data is stored from the
input for processing and for the output.
The
Input and Output Interfaces
NDGTA
• The input and output interfaces are where
the processor receives information from
external devices.
The
Communications Interface
NDGTA
• The communications interface is used to
receive and transmit data on
communication networks from or to other
remote PLCs.
• It is concerned with such actions as device
verification, data acquisition,
synchronisation between user applications
and connection management
Basic
Communications Model
Supervisory System
Communications Network
PLC 1
Plant / Machinery
PLC 2
Plant / Machinery
NDGTA
Communications Model:
Allen-Bradley
NDGTA
The internal
Architecture of a PLC
NDGTA
Address Bus
Programme
Panel
Control Bus
B
a
t
t
e
r
y
User
Program
CPU
RAM
C
L
O
C
K
System
Data
ROM
RAM
Input /
output
unit
Data Bus
I/O System Bus
Inputs
OptoCoupler
Buffer
Latch
Driver
Interface
D
r
i
v
e
r
s
Outputs
The CPU
NDGTA
• The CPU is made up of the following…
– An Arithmetic and Logic Unit (ALU) which is
responsible for data manipulation and
carrying out arithmetic operations of addition
and subtraction and logic operations of AND,
OR, NOT and EXCLUSIVE OR – HANDOUT
1.
The CPU
NDGTA
• Memory, termed registers, located within
the microprocessor and used to store
information involved in programme
execution
• A control unit that is used to control the
timing of operations.
• https://www.youtube.com/watch?v=cNN_t
TXABUA
The Buses
NDGTA
• The buses are paths used for communication
within the PLC.
• The information is transmitted in binary form,
that is, as a group of bits, with a bit being a
binary digit ‘1’ or ‘0’, indicative of on / off states.
• Bits are arranged into a ‘word’. A word is used
for a ‘group of bits’ constituting some piece of
information. Typically this might be 8-bits e.g.
1100 0101 – HANDOUT 2 – ASCII Code
• Each of the bits in a word is communicated
simultaneously along its own parallel wire.
The Data Bus
NDGTA
• The data bus carries the data used in the
processing done by the CPU.
• A microprocessor termed as 8-bit, has an
internal data bus that can handle 8-bit
numbers (words).
• It can thus perform operations between 8bit numbers and deliver results as 8-bit
values
The Address Bus
NDGTA
• The address bus is used to carry the addresses
of memory locations.
• Each word is located in memory
• Every memory location is given a unique
address so that the CPU ‘knows’ where to look
(read) a particular word or to store (write) a
particular word.
• If the address bus consists of 8-lines, then there
can be 28 = 256 addresses
• If the address bus consists of 16-lines, then
there can be 216 = 65,536 addresses
The Control Bus
NDGTA
• The control bus carries the signals used
by the CPU for control,
– For example it might be used to inform a
memory device whether it is to receive data
from an input or output.
– It is also used to carry timing signals used to
synchronise actions
The System Bus
NDGTA
• The system bus is used for
communications between the input /
output ports and the input / output unit
Memory
NDGTA
• Data and programme instructions need to
be stored by the PLC in order for the PLC
to process the data.
– System (Read Only Memory) ROM: gives
permanent storage for the operating system
– Random Access memory (RAM) is used for
the users programme
Memory
NDGTA
– RAM is used for data. This is where
information is stored on states of input and
output devices and the values of timers and
counters and other internal devices. (This is
sometimes called the register table or data
table).
• Part of this memory, that is a block of addresses,
will be put aside for input and output addresses
and the states of those inputs and outputs.
• Part will be set aside for pre-set data and part for
starting counter values, timer values and the like.
Memory
NDGTA
– Erasable and Programmable Read-onlymemory (EPROM) is used to store
programmes permanently
– If the memory size is 2048 bits then it can
store 256, 8 bit words (bytes).
– Similarly 4096 bits can store 512, 8 bytes or
256 x 16-bit words.
– 1K of memory represents 210 bits of storage
space i.e. 1024 bits can be stored.
Memory
NDGTA
– Manufacturers supply memory chips
with storage locations grouped in 1, 4
and 8 bits.
– Thus a 4K x 1 memory has 4 x 1024 x 1
= 1024 bit locations.
– A 4K x 8 memory has 4 x 1024 x 8 =
32,768 bit locations.
Memory
NDGTA
• Remembering that 1 byte = 8 bits, then
– 4K x 8 means that 4096 bytes can be
stored.
– For a 16 bit address bus there are 216
different addresses.
• Thus with 8-bit words stored at each address
there are 216 x 8 storage locations.
• Thus (216 x 8) / 210 = 64K x 8 i.e. which might
come in the form of 4 x 16K x 8bit memory
chips
CPU Operation
• http://www.asciitable.com
NDGTA