Sei sulla pagina 1di 47

“DENSITY BASED TRAFFIC LIGHT

CONTROL SYSTEM”
A Project Report
Submitted in partial fulfillment of the requirements for the award
of the degree of
MASTER OF SCIENCE IN
ELECTRONICS
SUBMITTED TO
Pt. Ravishankar Shukla University Raipur (C.G.)

SUBMITTED BY
SHUBHAM DEWANGAN (ROLL NO:- 1713517)

SUPERVISED BY
Dr. KAVITA THAKUR

CO-SUPERVISED BY
Miss. NEHA DEWANGAN

School of Studies in Electronic &Photonics


Pt. Ravishankar Shukla University Raipur (C.G.)
JUNE 2019
1
BONAFIDE CERTIFICATE
This is to certify that the project report entitled “DENSITY BASED TRAFFIC LIGHT
CONTROL SYSTEM” submitted to Pt. Ravishankar Shukla University Raipur is a bonafide
record of work done by SHUBHAM DEWANGAN, under my supervision from Jan 2019 to June
2019. The work has been presented in a manner suitable to warrant acceptance towards the
fulfillment of the requirement for the degree of Master of Science in Electronics, Pt. Ravishankar
Shukla University, Raipur (C.G.).

Date: 22-06-2019 Dr. KAVITA THAKUR


Place: RAIPUR (Supervisor)

………………………. Miss. NEHA DEWANGAN


Examiner (Co-Supervisor)
Name:
Address:

(SIGNATURE OF THE HEAD OF DEPARTMENT WITH SEAL)


(Dr. SANJAY TIWARI)

2
D ECLARATION BY CANDIDATES
We the undersigned declare that the project report entitled “DENSITY BASED TRAFFIC
LIGHT CONTROL SYSTEM” has been carried for the degree of Master of Science in Electronics,
Pt. Ravishankar Shukla University, Raipur (C.G.).

We declare that this written submission represents our ideas in our own words and other ideas
or words are also included. We have adequately cited and referenced the original sources. We also
declare that we have adhered to all principles of academic honesty and integrity and have not
misrepresented or fabricated or falsified any sources/ idea/data/fact in our submission. I understand
that any violation of the above will be considered to be indiscipline any action by the institute and by
the exam panel of the proper citation of the reference source & using any source content without the
permission will evoke the panel.

………………………
Place- Raipur SHUBHAM DEWANGAN
DATE – 22/06/2019

3
ACKNOWLEDGEMENT
Firstly, I would like to express my deep sense of gratitude to Dr. SANJAY TIWARI, Head,
SoS in Electronics & Photonics, Pt. Ravishankar Shukla University, Raipur(C.G),for his generous
supervision, co-operation and suitable suggestions throughout the course of present work and for
providing us infrastructural facilities to work in, without which this work would not have been
possible.
I express my sincere gratitude to Prof. KAVITA THAKUR, Assistant Professor, School of
Studies in Electronics & Photonics, Pt. Ravishankar Shukla University, Raipur, for his stimulating
guidance, continuous encouragement, cooperation and useful suggestions.

I also wish to extend my thanks to Miss. NEHA DEWANGAN, faculty of for the degree of
Master of Science in Electronics, Pt. Ravishankar Shukla University, Raipur (C.G.), for his help and
supervision and other teachers also for attending my project presentation and for their insightful
comments and constructive suggestions to improve the quality of this project work.

I am extremely thankful to Mr. RAMDAS BANJARE, technical staff of School of Studies in


Electronics & Photonics, Pt. Ravishankar Shukla University, Raipur and other staff member for
their support.

Signature of Student
SHUBHAM DEWANGAN

4
ABSTRACT
Nowadays, controlling the traffic becomes major issue because of rapid increase in
automobiles and also because of large time delays between traffic lights. So, in order to rectify this
problem, we will go for density based traffic lights system. This article explains you how to control
the traffic based on density.

In this system, we will use IR sensors to measure the traffic density. We have to arrange one
IR sensor for each road; these sensors always sense the traffic on that particular road. All these
sensors are interfaced to the microcontroller. Based on these sensors, controller detects the traffic
and controls the traffic system.

The project is aimed at designing a density based dynamic traffic signal system where the
timing of signal will change automatically on sensing the traffic density at any junction. Traffic
congestion is a severe problem in most cities across the world and therefore it is time to shift more
manual mode or fixed timer mode to an automated system with decision making capabilities.
Present day traffic signaling system is fixed time based which may render inefficient if one lane is
operational than the others. To optimize this problem we have made a framework for an intelligent
traffic control system. Sometimes higher traffic density at one side of the junction demands longer
green time as compared to standard allotted time We, therefore propose here a mechanism in which
the time period of green light and red light is assigned on the basis of the density of the traffic
present at that time. This is achieved by using PIR(proximity Infrared sensors). Once the density is
calculated, the glowing time of green light is assigned by the help of the microcontroller (Arduino).
The sensors which are present on sides of the road will detect the presence of the vehicles and sends
the information to the microcontroller where it will decide how long a flank will be open or when to
change over the signal lights. In subsequent sections, we have elaborated the procedure of this
framework.

5
LIST OF FIGURES Pg. No.

3.1. TRAFFIC CONGESTION 17


TRAFFIC PROBLEM 18
TECHNIQUES OF TRAFFIC MANAGEMENT 19

4.1 ARDUINO UNO 28

MICROCONTOLLER ARCHITECTURE 29

ATMEGA328P 30

IR SENSORS 32

GENERAL DISCRIPTION 33

HOW DOES IT WORKS 33

LIGHT EMITTING DIODE 34

TYPES OF RECOMBINATION 35

STRUCTURE 36

CIRCUIT DIAGRAM OF A CRYSTAL 36

CRYSTAL OSCILLATOR 37

VOLTAGE REGULATOR CIRCUIT LM7805 37

THE LM7805 PIN DIAGRAM 38

4.14. VARIABLE RESISTOR 38

4.15 CAPACITOR 39

