ES-37MahirPremium

ESP32 Smart Lighting (PIR + LDR + Relay + OLED)

With an ESP32, a PIR motion sensor, an LDR light sensor and a relay module, we turn your hallway, bathroom or pantry into smart lighting. If the room is already bright, the light stays off even when there is motion, so it never wastes energy during the day. The light stays on for 30 seconds, and the time extends automatically while motion continues.

4.3(6)
11 selesai
ESP32 Smart Lighting (PIR + LDR + Relay + OLED)
Walk into the hallway or pantry at night and the light switches on by itself, but it won't waste power during the day. A motion sensor notices you and a light sensor checks whether it is dark; when both agree, the ESP32 turns the lamp on through a relay, and the 30-second timer starts over every time you move. A small OLED screen shows the light's status and the seconds left. Relay note: This board runs on 3.3 V. Use a relay module with an optocoupler that can be triggered by a 3.3 V signal; 5 V modules without an optocoupler may not switch off with a 3.3 V signal.

Kod Sumber

Kandungan Premium

Kod sumber, versi blok dan soalan lazim projek ini terbuka untuk ahli Premium.

  • Semua Kod Projek
  • Versi blok
  • Soalan Lazim