Professional Documents
Culture Documents
Prem Project Report PLC Final Traffic - 1
Prem Project Report PLC Final Traffic - 1
ABSTRACT
Control Engineering has evolved over time. In the past humans were the main methods
for controlling a system. More recently electricity has been used for control and early electrical
control was based on relays. These relays allow power to be switched on and off without a
mechanical switch. It is common to use relays to make simple logical control decisions. The
development of low cost computer has brought the most recent revolution, the Programmable
Logic Controller (PLC). The arrival of the PLC began in the 1970s and has become the most
common choice for manufacturing controls. PLCs have been gaining popularity on the factory
floor and will probably remain predominant for some time to come.
PLCs are most certain for all mechanical engineers. Students studying in this stream
have to acquire a basic knowledge about automation. Recently, Board of Technical Education
(DTE) prescribed “Elements of Automation” course for 4th semester students’ in new C20
curriculum. In this regard, to make laboratory setup for junior friends, an attempt is made to
design and fabricate student friendly and safe PLC kits is undertaken. This project helps to
understand the automation concepts by easily by designing any conceived automation idea and
downloading to PLC. "Elevator Model" is also designed and fabricated to interface with PLCs.
Students can individually program and download any logic to control elevator model according
his conceived logic.
In this kits, latest and industry 2.0 recommended Allen Bradley's Micro820 PLC is
used. Most common programming method, Ladder Logic is used to program the PLC. Most
recent push buttons, sensors, motors, relay, solenoids and displays are used to make the models
more realistic
ACNOWLEDGEMENTS
We have great pleasure in expressing our deep sense of gratitude to this institution,
which as provided us an opportunity to do the project in the college and also facilities for doing
it.
We whole heatedly thank all staff members of Mechanical Engineering Department for
their suggestions and support.
Last but the least, we also thank all those who have been directly or indirectly involved
in the completion of our project.
CONTENTS
References 50-50
CHAPTER 1
INTRODUCTION TO PROGRAMMABLE LOGIC
CONTROLLERS
CHAPTER 1:
PROGRAMMABLE LOGIC CONTROLLER
1.1 INTRODUCTION:
A programmable logic controller, PLC, or programmable controller is a small computer
used for automation of real-world processes, such as control of machinery on factory assembly
lines. The PLC usually uses a microprocessor. The program can often control complex
sequencing and is written by skilled engineers. The program is stored in battery-backed memory
and/or EEPROMs.
PLCs differ from normal computers by its special input/output arrangements. These
connect the PLC to sensors and actuators. PLCs read limit switches, dual-level devices,
temperature indicators and the positions of complex positioning systems. Some even use
machine vision. On the actuator side, PLCs drive any kind of electric motor, pneumatic or
hydraulic cylinders or diaphragms, magnetic relays or solenoids. The input/output arrangements
may be built into a simple PLC, or the PLC may have external I/O modules attached to a
proprietary computer network that plugs into the PLC.
PLCs were invented as less expensive replacements for older automated systems that would use
hundreds or thousands of relays and cam timers. Often, a single PLC can be programmed to
replace thousands of relays. Programmable controllers were initially adopted by the automotive
manufacturing industry, where software revision replaced the re-wiring of hard- wired control
panels.
The functionality of the PLC has evolved over the years to include typical relay control,
sophisticated motion control, process control, Distributed Control Systems and complex
networking.
The earliest PLCs expressed all decision making logic in simple ladder logic inspired
from the electrical connection diagrams. The electricians were quite able to trace out circuit
problems with schematic diagrams using ladder logic. This was chosen mainly to reduce the
apprehension of the existing technicians.
1.2 HISTORY:
The PLC was invested in response to the needs of the American automotive
industry. Before the PLC, control, sequencing, and safety interlock logic for
manufacturing automobiles and trucks was accomplished using relays, timers and
dedicated closed-loop controllers. The process for updating such facilities for the yearly
model changeover was very time consuming and expensive, as the relay systems
needed to be rewired by skilled electricians. In 1968 GM Hydromantic (the automatic
transmission division of General Motors) issued a request for proposal for an
electronic replacement for hard-wired relay systems.
One of the very first 084 models build is now on display at Modicon’s
headquarters in North Andover, Massachusetts. It was presented to Modicon by GM,
when the unit was retired from nearly twenty years of uninterrupted service.
The first PLC systems evolved from conventional computers in the late 1960’s
and early1970’s these first PLCs were installed primarily in automotive plants.
Traditionally, the auto plants had to be shut down for up to a month at model changeover
time. The early PLCs were used along with other new automation techniques to shorten
the change over time. The PLC keyboard reprogramming procedure replaced the rewiring
of a panel full of wires, relays, times, and other components. The new PLCs helped reduce
change over time to a matter of a few days. With the adventure of the microprocessor
these devices have become very powerful in recent years. Both the personal computers
and PLCs are now used in manufacturing systems. Personal computers and PLC are based
upon microprocessor and these are used for similar type tasks on the shop floor.
Personal computers are generally designed for business used with control a
secondary function and for these personal computers normally it requires additional
interface software and hardware however various stand-alone personal computers are
become available that do have necessary construction to withstand rigors (sense of
coldness with concentration of skin) and demand of the factory environment. This PLCs
are designed for control of equipment of process in an industry environment which
requires high temperature, humidity variation and so on. The PLCs are designed in such
a way that PLC devices are directly connected to machines and industry plant. PLC
doesn’t require a monitor but it has the ability to have several types of peripheral devices
connected to view the status of program that it is running.
Input module
Output module
Processor
Memory
Power supply
Programming device
The input module and output module are the connections to the industrial process
that in to be controlled. The inputs to the controller are signals from limit switches,
pushbuttons, sensors, and other devices. The outputs from the controller in order to operate
motors, valves, and other devices required to actuate the process.
The processor is the central processing unit (CPU) of the programmable controller.
It executes the various logic and sequencing functions. The processor is similar in its
construction to those used in personal computers and microprocessor very other data-
processing equipment. Tied to the CPU is the PLC memory, which contains the program
of logic, sequencing, and other input/output operations.
The memory for a programmable logic controller is specified in the same way as
for a computer, and may range from 1k to over 48 k of storage capacity. A power supply
of 115V ac is specially used to drive the PLC even though the components of the industrial
process that are regulated may have a higher voltage and power rating than the controller
itself.
The bus is a group of parallel lines. Data bus is an electrical path that connects the
CPU, memory, and other hardware devices on the other board.
The Address bus is a set of wires, which is similar to the data bus, but it connects
only the CPU and the memory, and all it carries are memory address. A bus system carries
information and data to from the CPU main memory and input and output module. All the
operations and processes controlled by CPU within the PLC, the software which is the
user program written by PLC user, user programs are usually installed in RAM. A random
memory where they can be easily modified. Control bus or lines are required to activate
the correct bus station either as a transmitter or sender.
When a process is controlled by a PLC it uses inputs from sensors to make decisions
and update outputs to drive actuators, as shown in Figure. The process is real process that
will change over time. Actuators will drive the system to new states (or modes of
operation). This means that the sensors available limit the controller, if an input is not
available the controller will have no way to detect a condition.
The control loop is a continuous cycle of the PLC reading inputs, solving the ladder
logic, and then changing the outputs. Like any computer this does not happen instantly.
Figure shows the basic operation cycle of a PLC. When power is turned on initially the
PLC does a quick sanity check to ensure that the hardware is working properly. If there is
a problem the PLC will halt and indicate there is an error. For example, if the PLC backup
battery is low and power was lost, the memory will be corrupt and this will result in a fault.
If the PLC passes the sanity check it will then scan (read) all the inputs. After the inputs
values are stored in memory the ladder logic will be scanned (Solved) using the stored
values – not the current values. This is one to prevent logic problems when inputs change
during the ladder logic scans. When the ladder logic scan is complete the outputs will be
scanned the output values will be changed. After this the system goes back to do a sanity
check, and the loop continues indefinitely. Unlike normal computers, the entire program
will be run every scan. A typical time for each of the stages is in the order of milliseconds.
The input/output unit provides the interface between the system and the outside
world. Programs are entered into the input/output unit from a panel, which can vary from
small keyboards with liquid crystal displays to those using a visual display unit (VDU)
with keyboard. Alternatively the programs can be entered into the system by means of a
link to a personal computer which is loaded with an appropriate software package.
Common output voltages are 24V and 240V. Outputs are specified as being of
relay type, transistor type or Triac type. With the relay type, the signal from the PLC
output is used to operate a relay and so is able to switch currents of the order of few
amperes in an external circuit.
The relay isolates the PLC from the external circuit and can be used for both AC
and DC switching. Relays are relatively slow to operate. The transistor type of output
uses a transistor to switch current through the external circuit. This gives a faster
switching action. The transistor output is only for DC switching. Triac outputs can be
used to control external loads, which are connected to the AC power supply only. Opt
isolators are again used to provide isolation.
Basically ladder programming is used with PLCs. The ladder program consists of
individual rungs containing one output instruction and one or more input instructions. The
rungs could specify the state of switches.
For instance, the switch A and switch B inputs are tested; if switch A and switch B
are both closed then a solenoid, the output is enabled.
1) The following ladder program sequences carried out by means of PLC are:
2) Scan the program inputs with first rung of the ladder diagram.
3) With Ladder program inputs logically solve its operation.
4) Set or rest of the output for rung.
5) Until the end of the ladder program in every sequence it moves on to the next
rung and repeats the operations a, b, c.
When a ladder program is executed, every time each rung of the ladder diagram is
scanned to process the scanning of input/output data. The following two methods are to
be considered.
• Continuous updating
• Mass input or output copying
CONTINUOUS UPDATING:
The operating cycle of a PLC that consists of program scan and input/output scan,
the data associated with external outputs are transferred from the output data file to the
output terminals. Their data is updated during the previous scan of the ladder program and
also the input and output scan where, the inputs are scanned to determine their state and
associated ON/OFF states. During the program scan the updated status of the external
input device are applied to the ladder program. The CPU processes all the instructions in
the ascending rung order in the ladder programs scan that moves from one instruction to
the next instructions through all the rungs of the ladder program.
Whenever updating continuously for each input there should be a delay of 3ms in
time. When we compare for many inputs and output depending upon the length of the
program the time taken will be considerably more. As updating time is much more, to
overcome this and to permit execution of program, temporary memory is used to store the
data and RAM is used as a buffer (Temporary). When each program cycle starts the
microprocessor scans all the inputs with their status and the copies into the I/O addresses
in RAM.
The stored data in RAM are used during every next step which the PLC execute
the program and then stores the result of the execution for subsequent use and at the end
the PLC always updates the status of the outputs.
PLC inputs are easily represented in ladder logic. In Figure there are three types of
inputs shown. The first two is normally open and normally closed inputs. The III
(immediate Input) function allows inputs to be read after the input scan, while the ladder
logic is being scanned. This allows ladder logic to examine input values more often than
once every cycle.
Normally open and active input will close the contact and allow power to flow.
Normally closed, power flows when the input is not open. In ladder logic there are multiple
types of outputs, but these are not cons available on all PLCs. Some of the outputs will be
externally connected to device the PLC, but it is also possible to use internal memory
locations in the PLC. Six outputs are shown in Figure. The first is a normal output, when
energized the will turn on, and energize an output. The circle with a diagonal line through
is an on output. When initially energized the output will turn off. This type of output is not
available all PLC types. When initially energized the OSR (One Shot Relay) instruction
will for one scan, but then be off for all scans after, until it is turned off. The L (latch
unlatch) instructions can be used to lock outputs on. When an L output is energized output
will turn on indefinitely, even when the output coil is de-energized. The only are turned off
using a U output. The last instruction is the IOT (Immediate that will allow outputs to be
updated without having to wait for the ladder logic’s completed.
LADDER LOGIC:
The normally closed contacts touch when the input coil is not energized. Relays
are normally drawn in schematic form using a circle to represent the input coil. The
output contacts are shown with two parallel lines. Normally open contacts are shown as
two lines, and will be open (non-conducting) when the input is not energized. Normally
closed contacts are shown with two lines with a diagonal line through them. When the
coil is not energized the normally closed contacts will be closed.
Relays are used to let one power source close a switch for another (often-high
current) power source, while keeping them isolated. An example of a relay in a simple
control application is shown in Figure. In this system the first relay on the left is used as
normally closed, and will allow current to flow until a voltage is applied to the input A.
The second relay is normally open and will not allow current to flow until a voltage is
applied to the input B. If current is flowing through the first two relays then current will
flow through the coil in the third relay, and close the switch for output C. This circuit
would normally be drawn in the ladder logic form. This can be read logically as C will be
ON.
The example in Figure does not show the entire control system, but only the logic.
When we consider a PLC there are inputs, outputs, and the logic. Above figure shows a
more complete representation of the PLC. Here there are two inputs from push buttons.
We can imagine the inputs as activating 24V DC relay coils in the PLC. This in turn drives
an output relay that switches 115V AC that will turn on a light. Note, in actual PLCs inputs
are never relays, but outputs are often relays. The ladder logic in the PLC is actually a
computer program that the user can enter and change. Notice that both of the inputs push
buttons are normally open, but the ladder logic inside the PLC has one normally open
contact.
PROGRAMMING:
Early PLCs, up to the mid-1980s, were programmed using proprietary
programming panels or special-purpose programming terminals, which often had
dedicated function keys representing the various logical elements of PLC programs.
Programs were stored on cassette tape cartridges. Facilities for printing and documentation
were very minimal due to lack of memory capacity. More recently, PLC programs are
typically written in a special application on a personal computer then downloaded by a
direct-connection cable or over a network to the PLC. The very oldest PLCs used non-
volatile Magnetic core memory but now the program is stored in the PLC either in battery-
backed-up RAM or some other non-volatile flash memory.
Early PLCs were designed to be used by electricians who would learn PLC
programming on the job. These PLCs were programmed in “ladder logic”, which strongly
resembles schematic diagram of relay logic. Modern PLCs can be programmed in a variety
of ways, from ladder logic to more traditional programming languages such as BASIC
and C. Another method is State Logic, a Very High Level Programming Language
designed to program PLCs based on State Transition Diagrams.
Recently, the International standard IEC 61131-3 has become popular. IEC 61131-
3 currently defines five programming languages for programmable control systems:
FBD (Function block diagram), LD (Ladder diagram), ST (Structured text, similar to the
Pascal programming language, IL (Instruction list, similar to assembly language) and SFC
(sequential function chart). These techniques emphasize logical organization of operations.
Within the PLC CPU registers are found in to location. The microprocessor has
internal Registers most of which are not directly accessible by the user. These registers (4,
8, 16 or 32 bits wide depending on the microprocessor) help the control and arithmetic
and logic units within the processor to carry out their tasks. Accumulator register, data
Registers, index registers condition, code registers, scratch pad registers and instruction
register work to temporarily store data, which in turn is used to facilitate the carrying out
of programmed functions.
In addition to their internal registers, the CPU‟s Rams also contains slots that are
designated to hold variable information. These locations, or address, become external
registers there can be a mere handful of such registers or hundreds depending on the size
of the CPU and complexity of the user program.
1) Holding register
A single –input timer called a no retentive timer is used in some PLCs. Eg:
Energizing IN001 causes the timer to run for 4 seconds. At the end of 4 seconds the output
goes on. When the input is de-energized the output goes off and the timer resets to 0. If
the input IN001 is turned off during the internal (E.g.: after 2.7 seconds) the timer resets
to 0. In this case the output would not have turned on.
There are disadvantages of the single- input type timer that are overcome by the
multiple input timer. There is 3 type of formats for PLC timers.
1) Block format
2) Coil format with separate enable 4 reset
3) Coil format
The black format includes the enabled reset line. Which allows the timer to run
when energized? When de-energized, the timer is kept at O or reset to 0. The upper line
causes the timer to run when the time is enabled. When enabled the timer runs as long or
the run input is energized. If Two other timer functions are including in some PLCs. Time
delay on 4-time delay off there are 3 states in a timing cycle.
A system of “X‟ for on 4 „0‟ for off is normally used. The examples illustrate this
convention. In some system as 1 is used instead of an x to indicate contract closed.
1) On delay output B comes on at a specific set time after output A is turned on. When
A is turned off B also goes off.
2) Off delay. Both A and B have been turned on at the sometime. Both are in
operation. When A is turned off, B remains on for a specific set time period before
going off.
3) Limited on time A and B go on at the same time B goes off after specific set time
period but A remains on.
4) Repeat cycling, An output pulses on and quickly off at a constant pre-set time into
5) On-shot operation, output B goes on for a specified time after output A is turned
on. Output B will run for its specified time interval even if A is turned off during
the B timing interval.
6) Alternate on 4 off two outputs. An E.g. of this timing. Application is two alternately
flashing signal lights. The time on for each of the two lights may be the same or
the two times could be set to different intervals.
7) Multiple on delay 2 different event start at different time intervals after an initial
starting time reference point. Multiple off delay 2 different functions remain on for
two different time intervals after a process is turned off.
8) Interval time within a cycle e we may require that an output come on 7.5 seconds.
After system start up remain on for 4 seconds and then go off 4 stay off. The
interval would then be repeated only after the system is shut off and then turned
back on.
PLC COUNTER
1) up counters
2) down counters
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.
In this system, a continuous (unbroken) light beam causes the light sensor to close
its output contact, energizing discrete channel IN4. When an object on the conveyor belt
interrupts the light beam from source to sensor, the sensor’s contact opens, interrupting
power to input IN4.A push-button switch connected to activate discrete input IN5 when
pressed will serve as a manual “reset” of the count value. An indicator lamp connected to
one of the discrete output channels will serve as an in indicator of when the object count
value has exceeded some pre-set limit. We will now analyze a simple Ladder Diagram
program designed to increment a counter instruction each time the light beam breaks.
1) Process planning.
2) Production machine programming.
3) Tool and fixture Engineering.
4) Work and production standard
5) Process planning.
6) Production machine programming.
7) Tool and fixture Engineering.
Merits:
2) Lower Cost: - Increased technology makes it possible to condense more functions into
smaller and less expensive packages. Now you can purchase a PLC with numerous
relays, times, and controllers, a sequencer, and other functions for under a hundred
dollars.
4) Speed of Operation: - Relays can take an unacceptable amount of time to actuate. The
operational speed for the PLC program is very fast. The speed for the PLC logic
operation is determined by scan time, which is a matter of milliseconds
6) Reliability and Maintainability: - Solid-state devices are more reliable, in general, than
mechanical systems or relays and timers. The PLC is made of solid-state components
with very high reliability rates. Consequently, the control system maintenance costs
are low and down time are minimal.
8) Security: - A PLC program change cannot be made unless the PLC is properly
unlocked and programmed. Relay panels tend to undergo undocumented changes.
People on late shifts do not always record panel alterations made when the office area
is locked up for the night.
Demerits
CHAPTER 2
Panel Board drawing is prepared using Solid Edge software as shown in figure
2.2. Red lines in the figure shows the slot cutting areas and blue lines are for engraving.
At most care is taken accommodate all the mountings on the panel board for
easy accessibility and understanding. Then the CAD drawings DXF format is sent for
cutting and engraving on the 5mm thick acrylic sheet.
Figure 2.3: Acrylic Panel Board prepared using Laser engraver and cutter
Figure 2.3 shows finished acrylic panel sheet. From the sketch it clear seen that all
the interfacing and mounting provisions are made in the panel board
Each work station has Allen-Bradley Micro 820 PLC. Totally five PLC are used in
this project. The AB PLC model having catalogue number 2080-LC20-20QBB is used here.
This Micro820 series PLC has 20 point (12 IOs) Micro PLC is specifically designed for
small standalone machines and remote automation projects with embedded Ethernet and
serial ports. It has a Controller, 12 24V DC Inputs, 4 configurable analogue input with
thermistor voltage reference out, 7 24V DC Source Output, 1 Analog Output, Embedded
Ethernet Port and RS- 232/485 non-isolated Serial port, Embedded RTC, Micro-SD Card
support, 2 Plug-In slots.
It can function as a RTU (remote terminal unit) for remote machines with support
for Modbus RTU and TCP. It has embedded support for 4 thermistor temperature inputs
for use as a DDC (direct digital controller) for Building Management Systems.
The Micro820 supports an embedded micro-SD slot that can be used for storing
large amounts of data that normally cannot fit into memory for applications that require
data log and recipe. All files are stored in CSV text format for easy viewing and editing.
The micro-SD card is also used for backing up and restoring the program, which can be
used for duplicating the program in several machines.
Automation. CCW Version 13 is used in this project. This software has following
features
• Easy to configure – Single software package reduces initial machine development time
and cost
• Easy to program – Simplify programming process with sample code and user-defined
function blocks
• Easy to visualize – Reference Micro800 controller variables directly when creating
HMI tags Connected Components Workbench design and configuration software
offers controller programming, device configuration, and integration with HMI editor.
Each work station has independent power supply. 24 volts 5 amps DC power
Supply is used is shown in fig 2.6. Two separate DPST switches are used for PLC and
other components of the workstation.
CHAPTER 3
INTRODUCTION
Traffic signals are not a solution for all traffic problems at intersections, and
unwarranted signals can adversely affect the safety and efficiency of traffic by causing
one or more of the following:
• Excessive delay;
• Increased traffic congestion, air pollution and fuel consumption;
• Disobedience of signals;
• Increased use of less-adequate streets to avoid traffic signals;
• Increased frequency of crashes, especially rear-end collisions.
Logic Description:
Two-way traffic interaction is considered for designing the traffic light for the given
location. When the START push button is pressed sequence shown in Table 8.1 takes place.
When START button is not pressed or the STOP button is pressed the yellow light on both
direction (SOUTH and EAST) will flash continuously until the START button is ON.
Components required
2 PLC 1
3 INDICATORS 6
4 ALUMINIUM
FRAME
5 BANANA PINS 8
FEMALE
ALUMINIUM FRAME:
INDICATORS :
Ladder diagram:
Rung 1 Diagram: Start the main switch of traffic signal by pressing START button and
switch off by using STOP button
Rung 4 Diagram: To turn on GREEN 1 timer after YELLOW 1light turns OFF
Rung 8 Diagram: To run the timer for GREEN 2 after YELLOW 2 timer
Rung 11 Diagram: To turn on RED 2 along with YELLOW 1 and turn it off with GREEN 1
Result: A Two way traffic signal light is designed and tested successfully.
CHAPTER 4
On Estimating this project, we get the idea of the cost of the project and hence its
feasibility can determinate i.e., whether the project could be taken up within the funds
available or not. Estimation gives an idea of time required for the completion of the work.
costing its provides a tool for price fixations as well as price control costing can be
help the make decisions about tariff protection, and it can also offer information relating to
wage. A final advantage of costing is that it helps us within to make decisions about wages.
Sl No
Particulars Quantity Rate Amount
Miscellaneous 5000
Chapter 5
CONCLUSION
CONCLUSIONS
This PLC Trainer kit is an experimental platform, by using this ladder logics
programs can be checked. This equipment is specially built for teaching and student
community. Following are the some of the important from the project work.
conclusions drawn
REFERENCE