6
LIST OF TABLE Pg. No.

ARDUINO UNO AND ATMEGA328P 20


PIN AND THEIR FUNCTION 31
PIN DESCRIPTION OF LM7805 38

7
CONTENTS Pg.No.

CHAPTER 1
1. INTRODUCTION 11
GENERAL BACKGROUND 11
PRESENT TRAFFIC SIGNALING SYSTEM 11
OPERATIONAL MODEL 12
CHALLENGES AND FUTURE ADVANTAGES 13
CONCLUSION 13
CHAPTER 2
2. COMPONENT USED 15
CHAPTER 3
3. LITERATURE REVIEW 17
INTRODUCTION 17
LITERATURE REVIEW 18
TECHNIQUE OF TRAFFIC MANAGEMENT 19
SIMPLE TRAFFIC MANAGEMENT SCHEME 20
AUTOMETIC TRAFFIC MANAGEMENT SCHEME 21
INTELLIGENT TRAFFIC MANAGEMENT SCHEME ON IMAGE
PROCESSING 21
INTELLIGENT TRAFFIC MANAGEMENT SCHEME USING WIRELESS
TECHNOLOGY 21
IRIS (INTELLIGENT ROADWAY INFORMATION SYSTEM) 21
CHAPTER 4

4. DESIGN & IMPLEMENTATION 27


ARDUINO UNO 27
PIN FUNCTIONS 27
MICROCONTROLLER 29
ATMEGA328P 30
IR SENSOR 32
GENERAL DISCRIPTION 33
LIGHT EMITTING DIODE 34
TYPES OF COMBINATION 34
STRUCTURE 35
CRYSTAL OSCILLATOR 36
VOLTAGE REGULATION 37
8
VARIABLE RESISTOR 38
CAPACITOR 39
CHAPTER 5
5. WORKING PRINCIPLE 41
ADVANTAGES 43
APPLICATIONS 44
CHAPTER 6
DISCUSSION, CONCLUSION CHALLENGES AND FUTURE SCOPE OF
ADVANCEMENTS 10

DISCUSSION 46
CONCLUSION 46
CHALLENGES AND FUTURE SCOPE OF ADVANCEMENTS 47
REFERENCES 48
APPENDIXES 49

9
CHAPTER 1
INTRODUCTION

10
1. INTRODUCTION

General Background

In today’s high speed life,traffic congestion becomes a serious issue in our day to day activities.
It brings down the productivity of individual and thereby the society as lots of work hour is wasted
in the signals. High volume of vehicles, the inadequate infrastructure and the irrational distribution
of the signaling system are main reasons for this chaotic congestions. It indirectly also adds to the
increase in pollution level as engines remain on in most cases, a huge volume of natural resources in
forms of petrol and diesel is consumed without any fruitful outcome. Therefore, in order to get rid of
these problems or at least reduce them to significant level, newer schemes automation technique in
this field of traffic signaling system.

PRESENT TRAFFIC SIGNALING SYSTEM

Under present scenario, traffic control is achieved by the use of a system of hand signs by traffic
police personnel, traffic signals, and markings. A comparable and matching education program is
needed, through driver-licensing authorities, to assure that those who operate motor vehicles
understand the rules of the road and the actions that they are required or advised to take when a
particular control device is present. Each traffic control device is governed by standards of design
and usage; for example, stop signs always have a red background and are octagonal in shape. Design
standards allow the motorist to quickly and consistently perceive the sign in the visual field along the
road. Standard use of colors and shape aids in this identification and in deciding on the appropriate
course of action.
Under current circumstances, traffic lights are set on in the different directions with fixed time
delay, following a particular cycle while switching from one signal to other creating unwanted and
wasteful congestion on one lane while the other lanes remain vacant.
The system we propose identify the density of traffic on individual lanes and thereby regulate
the timing of the signals’ timing. IR trans receivers count the obstructions and provide an idea about
the traffic density on a particular lane and feed this response to a controller unit which will make the
necessary decisions as and when required.

OPERATIONAL MODEL

The model works on the principle of changing delay of Traffic signals based on the number of
11
1
cars passing through an assignedsection of the road. There are four sensors placed at four sides of a
four way road which counts the number of cars passing by the area covered by the sensors.
Here we are using IR sensors replacing system to design an intelligent traffic control system. IR
sensor contains IR transmitter IR receiver (photodiode) in itself. These IR transmitter and IR
receiver will be mounted on same sides of the road at a particular distance. As the vehicle passes
through these IR sensors, the IR sensor will detect the vehicle & will send the information to the
microcontroller. The microcontroller will count the number of vehicles, and pro glowing time to
LED according to the density of vehicles. If the density is higher, LED will glow for higher tim than
average or vice versa. The traffic lights are initially running at a fixed delay of 5 seconds, which in
turn produces a delay of 20 seconds in the entire process. This entire embedded system is placed at
that junction. Microcontroller is interfaced with leds and IR sensors .The total no of IR sensors
required are 4 and Led’s 12 Therefore these are connected to any two ports of Microcontroller.

CHALLENGES AND FUTURE SCOPE OF ADVANCEMENTS

Though the prototype model worked very efficiently with remarkable outputs, the real life
situation is going to be way more challenging and demanding. Few of the challenges that should be
taken into account are listed as follows
 Low range IR sensors may not be an answer for long range signaling system. We may resort to
ultrasound or radar techniques for big scale set-ups.
 Next is the influence of stray signals that may alter the reading of sensor receptors and lead to
conveying false information to the microcontroller.
 Periodic checking of the accuracy and precision is a must for efficacious operation of this
model prototype.

Safety first: it has to be absolutely made sure that no compromise is being made on safety
issues, i.e. a secondary stand-by set-upthat can switch over from automated to manual mode, should
be provided in case of sensor or circuit malfunctions so that vehicular crowd does not go beyond
control.
As part of future advancements, the traffic check post may be connected by wireless
transmitters by which the crossings ahead may be an anticipation of the traffic that is approaching.
This may be achieved the connecting the sensor network with GPS connectivity and short wave
radio transmission signals. This will act as a feedforward system making the signaling system even
more smooth and congestion free.

