Skip to the content
4 layers44 × 48.1 mmDimmer esp v1 main, the printed circuit board in 3D

a rotary dimmer switch

Size
44 × 48.1 mm
Copper layers
4
Thickness
1.6 mm
Parts
59
Nets
52
Pads
231
Tracks, vias
829, 80
Routed
Yes
KiCad
KiCad 10.0 (file 20260206)
Created
21 Nov 2023
Updated
28 Oct 2026

Overview

Dimmer esp v1 main is an open-source printed circuit board by dagroe, from the dagroe/zigbee-rotary-dimmer-switch repository on GitHub, published under the MIT licence. It is a 4-layer board of 44 × 48.1 mm with 59 parts on 52 nets, routed with 829 tracks and 80 vias.

It is built around the ESP32-C6-MINI-1-N4, SN74LV1T125DBVR-TP and IRM-02-5S, with the PEC11S-929K-S0015, SGM2212-3.3XKC3G/TR and 0603B103K500NT among its other parts. Its parts include 20 resistors, 12 capacitors, 6 diodes, 5 ICs and 4 switches. It belongs with the ESP32 and RISC-V boards of this library.

Main components

12

README

README.md

A rotary Zigbee dimmer switch

A Zigbee dimmer switch with a tactile feeling like classic rotary dimmers that seamlessly integrates with your existing switch and socket design lines (e.g. Gira System 55).

Use case, requirements, and features

The goal of this dimmer switch is to

  • provide tactile feeling like classic rotary dimmers, i.e. rotate and push one big knob (instead of multiple buttons)
  • integrate with existing switch and socket design lines (e.g. Gira System 55), also for multi frames
  • offer an optional 230V (or 110V) power supply, no more changing batteries + acts as Zigbee router
  • control existing smart lights (e.g. Philips Hue), not making classic bulbs smart (i.e. switching/dimming classic bulbs)

Also nice to have:

  • be extendable, e.g. easily add multiple dimmer switches or push buttons in multi frames
  • ✅ allow for a second rotary input by rotating the knob while pushing it (e.g. to change color temperature or scenes) — implemented: push + rotate changes color temperature
  • ✅ feature an integrated 230V (or 110V) mechanical switch to switch power of the connected lamp socket (e.g. for emergencies or to reset the lamp when replacing classic wall switches) — implemented: on-board relay + dedicated button
  • be affordable

Backstory: Why yet another Zigbee dimmer switch?

TL;DR; I couldn't find one to fit my use case, so I decided to build my own.

When I moved into my new home I already had many Philips Hue Bulbs and classic Hue dimmer switches (the on with the four buttons) to control the lights. However, those didn't integrate well with my Gira System 55 outlets, switches, frames, etc. even when using fancy adapters (https://www.samotech.co.uk/products/philips-hue-dimmer-frame-cover-light-switch/) And I was also a big fan of using a rotary knob for dimming lights, since it is just more convenient.

So why didn't I use available rotary zigbee dimmers? Basically all dimmers I found are "real" dimmers, in the sense that they expect to control a load (classic dimmable bulb) or simply don't fit into the 55mm Gira system.

Since I though "well, it can't be that hard to hook up a rotary encoder to a Zigbee chip", I set out to build a rotary dimmer switch myself.

Current state of development

A working second prototype is built around the ESP32-C6. It joins any standard Zigbee coordinator (zigbee2mqtt, Home Assistant ZHA, deCONZ, …) as a mains-powered Zigbee router and controls bound smart lights with a single rotary knob. Hardware, firmware, and enclosure design files are all in this repository. It is a DIY prototype, not a finished product — see Help wanted.

Hardware

  • ESP32-C6-MINI module (Zigbee/Thread radio), programmed/powered over USB-C.
  • Integrated 230V → 5V power supply (IRM-02-5S) plus a 3.3V regulator — no batteries, and it acts as a Zigbee router.
  • Rotary encoder with push (the single "big knob") for dimming and on/off.
  • WS2812B RGB LED for status/feedback.
  • On-board 230V relay (on a normally-closed contact) to switch the connected lamp socket directly, with a dedicated button to toggle it.
  • A separate commissioning button for pairing / factory reset.
  • Two external daughterboard ports so the in-wall module can drive a second control surface: a port for an external rotary encoder (a second dimmer) and a port for a plain wall switch. Both are optional — when nothing is wired in they idle and stay unused.
  • Designed to fit Gira System 55 frames.

Controls

