Skip to the content
PCBKitNew board
2 layers131.1 × 149.9 mmHEDC B001, the printed circuit board in 3D

An ESP32-based alarm clock with a dot matrix LED display, rotary encoder interface, MP3 audio playback, and a web configuration UI.

Size
131.1 × 149.9 mm
Copper layers
2
Thickness
1.6 mm
Parts
70
Nets
105
Pads
398
Tracks, vias
129, 1
Pours
3
Routed
Yes
KiCad
KiCad 8.0 (file 20240108)
Created
26 Mar 2026
Updated
17 Apr 2026

Overview

HEDC B001 is an open-source printed circuit board by Thaddeus-Maximus, from the Thaddeus-Maximus/dotclock repository on GitHub. It is a 2-layer board of 131.1 × 149.9 mm with 70 parts on 105 nets, routed with 129 tracks and 1 via.

It is built around the ESP32-WROOM-32, SN65HVD231DR-JSM and TPS629210DRLR-ET, with the ACS37220LEZATR-100B3, ULN2003ADRG and DRV5033AJQDBZRQ1 among its other parts. Its parts include 18 resistors, 12 switches, 11 capacitors, 9 ICs and 6 connectors. It belongs with the lEDs and displays boards and the ESP32 boards of this library.

Main components

10

README

README.md

dotclock

An ESP32-based alarm clock with a dot matrix LED display, rotary encoder interface, MP3 audio playback, and a web configuration UI.

Features

  • 32x8 dot matrix display (4x FC-16 / MAX7219 modules) with custom 3x6 pixel font
  • Rotary encoder for all on-device interaction (press to cycle modes, turn to adjust)
  • MP3 alarm tones stored on-chip (LittleFS, ~12MB available)
  • Web UI for settings, time sync, WiFi config, and file management
  • 25-step brightness (8 software PWM + 16 hardware levels)
  • Persistent settings via NVS

User Interface

The encoder button cycles through modes. The knob adjusts the value for the current mode. After 15 seconds of inactivity, the display returns to time mode.

ModeIconKnob ActionNotes
Time(none, full-width HH:MM)Dismisses alarm if ringingDefault mode
VolumeSpeaker icon0-16Plays alarm tone as preview while adjusting
BrightnessBulb icon1-24
AlarmBell iconAdjusts alarm time by 1min (fast: 15min)Scroll below 00:00 for OFF; defaults to OFF
Set TimeClock iconAdjusts system clock by 1min (fast: 15min)

When the alarm is ringing, the display flashes inverted at ~1.4Hz. Press button or turn knob to dismiss.

Web Interface

WiFi AP: dotclock / password dotclock1 / IP 192.168.4.1

  • Sync time from phone/browser (with timezone)
  • Set alarm time, enable/disable, select alarm sound
  • Adjust brightness and volume
  • Connect to a WiFi network (AP+STA mode, enables SNTP)
  • Upload, rename, and delete MP3 files

Audio

  • MP3 files, decoded via libhelix-mp3
  • 8-bit DAC output on GPIO25 through a PAM8403 class-D amplifier
  • GPIO25 driven low when idle to minimize speaker static

Project Structure

  • HEDC-F001/ — Firmware (ESP-IDF v5.3.1 project)
  • HEDC-B002/ — Hardware (board schematic, see hardware reference below)

TODO

  • Read encoder (debouncing, velocity detection)
  • Set display (writing, brightness control)
  • Custom 3x6 pixel font with 8x8 mode icons
  • MP3 audio playback
  • Alarm system with looping playback
  • Web interface (settings, file management, time sync)
  • Persistent settings (NVS)
  • WiFi AP + STA with SNTP
  • Fine-tune font glyphs
  • RC filter on DAC output for cleaner audio

HEDC-B002 Hardware Reference

Board Overview

The HEDC-B002 is an ESP32-based controller board with USB-C programming, SPI LED output (5V level-shifted), a rotary encoder with push button, an audio amplifier, and a 32.768kHz RTC crystal. The crystal, however, doesn't work right, it seems.