11
2
CONCLUSION
There is exigent need of efficient traffic management system in our country, as India meets
with 384 road accidents every day. To reduce this congestion and unwanted time delay in traffic an
advanced system is designed here in this project. With field application of this technology, the
maddening chaos of traffic can be effectively channelized by distributing the time slots based on
the merit of the vehicle load in certain lanes of multi junction crossing. We have successfully
implemented the prototype at laboratory scale with remarkable outcome. The next step forward is
to implement this schema is real life scenario for first hand results, before implementing it on the
largest scale. We believe that this may bring a revolutionary change in traffic management system
on its application in actual field environment.

11
3
CHAPTER 2
COMPONENTS USED

11
4
2. COMPONENTS USED

 Arduino UNO board


 ATmega328P IC
 LED (4 Red, 4 Green, 4 Yellow)
 Resistor (10kΩ)
 Battery (9v)
 Crystal oscillator [KDS16.000 (16 MHz)]
 Capacitor 22/AEC(22pf)
 Variable Resistor (10KΩ)
 Voltage Regulator(KA7805)
 IR Transmitter
 IR Reciver

11
5
CHAPTER 3
LITERATURE REVIEW

11
6
3. LITERATURE REVIEW

Introduction
With advancement of technology, new vehicles providing more luxury life are coming
daily into market. Everyone prefers to travel by these luxury vehicles for more comfort instead
of public transportation. The increasing demand of private vehicles leads to problem of more
traffic on roads. Traffic congestion many times costs of someone life. Many solutions are
provided by governments but these solutions are not sufficient. There should be some solution to
provide ways to emergency vehicles. IRIS (Intelligent Roadway Information System) is an open
source Advanced Traffic Management System (ATMS) software project developed by the
Minnesota Department of Transportation[1]. It is used by transportation agencies to monitor and
manage interstate and highway traffic. IRIS uses the GPL license. The researchers at the
AHMCT Research Center at UC Davis used innovative, newly available, free, open-source
ATMS software called IRIS as the basis for creating an enhanced transportation management
system. IRIS was made freely available in 2007 [2]. Caltrans is the first transportation agency to
embrace IRIS and make use of its innovative, collaborative, shared development model known
as open-source. Working with Caltrans and Mn/DOT, the researchers collaboratively developed
enhancements, and extended IRIS to be compatible with the Caltrans District 10 infrastructure
and field devices as well as adapting it to match the district’s specific nuances and operational
aspects. The enhanced IRIS system was integrated with existing Caltrans hardware and software
systems. Enhancements were contributed back to Mn/DOT for use by other public and private
agencies. The researchers modified IRIS to assume the functions of middleware and Automated
Warning System for District 10. Extensive user acceptance and operational testing were
performed, leading to deployment in Caltrans District 10. Pilot testing was performed in
Districts 1, 2, and 5. The Caltrans urban Transportation Management Centers (TMCs) use the
Advanced Traffic Management System (ATMS) software tool, which provides real-time
information on highway conditions to detect traffic incidents, manage the flow of traffic, and
disseminate traveler information [3]. ATMS helps Caltrans reduce commuting times, maximize
roadway capacity, and generally provide safer traveling routes. It also provides operators with
unified access and control to multiple types of roadway devices rather than having to operate
disparate systems. ATMS is composed of several proprietary software solutions that are
expensive to acquire. The recurring maintenance costs have also been increasing. Caltrans rural
districts often cannot afford the initial setup cost, let alone the recurring costs associated with
20
development and operation. In addition, rural districts do not have the same mobility needs as
large metropolitan regions and therefore do not require many of the advanced features and
capabilities that ATMS provides. As a result, Caltrans rural districts have addressed traffic
management by developing disparate solutions with non-uniform management, administration,
and operating protocols.

LITERATURE REVIEW
The Iris/ARTES 10 programme of the European Space Agency (ESA) aims to develop
a satellite system for air traffic services (ATS) and aeronautical operational control (AOC)
complementing the existing and future aeronautical communications infrastructure. This paper
presented the approach to and the results of the Iris communication capacity assessment
conducted in the first phase of the programme [5]. The approach discussed within this paper was
based on a combination of the message exchanges defined in the ldquo communications
operating concept and requirements for the future radio systemrdquo document (COCR) of
EUROCONTROL and FAA and realistic airtraffic scenarios. The generated voice, data and air
traffic was intended for two major purposes: first to identify capacityand protocol requirements
for the design of the Iris communication system and secondly as input for the system
performance evaluation (2008).

TECHNIQUES OF TRAFFIC MANAGEMENT


Recommender In real world there are many traffic management schemes established already.
These schemes are described below:

Simple Traffic Management Scheme: - This is the simplest form of traffic management,
which includes human in the system. In this scheme, a traffic officer is placed on each and every
cross-section of roads; the traffic police controls flow of traffic. As shown in fig. 1, a police
officer stands in middle of road and monitors flow of traffic In time of congestion she/he gives
signals to the vehicle driver whether to drive or stop. She/he is also able to recognize emergency
case, so she/he can choose which lane needs more priority than other. This scheme is most
efficient than any other technique. But as it includes human as a part of system this scheme is
inadequate. Efficiency of system depends on experience and capability of the person.

Automatic Traffic Management Scheme: - In order to remove most weak link (i.e. human) in
above system, an automatic traffic management scheme is suggested. This system includes
simple three color traffic signal, which we see every day. Generally for each lane 120 seconds of
green light is on. Before green light, yellow light flashes for 20 second, signifying to start your
vehicle and be ready to go. For all the time red light is on, ordering each vehicle to stop. This
system cannot identify emergency vehicle, it treats normal car and ambulance same way. So

20
there are chances of delay in emergency services. Drivers disobeying signal rules are also
headache, sometimes they causes serious accidents.