InputAction
Rotate knobBrightness up / down (bound lights)
Push knob — short tapToggle on / off
Push knob — holdOff
Push and rotateColor temperature (warm / cool)
Relay button — tapCut / restore the 230V outlet (works even with no network)
External encoder (optional)Second, independently bindable dimmer — same controls as the knob
External wall switch (optional)Toggle on / off for its own independently bound light
Commission button — tapPair (start network steering)
Commission button — hold ~5 sFactory reset (yellow warning while holding, red on reset)

LED feedback: green = joined · solid red = not connected · white blink = command sent · red blink = command dropped (not joined) · blue blink = relay toggled · yellow = pairing / reset warning.

Firmware

Built with ESP-IDF and the esp-zigbee-sdk. From firmware/:

text
idf.py set-target esp32c6
idf.py build
idf.py -p <PORT> flash monitor

After the first flash, firmware updates are delivered over the air (standard Zigbee OTA, with automatic rollback of a bad image). The single source of truth for the version is firmware/main/version.h.

Repository layout

  • hardware/ — KiCad schematics, PCB, and exported gerbers/3D models.
  • firmware/ — ESP-IDF project (firmware/docs/OTA.md, firmware/z2m/README.md, firmware/TODO.md).
  • enclosure/ — printable enclosure / knob design files.

zigbee2mqtt integration & over-the-air updates

The dimmer joins any standard Zigbee coordinator and exposes four endpoints: the on-board controller (endpoint 1) that sends on/off, brightness and color commands to bound lights, the on-board 230V relay (endpoint 2) to switch the connected lamp socket directly, and the two optional daughterboard ports — an external encoder (endpoint 3, a second dimmer) and an external wall switch (endpoint 4). Each controller endpoint is bound independently, so they act as separate controllers sharing one device card. It also implements the standard Zigbee OTA Upgrade cluster, so firmware updates are delivered over the air. To add the device to zigbee2mqtt and receive OTA updates from this repo, follow firmware/z2m/README.md. Firmware-side OTA details (partitioning, rollback) are in firmware/docs/OTA.md.

Help wanted

My prototype is working but I see a lot of potential for improvement. Since I am mostly a software engineer with limited knowledge of electronics, I am looking for other interested in taking this project further. You can find me on discord here: https://discord.gg/CjbDc5nPja or checkout the discussion here: https://community.home-assistant.io/t/diy-zigbee-rotary-wall-dimmer/681751

Parts

59
QtyValueFootprintReferences
1510kResistor_SMD:R_0603_1608MetricR1, R2, R3, R4, R5, R6, R8, R9, R12, R13, R14, R15, R16, R18, R19
40.01uCapacitor_SMD:C_0603_1608MetricC1, C2, C11, C12
30.1uF/50V(10%)Capacitor_SMD:C_0603_1608MetricC3, C5, C9
310uF/25V(20%)Capacitor_SMD:C_Elec_4x5.4C4, C6, C8
3LESD5D5.0CT1GDiode_SMD:D_SOD-523D2, D3, D5
25.1kResistor_SMD:R_0603_1608MetricR10, R11
2MountingHoleMountingHole:MountingHole_2.2mm_M2_DIN965H1, H2
10.1uFCapacitor_SMD:C_0603_1608MetricC10
11N4148WSDiode_SMD:D_SOD-323D1
11N5819HW-7-FDiode_SMD:D_SOD-123D4
11kResistor_SMD:R_0603_1608MetricR7
11uCapacitor_SMD:C_0603_1608MetricC7
13.3kResistor_SMD:R_0603_1608MetricR17
1330Resistor_SMD:R_0603_1608MetricR20
1BC817Package_TO_SOT_SMD:SOT-23Q1
1Commissionbutton_jlc:SW-SMD_L3.9-W3.0-P4.45SW1
1Conn_01x02Connector_JST:JST_SH_SM02B-SRSS-TB_1x02-1MP_P1.00mm_HorizontalJ3
1ESP32-C6-MINIespressif_mcu:WIFIM-SMD_61P-L16.6-W13.2-P0.80-ESP32-C6-MINI-1-N4U4
1FTR-LYCA005Yrelay_mouser:FTRLYCA024YK1
1Fuse 230V 500mA Slowjlc_misc:0443.500DRF1
1GNDTestPoint:TestPoint_Pad_D1.5mmTP4
1GPIO9TestPoint:TestPoint_Pad_D1.5mmTP1
1IRM-02-5SConverter_ACDC:Converter_ACDC_MeanWell_IRM-02-xx_SMDPS1
1LED: WS2812B_5050LED_SMD:LED_WS2812B_PLCC4_5.0x5.0mm_P3.2mmD6
1PEC11S-929K-S0015bourns_encoder:PEC11S929KS0015IC1
1RXTestPoint:TestPoint_Pad_D1.5mmTP3
1Resetbutton_jlc:SW-SMD_L3.9-W3.0-P4.45SW3
1SGM2212-3.3XKC3G/TRldo_jlcpcb:SOT-223-3_L6.5-W3.4-P2.30-LS7.0-BRU1
1SM05B-SRSS-TB_LF__SN_Connector_JST:JST_SH_SM05B-SRSS-TB_1x05-1MP_P1.00mm_HorizontalJ2
1SN74LV1T125DBVRPackage_TO_SOT_SMD:SOT-23-5U3
1Screw_Terminal_01x03TerminalBlock_Phoenix:TerminalBlock_Phoenix_MKDS-1,5-3-5.08_1x03_P5.08mm_HorizontalJ1
1TXTestPoint:TestPoint_Pad_D1.5mmTP2
1Togglebutton_jlc:SW-SMD_L3.9-W3.0-P4.45SW2
1USB TYPE-C 16PLT-H10.0usb_jlc:TYPE-C-SMD_USB4120-03-CU2