Power

RailSourceRegulator
+5VUSB-C (J1)Direct from VBUS
+3.3V+5V railU4 AMS1117-3.3 (SOT-223)

ESP32 GPIO Map

Used GPIOs

GPIODirectionNet LabelFunctionNotes
IO0-UART_~BOOTBoot mode selectAuto-reset circuit via Q1. Do not use at runtime.
IO1TXUART_TXDSerial TX to CH340CUSB serial. Directly to J3 header pin alternate.
IO3RXUART_RXDSerial RX from CH340CUSB serial.
IO14InputES1Rotary encoder push switch5.1kΩ pull-up to 3.3V. Active LOW.
IO17OutputCSSPI chip select3.3V → 5V via U1 74HCT244 → J3 pin 4 (CS_5V)
IO18OutputCLKSPI clock3.3V → 5V via U1 74HCT244 → J3 pin 5 (CLK_5V)
IO23OutputDINSPI data out3.3V → 5V via U1 74HCT244 → J3 pin 3 (DIN_5V)
IO25OutputINLAudio output to amplifierAC-coupled into PAM8403 left channel input
IO26InputEA1Rotary encoder channel A5.1kΩ pull-up to 3.3V
IO27InputEB1Rotary encoder channel B5.1kΩ pull-up to 3.3V
IO32-CRYSTAL_132.768kHz crystal (XIN)Y1 CM315D32768DZFT, 22pF load caps (C7, C8)
IO33-CRYSTAL_232.768kHz crystal (XOUT)Y1 CM315D32768DZFT, 22pF load caps (C7, C8)
EN-UART_ENChip enableAuto-reset circuit via Q1 + RC timing cap

Unused GPIOs

GPIOPin #Notes
IO224Explicitly no-connect on schematic
IO426Available
IO529Available (outputs PWM at boot)
IO1214Available (boot fail if pulled high)
IO1316Available
IO1523Available (outputs PWM at boot)
IO1627Available
IO1931Available
IO2133Available
IO2236Available
IO346Available (input only, no pull-up/down)
IO357Available (input only, no pull-up/down)
SENSOR_VP (IO36)4Available (input only)
SENSOR_VN (IO39)5Available (input only)

Components

U3 — CH340C (USB-to-Serial)

SOIC-16 USB-UART bridge. Internal oscillator (no external crystal). Connected to USB-C connector J1.

CH340C PinNetConnects To
TXDUART_TXDESP32 IO1 (RXD0)
RXDUART_RXDESP32 IO3 (TXD0)
~DTRDTRQ1 auto-reset circuit
~RTSRTSQ1 auto-reset circuit
UD+/UD-USB D+/D-J1 USB-C connector
V3-100nF decoupling cap (C6) to GND

Q1 — MMDT3904-7-F (Auto-Reset)

Dual NPN transistor (SOT-363) implementing the standard ESP32 auto-programming circuit. Cross-coupled: RTS drives IO0 (BOOT), DTR drives EN, so a DTR/RTS sequence enters the bootloader automatically.

U1 — 74HCT244 (Level Shifter)

TSSOP-20 octal buffer. Powered from +5V. Converts 3.3V ESP32 SPI signals to 5V for J3 output. Bank 1 active (OE tied to GND), bank 2 active but unused.

Input (3.3V)Output (5V)Signal
1A0 ← CS (IO17)1Y0 → CS_5VChip select
1A1 ← CLK (IO18)1Y1 → CLK_5VClock
1A2 ← DIN (IO23)1Y2 → DIN_5VData

J3 — 5-Pin LED Output Connector (FC-16 footprint)

PinSignal
1+5V
2GND
3DIN_5V
4CS_5V
5CLK_5V

This is the SPI output for driving an LED matrix or display panel.

SW1 — PEC09-2320F-S0015 (Rotary Encoder)