Intelligent Traffic Management Scheme based on Image Processing: - This scheme includes
cameras, which are meant to measure length of traffic in the system. Cameras are mounted on a
high pole so they can cover long distance. Video footage covered by camera is analyzed by a
computer chip in order to detect object (i.e. car, truck, etc.) on road. Different object detection
techniques are being used now days. Cameras are also useful in detection of violation of traffic
laws.

Intelligent Traffic Management Scheme using Wireless Technologies: - In this scheme,


emergency vehicle and traffic signal are equipped with wireless antennas and receiver. As
emergency vehicle come near to an inter-section, it broadcast a signal, to notify traffic signal its
presence. As soon as traffic signal receive signal from emergency vehicle it gives green light to
that particular lane, in which emergency vehicle is coming.

IRIS (Intelligent Roadway Information System): - IRIS is an open source Advanced Traffic
Management System (ATMS) software project developed by the Minnesota Department of
Transportation. It is used by transportation agencies to monitor and manage interstate and
highway traffic. IRIS uses the GPL license. Advanced Traffic Management System (ATMS)
software tool, which provides real-time information on highway conditions to detect traffic
incidents, manage the flow of traffic, and disseminate traveller information. ATMS helps to
reduce commuting times, maximize roadway capacity, and generally provide safer travelling
routes. It also provides operators with unified access and control to multiple types of roadway
devices rather than having to operate disparate systems. ATMS is composed of several
proprietary software solutions that are expensive to acquire.

20
CHAPTER 4
DESIGN AND IMPLEMENTATION

22
0
4. DESIGN AND IMPLEMENTATION

Arduino UNO
The Arduino Uno is a microcontroller board based on the ATmega328 (datasheet). It has 14 digital
input/output pins (of which 6 can be used as PWM outputs), 6 analog inputs, a 16 MHz ceramic
resonator, a USB connection, a power jack, an ICSP header, and a reset button.

Arduino is an open-source platform used for building electronics projects. Arduino consists of both a
physical programmable circuit board (often referred to as a microcontroller) and a piece of software,
or IDE (Integrated Development Environment) that runs on your computer, used to write and upload
computer code to the physical board.

The Arduino platform has become quite popular with people just starting out with electronics, and
for good reason. Unlike most previous programmable circuit boards, the Arduino does not need a
separate piece of hardware (called a programmer) in order to load new code onto the board – you can
simply use a USB cable. Additionally, the Arduino IDE uses a simplified version of C++, making it
easier to learn to program. Finally, Arduino provides a standard form factor that breaks out the
functions of the micro-controller into a more accessible package.

PIN FUNCTIONS

USB to PC: It is used to communicate Arduino via Universal Serial Bus to PC for
programming/sending data to Arduino serially.
7V to 12V DC Input: For external supply, the voltage range of 7V to 12V DC is recommended. The
9V battery can be used to power your Arduino Uno board.
Reset Button: It Resets the Arduino board if pressed.
ICSP: Abbreviated as In Circuit Serial Programming which consists of MOSI, MISO, SCK, RESET,
VCC, and GND. ICSP allows the user to program the microcontroller when SDA: Serial Data, It is
the bidirectional data line that is used by I2C.
SCL: Serial Clock, It is used to indicate that data is ready on bidirectional data line that is used by
I2C.
AREF : Analog Read Reference, It is mainly used for analog Reference() function calls, as default it
is not required but to use it you have to add some voltage source between 0V to 5V in AREF Pin
which will be considered as accurate reference voltage.

22
1
GND: Ground.
SCK: Serial Clock, which is used by SPI (Serial Peripheral Interface). It is clock generated by
‘Master’ which is used to clock the data to the ‘Slave’.
MOSI: Master Out Slave In, The data is transmitted from Master to Slave. (Master -> Slave)
MISO: Master In Slave Out, The data is transmitted to Master from Slave. (Slave -> Master)
SS: Slave Select, It is used to select the ‘Slave’. Make high to SS pin to deactivate & make low to
activate it.
INT1 & INT0: These are hardware interrupts; it calls the ISR (Interrupt Service Routine) when the
pin change occurs.
TX: Transmit; it is used to transmit TTL serial data. It is also referred as ‘outwards’ since it
‘transmits’ data from Arduino to other connected peripheral device.
RX: Receive; it is used to receive TTL serial data. IT is also referred as ‘inwards’ since it ‘receives’
data from external hardware to Arduino.
VIN: Voltage In, If you’re powering your Arduino board from USB nothing is obtained from Vin
pin. But, if you’re powering the board with external supply then that supply is directly obtained from
Vin pin5V Pin: It is used to power external components connected to Arduino which needs 5V.
3.3V Pin: It is used to power external components connected to Arduino which needs 3.3V
IORef: Input Output Voltage Reference, It allows shields connected to Arduino board to check
whether the board is running at 3.3V or 5V.

Fig .4.1 Arduino UNO

22
2
Microcontroller
Microcontroller is a single chip micro computer made through VLSI fabrication. A microcontroller
also called an embedded controller because the microcontroller and its support circuits are often built
into, or embedded in, the devices they control. A microcontroller is available in different word
lengths like microprocessors (4bit,8bit,16bit,32bit,64bit and 128 bit microcontrollers are available
today).

A microcontroller contains one or more of the following components:

 Central processing unit (CPU)


 Random Access Memory (RAM)
 Read Only Memory (ROM)
 Input/output ports
 Timers and Counters
 Interrupt controls
 Analog to digital converters
 Digital analog converters
 Serial interfacing ports
 Oscillatory circuits.

Microcontrollers need to be programmed to be capable of performing anything useful. It then


executes the program loaded in its flash memory – the code comprised of a sequence of zeros and
ones. It is organized in 12-, 14- or 16-bit wide words, depending on the microcontroller’s
architecture. Every word is considered by the CPU as a command being executed during the
operation of the microcontroller.

Fig 4.2: Microcontroller Architecture


22
3
ATmega328P

