Chapter 1 (ECEG6223) PDF

You might also like

Download as pdf or txt
Download as pdf or txt
You are on page 1of 73

1

CHAPTER ONE
INTRODUCTORY PLC CONCEPTS
Dr. Ayele Nigussie
2

Outline

• Introduction to PLCs
• Number Systems and Codes
• Logic Concepts
3

Chapter objectives

• To understand the overview of PLCs


• To recap number systems and codes
and their applications in PLCs
• To refresh the knowledge of logic
concepts and their applications in
PLCs
4

Introduction to PLCs

• Every aspect of industry— from power generation to


automobile painting to food packaging— uses
programmable logic controllers (PLCS). Why?

• To expand and enhance production.

But what are these PLCs?


5

Introduction to PLCs…
DEFINITION
• PLCs are solid-state
members of the computer
family using integrated
circuits instead of
electromechanical
devices to implement
control functions.
• They store instructions to
control industrial
machines and processes.

• PLCS are mature industrial


controllers.
6

Introduction to PLCs…
• In 1969, first PLCs appeared replacing original hardwired
relay logic.
• Relay logic uses electrically operated devices to
mechanically switch electrical circuits.
7

Introduction to PLCs…
• First PLCs were more or less just relay replacers.
• But today they
o are fast
o are small, low-cost PLCs
• consume less power
• contain high-density input/output (I/O) systems
• are space-efficient interfaces at low cost.
• are intelligent, microprocessor-based I/O interfaces
• include PID controllers
• and so on.
• PLCs now involve advanced programming like OOP.
8

Introduction to PLCs…

PLC system with high-density I/O (64-


point modules)
Small PLC with built-in I/O and
detachable, handheld
programming unit

Allen-Bradley’s Programmable
controller family concept with
several PLCs
9

Introduction to PLCs…
PRINCIPLES OF OPERATION
• A PLC consists of two basic sections:
• CPU
• I/O interface system
10

Introduction to PLCs…
• The CPU governs all PLC activities. It has
1. processor
2. memory system and
3. system power supply
11

Introduction to PLCs…
• In 1 scan, the CPU completes
three processes:
1. reads, or accepts, input
data from field devices via
input interfaces,
2. executes, or performs,
control program stored in
the memory system, and
3. writes, or updates, the
output devices via the
output interfaces.
12

Introduction to PLCs…
• Input/output interface
13

Introduction to PLCs…
• (a) Personal computer used as a programming device
and (b) a mini-programmer unit.
14

Introduction to PLCs…
When do we go for a PLC?
• Is there a need for flexibility in control logic changes?
• Is there a need for high reliability?
• Are space requirements important?
• Are increased capability and output required?
• Are there data collection requirements?
• Will there be frequent control logic changes?
• Will there be a need for rapid modification?
• Must similar control logic be used on different machines?
• Is there a need for future growth?
• What are the overall costs?
If the answers to some of the above questions are yes,
a PLC is indeed need.
15

Introduction to PLCs…
• A PC used as a bridge between a PLC system and a main
computer system
16

Introduction to PLCs…
AREAS OF PLC APPLICATIONS
17

Introduction to PLCs…
AREAS OF
PLC
APPLICATIONS
18

Introduction to PLCs…
PLC PRODUCT APPLICATION RANGES
1. micro PLCs
2. small PLCs
3. medium PLCs
4. large PLCs
5. very large PLCs
19

Introduction to PLCs…
LADDER DIAGRAMS AND THE PLC
• The ladder diagram has and continues to be the
traditional way of representing electrical sequences of
operations.

Simple electrical ladder diagram


20

Introduction to PLCs…
• PLC transformation of the simple diagram is
21

Introduction to PLCs… ADVANTAGES


OF PLCS
22

Introduction to PLCs… Advantages of


PLCS
23

Introduction to PLCs…
• PLC I/O connection
diagram showing
no physical
connections
between the inputs
and outputs
24

Introduction to PLCs…
• Remote I/O station installation
25

Introduction to PLCs…
• EASE OF MAINTENANCE AND TROUBLESHOOTING
• From the beginning, PLCs have been designed with ease of
maintenance in mind. With virtually all components being solid-
state, maintenance is reduced to the replacement of modular,
plug-in components.
• Fault detection circuits and diagnostic indicators, incorporated
in each major component, signal whether the component is
working properly or malfunctioning.
• In fact, most failures associated with a PLC based system from
failures directly related to the field input/output devices, rather
than the PLC’s CPU or I/O interface system.
• The monitoring capability of a PLC system can easily detect
and correct these field device failures.
26

Introduction to PLCs…
• Failures in a PLC-based system
27

Introduction to PLCs…
• With the aid of the programming device, any programmed
logic can be viewed to see if inputs or outputs are ON or
OFF.
28

Number Systems and Codes


• The following statements apply to any number system:
Every number system has a base or radix.
Every system can be used for counting.
Every system can be used to represent quantities or
codes.
Every system has a set of symbols.
• The base of a number system determines the total number of
unique symbols used by that system.
• Hexadecimal number system 16… 0,1,2,…,9, A,B,C,D,E,F
• Decimal number system 10… 0,1, 2,…,9
• Octal number system 8… 0, 1, 2, …, 7
• Binary number system 2… 0,1
29

Number Systems and Codes…


• Sum-of-the weights method
30

Number Systems and Codes…


• Decimal equivalent
31

Number Systems and Codes…


Binary system
• The binary number system uses the number 2 as the
base.
• Thus, the only allowable digits are 0 and 1; there are no
2s, 3s, etc.
• For devices such as PLCs and digital computers, the
binary system is the most useful.
32

Number Systems and Codes…


Binary to number system conversion
33

Number Systems and Codes…


• One word, two bytes, sixteen bits
34

