Presentaion 7 Programmable Logic Controller (PLC)
Presentaion 7 Programmable Logic Controller (PLC)
Programmable Logic
Controller (PLC)
Brain Storming
AC and DC Motor
Brain Storming
Solenoid
Introduction
A programmable logic controller (PLC) is a digital electronic device that uses a
programmable memory to store instructions and to implement functions such as logic,
sequencing, timing, counting and arithmetic in order to control machines and processes
and has been specifically designed to make programming easy.
The term logic is used because the programming is primarily concerned with
implementing logic and switching operations.
Input devices, e.g. switches, and output devices, e.g. motors, being controlled are
connected to the PLC and then the controller monitors the inputs and outputs according
to the programmed stored in the PLC.
Cont.
• PLCs are similar to computers but have certain features which are specific to their use as
controllers. These are:
1. They are rugged and designed to withstand vibrations, temperature, humidity and
noise;
It is supplied with a clock with a frequency of typically between 1 and 8 MHz . This
frequency determines the operating speed of the PLC and provides the timing and
synchronization for all elements in the system.
A bus system carries information and data to and from the CPU, memory and input/
output units.
Basic PLC structure
Cont.
The input and output units provide the interface between the system and the outside
world and are where the processor receives information from external devices and
communicates information to external devices.
The input/output interfaces provide isolation and signal conditioning functions so that
sensors and actuators can often be directly connected to them without the need for other
circuitry.
Inputs might be from limit switches which are activated when some event occurs,
or other sensors such as Proximity sensors, or flow sensors. The outputs might be
to motor, starter, coils, solenoid valves, etc.
Cont.
PLCs were first conceived in 1968. They are now widely used and extend from small
self-contained units, i.e. single boxes, for use with perhaps 20 digital input/outputs to
rack-mounted systems which can be used for large numbers of inputs/outputs, handle
digital or analogue inputs/outputs, and also carry out proportional plus integral plus
derivative (PID) control modes.
The single-box type 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.
Programmable Logic Controller
Ladder Programming
The form of programming commonly used with PLCs is ladder programming. This
involves each program task being specified as though a rung of a ladder.
Thus such a rung could specify that the state of switches A and B, the inputs, be examined
and if A and B are both closed then a solenoid, the output, is energized.
The figure below illustrates this idea by comparing it with an electric circuit.
Cont.
The sequence followed by a PLC when carrying out a program can be summarized as
follows;
1. Scan the inputs associated with one rung of the ladder program.
2. Solve the logic operation involving those inputs.
3. Set/reset the outputs for that rung.
4. Move on to the next rung and repeat operations 1, 2, 3.
5. Move on to the next rung and repeat operations 1, 2, 3.
6. Move on to the next rung and repeat operations 1, 2, 3.
7. And so on until the end of the program with each rung of the ladder program scanned
in turn. The PLC then goes back to the beginning of the program and starts again.
Cont.
PLC programming based on the use of ladder diagrams involves writing a program in a
similar manner to drawing a switching circuit. The ladder diagram consists of two
vertical lines representing the power rails.
Circuits are connected as horizontal lines, i.e. the rungs of the ladder, between these two
verticals. The figure below shows the basic standard symbols that are used and an
example of rungs in a ladder diagram.
In drawing the circuit line for a rung, inputs must always precede outputs and there must
be at least one output on each line. Each rung must start with an input or a series of
inputs and end with an output.
Ladder program
Cont.
To illustrate the drawing of a ladder diagram, consider a situation where the output from
the PLC is to energize a solenoid when a normally open start switch connected to the
input is activated by being closed.
Starting with the input, we have the normally open symbol ||.
The line terminates with the output, the solenoid, with the symbol ( ).
To indicate the end of the program, the end rung is marked. When the switch is closed the
solenoid is activated.
Cont.
(a) AND, (b) OR, (c) NAND, (d) NOR, (e) XOR.
(a) AND, (b) OR, (c) NOR, (d) NAND
XOR.
Latching and internal relays
The term latch circuit is used for the circuit which carries out such an operation. It is a
self-maintaining circuit in that, after being energized, it maintains that state until another
input is received.
PLCs are generally provided with only a delay-on timer (TON), small PLCs possibly
having only this type.
(a), (b) Delay-on timer
Counters
Counters are used when there is a need to count a specified number of contact
operations, e.g. where items pass along a conveyor into boxes, and when the specified
number of items has passed into a box, the next item is diverted into another box.
Counter circuits are supplied as an internal feature of PLCs. In most cases the counter
operates as a down-counter. This means that the counter counts down from the present
value to zero, i.e. events are subtracted from the set value. When zero is reached the
counter’s contact changes state.
An up-counter would count up to the preset value, i.e. events are added until the
number reaches the pre-set value. When the set value is reached the counter’s
contact changes state.
Relays
When a current passes through a solenoid, a magnetic field is produced; this can then
attract ferrous metal components in its vicinity. With the relay, this attraction is used to
operate a switch. Relays can thus be used to control a larger current or voltage and,
additionally, to isolate the power used to initiate the switching action from that of the
controlled power.