Bourns horizontal-mount rotary encoder with push button. All signals pulled up to 3.3V with 5.1kΩ resistors.

FunctionNetGPIOActive State
Encoder AEA1IO26LOW pulses
Encoder BEB1IO27LOW pulses
Push switchES1IO14LOW when pressed

U2 — PAM8403DR (Audio Amplifier)

SOP-16 class-D stereo amplifier, powered from +5V. Left channel input (INL) driven from ESP32 IO25 through a coupling capacitor. Speaker output on SPK1 header (marked DNP — do not populate).

ConnectionDetail
InputIO25 → coupling cap → INL (pin 7)
OutputLOUT+/LOUT- → SPK1 (2-pin header)
Power+5V / GND

Y1 — CM315D32768DZFT (RTC Crystal)

32.768kHz crystal connected to IO32/IO33 with 22pF load capacitors (C7, C8). Provides a precise timebase for RTC functionality.

J1 — USB-C Connector (UJ20-C-V-C-1-SMT-TR)

USB 2.0 Type-C receptacle (14-pin). CC1/CC2 have 5.1kΩ pull-downs (R6, R7) for device identification.

Code Quick-Reference

cpp
// --- Pin Definitions ---

// SPI LED output (directly usable with hardware SPI: VSPI)
#define PIN_LED_CS    17  // SPI chip select
#define PIN_LED_CLK   18  // SPI clock (VSPI CLK)
#define PIN_LED_DIN   23  // SPI MOSI (VSPI MOSI)

// Rotary encoder (active LOW, external 5.1k pull-ups)
#define PIN_ENC_A     26  // Encoder channel A
#define PIN_ENC_B     27  // Encoder channel B
#define PIN_ENC_SW    14  // Encoder push switch

// Audio output (PWM/DAC → PAM8403 amplifier)
#define PIN_AUDIO     25  // DAC1 output (IO25 is DAC channel 1)

// UART (directly to CH340C — used by USB serial, avoid reassigning)
// #define PIN_TXD0    1
// #define PIN_RXD0    3

// RTC crystal (do not use as GPIO)
// IO32 — XTAL 32.768kHz XIN
// IO33 — XTAL 32.768kHz XOUT

Notes for Firmware

  • SPI: IO17/IO18/IO23 map to the default VSPI bus (CLK=18, MOSI=23). IO17 is used as CS but is not the default VSPI CS0 (IO5), so configure it manually.
  • Audio: IO25 is one of the ESP32's two DAC outputs (DAC1). You can use dacWrite(25, value) for simple waveforms, or configure I2S for higher quality audio output to the PAM8403.
  • Rotary encoder: Use interrupt-driven decoding on IO26/IO27. The push button on IO14 should be debounced in software.
  • RTC crystal: IO32/IO33 are dedicated to the 32.768kHz crystal. Use the ESP32's internal RTC with this external crystal for accurate timekeeping. Configure via rtc_clk_32k_enable() or the ESP-IDF RTC API.
  • Boot strapping: IO0 is used for boot mode (auto-reset handles this). IO2 is NC. IO12/IO15 affect boot — if using them, ensure they're not pulled to unexpected states at power-on.

Parts