Number Systems and Codes…


• Decimal and binary counting
35

Number Systems and Codes…


• Decimal, binary, and octal counting
36

Number Systems and Codes…


• Binary, decimal, and hexadecimal counting
37

Number Systems and Codes…


• Hexadecimal to decimal conversion
38

Number Systems and Codes…


• Hexadecimal numbers can easily be converted to binary
without any mathematical transformation.
• To convert a hexadecimal number to binary, simply write
the 4-bit binary equivalent of the hex digit for each
position.
39

Number Systems and Codes…


• In this manner, a very large binary number can be easily
represented by an octal number with significantly fewer
digits.
40

Number Systems and Codes…


From decimal to any base conversion
• Example from base 10 to 5
41

Number Systems and Codes…

• 100011
• Exercise: Convert 20 to hexadecimal system.
42

Number Systems and Codes…


ONE’S AND TWO’S COMPLEMENT
• The one’s and two’s complements of a binary number are
operations used by PLCs, as well as computers, to
perform internal mathematical calculations.
• To complement a binary number means to change it to a
negative number.
ONE’S COMPLEMENT
• The negative of 101112 is −101112 .
• But not suitable for computers.
• One’s complement method puts extra bit as MSB and
inverts each bit.
• +23 −→ 0101112 and −23 −→ 1010002
43

Number Systems and Codes…


TWO’S COMPLEMENT
• In the one’s complement, all bits are inverted; but in the
two’s complement, each bit, from right to left, is inverted
only after the first 1 is detected.
• Example
44

Number Systems and Codes…


BINARY CODES
• For communication between PLCs and digital devices,
several codes for representing numbers, symbols, and
letters are standardized in the industry.
• ASCII
•BCD
• Gray
• Read about these codes
45

Number Systems and Codes…


• (a) ASCII representation of the character Z and (b) the
ASCII transmission of the character Z
46

Number Systems and Codes…


BCD
• Decimal, binary, and BCD counting
47

Number Systems and Codes…


• The BCD representation of a decimal number is obtained
by replacing each decimal digit with its BCD equivalent.
• The BCD representation of decimal7493 is shown here
as an example:
48

Number Systems and Codes…


• (a) Thumbwheel switch converts decimal numbers into
BCD inputs for a PLC.
• (b) The seven-segment display converts the BCD outputs
from the PLC into a decimal number
49

Number Systems and Codes…


GRAY: The Gray code is suited primarily for position
transducers. One bit changes as the counting number
increases.
50

Number Systems and Codes…


• REGISTER WORD FORMATS
• PLC operations are performed using a group of 16 bits
that represent numbers and codes.
• The group of bits with which a particular machine
operates is called a word.
• A PLC word is also called a register or location.
51

Logic Concepts
• To understand PLCs and their applications, you must first
understand the logic concepts behind them.
THE BINARY CONCEPT
• The binary system has two states and can be represented
by ON and OFF.
• Binary 1 represents the presence of a signal.
• Binary 0 represents the absence of the signal.
• The two states are actually represented by two distinct
voltage levels, +V and 0V.
• Often, binary 1 (or logic 1) is referred to as TRUE, ON, or
HIGH, while binary 0 (or logic 0) is referred to as FALSE,
OFF, or LOW.
52

Logic Concepts…
• Binary concept using positive logic

• 1 is referred to as positive logic


• 0 negative logic
53

Logic Concepts…
LOGIC FUNCTIONS
• The AND function
54

Logic Concepts…
55

Logic Concepts…
56

Logic Concepts…
• THE OR FUNCTION
57

Logic Concepts…
58

Logic Concepts…
59

Logic Concepts…
• THE NOT FUNCTION
60

Logic Concepts…
• Show the logic gate, truth table, and circuit representation for a
solenoid valve (V1) that will be open (ON) if selector switch S1 is ON
and if level switch L1 is NOT ON (liquid has not reached level).
61

Logic Concepts…
• PRINCIPLES OF BOOLEAN ALGEBRA AND LOGIC
62

Logic Concepts…
63

Logic Concepts…
64

Logic Concepts…
65

Logic Concepts…
66

Logic Concepts…
PLC CIRCUITS AND LOGIC CONTACT SYMBOLOGY
• Hardwired logic refers to logic control functions (timing,
sequencing, and control) that are determined by the way
devices are interconnected.
• A prime function of a PLC is to replace existing hardwired
control logic and to implement control functions for new
systems.
• Consider the following figures: The ladder circuit
connections of the hardwired relay circuit are
implemented in the PLC via software instructions.
• Thus all of the wiring can be thought of as being inside
the CPU (softwired as opposed to hardwired).
67

Logic Concepts…

Hardwired relay logic circuit PLC ladder diagram implementation


68

Logic Concepts…
• The logic implemented in PLCs is based on AND, OR,
and NOT logic functions.
• These functions are used either alone or in combination to
form instructions that will determine if a device is to be
switched on or off.
• How these instructions are implemented to convey
commands to the PLC is called the language.
• The most widely used languages for implementing on/off
control and sequencing are ladder diagrams and
Boolean mnemonics, among others.
69

Logic Concepts…
70

Logic Concepts…
ON/OFF input and output devices.
71

Logic Concepts…
ADDRESSES USED IN PLCS
• Each symbol on a rung will have a reference number,
which is the address in memory where the current status
(1 or 0) for the referenced input is stored.
• When a field signal is connected to an input or an output
interface, its address will be related to the terminal where
the signal wire is connected.
• The address for a given input/output can be used
throughout the program as many times as required by the
control logic.
• This PLC feature is an advantage when compared to
relay-type hardware, where additional contacts often
mean additional hardware.
72

Logic Concepts…
73

Logic Concepts…
CONTACT SYMBOLS USED IN PLCS

You might also like