The ATmega328P is a low-power CMOS 8-bit microcontroller based on the AVR enhanced RISC
architecture. By executing powerful instructions in a single clock cycle, the ATmega328P achieves
throughputs approaching 1 MIPS per MHz allowing the system designed to optimize power
consumption versus processing speed.

It has 28 pins. There are 14 digital I/O pins from which 6 can be used as PWM outputs and 6 analog
input pins. The I/O pins account for 20 of the pins. The 20 pins can act as input to the circuit or as
output. Whether they are input or output is set in the software.

Two of the pins are for the crystal oscillator and are supposed to provide a clock pulse for the
ATmega chip. The clock pulse is needed for synchronization so that communication occurs in
synchrony between the ATmega chip and a device connected to it. Two of the pins, Vcc and GND
are for powering the chip. The microcontroller requires between 1.8-5.5V of power to operate.

The pin-out for the microcontroller is shown below:

Fig 4.3: ATmega 328P

30
The Atmega328 chip has an analog-to-digital converter (ADC) inside of it. This must be or else the
Atmega328 wouldn't be capable of interpreting analog signals. Because there is an ADC, the chip
can interpret analog input, which is why the chip has 6 pins for analog input. The ADC has 3 pins set
aside for it to function- AVCC, AREF, and GND. AVCC is the power supply, positive voltage, that
for the ADC. The ADC needs its own power supply in order to work. GND is the power supply
ground. AREF is the reference voltage that the ADC uses to convert an analog signal to its
corresponding digital value. Analog voltages higher than the reference voltage will be assigned to a
digital value of 1, while analog voltages below the reference voltage will be assigned the digital
value of 0. Since the ADC for the Atmega328 is a 10-bit ADC, meaning it produces a 10-bit digital
value, it converts an analog signal to its digital value, with the AREF value being a reference for
which digital values are high or low. Thus, a portrait of an analog signal is shown by this digital
value; thus, it is its digital correspondent value.

The last pin is the RESET pin. This allows a program to be rerun and start over. The table below
gives a description for each of the pins and their functions.

Table 3.2 Pins and their functions

Pin
Description Function
Number
1 PC6 Reset
2 PD0 Digital Pin (RX)
3 PD1 Digital Pin (TX)
4 PD2 Digital Pin
5 PD3 Digital Pin (PWM)
6 PD4 Digital Pin
7 Vcc Positive Voltage (Power)
8 GND Ground
9 XTAL 1 Crystal Oscillator
10 XTAL 2 Crystal Oscillator
11 PD5 Digital Pin (PWM)
12 PD6 Digital Pin (PWM)
13 PD7 Digital Pin
14 PB0 Digital Pin
15 PB1 Digital Pin (PWM)
16 PB2 Digital Pin (PWM)

31
17 PB3 Digital Pin (PWM)
18 PB4 Digital Pin
19 PB5 Digital Pin
20 AVCC Positive voltage for ADC (power)
21 AREF Reference Voltage
22 GND Ground
23 PC0 Analog Input
24 PC1 Analog Input
25 PC2 Analog Input
26 PC3 Analog Input
27 PC4 Analog Input
28 PC5 Analog Input

IR Sensor

General Description
The IR Sensor-Single is a general purpose proximity sensor. Here we use it for collision
detection. The module consist of a IR emitter and IR receiver pair. The high precision IR receiver
always detects a IR signal. The module consists of 358 comparator IC. The output of sensor is high
whenever it IR frequency and low otherwise. The on-board LED indicator helps user to check status of
the sensor without using any additional hardware. The power consumption of this module is low. It
gives a digital output.
Pin Configuration
The figure to the right is a top view of the IR Sensor module. The following table gives
its pin description.

Application Ideas
• Obstacle detection
• Shaft encoder
• Fixed frequency detection
Overview of Schematic
The sensitivity of the IR Sensor is tuned using the potentiometer. The potentiometer is

32
6
tuneable in both the directions. Initially tune the potentiometer in clockwise direction such that the
Indicator LED starts glowing. Once that is achieved, turn the potentiometer just enough in anti-
clockwise direction to turn off the Indicator LED. At this point the sensitivity of the receiver is
maximum. Thus, its sensing distance is maximum at this point. If the sensing distance (i.e., Sensitivity)
of the receiver is needed to be reduced, then one can tune the potentiometer in the anti-clockwise
direction from this point. Further, if the orientation of both Tx and Rx LED’s is parallel to each other,
such that both are facing outwards, then their sensitivity is maximum. If they are moved away from each
other, such that they are inclined to each other at their soldered end, then their sensitivity reduces. Tuned
sensitivity of the sensors is limited to the surroundings. Once tuned for a particular surrounding, they
will work perfectly until the IR illumination conditions of that region nearly constant. For example, if
the potentiometer is tuned inside room/building for maximum sensitivity and then taken out in open
sunlight, its will require retuning, since sun’s rays also contain Infrared (IR) frequencies, thus acting as a
IR source (transmitter). This will disturb the receiver’s sensing capacity. Hence it needs to be retuned to
work perfectly in the new surroundings. The output of IR receiver goes low when it receives IR signal.
Hence the output pin is normally low because, though the IR LED is continuously transmitting, due to
no obstacle, nothing is reflected back to the IR receiver. The indication LED is off. When an obstacle is
encountered, the output of IR receiver goes low, IR signal is reflected from the obstacle surface. This
drives the output of the comparator low. This output is connected to the cathode of the LED, which then
turns ON.
Pin Out Dimensions

Light Emitting Diode


