Smart street light with motion dimming and fault report
Street lights burn at full power all night on empty roads, and failed lamps go unreported for weeks. Lights that dim when no one is near, brighten for traffic and report faults cut energy and repair delays.
- Parts
- ₹3,560
- Build
- 13 weeks
- Board
- ESP32
- Objectives
- 6
Block diagram
- LDRSwitches on at dusk
- Radar motion sensorSees people and vehicles
- Current sensorChecks the lamp actually draws power
- ESP32Sets brightness and reports
- Solar power unitPanel, charger and cell that keep the node running+
- MOSFET LED driverDims the LED with PWM
- 3 W LEDThe lamp
- LoRa linkCarries readings from field nodes to the gateway+
Objectives
- To switch lights on at dusk and off at dawn with hysteresis.
- To run at 30% when the road is empty and 100% for 30 s after motion.
- To detect a failed lamp from its current and report its pole number.
- To measure energy used in a night against always-full brightness.
- To power the system from a solar-charged battery and measure its energy budget.
- To build a multi-node LoRa network and measure its range and packet delivery.
Parts and specifications
- ESP32 DevKit V1Dual-core 240 MHz, 520 KB SRAM, Wi-Fi + Bluetooth, 3.3 V logic, 12-bit ADC (use ADC1 pins when Wi-Fi is on)₹450Buy
- LDR with 10 kΩ resistorAbout 1 MΩ dark to 1 kΩ bright, response 20 to 30 ms, use in a voltage divider₹10Buy
- RCWL-0516 radar motion sensor3.2 GHz Doppler, 5 to 7 m, sees through plastic, 2 s hold, 3.3 V output₹120Buy
- IRLZ44N logic-level MOSFET55 V 47 A, fully on at VGS 4.5 V (RDS(on) about 25 mΩ), good from 5 V pins₹40Buy
- × 33.3 Ω 3 W resistors (one per LED)₹30
- LM2596 buck converter4 to 40 V in, 1.25 to 37 V out, up to 2 A continuous (3 A peak), about 85% efficient₹90Buy
- Pole models and heatsinks₹300
- TP4056 charger with protection1 A CC/CV Li-ion charging to 4.2 V, DW01 protection cuts at about 2.5 V₹40Buy
- MT3608 boost converter (3.7 V to 5 V)2 to 24 V in, up to 28 V out, 2 A switch, for 3.7 V to 5 V₹50Buy
- SX1278 Ra-02 LoRa module 433 MHzUp to +20 dBm, sensitivity −148 dBm, 1 to 5 km line of sight, SPI, 3.3 V₹900Buy
- × 2433 MHz spring antenna₹60
- ESP32 DevKit V1 (second node)Dual-core 240 MHz, 520 KB SRAM, Wi-Fi + Bluetooth, 3.3 V logic, 12-bit ADC (use ADC1 pins when Wi-Fi is on)₹450Buy
Total about ₹3,560 at typical online prices. Tap a part for its pinout and datasheet notes.
Design calculations
R = (12 − 3 × 3.2) / 0.7 ≈ 3.4 Ω for three in series; or one LED per 3.3 Ω branch from a lower supply. Power in R = 0.7² × 3.4 = 1.7 W, so use 3 W resistors.
100% = 9 W, 30% ≈ 2.7 W. If motion keeps the lamp bright 20% of a 12-hour night: 9 × 2.4 + 2.7 × 9.6 = 47.5 Wh vs 108 Wh, a 56% saving.
Expected current at a duty d is about 0.7 A × d. Under 30% of expected = lamp failed; over 130% = short.
Pin map
| Signal | Pin or connection |
|---|---|
| LDR divider | GPIO 34 |
| RCWL-0516 OUT | GPIO 27 |
| MOSFET gate (via 100 Ω, 10 kΩ pull-down) | GPIO 25 (PWM 1 kHz) |
| INA219 in the LED line | I²C 21 / 22 |
| LED string | 12 V → 3 W LEDs each with 3.3 Ω, low-side MOSFET |
Firmware outline
- Read the LDR every 5 s; on below the dusk level for 1 minute, switch to night mode (hysteresis to dawn level).
- Night mode: 30% PWM; on motion go to 100% and hold 30 s, then fade down over 3 s.
- Every minute compare measured current with expected; report a fault with the pole ID.
- Over LoRa or Wi-Fi, send hourly energy and status.
Test plan
| Test | Expected result |
|---|---|
| Covering the LDR | Turns on after 1 minute, no flicker at the threshold |
| Walk past | Full brightness within 0.5 s |
| One LED disconnected | Fault reported |
| One night | Energy measured vs full brightness |
These rows start your results table when you plan the project.
Viva practice
Say your answer out loud first, then check. The first 2 answers are free; Maker opens all 5.
Make it yours
One or two upgrades for a mini project, two to four for a major one.
Build these first
Datasheets and sources to cite
- IS 1944 (code for lighting of public thoroughfares)
- EESL Street Lighting National Programme
- TI INA219 datasheet
About this project
How much does the smart street light with motion dimming and fault report project cost?
About ₹1,540 for the parts in the base list: ESP32 DevKit V1, LDR with 10 kΩ resistor, RCWL-0516 radar motion sensor, INA219 current and power sensor, IRLZ44N logic-level MOSFET, 3 W LED on star heatsink × 3, 3.3 Ω 3 W resistors (one per LED) × 3, 12 V 2 A DC adapter, LM2596 buck converter, Pole models and heatsinks.
How long does it take?
About 8 weeks for the base project, built on an ESP32. Each upgrade adds time.
Which branches is it suitable for?
Electrical and Electronics, Electronics and Communication, Diploma (any electronics branch), as a mini or major project.
Which pins and design calculations does it use?
LDR divider on GPIO 34; RCWL-0516 OUT on GPIO 27; MOSFET gate (via 100 Ω, 10 kΩ pull-down) on GPIO 25 (PWM 1 kHz). Worked calculations on this page: led resistor, dimming energy, fault detection.
How do I test it?
Covering the LDR: Turns on after 1 minute, no flicker at the threshold. Walk past: Full brightness within 0.5 s. One LED disconnected: Fault reported. One night: Energy measured vs full brightness.
What are the objectives?
To switch lights on at dusk and off at dawn with hysteresis. To run at 30% when the road is empty and 100% for 30 s after motion. To detect a failed lamp from its current and report its pole number. To measure energy used in a night against always-full brightness.
