Skip to the content
2 layers65 × 35 mmVFD HMI Module, the printed circuit board in 3D

A Variable Frequency Drive, designed and built for Projekt Mechatronik in SoSe26

Size
65 × 35 mm
Copper layers
2
Thickness
1.6 mm
Parts
21
Nets
39
Pads
106
Tracks, vias
121, 77
Pours
1
Routed
Yes
KiCad
KiCad 10.0 (file 20260206)
Created
20 Jul 2026
Updated
20 Jul 2026

Overview

VFD HMI Module is an open-source printed circuit board by DriveLink-HM, from the DriveLink-HM/DriveLink repository on GitHub, published under the GPL-3.0 licence. It is a 2-layer board of 65 × 35 mm with 21 parts on 39 nets, routed with 121 tracks and 77 vias.

It is built around the ESP32-S3-WROOM-1-N8. Its parts include 8 capacitors, 7 resistors, 3 connectors, 2 switches and 1 IC. It belongs with the lEDs and displays boards and the ESP32 boards of this library.

Main components

1

README

README.md

DriveLink

An open-hardware variable frequency drive (VFD) for three-phase induction motors, developed for the course Projekt Mechatronik at Munich University of Applied Sciences (HM).

DriveLink rectifies single-phase 230 V AC mains into a ≈325 V DC link and drives the motor through an Infineon IM06B50GC1 CIPOS Mini intelligent power module (600 V / 50 A). The power stage is controlled by an STM32G474 whose firmware is generated from a PLECS model, while a detachable ESP32-S3 HMI provides an OLED display, rotary-encoder control, and a WiFi web dashboard. This repository contains everything needed to reproduce the device: KiCad schematics and PCB layouts, firmware, the PLECS model, enclosure CAD files, and documentation.

Fuly assembled DriveLink VFD in its enclosure

⚠️ Safety warning — This device connects directly to mains voltage and its DC link operates at ≈325 V. The DC-link capacitors store a lethal charge even after disconnection. This is a student prototype: it is not certified for mains-connected installations and must only be operated by qualified persons, behind an isolation transformer or RCD, inside a closed enclosure. Reproduce and operate it at your own risk.

Status: working prototype — see Known limitations.

Pitch video

https://github.com/user-attachments/assets/3f33c3a8-9b28-4335-b2a6-baa4afd1d7ac

Full quality Video (Download only)

Features

  • 230 V AC single-phase input: bridge rectifier, NTC inrush limiting, 4× 560 µF DC link
  • Three-phase output for induction motors, open-loop V/f control, 10 kHz sinusoidal PWM
  • Output frequency adjustable from −100 to +100 Hz (sign = direction of rotation)
  • Motor-control firmware generated from the PLECS model (PLECS Coder, STM32G4x target)
  • ESP32-S3 HMI with 128×64 OLED (SH1106), rotary encoder, and two buttons
  • Standalone WiFi access point with a live telemetry dashboard and JSON API
  • Telemetry: DC-link voltage, shunt-based phase currents, module temperature
  • KiCad 10 hardware projects, 3D-printable enclosure with Fusion 360 sources

System architecture

Block schematic of the DriveLink system

Block schematic of the implemented system (editable source: system-block-diagram.svg).

The system consists of two boards:

  • Mainboard (Mainboard/) — the complete power path: mains input with rectifier and NTC, DC link, IM06B50GC1 inverter stage, shunt current measurement, plus the STM32G474RE controller, auxiliary buck/step-down supplies, and fan control. The schematic is split into sheets (rectifier, VFD, STM, Buck_Converter, Step_Down_Converter, cooling).
  • HMI module (HMI/) — an ESP32-S3 board with display, encoder, and buttons that mounts in the enclosure front. It sends the frequency setpoint to the mainboard and receives telemetry over a 3-wire UART link.

The two boards speak a small framed serial protocol, specified in docs/UART_PROTOCOL.md.

Repository layout

PathContent
Mainboard/KiCad 10 project of the power/controller board, BOM (CSV), STEP model, PCB stand STL
HMI/PCB/KiCad 10 project of the HMI board
HMI/Firmware/PlatformIO project for the ESP32-S3 HMI firmware
HMI/pc_testing/PC-side test utilities for dashboard and UART development
plecs/PLECS model VFD_SW.plecs (simulation + STM32 code generation)
plecs/dirty_patch/Build script and reference copies of the UART code embedded in the model
case/Enclosure: Fusion 360 archive, STEP files, front bezel STL, fan impeller
docs/Project report (German), block diagram, datasheets, poster, protocol spec