A Light emitting diode (LED) is essentially a pn junction diode. When carriers are
injected across a forward-biased junction, it emits incoherent light. Most of the commercial LEDs are
realized using a highly doped n and a p Junction. To understand the principle, let’s consider an unbiased
pn+ junction (Figure1 shows the pn+ energy band diagram). The depletion region extends mainly into
the p-side. There is a potential barrier from Ec on the n-side to the Ec on the p-side, called the built-in
32
7
voltage, V0. This potential barrier prevents the excess free electrons on the n+ side from diffusing into
the p side. When a Voltage V is applied across the junction, the built-in potential is reduced from V0 to
V0 – V. This allows the electrons from the n+ side to get injected into the p-side. Since electrons are the
minority carriers in the p-side, this process is called minority carrier injection. But the hole injection
from the p side to n+ side is very less and so the current is primarily due to the flow of electrons into the
p-side.
The recombination can be classified into the following two kinds
• Direct recombination
• Indirect recombination
Direct Recombination: In direct band gap materials, the minimum energy of the conduction band
lies directly above the maximum energy of the valence band in momentum space energy (Figure 2
shows the E-k plot(see Appendix 2) of a direct band gap material). In this material, free electrons at the
bottom of the conduction band can recombine directly with free holes at the top of the valence band, as
the momentum of the two particles is the same. This transition from conduction band to valence band
involves photon emission (takes care of the principle of energy conservation). This is known as direct
recombination. Direct recombination occurs spontaneously. GaAs is an example of a direct band-gap
material.
Indirect Recombination: In the indirect band gap materials, the minimum energy in the
conduction band is shifted by a k-vector relative to the valence band. The k-vector difference represents
a difference in momentum. Due to this difference in momentum, the probability of direct electronhole
recombination is less. In these materials, additional dopants (impurities) are added which form very
shallow donor states. These donor states capture the free electrons locally; provides the necessary
momentum shift for recombination. These donor states serve as the recombination centers. This is called
Indirect (non-radiative) Recombination. Figure3 shows the E-k plot of an indirect band gap material and
an example of how Nitrogen serves as a recombination center in GaAsP. In this case it creates a donor
state, when SiC is doped with Al, it recombination takes place through an acceptor level.
LED Structure: The LED structure plays a crucial role in emitting light from the LED surface.
The LEDs are structured to ensure most of the recombinations takes place on the surface by the
following two ways.
• By increasing the doping concentration of the substrate, so that additional free minority charge
carriers electrons move to the top, recombine and emit light at the surface.
• By increasing the diffusion length L = √ Dτ, where D is the diffusion coefficient and τ is the carrier
life time. But when increased beyond a critical length there is a chance of re-absorption of the
photons into the device.
The LED has to be structured so that the photons generated from the device are emitted without
being reabsorbed. One solution is to make the p layer on the top thin, enough to create a depletion
32
8
layer. Following picture shows the layered structure. There are different ways to structure the dome
for efficient emitting.

Crystal oscillator

Crystal oscillators are electronic oscillator circuits that use inverse piezoelectric effect. With this
effect, when electric field is applied across certain materials they will produce mechanical
deformation. Therefore a crystal uses mechanical resonance of a vibrating crystal of piezoelectric
material so that there is creation of an electric signal with precise frequency. They have high
stability, are low cost and quality factor which makes them superior over such resonators as LC
circuits, ceramic resonators and turning forks.

The crystal action can be represented by an equivalent electrical resonant circuit.

Figure 4.10: circuit diagram of a crystal

The optimal values of the capacitors depend on whether a quartz crystal or ceramic resonator is being
used. It will also depend on application-specific requirements on start-up time and frequency

32
9
tolerance. Crystal oscillators are not built into ICs because they cannot be easily fabricated with IC
processes and the size is physically larger than IC circuits.

The internal oscillators of microcontrollers are RC oscillators. The reason why crystal oscillators are
used is because the quality factor is on the order of 100000 while that of RC oscillators is on the
order of 100. Therefore, the crystal oscillator has lower phase noise and lower variation in output
frequency.

Fig 4.11: crystal oscillator

Voltage Regulator

Voltage regulators are designed to automatically maintain voltages at a constant level. The LM7805
voltage regulator is used. It is a member of the 78xx series of fixed linear voltage regulator ICs.
Voltage sources in circuits could be having fluctuations and thus not be able to give fixed voltage
output. The voltage regulator IC maintains the output voltage at a value that is constant. The
LM7805 provides +5V regulated power supply. Capacitors are connected at the input and output
depending on respective levels of voltage.

Fig 4.12: Voltage Regulator Circuit LM7805


33
0
The pin diagram of the 7805 is shown below:

Fig 4.13: The LM7805 pin diagram

Table 3.3: Pin Description of LM7805

Pin
Function Name
No

1 Input voltage (5V-18V) Input

2 Ground (0V) Ground

3 Regulated output; 5V (4.8V-5.2V) Output

Variable Resistor
Variable resistor: An electronic component that is used to vary the amount of current that flows
through a circuit. It works by sliding a wiper terminal across a resistive material, typically a thin film
or chunk of carbon or a resistive wire made of nickel chromium or tungsten alloys.

Fig 4.14: Variable resistor


33
1
Capacitor

A capacitor is a passive two-terminal electrical component that stores potential energy in an electric
field. The effect of a capacitor is known as capacitance. While some capacitance exists between any
two electrical conductors in proximity in a circuit, a capacitor is a component designed to add
capacitance to a circuit. The capacitor was originally known as a condenser.

The physical form and construction of practical capacitors vary widely and many capacitor types are
in common use. Most capacitors contain at least two electrical conductors often in the form of
metallic plates or surfaces separated by a dielectric medium. A conductor may be a foil, thin film,
sintered bead of metal, or an electrolyte. The non-conducting dielectric acts to increase the
capacitor's charge capacity. Materials commonly used as dielectrics include glass, ceramic, plastic
film, paper, mica, and oxide layers. Capacitors are widely used as parts of electrical circuits in many
common electrical devices. Unlike a resistor, an ideal capacitor does not dissipate energy.

When two conductors experience a potential difference, for example, when a capacitor is attached
across a battery, an electric field develops across the dielectric, causing a net positive charge to
collect on one plate and net negative charge to collect on the other plate. No current actually flows
through the dielectric; however, there is a flow of charge through the source circuit. If the condition
is maintained sufficiently long, the current through the source circuit ceases. However, if a time-
varying voltage is applied across the leads of the capacitor, the source experiences an ongoing
current due to the charging and discharging cycles of the capacitor.