70
QtyValueFootprintReferences
12A161CS12VDC.64footprints:RELAY_A161CS12VDC.64K1, K2, K3, K4, K5, K6, K7, K8, K9, K10, K11, K12
104.7kResistor_SMD:R_0805_2012MetricR1, R2, R3, R7, R8, R9, R11, R15, R26, R27
5, , , ,
5100nFCapacitor_SMD:C_0603_1608MetricC1, C6, C7, C9, C13
54.7uFCapacitor_SMD:C_0805_2012MetricC2, C3, C5, C10, C12
3100Resistor_SMD:R_0805_2012MetricR10, R13, R14
3Conn_01x12footprints:AT04-12PX-BMXXJ1, J2, J3
3LEDLED_THT:LED_D5.0mmD6, D7, D8
242.2kResistor_SMD:R_0805_2012MetricR6, R17
2CIGT201610LH2R2MNEfootprints:RES_CIGT201610_SAML1, L2
2Conn_01x04footprints:AT04-4P-BMxxJ5, J6
2S93520footprints:S93520J_BAT-1, J_BAT+1
2TPS629210DRLRfootprints:SOTFL50P160X60-8NU2, U6
2ULN2003ADRfootprints:SOIC127P600X175-16NU4, U5
1150kResistor_SMD:R_0805_2012MetricR5
11MResistor_SMD:R_0805_2012MetricR4
1680uFCapacitor_SMD:CP_Elec_10x12.5C4
180.6kResistor_SMD:R_0805_2012MetricR18
1ACS37220LEZATR-100B3footprints:ACS37220LEZATR200B5U9
1B340A-13-FDiode_SMD:D_SMAD4
1Conn_01x06footprints:AT04-6P-BMXXJ7
1DRV5033AJQDBZRfootprints:DBZ0003A-MFGU1
1ESP32-WROOM-32RF_Module:ESP32-WROOM-32U3
1SN65HVD231DRfootprints:SOIC127P600X175-8NU10
1TCA9535PWRPackage_SO:TSSOP-24_4.4x7.8mm_P0.65mmU11

The 69 most common of 70 parts.

Questions

How big is the HEDC B001 PCB?

It measures 131.1 × 149.9 mm and has 2 copper layers, 1.6 mm thick.

What parts does the HEDC B001 use?

70 parts, built around the ESP32-WROOM-32, SN65HVD231DR-JSM, TPS629210DRLR-ET and ACS37220LEZATR-100B3. 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 HEDC B001 KiCad files?

From the Thaddeus-Maximus/dotclock repository on GitHub, at the commit this page was made from: the board is HEDC-B001/HEDC-B001.kicad_pcb and its schematic HEDC-B001/HEDC-B001.kicad_sch. PCBKit opens the board in the browser, with nothing to install.

Can I use the HEDC B001 design in my own project?

Its repository states no licence, so its author keeps all rights: ask Thaddeus-Maximus before reusing the design.

More from Thaddeus-Maximus/dotclock

1
  • 2 layers64.1 × 31.8 mmHEDC B002, the printed circuit board in 3D

    HEDC B002

    Thaddeus-Maximus/dotclock

    An ESP32-based alarm clock with a dot matrix LED display, rotary encoder interface, MP3 audio playback, and a web configuration UI.

    34 parts

Similar boards

  • 2 layers46 × 51.3 mmIMD & AMS Latches V1.0, the printed circuit board in 3D

    IMD & AMS Latches V1.0

    Lafayette-Motorsports/LVBoards

    LV Board repository for Motorsports created 09.02.2025

    23 parts1
  • 4 layers70 × 60 mmCAN Logger V2.0, the printed circuit board in 3D

    CAN Logger V2.0

    deep-th/CAN_Logger

    This is a compact and reliable CAN logger board built for automotive and industrial applications. It features the ESP32-S3 microcontroller and MCP25625 CAN controller with integrated transceiver, supporting two…

    138 parts3
  • 4 layers54.6 × 99.3 mmSH wg, the printed circuit board in 3D

    SH wg

    hatlabs/SH-wg-hardware

    Sailor Hat WiFi Gateway hardware design files

    85 parts3
  • 4 layers35 × 21.7 mmController, the printed circuit board in 3D

    Controller

    c4deszes/bike-front-light

    64 parts
  • 2 layers37 × 32.5 mmRotor sensor, the printed circuit board in 3D

    Rotor sensor

    c4deszes/bike-rotor-sensor

    Speed sensor for bicycle

    50 parts
  • 4 layers50.5 × 113 mmSub Board, the printed circuit board in 3D

    Sub Board

    DennisSchulmeister/ModularMusicController

    Open Modular Music Controller – Build your own custom hardware controller

    200 partsGPL-3.0