Toolchain

ToolNeeded forNotes
KiCad 10+Viewing/editing PCBs, Gerber exportProject files are in KiCad 10 format and will not open in older versions
PLECS 5.0+ with PLECS CoderSimulation and STM32 code generationCoder license with the STM32 target family required
PlatformIOBuilding/flashing the HMI firmwareCLI or VS Code extension
Arm GNU Toolchain + GNU MakeCompiling the generated STM32 codearm-none-eabi-gcc and make must be on PATH
PowerShellRunning build.ps1Preinstalled on Windows; pwsh works on Linux/macOS
STM32CubeProgrammer + ST-LINKFlashing the STM32Any SWD-capable probe works
Python 3 (optional)PC test utilitiespip install pyserial requests
Fusion 360 / slicer (optional)Modifying/printing the enclosureSTEP and STL files are included

Building the hardware

DriveLink mainboard front and back Assembled DriveLink mainboard (front and back).

PCBs

  1. Open Mainboard/Projekt_Mechatronik_DC-AC.kicad_pro and HMI/PCB/VFD-HMI-Module.kicad_pro in KiCad 10.

  2. Export Gerber and drill files (File → Fabrication Outputs) and order the boards — the prototypes were manufactured by JLCPCB with default settings.

  3. Source the components: the mainboard BOM is included as Projekt_Mechatronik_DC-AC.csv (semicolon-separated, with datasheet links); export the HMI BOM from KiCad if needed. Key parts:

    FunctionPartManufacturer
    Power module (3-phase inverter)IM06B50GC1 (600 V / 50 A)Infineon
    Motor controllerSTM32G474RETxSTMicroelectronics
    HMI controllerESP32-S3 moduleEspressif
    RectifierGBU5010MCC
    Inrush limiter (NTC)SL32 5R020Ametherm
    DC-link capacitors4× ESMM401VSN561MA40S, 560 µF / 400 VChemi-Con
    Current shunts3× GMR100HJBFHR020, 20 mΩ / 7 WRohm
  4. Assemble and solder the boards (mostly SMD; the power module, connectors, and electrolytics are through-hole).

Enclosure

The case/ folder contains the printable enclosure:

  • housing.f3z / housing.step — the main enclosure (Fusion 360 archive and neutral STEP)
  • HMI_blende.stl — front bezel for display, encoder, and buttons
  • Propeller_groß.f3d / .step — impeller for the cooling fan
  • Mainboard/Ständer.stl — stand for bench operation of the bare PCB

Print the STLs on any FDM printer (no special settings required); use the STEP/F3Z sources to adapt the design.

Building the firmware

The device runs two firmwares: the HMI firmware (hand-written, PlatformIO) and the motor-control firmware (generated from the PLECS model).

HMI firmware (ESP32-S3)

sh
cd HMI/Firmware
pio run -e esp32-s3-devkitc-1                 # build
pio run -e esp32-s3-devkitc-1 -t upload       # flash via USB
pio device monitor -b 115200                  # serial log

platformio.ini defines two environments: esp32-s3-devkitc-1 for the actual HMI hardware and esp32 for bench tests on a generic ESP32 devkit. All library dependencies (U8g2, ESP32Encoder, ESPAsyncWebServer, ArduinoJson) are fetched automatically on first build.

Motor-control firmware (STM32G474)

The PLECS model is the single source of truth for the motor control — the STM32 code is generated, not written by hand:

  1. Open plecs/VFD_SW.plecs in PLECS (the Coder target STM32G4x is preconfigured in the model).

  2. Open Coder → Coder options…, choose an output directory (e.g. plecs/VFD_SW_codegen, which is gitignored), and click Build to generate the sources (VFD_SW_1.c, …) and the makefile VFD_SW.mk.

  3. Copy plecs/dirty_patch/build.ps1 into the output directory and run it:

    powershell
    cd plecs/VFD_SW_codegen
    pwsh ./build.ps1     # or run in Windows PowerShell

    The script activates the embedded UART code (see below) and runs make clean && make, producing an .elf binary.

  4. Connect an ST-LINK to the mainboard's SWD header and flash the .elf with STM32CubeProgrammer.

