Skip to content

Instantly share code, notes, and snippets.

View mjleonides's full-sized avatar

Mike Leonides mjleonides

View GitHub Profile
@mjleonides
mjleonides / esphome_esp32_onboard_led.md
Created January 24, 2026 13:52
How to control the onboard LED on ES32-WROOM-32 using ESPHome

February 5, 2025

I have a few ESP32-WROOM-32s placed conveniently in my home serving as a Bluetooth proxy or presence detector for Home Assistant. Due to their locations, I thought it would be really useful if I could add indicator lights to the boards to notify of different things: home alarm status, garage door left open, etc.

I had noticed that they have a red onboard LED that indicated power to the board, but upon closer inspection there is a second LED that seems totally unused. It took me a surprisingly long time to figure out what that second LED was and how to control it, but I eventually came across this post on Starting Electronics indicating that the second LED was connected to GPIO2.

Using ESPHome, I added this configuration and flashed the board:

output:
  - platform: gpio