Capacitance is defined as the ratio of the electric charge on each conductor to the potential difference
between them. The unit of capacitance in the International System of Units (SI) is the farad (F),
defined as one coulomb per volt (1 C/V). Capacitance values of typical capacitors for use in general
electronics range from about 1 picofarad (pF) (10−12 F) to about 1 millifarad (mF) (10−3 F).

Fig 4.15: Capacitor


33
2
CHAPTER 5
WORKING PINCIPLE

40
5. WORKING PINCIPLE

The model works on the principle of changing delay of Traffic signals based on the number of
cars passing through an assignedsection of the road. There are four sensors placed at four sides of a
four way road which counts the number of cars passing by the area covered by the sensors.

Here we are using IR sensors replacing system to design an intelligent traffic control system.
IR sensor contains IR transmitter IR receiver (photodiode) in itself. These IR transmitter and IR
receiver will be mounted on same sides of the road at a particular distance. As the vehicle passes
through these IR sensors, the IR sensor will detect the vehicle & will send the information to the
microcontroller. The microcontroller will count the number of vehicles, and pro glowing time to
LED according to the density of vehicles. If the density is higher, LED will glow for higher tim
than average or vice versa. The traffic lights are initially running at a fixed delay of 5 seconds,
which in turn produces a delay of 20 seconds in the entire process. This entire embedded system is
placed at that junction. Microcontroller is interfaced with leds and IR sensors .The total no of IR
sensors required are 4 and Led’s 12 Therefore these are connected to any two ports of
microcontroller.

IR transmitter and receiver pairs, proximity sensor is used. The output voltage according to
distance from an object comparator with a reference set. The reference is set by a variable resistance
according to required range of sensing.

When the sensor finds any object, comparator low else it gives + 5 V (HIGH). The controller
program counts this change of events from LOW to HIGH indicating passing of a vehicle.