How the "dirty patch" works

The generated firmware needs UART code (STM32 HAL) to talk to the HMI, but PLECS also compiles the model's C-Script for host-side simulation, where no HAL exists. The UART implementation therefore lives inside the model's C-Script blocks wrapped in comment guards:

c
/*//                      ← guard line: everything below is a comment…
#define UART_ENABLED
... real UART code ...
//*/                      ← …until here

#ifndef UART_ENABLED
void uart_init(void) {}   /* no-op stubs used during simulation */
...
#endif
  • In simulation the guards stay in place: the UART block is one big comment and the no-op stubs compile instead.
  • For the target build build.ps1 deletes the guard lines from the generated VFD_SW_1.c, activating the real implementation before calling make.

The files in plecs/dirty_patch/ (code_declarations.c, start_function_code.c, output_function_code.c) are reference copies of those C-Script sections. To change the UART code, edit it inside the PLECS model and keep the copies in sync.

Operating manual

  1. Assemble both boards into the enclosure, connect the motor phases, and close the case before applying mains power.
  2. Switch on the mains input. The NTC soft-start charges the DC link; the HMI boots into the STOPPED state (no output).
  3. Control the drive from the front panel:
ControlAction
Rotary encoderSelect the frequency setpoint (−100 … +100 Hz; negative values reverse rotation)
Encoder pushApply the selected setpoint to the output
Confirm buttonToggle static/dynamic mode — in dynamic mode the output follows the encoder live, without pressing
Back buttonEnable / disable the output (STOPPED)

The display shows the live output frequency (large, right) and the pending setpoint (left, in static mode) in the top half, and DC-link voltage plus module temperature in the bottom half. When the output is disabled, STOPPED is shown and 0 Hz is commanded.

Web dashboard & API

The HMI opens its own WiFi access point:

  • SSID: DriveLink — Password: DriveLink123
  • Dashboard: http://192.168.4.1 — live telemetry chart and remote frequency control

Web app

The dashboard is backed by a small JSON API that can also be used directly:

sh
# Read telemetry
curl http://192.168.4.1/api/status
# → {"frequency_hz":50.00,"voltage_v":324.10,"temperature_c":42.5,"output_disabled":false}

# Set the frequency setpoint (clamped to −100…+100 Hz)
curl -X PUT http://192.168.4.1/api/status \
     -H "Content-Type: application/json" \
     -d '{"frequency_hz": 42}'

Developing without hardware

HMI/pc_testing/ contains helpers for working on the HMI without a powered mainboard:

  • web_test.py — serves the dashboard locally at http://127.0.0.1:8000 with simulated telemetry, and can forward setpoints to a connected device; useful for dashboard UI work. The browser assets (static.html, chart.js) are the sources for the copies embedded in HMI/Firmware/include/web.h — after editing them, update the raw literals there.
  • uart_test.py — emulates a mainboard on a USB-UART adapter, answering setpoints with a rough induction-motor model. Note that it still speaks an older protocol revision (see docs/UART_PROTOCOL.md).

Known limitations

Honest notes from the project report and code:

  • The current measurement is unreliable — the amplifier signal arriving at the STM32 is too noisy, so phase currents are not displayed.
  • Due to a signal-wiring mix-up in the PLECS model, the temperature is transmitted in the L1-current telemetry slot; the HMI compensates in software (see docs/UART_PROTOCOL.md).
  • Rapid setpoint changes cause visible motor jerk — there is no frequency ramp yet.
  • At continuous 50 Hz operation the module reaches 60–70 °C; a larger fan is planned.
  • The telemetry frame has no checksum and no byte stuffing, so occasional frames are dropped (tolerated by design).

Documentation

Team

Developed as part of Projekt Mechatronik at Munich University of Applied Sciences (HM), supervised by Prof. Dr. Marek Galek and Prof. Dr. Ulrich Unterhinninghofen:

License

This project is licensed under the GNU General Public License v3.0 — see LICENSE.

Parts

