๐ ๏ธ MAKER GUIDEJul 07, 2026โขโฑ๏ธ 3 min readโข๐ณ๐ต Tested in Nepal
Density-Based Smart Traffic Light System with Emergency Vehicle Priority
Reduce traffic congestion in Kathmandu intersections with adaptive ultrasonic vehicle queue sensing, LED traffic modules, and RFID ambulance clearance from Ghumti Pasal.
๐ ๏ธ BILL OF MATERIALS (BOM)
Required Hardware & Component Checklist
Curated components verified for this project. Check the items you need, adjust quantities, and add straight to cart:
Estimated Total (5/5 items):
NPRย 2,840
โ Cash on Delivery across Nepal
All parts selected
NPRย 1,300
NPRย 100
NPRย 1,200
NPRย 40
NPRย 200
Density-Based Smart Traffic Light System with Emergency Vehicle Priority
Educational Notes
This project is designed to be accessible to students from Class 4 to Masters level, with complexity scalable to match different age groups and skill levels.
Learning Objectives:
- Understand basic electronics and circuitry principles
- Learn sensor applications and data collection techniques
- Develop problem-solving skills through hands-on building and troubleshooting
- Apply programming concepts to control hardware and process data
- Connect projects to real-world Nepalese contexts and challenges
Adaptability:
- For younger students (Class 4-8): Focus on assembling pre-built circuits, observing results, and understanding basic concepts
- For intermediate students (Class 9-12): Modify code, experiment with parameters, and explore underlying principles
- For advanced students (Undergraduate/Masters): Optimize designs, add features, conduct research extensions, and analyze performance
Safety Note: Always supervise younger students when working with electricity, heat, or moving parts.
Create a smart intersection model that dynamically allocates green light timing and grants override to ambulances via RC522 RFID.
Hardware Bill of Materials:
- Microcontroller: UNO R3 ATMEGA328P-PU Development Board with 30cm cable
- Indicators: LED 5mm Red, Green, Yellow Pack
- RFID Reader: HS-S62-L RC522 NFC RFID Reader Writer Module 13.56MHz
- Alarm & Power: Active Buzzer + 9v 1A Power Supply Adapter
Circuit Pinout & Wiring Connections:
| Component / Sensor Pin | Arduino Uno Pin | Function / Description |
|---|---|---|
| Traffic Lane Red / Yellow / Green | Pin D2, D3, D4 | Standard Traffic Signal Control |
| Priority Lane Red / Yellow / Green | Pin D5, D6, D7 | Intersecting Traffic Signal Control |
| RC522 SDA / SCK / MOSI / MISO | Pin D10, D13, D11, D12 | SPI RFID Ambulance Receiver |
| RC522 3.3V / GND | 3.3V / GND | Reader Power |
| Active Buzzer (+) | Pin D8 | Emergency Ambulance Clearance Chime |
Firmware Source Code (Arduino Mega 2560 C++)
#include <Wire.h>
#include <EEPROM.h>
#include <SPI.h>
#include <MFRC522.h>
#define SS_PIN 5
#define RST_PIN 22
MFRC522 rfid(SS_PIN, RST_PIN);
const char* ssid = "GhumtiPasal_WiFi";
const char* pass = "NepalMakers2026";
void setup() {
Serial.begin(9600);
SPI.begin();
rfid.PCD_Init();
Serial.println("RFID Contactless Reader Ready. Tap Card...");
}
void loop() {
if (!rfid.PICC_IsNewCardPresent() || !rfid.PICC_ReadCardSerial()) {
delay(50);
return;
}
String cardUID = "";
for (byte i = 0; i < rfid.uid.size; i++) {
cardUID += String(rfid.uid.uidByte[i] < 0x10 ? "0" : "");
cardUID += String(rfid.uid.uidByte[i], HEX);
}
cardUID.toUpperCase();
Serial.println("Scanned Card UID: " + cardUID);
Serial.println("Access Granted! Syncing record with database...");
rfid.PICC_HaltA();
rfid.PCD_StopCrypto1();
delay(2000);
}
โ Previous Guide
Hand Gesture Motion Controlled Robot Arm using Accelerometer & NRF24L01
Next Guide โ
Smart Keyless Door Access Control System with RC522 RFID & 12V Solenoid
