PLC R
PLC R
1
DEPARTMENT OF ELECTRICAL AND ELECTRONICS
ENGINEERING
University College of Engineering Narasaraopet
Jawaharlal Nehru Technological University Kakinada
Narasaraopet – 522601, Andhra Pradesh, (2022-2023)
CERTIFICATE
This is to certify that the technical report on Industrial Training entitled “PROGRAMMBLE
LOGIC CONTROLLER” that is being submitted by DASARI PAVAN KUMAR
(22035A0207) in partial fulfilment for the award of Bachelor of Technology in Electrical and
Electronics Engineering to the University College of Engineering Narasaraopet, Jawaharlal Nehru
Technological University Kakinada is a record of bonafide work carried out by his under our
supervision.
2
3
ABSTRACT
An industrial PLCs system is used for the development of the controls of machinery. This paper
describes the PLCs systems in terms of their architecture, their interface to the process hardware,
the functionality and the application development facilities they provide. Some attention is also
paid to the industrial standards to which they abide their planned evolution as well afterpotential
benefits of their use
Ladder Logic is a graphical programming language, initially programmed with simple contacts
that simulate the opening and closing of relays. Ladder Logic programming has been expanded to
include functions such as Counters, Timers, shift Registers and math operations.
Ladder logic is a method of drawing electrical logic schematics. It is now a graphical language
very popular for programming Programmable Logic Controllers (PLCs). It was originally invented
to describe logic made from relays. The name is based on the observation that programs in this
language resemble ladders, with two vertical "rails" and a series of horizontal "rungs" between
them.
4
DECLARATION
5
Table of content:
6
4. OPERATION AND INSTRUCTIONS .............................................................. 13
4.1 TIMER ......................................................................................................... 13
4.2 COUNTER ..................................................................................................... 14
4.2.1 PLC COUNTER INSTURCTIONS .......................................................... 14
4.2.2 Counter Instructions Come in Three Basic types ...................................... 14
5. BIT ..................................................................................................................... 15
5.1 Lamp Glows w=When Aat Input Switch is Actuated ................................... 17
5.11 Programming for Start/Stop of Motor by PLC ........................................... 18
5.2 Starting of Motor ............................................................................................ 19
5.21 Logic for Continuous Running of Motor when Start Button Is Released .... 20
5.22 To Stop the Motor ...................................................................................... 21
6. CONTROL SYSTEMS ....................................................................................... 22
6.1 SCADA........................................................................................................... 22
6.2 HMI ................................................................................................................. 22
6.3 PROGRAMMABLE AUTOMATION CONTROLLER (PAC) ........................ 23
6.4 DESIGNING OF CONTROL PANEL ........................................................... 24
6.4.1 Requirements ............................................................................................... 24
6.4.2 Drawings ...................................................................................................... 24
6.5 DISTRIBUTED CONTROL SYSTEM.......................................................... 26
6.5.1 STRUCTURE ............................................................................................... 26
7
1. INTRODUCTION TO AUTOMATION
1.1 AUTOMATION
Automation or industrial automation is the use of control system such as computers, controllers to
control industrial machinery and processes, to optimize productivity in the production of goods
and delivery of services. Automation is a step beyond mechanization. Whereas mechanization
provides human operators with machinery to assist them with the muscular requirements of work,
automation greatly decreases the need of human sensory and mental requirements.
Fig 1.11
Fig 1.2
1
1.2 History of PLC’s
The fist Programmable Logic Controllers were designed and developed by Modicon as a
relay replacer for GM and Landies.
The primary reason for designing such a device was eliminating the large cost involved in
replacing the complicated relay-based machine control systems for major U.S. car
manufacturers.
These controllers eliminated the need of rewiring and adding additional hardware for every
new configuration of logic. The first PLC, modal 084, was invented by Dick Morley in
1968
The first commercial successful PLC, the model 184, was introduced in 1973 and was
designed by Machiel Greenberg. Communications abilities began to appear in
approximately 1973. The first such system was Modicon’s Modbus. The PLC could now
talk to other PLC’s and they could be far away from the actual machine they were
controlling.
Fig 1.2
2
1.3 Principle and Tools of PLC
Programmable Logic Controllers are used for continuously monitoring the input values from
sensors and produces the outputs for the operation of actuators based on the program. Every PLC
system comprises these three modules:
CPU module
Power supply module
One or more I/O module
Fig 1.31
PLC Architecture
1.31 CPU Module:
A CPU module consists of central processor and its memory. The processor is responsible for
performing all the necessary computations and processing of data by accepting the inputs and
producing the appropriate outputs.
This module supplies the required power to the whole system by converting the available AC
power to DC power required for the CPU and I/O modules. The 5V DC output drives the computer
circuitry.
The input and out modules of the programmable logic controller are used to connect the sensors
and actuators to the system to sense the various parameters such as temperature, pressure and flow,
etc. These I/O modules are of two types: digital or analog
3
INPUT MODULE
Input Module ¢ Input modules interface directly to devices such as switches and
temperature sensors. Input modules convert many different types of electrical signals
such as 120VAC, 24VDC, or 4-20mA, to signals which the controller can understand.
Since all electrical systems are inherently noisy, electrical isolation is provided
between input and processor. The component most often used for this purpose is opt
coupler. Input signal from the field devices are usually 4 to 20 ma or 0-10 V.
Fig 1.32
4
OUTPUT MODULE
Output module interface directly to devices such as motor starters and lights Output modules take
digital signals from the PLC and convert them to electrical signals such as 24VDC and 4 mA that
field devices can understand. D to A conversion is carried out in their modules. Usually Silicon
Controlled Rectifier (SCR), trial, or dry contact relays are used for this purpose. Normally the
Fig 1.33
5
2. Fundamental of PLC
Fig 2.11
This type of PLC is most commonly called the Fixed I/O PLC. “Fixed I/O” actually stands for
Fixed “Input/Output”. When you buy Compact PLCs, you will notice that the input section and
the output sections of the PLC are integrated into the microcontroller itself.
This means that every type of output or input is fixed and is determined by the manufacturer.
Furthermore, the number of inputs and outputs may not be expanded in this type of PLC.
6
2.12 Modular PLC
Fig 2.12
The modular PLC is a type that allows multiple expansions of the PLC system through the use
of modules, hence the term “modular”.
Modules give the programmable logic controller additional features like increased number of I/O
units, and they are usually easier to use because each component is independent of each other.
The power supply, communications module, Input/Output module are all separate to the actual
microcontroller so you have to manually connect them to each other to create your PLC control
system.
A type of modular PLC is the rack-mounted or rack mount PLC. In a rack mount PLC, the
communications module of the PLC resides in the rack itself, so all connections are centralized.
7
3. PLC Programming
PLC operates by continually scanning the program and acting upon the instructions, one at a time,
to switch on or off the various outputs. In order to do this PLC first scans all, the inputs and stores
their states in memory. Then it carries out program scan and decides which outputs should be high
according to the program logic. Then finally it updates these values to the output table, making the
required outputs go high. At his point PLC checks its own operating system and if everything is
ok, it goes back to scanning inputs all over again.
Whenever a program is executed in a PLC, before changing any output state, the processor scans
the input table and the entire program, which gives rise to states of the output devices according
to the program logic. These values are then updated to the output table making the device.
Time taken by plc to execute these three steps (Checking Input status, Executing
Fig 3.11
8
3.2 Programming Languages used to Program a PLC
While Ladder Logic is the most commonly used PLC programming language, but I is not the only
one. Following table lists some of the Languages that are used to program a PLC.
Fig 3.21
Ladder logic is a method of drawing electrical logic schematics. It is now a graphical language
very popular for programming Programmable Logic Controllers (PLCs). It was originally
9
invented to describe logic made from relays. The name is based on the observation that programs
in this language resemble ladders, with two vertical "rails" and a series of horizontal "rungs"
between them.
A program in ladder logic, also called a ladder diagram, is similar to a schematic for a set of relay
circuits. An argument that aided the initial adoption of ladder logic was that a wide variety of
engineers and technicians would be able to understand and use it without much additional training,
because of the resemblance to familiar hardware systems.
(This argument has become less relevant given that most ladder logic programmers have a
software background in more conventional programming languages, and in practice
implementations of ladder logic have characteristics — such as sequential execution and support
for control flow features — that make the analogy to hardware somewhat imprecise.)
Ladder logic is widely used to program PLCs, where sequential control of a processor
manufacturing operation is required. Ladder logic is useful for simple but critical control systems,
or for reworking old hardwired relay circuits. As programmable logic controllers became more
sophisticated it has also been used in very complex automation systems.
Ladder logic can be thought of as a rule-based language, rather than a procedural language. A
"rung" in the ladder represents a rule. When implemented with relays and other electromechanical
devices, the various rules "execute" simultaneously and immediately. When implemented in a
programmable logic controller, the rules are typically executed sequentially by software, in a loop.
The language itself can be seen as a set of connections between logical checkers (relay contacts)
and actuators (coils). If a path can be traced between the left side of the rung and the output,
through asserted (true or "closed") contacts, the rung is true and the output coil storage bit is
asserted (1) or true. If no path can be traced, then the output is false (0) and the "coil" by analogy
to electromechanical relays is considered "de-energized". The analogy between logical
propositions and relay contact status is due to Claude Shannon.
10
Ladder logic has "contacts" that "make" or "break" "circuits" to control "coils." Each coil or
contact corresponds to the status of a single bit in the programmable controller's memory. Unlike
electromechanical relays, a ladder program can refer any number of times to the status of a single
bit, equivalent to a relay with an indefinitely large number of contacts.
So-called "contacts" may refer to inputs to the programmable controller from physical devices
such as pushbuttons and limit switches, or may represent the status of internal storage bits which
may be generated elsewhere in the program.
Each rung of ladder language typically has one coil at the far right. Some manufacturers may allow
more than one output coil on a rung.
--[ ]-- A regular contact, true when its coil is true (normally false)
--[\]-- A "not" contact, false when its coil is true (normally true)
The "coil" (output of a rung) may represent a physical output which operates some
Input Instruction
actuated, then this instruction will not be true and hence output will not be generated. This
Instruction is Called IXO or Examine If Open. A NC switch is actuated, then only this instruction
will be true. If a NC switch is actuated, then this instruction will not be true and hence output will
not be generated.
11
Output Instruction
i.e.; If any instruction either XIO or XIC is true then output will be high. Due to high output a 24-
volt signal is generated from PLC processor.
3.25 Rung
Rung is a simple line on which instruction are placed and logics are created
Fig 3.22
12
4. OPERATION AND INSTUCTIONS
4.1 TIMER
A timer is a programmable instruction that lets you turn on or turn off bits after a preset time. The
two primary types of timers are TON for “timer on delay” and TOF for “timer off delay”. Timers
in RS Logix 5000 use tag names for identification.
Fig 4.1a
Fig 4.1b
13
4.2 COUNTER
A counter is a programmable instruction that lets you turn on or turn off bits after a preset count
has been reached. There are different types of counters available in the RS Logix, but the CTU
(counter up) instruction covers everything we will talk about here. Counters in RS Logix 5000 use
tag names for identification.
A counter is a PLC instruction that either increments (counts up) or decrements (counts down) an
integer number value when prompted by the transition of a bit from 0 to 1 (“false” to “true”).
1. up counters,
2. down counters, and
3. up/down counters.
Both “up” and “down” counter instructions have single inputs for triggering counts, whereas
“up/down” counters have two trigger inputs: one to make the counter increment and one to make
the counter decrement.
Fig 4.2
14
5 BIT
An address within the PLC. It can be an input, output or internal coil, among others.
Practical Examples
Example-1
Fig 5.1
Fig 5.12a
Fig 5.12b
15
Fig 5.13
When the pushbutton switch is unactuated (unpressed), no power is sent to the X1input of the PLC.
Following the program, which shows a normally-open X1 contact in series with a Y1 coil, no
"power" will be sent to the Y1 coil. Thus, the PLC's Y1output remains de-energized, and the
indicator lamp connected to it remains dark.
If the pushbutton switch is pressed, however, power will be sent to the PLC's X1 input. Any and
all X1 contacts appearing in the program will assume the actuated (non-normal) state, as though
they were relay contacts actuated by the energizing of a relay coil named "X1". In this case,
energizing the X1 input will cause the normally- open X1 contact will "close," sending "power" to
the Y1 coil. When the Y1coilof the program "energizes," the real Y1 output will become energized,
lighting up the lamp connected to it:
16
5.1 Lamp Glows when at Input Switch is Actuated
Fig 5.14
It must be understood that the X1 contact, Y1 coil, connecting wires, and "power" appearing in the
personal computer's display are all virtual. They do not exist as real electrical components. They
exist as commands in a computer program -- a piece of software only -- that just happens to
resemble a real relay schematic diagram.
Equally important to understand is that the personal computer used to display and edit the PLC's
program is not necessary for the PLC's continued operation. Once a program has been loaded to
the PLC from the personal computer, the personal computer may be unplugged from the PLC, and
the PLC will continue to follow the programmed commands.
17
It includes the personal computer display in these illustrations for your sake only, in aiding to
understand the relationship between real-life conditions (switch closure and lamp status) and the
program's status ("power" through virtual contacts and virtual coils).
The true power and versatility of a PLC is revealed when we want to alter the behavior of a control
system. Since the PLC is a programmable device, we can alter its behavior by changing the
commands we give it, without having to reconfigure the electrical components connected to it. For
example, suppose we wanted to make this switch-and-lamp circuit function in an inverted fashion:
push the button to make the lamp turn off, and release it to make it turn on.
The "hardware" solution would require that a normally-closed pushbutton switch be substituted
for the normally-open switch currently in place. The "software" solution is much easier: just alter
the program so that contact X1 is normally-closed rather than normally-open.
Fig 5.15
18
Fig 5.16
Another contact in the program, named Y'1, uses the output coil status as a seal-in contact, directly,
so that the motor contactor will continue to be energized after the "Start" pushbutton switch is
released. You can see the normally-closed contact X2 appear in a colored block, showing that it is
in a closed ("electrically conducting") state.
Fig 5.17
20
5.22 To Stop the Motor
To stop the motor, we must momentarily press the "Stop" pushbutton, which will energize the X2
input and "open" the normally- closed "contact," breaking continuity to the Y1 "coil:
Fig 5.18
When the "Stop" pushbutton is released, input X2 will de-energize, returning "contact" X2 to its
normal, "closed" state. The motor, however, will not start again until the "Start" pushbutton is
actuated, because the "seal-in" of Y1 has been lost.
1
6. CONTROL SYSTEMS
6.1 SCADA
Supervisory Control and Data Acquisition (or SCADA) is an automated control process that many
large industries use for industrial automation, such as manufacturing, construction, and
engineering facilities.
Often, SCADA will also have a separate component called HMI (human-machine interface).
Altogether, SCADA is a system that has software and hardware elements used to control processes,
interactions, and monitor and record data through PLCs and HMIs.
6.2 HMI
A human-machine interface is a user interface or dashboard that allows the human operator to
interact with a machine. HMIs are used all over the world in various technologies, ranging from
smartphones to power plants.
HMIs are not part of a particular software but is used for people to communicate with a machine
or device. Mainly, HMIs help users understand and control data with the touch of their fingertips
through communicable devices, such as:
Screens
Buttons
Levers
Computer mouse
Keyboards
SCADA systems can function without an HMI, although having one is often recommended. This
way, the operator can understand how to communicate with the system and receive any error
notices that need to be addressed.
2
6.3 PROGRAMMABLE AUTOMATION CONTROLLER (PAC)
controller (PAC) is a term that is loosely used to describe any type of automation controller that
incorporates higher-level instructions. The systems are used in industrial control systems (ICS) for
machinery in a wide range of industries, including those involved in critical infrastructure.
A PAC makes it possible to provide more complex instructions to automated equipment, enabling
much the same capabilities as PC-based controls in an all-in-one package like a programmable
logic controller (PLC).
PLCs were created in the 1960s as an improvement over relay-based systems. Although more
advanced than relay, PLCs still functioned by simple ladder logic that resembled the appearance
of wiring diagrams of relay systems. In the beginning, PLCs had limited memory, required
proprietary terminals and lacked remote I/O (input/output) capabilities. Additional abilities
required adding hardware cards. PC-based programming of PLC was introduced in the 1980s and
offered greater abilities, more memory and sequential control.
Early PACs came on the scene at the beginning of the 21st century. PACs offered a combination
of the abilities and technologies of distributed control systems (DCS) and remote terminal units
(RTU) as well as some of the abilities offered by PC control. PACs offered more connectivity
options and broader control while maintaining smaller packaging and durability for environmental
stresses and shock. With these new improvements, PACs were widely adopted.
Controllers of both types (PAC and PLC) have advanced since their creation. With the increased
capabilities of PLC, the differentiating lines between the two have blurred. Higher-end PLCs with
increased capabilities are often marketed as PAC.
3
6.4 DESINGING OF CONTROL PANEL
Understanding the basics of designing, assembling, and testing control panels is important for
original equipment manufacturers (OEMs) and systems integrators (SIs), and for the end users
who will receive these panels and operate them for years or decades. Panel design is a specialty,
and it requires much more than picking some parts and bolting them into an enclosure, but there
are many products and resources to help get the job done.
Requirements
Project needs are defined and specified by some level of requirements. Sometimes these are huge
and detailed documents, while other times they are more informal. And all designs must comply
with applicable electrical, UL, and safety codes—along with local requirements, and regulations.
EIC devices are installed into control panels to:
Drawings
Design personnel need to consider power consumption, overcurrent protection and conductor
sizing, conductor/cable tagging and routing, UL requirements, and code compliance. Drawing
packages define the work, and should include some or all of the following:
4
Interior layouts with dimensions and wire management provisions
Power distribution and grounding drawings
Block diagram and/or communication system architecture
I/O module and field termination strip drawings
Intelligent device drawings for VFDs, motion controllers, and the like
Fig 6.1
5
6.5 DISTRIBUTED CONTROL SYSTEM
A distributed control system (DCS) is a computerized control system for a process or plant
usually with many control loops, in which autonomous controllers are distributed throughout the
system, but there is no central operator supervisory control. This is in contrast to systems that use
centralized controllers; either discrete controllers located at a central control room or within a
central computer. The DCS concept increases reliability and reduces installation costs by
localizing control functions near the process plant, with remote monitoring and supervision.
Distributed control systems first emerged in large, high value, safety critical process industries,
and were attractive because the DCS manufacturer would supply both the local control level and
central supervisory equipment as an integrated package, thus reducing design integration risk.
Today the functionality of Supervisory control and data acquisition (SCADA) and DCS systems
are very similar, but DCS tends to be used on large continuous process plants where high reliability
and security is important, and the control room is not geographically remote. Many machine
control systems exhibit similar properties as plant and process control systems do.
6.51STRUCTURE
The key attribute of a DCS is its reliability due to the distribution of the control processing around
nodes in the system. This mitigates a single processor failure. If a processor fails, it will only affect
one section of the plant process, as opposed to a failure of a central computer which would affect
the whole process. This distribution of computing power local to the field Input/Output (I/O)
connection racks also ensures fast controller processing times by removing possible network and
central processing delays.
The accompanying diagram is a general model which shows functional manufacturing levels using
computerized control.
6
Referring to the diagram;
Level 0 contains the field devices such as flow and temperature sensors, and final
control elements, such as control valves
Level 1 contains the industrialized Input/Output (I/O) modules, and their associated
distributed electronic processors.
Level 2 contains the supervisory computers, which collect information from processor
nodes on the system, and provide the operator control screens.
Level 3 is the production control level, which does not directly control the process, but
is concerned with monitoring production and monitoring targets
Level 4 is the production scheduling level.
Levels 1 and 2 are the functional levels of a traditional DCS, in which all equipment are part of an
integrated system from a single manufacturer.
Levels 3 and 4 are not strictly process control in the traditional sense, but where production control
and scheduling take place.
Fig 6.2
7
Conclusion
Programmable Logic Circuits like an Arduino that is mainly used for industrial
automation. However, the main difference between a PLC and an Arduino is their
price, as the PLC usually has 100 times the price of an Arduino. The PLC has a better
processor power & memory, can handle more current in the I/O ports, the ports are
optocoupled, it is more robust, it is closed architecture, it comes with industrial
certificates, safety features etc.
8
References:
1. https://trainings.internshala.com/plc-programming -internship
2. WWW.Wikipedia.com
3. http://WWW.insulatorindia.com