The objective of the IR sensor is to detect obstacles. It comprises an emitter (IR LED),
detector (IR photodio and ancillary circuitry. The stronger the reception of IR radiation source,
greater is the output voltage.

We have used Op – Amp LM324 for the comparator operation where Vin is compared against
V ref with no feedback resistance and very high gain. Her connected to +5V and –Vcc the OPAMP
output acts as digital HIGH or LOW for the microcontroller.

41
When Vin is found lesser than V ref output of the comparator produces a LOW signal and
when Vin is greater than V ref (Vin > V Ref), the comparator output produces a HIGH.

Three sets of LEDs viz Green, Yellow and Red are used to indicate the GO state, Ready to
Go state and WAIT state.

The LEDs G (green), Y (yellow) and R (red) glow following sequence


• G1-Y2-R3-R4
• G2-Y3-R4-R1
• G3-Y4-R1-R2
• G4-Y1-R2-R3.
Therefore G1 and Y2 are connected to same ports similarly G2-Y3, G3-Y4, G4-Y1. The Red
LEDs are connected to separate ports and glows according to the logic given in the Program.

42
Advantages

 Avoids wastage of time due to the traffic.


 Fully automatic.
 Low power consumption.
 It provides the easy access in the traffic light.
 Low cost to design the circuit, maintenance of the circuit is good.
 By using this microcontroller IC we can create many more control to the appliances.
 Easy convenience to handle.

43
Applications
 IR receiver module extended with automatic turn off when no vehicles are running on any
side of the road which helps in power consumption saving.

 The system can be replaced by image processing system which will give efficient results .

44
CHAPTER 6
DISCUSSIONS, CONCLUSIONS AND
RECOMMENDATIONS FOR
FURTHER WORK

45
DISCUSSIONS, CONCLUSIONS AND CHALLENGES AND FUTURE SCOPE
OF ADVANCEMENTS

Discussion

In this chapter we have presented an overview of freeway traffic control theory and
practice. In this context we have discussed traffic measurements and estimation, individual traffic
control measures, and the approaches behind them that relate the control signals to the given traffic
situation. The trend of the everincreasing traffic demands and the appearance of new control
technologies have led to the new field of network-oriented traffic control systems. Although there
have been many interesting publications about the theory and practice of integrated traffic control,
several challenges remain, such as the integration of traffic state estimation and dynamic OD
information in the control approaches. The lively research in freeway traffic control shows that this
field is still practically relevant and theoretically challenging. Facing these challenges can be
expected to lead to new freeway traffic control approaches in theory and practice resulting in higher
freeway performance in terms of efficiency, reliability, safety and environmental effects.
Furthermore, in the future the developments in the field of in-car systems and advanced sensor
technologies are expected to enable new traffic management approaches that may measure and
control traffic in more detail and with higher performance.

Conclusion

There is exigent need of efficient traffic management system in our country, as India meets
with 384 road accidents every day. To reduce this congestion and unwanted time delay in traffic an
advanced system is designed here in this project. With field application of this technology, the
maddening chaos of traffic can be effectively channelized by distributing the time slots based on the
merit of the vehicle load in certain lanes of multi junction crossing. We have successfully
implemented the prototype at laboratory scale with remarkable outcome. The next step forward is to
implement this schema is real life scenario for first hand results, before implementing it on the
largest scale. We believe that this may bring a revolutionary change in traffic management system on
its application in actual.

CHALLENGES AND FUTURE SCOPE OF ADVANCEMENTS


46
Though the prototype model worked very efficiently with remarkable outputs, the real life
situation is going to be way more challenging and demanding. Few of the challenges that should be
taken into account are listed as follows:

• Low range IR sensors may not be an answer for long range signaling system. We may resort to
ultrasound or radar techniques for big scale set-ups.
• Next is the influence of stray signals that may alter the reading of sensor receptors and lead to
conveying false information to the microcontroller.
• Periodic checking of the accuracy and precision is a must for efficacious operation of this model
prototype.

Safety first: it has to be absolutely made sure that no compromise is being made on safety
issues, i.e. a secondary stand-by set-upthat can switch over from automated to manual mode, should
be provided in case of sensor or circuit malfunctions so that vehicular crowd does not go beyond
control.
As part of future advancements, the traffic check post may be connected by wireless
transmitters by which the crossings ahead may be an anticipation of the traffic that is approaching.
This may be achieved the connecting the sensor network with GPS connectivity and short wave
radio transmission signals. This will act as a feedforward system making the signaling system even
more smooth and congestion free.

REFERENCES

1. Intelligent Traffic Signal Control System Using Embedded System by Dinesh Rotake and
Prof. Swapnili Karmore, Innovative Systems Design And Engineering, ISSN 2222-1727
(paper) ISSN 2222-2871 (online), Vol. 3, No. 5, 2012.
2. Image Processing Based Intelligent Traffic Controller by Vikramaditya Dangi, Amol Parab,
Kshitij Pawar and S.S Rathod. Undergraduate Academic Research Journal (UARJ), ISSN:
2278 – 1129, Vol-1, 2012.
47
3. Mehta V.K. Principle of Electrical Machines, S. Chand Limited, 2002.
4. Mehta V.K. Principle of Electronics, S. Chand, 2005.

48
APPENDIXES

Appendix One: Code used in the Arduino programming


void setup()
{
pinMode(0,INPUT);
pinMode(1,INPUT);
pinMode(2,INPUT);
pinMode(3,INPUT);

pinMode(4,OUTPUT);
pinMode(5,OUTPUT);
pinMode(6,OUTPUT);
pinMode(7,OUTPUT);
pinMode(8,OUTPUT);
pinMode(9,OUTPUT);
pinMode(10,OUTPUT);
pinMode(11,OUTPUT);
pinMode(12,OUTPUT);
pinMode(13,OUTPUT);
pinMode(A0,OUTPUT);
pinMode(A1,OUTPUT);
}

void loop()
{
digitalRead(0);
digitalRead(1);
digitalRead(2);
digitalRead(3);

49
if(digitalRead(0) == HIGH)
{
digitalWrite(4,HIGH);
digitalWrite(5,HIGH);
digitalWrite(6,LOW);
digitalWrite(7,LOW);
digitalWrite(8,HIGH);
digitalWrite(9,LOW);
digitalWrite(10,HIGH);
digitalWrite(11,HIGH);
digitalWrite(12,LOW);
digitalWrite(13,HIGH);
digitalWrite(A0,HIGH);
digitalWrite(A1,HIGH); //1st Signal
delay(10000);
}

if(digitalRead(1) == HIGH)
{
digitalWrite(4,LOW);
digitalWrite(5,HIGH);
digitalWrite(6,HIGH);
digitalWrite(7,LOW);
digitalWrite(8,HIGH);
digitalWrite(9,HIGH);
digitalWrite(10,LOW);
digitalWrite(11,HIGH);
digitalWrite(12,HIGH);
digitalWrite(13,LOW);
digitalWrite(A0,HIGH);
digitalWrite(A1,HIGH); //2nd Signal
delay(10000);
41
0
}

if(digitalRead(2) == HIGH)
{
digitalWrite(4,LOW);
digitalWrite(5,LOW);
digitalWrite(6,HIGH);
digitalWrite(7,HIGH);
digitalWrite(8,HIGH);
digitalWrite(9,HIGH);
digitalWrite(10,HIGH);
digitalWrite(11,LOW);
digitalWrite(12,HIGH);
digitalWrite(13,HIGH);
digitalWrite(A0,LOW);
digitalWrite(A1,HIGH); //3rd Signal
delay(10000);
}

if (digitalRead(3) == HIGH)
{
digitalWrite(4,HIGH);
digitalWrite(5,LOW);
digitalWrite(6,LOW);
digitalWrite(7,HIGH);
digitalWrite(8,LOW);
digitalWrite(9,HIGH);
digitalWrite(10,HIGH);
digitalWrite(11,HIGH);
digitalWrite(12,HIGH);
digitalWrite(13,HIGH);
digitalWrite(A0,HIGH);
digitalWrite(A1,LOW); //4th Signal
41
1
delay(10000);
}

else
{
digitalWrite(4,HIGH);
digitalWrite(5,HIGH);
digitalWrite(6,LOW);
digitalWrite(7,LOW);
digitalWrite(8,HIGH);
digitalWrite(9,LOW);
digitalWrite(10,HIGH);
digitalWrite(11,HIGH);
digitalWrite(12,LOW);
digitalWrite(13,HIGH);
digitalWrite(A0,HIGH);
digitalWrite(A1,HIGH); //1st Signal
delay(5000);
digitalWrite(4,LOW);
digitalWrite(5,HIGH);
digitalWrite(6,HIGH);
digitalWrite(7,LOW);
digitalWrite(8,HIGH);
digitalWrite(9,HIGH);
digitalWrite(10,LOW);
digitalWrite(11,HIGH);
digitalWrite(12,HIGH);
digitalWrite(13,LOW);
digitalWrite(A0,HIGH);
digitalWrite(A1,HIGH); //2nd Signal
delay(5000);
digitalWrite(4,LOW);
digitalWrite(5,LOW);
41
2
digitalWrite(6,HIGH);
digitalWrite(7,HIGH);
digitalWrite(8,HIGH);
digitalWrite(9,HIGH);
digitalWrite(10,HIGH);
digitalWrite(11,LOW);
digitalWrite(12,HIGH);
digitalWrite(13,HIGH);
digitalWrite(A0,LOW);
digitalWrite(A1,HIGH); //3rd Signal
delay(5000);
digitalWrite(4,HIGH);
digitalWrite(5,LOW);
digitalWrite(6,LOW);
digitalWrite(7,HIGH);
digitalWrite(8,LOW);
digitalWrite(9,HIGH);
digitalWrite(10,HIGH);
digitalWrite(11,HIGH);
digitalWrite(12,HIGH);
digitalWrite(13,HIGH);
digitalWrite(A0,HIGH);
digitalWrite(A1,LOW); //4th Signal
delay(5000);
}
}

41
3
51

Potrebbero piacerti anche