More from dagroe/zigbee-rotary-dimmer-switch

1
  • 2 layers42 × 39.5 mmDimmer esp v1 power230, the printed circuit board in 3D

    Dimmer esp v1 power230

    dagroe/zigbee-rotary-dimmer-switch

    a rotary dimmer switch

    4 parts24MIT

Similar boards

  • 2 layers28 × 20 mmMicroduck Audio AMP R3, the printed circuit board in 3D

    Microduck Audio AMP R3

    ldcyes/OpenDuck

    已完成可编辑原理图、真实四层 PCB 和本地库。阶梯板面积 4510 mm²,比原 65×60 + 32×30 mm 两板总面积 4860 mm² 少 350 mm²(7.20%)。原 TDK 模块本体、四个安装孔和原 TDK 器件位置保留,回生电容采用原料号卧装,J1 因实际拔插通道冲突改为同系列 BM08 顶插。当前为工程候选,未制造,未完成热、回生瞬态、低电量或行走验收。

    14 parts
  • 2 layers55 × 35 mmPwr sply, the printed circuit board in 3D

    Pwr sply

    hubertmis/zathome

    Smart home embedded devices based on Zephyr OS

    16 parts5
  • 4 layers150 × 30 mmSingle sh proto, the printed circuit board in 3D

    Single sh proto

    andrewsharmon/rp2350-stepper-controller

    Low-cost 10-axis sine-microstepping controller for small steppers on the RP2350 (PIO + DMA). WIP.

    163 partsMIT
  • 2 layers127.5 × 68.5 mmGhost host, the printed circuit board in 3D

    Ghost host

    VEXU-GHOST/ghost_kicad

    Welcome to UT IEEE RAS VEXU GHOST's repository for our PCB developments! - PCB Images - Onboarding

    182 parts
  • 2 layers83.8 × 71.1 mmDev habit reminder, the printed circuit board in 3D

    Dev habit reminder

    Rikeroo/habit-reminder

    Low energy physical habit reminder, using RGB LEDs, a small task screen and tactile switches to build useful habits and get tasks done

    13 parts
  • 4 layers35 × 35 mmCanonical, the printed circuit board in 3D

    Canonical

    AnasSarkiz/smart-nema14-motor-controller

    STEPPERONLINE 14HM11-0404S controller — unrouted work-in-progress prototype; mechanical and electrical qualification pending

    213 parts

Questions

How big is the Dimmer esp v1 main PCB?

It measures 44 × 48.1 mm and has 4 copper layers, 1.6 mm thick.

What parts does the Dimmer esp v1 main use?

59 parts, built around the ESP32-C6-MINI-1-N4, SN74LV1T125DBVR-TP, IRM-02-5S and PEC11S-929K-S0015. The full list of its parts is on this page, with links to each part's symbol and footprint where PCBKit's library has them.

Where can I download the Dimmer esp v1 main KiCad files?

From the dagroe/zigbee-rotary-dimmer-switch repository on GitHub, at the commit this page was made from: the board is hardware/design_files/main_board/dimmer_esp_v1_main.kicad_pcb and its schematic hardware/design_files/main_board/dimmer_esp_v1_main.kicad_sch. PCBKit opens the board in the browser, with nothing to install.

Can I use the Dimmer esp v1 main design in my own project?

Its repository publishes it under the MIT licence: you may reuse it on that licence's terms (keep the author's notice, and for a copyleft licence share your changes alike).