Skip to content
This my attempt to add a display output to the Espressif Mesh Light example
Branch: master
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Type Name Latest commit message Commit time
Failed to load latest commit information.



Mission of this Repository

This is my humble attempt to start coding directly in ESP-IDF as a framework instead of using the Arduino Framework. As a background note, I started designing and 3D-printing my own LED Lamps and at the same time I started a Mesh Light project in KEEP IN MIND: That I'm using a Heltec WiFi32 for this example that has a 26Mhz crystal instead of a 40Mhz so in the menuconfig is configurable like this:

$ make menuconfig:
Components -> ESP32-Specific -> Main XTAL frequency -> 26 Mhz for this boards or 40 Mhz for others (Wemos, etc)

I didn't want to Fork a ESP-MDF and keep only a minimal "Light example" that's why I'm leaving branch master as is and doing my updates in develop branch.


ESP32-MeshKit-Light is a smart lighting solution based on ESP-MESH. It features network configuration, upgrade, local control, device association, etc., and will facilitate your understanding of ESP-MESH to implement further development. Before running this example, please refer to ESP32-MeshKit Guide.

Note: This example is not limited to ESP32-MeshKit-Light, and can also be applied to an ESP32 module connected to an external LED.


ESP32-MeshKit-Light supports 5 types of PWM IO interfaces. Its color temperature (CW) and color hue (RGB) can be adjusted, with an output power of 9 W and 3.5 W respectively.

  1. Inside View and Pin Layout

Inside View

  1. Pin Definition
No. Name Type Description
1, 7 GND P Ground
2 CHIP_PU I Chip enabling (High: On); module internal pull-up; alternative for external enabling
3 GPIO32 I/O RTC 32K_XP (32.768 kHz crystal oscillator input); alternative for function expansion
4 GPIO33 I/O RTC 32K_XN (32.768 kHz crystal oscillator output); alternative for function expansion
5 GPIO0 I/O IC internal pull-up; alternative for function expansion
6 VDD3.3V P Power supply, 3V3
8 GPIO4 O PWM_R output control
9 GPIO16 O PWM_G output control; alternate UART interface (URXD)
10 GPIO5 O PWM_B output control; alternate UART interface (UTXD)
11 GPIO23 O PWM_BR output control
12 GPIO19 O PWM_CT output control
13 GPIO22 I/O Shared by PWM; alternative for function expansion
14 GPIO15 I IC internal pull-up; alternative for function expansion
15 GIPO2 O IC internal pull-down; alternative for function expansion
16 UORXD I/O UART interface (RXD) for debugging and software downloading
17 UOTXD I/O UART interface (TXD) for debugging and software downloading
19 ANT I/O External antenna output
18, 20 GND P RF ground

Light Color Change in Different Statuses

  1. Wait be to networked: flashes yellow

  2. Verify network configuration information: flashes orange

  3. Networked successfully: flashes green

  4. Start to upgrade: flashes light blue for 3 seconds

  5. Upgrade successfully, ready to reboot: flashes blue

  6. Abnormal reboot: flashes red

Note: The device can be reset by powering it off/on for three consecutive times.

You can’t perform that action at this time.