Density Based Traffic Signal System using Microcontroller
Nowadays, controlling the traffic becomes major issue because of rapid increase in automobiles because of large time delays between Traffic Signal 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.
We will utilise infrared sensors to measure traffic density in this system. We must set up one IR sensor for each road; these sensors will always detect traffic on that route. The microcontroller is connected to all of these sensors. The controller detects and regulates the traffic system using these sensors.
- Density Based Traffic Signal System Circuit Principle:
- Density Based Traffic Signal System Circuit Diagram:
- Circuit Components:
- Density Based Traffic Light Control System Circuit Design:
- Density based Traffic Signal System Circuit Simulation Video:
- DOWNLOAD PROJECT CODE
- How to Operate Density based Traffic Signal System Circuit?
- Density based Traffic Signal System Project Output Video:
- Limitations of this Circuit:
Density Based Traffic Signal System Circuit Principle:
The microcontroller is the brains of this traffic system. The microcontroller’s PORT C (PC0, PC1, PC2, and PC3) is connected to IR sensors, while PORT B and PORT D are connected to traffic lights. If there is traffic on the road, the sensor output changes to logic 0; otherwise, it changes to logic 1. We must develop the application to control the traffic system using the IR sensor outputs.
If you receive logic 0 from any of these sensors, we have to give the green signal to that particular path and give red signal to all other paths. Here continuously we have to monitor the IR sensors to check for the traffic.
Density Based Traffic Signal System Circuit Diagram:
- ATmega8 controller
- PCB board
- IR sensors -4
- 12v Battery or adaptor
- Serial cable
- Connecting wires
Density Based Traffic Light Control System Circuit Design:
Four infrared sensors, an ATmega8 microprocessor, and four traffic lights make up this circuit.
The IR transmitter resembles an LED. This IR transmitter produces IR beams at all times. This IR transmitter’s working voltage ranges from 2 to 3 volts. These infrared (IR) rays are undetectable to the naked eye. However, we can see these IR rays with a camera.
The IR receiver receives the IR rays sent out by the IR transmitter. Normally, an IR receiver has a high resistance in the mega ohm range, but when it receives IR photons, the resistance drops dramatically. The IR receiver’s operating voltage is similarly 2 to 3 volts.
We must position these IR pairs in such a way that the IR receiver can receive the IR rays even if an obstacle is placed in front of them. The transmitted IR rays hit the object and reflect back to the IR receiver when we turn on the power.
LEDs can be used in place of traffic signals (RED, GREEN, YELLOW). In a typical traffic system, the LEDs must be lit on a regular basis. If the traffic density on a certain path is high, the green LED on that path will illuminate, while the red LEDs on the remaining paths will glow.
In a conventional traffic system, we allow for a one-minute time delay for each path.
The above figure shows the IR sensor circuit. Here 330 ohm resistor is used to drop the voltage otherwise IR transmitter may get damaged. To vary the obstacle sensing distance, we have used a potentiometer. We have taken the ouput from transistor collector. This sensor gives the digital output.
Density based Traffic Signal System Circuit Simulation Video:
How to Operate Density based Traffic Signal System Circuit?
- Connect 12V battery or adaptor to the development board.
- Switch on the supply.
- Burn the program to the ATmega8 microcontroller by keeping the programming switch sw2 in program mode.
- Connect four IR sensors to PORT C.
- Connect LEDs to PORT B and PORT D.
- Arrange all this LED’s same as like traffic lights.
- Arrange one IR sensor for each road.
- Now you can see the normal traffic system based on time basis.
- Now if you place any obstacle in front of any IR sensor, then the system allows the traffic of that particular path by glowing GREEN light.
- Finally, turn off the board power supply.
Density based Traffic Signal System Project Output Video:
Limitations of this Circuit:
- IR sensors sometimes may absorb normal light also. As a result, traffic system works in improper way.
- IR sensors work only for fewer distances.
- We have to arrange IR sensors in accurate manner otherwise they may not detect the traffic density.