21
QtyValueFootprintReferences
30.1uCapacitor_SMD:C_0603_1608MetricC2, C4, C8
3DNPResistor_SMD:R_0603_1608MetricR1, R2, R3
3DNPCapacitor_SMD:C_0603_1608MetricC5, C6, C7
210kResistor_SMD:R_0603_1608MetricR5, R8
24.7kResistor_SMD:R_0603_1608MetricR6, R7
2SW_PushButton_Switch_SMD:SW_Push_1P1T_NO_Vertical_Wuerth_434133025816SW0, SW1
110uCapacitor_SMD:C_0603_1608MetricC1
11uCapacitor_SMD:C_0603_1608MetricC3
1Conn_01x04_PinConnector_PinHeader_2.54mm:PinHeader_1x04_P2.54mm_VerticalJ1
1Conn_01x05_SocketConnector_JST:JST_PH_S5B-PH-K_1x05_P2.00mm_HorizontalJ2
1Conn_01x09_PinConnector_PinHeader_2.54mm:PinHeader_1x09_P2.54mm_VerticalJ3
1ESP32-S3-WROOM-1RF_Module:ESP32-S3-WROOM-1U1

More from DriveLink-HM/DriveLink

1
  • 4 layers200 × 100 mmProjekt Mechatronik DC AC, the printed circuit board in 3D

    Projekt Mechatronik DC AC

    DriveLink-HM/DriveLink

    A Variable Frequency Drive, designed and built for Projekt Mechatronik in SoSe26

    190 parts2GPL-3.0

Similar boards

  • 2 layers85 × 115 mmOSO BOOK B1, the printed circuit board in 3D

    OSO BOOK B1

    joeycastillo/The-Open-Book

    For details on how to build, test and use Open Book, I've made documentation available here.

    76 parts8.1kCC-BY-SA-4.0
  • 2 layers299 × 82.5 mmPixelWave, the printed circuit board in 3D

    PixelWave

    hackclub/OnBoard

    💡 Join 1,000 teenagers and make your first PCB with a $100 grant!

    663 parts915
  • 4 layers56.5 × 99.8 mmBitaxeGamma, the printed circuit board in 3D

    BitaxeGamma

    bitaxeorg/bitaxeGamma

    Bitaxe based on the BM1370 from the S21 Pro

    147 parts432CERN-OHL-S-2.0
  • 2 layers129.5 × 50.8 mmLilka, the printed circuit board in 3D

    Lilka

    lilka-dev/lilka

    Схема та документація ігрової консолі Lilka

    39 parts234GPL-2.0
  • 4 layers84.5 × 129.5 mmBitaxeHex, the printed circuit board in 3D

    BitaxeHex

    bitaxeorg/ultraHex

    multi-ASIC Bitcoin miner

    369 parts190CERN-OHL-S-2.0
  • 2 layers110 × 115 mmEsp32 keyboard v0.1, the printed circuit board in 3D

    Esp32 keyboard v0.1

    hhuysqt/esp32s3-keyboard

    USB/BLE keyboard driver based on ESP32S3-WROOM-1

    230 parts168GPL-3.0
  • 2 layers35.1 × 36.6 mmBinNanoFOC, the printed circuit board in 3D

    BinNanoFOC

    katbinaris/nanofoc_devkit

    Compact All-In-One BLDC Controler featuiring ESP32-S3, TMC6300 and Magalpha sensors. Small 35x35mm footprint.

    76 parts146
  • 2 layers148 × 81 mmCommunicator pcb, the printed circuit board in 3D

    Communicator pcb

    Hack-a-Day/2025-Communicator_Badge

    The 2025 Hackaday Supercon RF Communicator Badge

    58 parts107MIT

Questions

How big is the VFD HMI Module PCB?

It measures 65 × 35 mm and has 2 copper layers, 1.6 mm thick.

What parts does the VFD HMI Module use?

21 parts, built around the ESP32-S3-WROOM-1-N8. 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 VFD HMI Module KiCad files?

From the DriveLink-HM/DriveLink repository on GitHub, at the commit this page was made from: the board is HMI/PCB/VFD-HMI-Module.kicad_pcb and its schematic HMI/PCB/VFD-HMI-Module.kicad_sch. PCBKit opens the board in the browser, with nothing to install.

Can I use the VFD HMI Module design in my own project?

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