Overview
This project is a dual-channel smart lab power supply powered by the ESP32 microcontroller. It features a TFT display, a rotary encoder with push-button, and provides preset voltage outputs with precise closed-loop feedback control. Voltage adjustment is done mechanically via stepper motors, which are driven by the ESP32 based on live voltage readings — ensuring accurate and reliable output regulation.
Key Features
-
Dual independent output channels
-
Selectable voltage presets: 3V, 5V, 7V, and a customizable value per channel
-
EEPROM-based preset storage
-
OTA (Over-the-Air) firmware updates via Wi-Fi
-
Real-time display of:
-
Voltage (V)
-
Current (A)
-
Power (W)
-
Peak power draw (dynamically updated)
-
Hardware Components
-
ESP32 Dev Board (WROOM-32 or ESP32-S3)
-
TFT Display (ILI9488 or similar, 320x480)
-
Rotary encoder + push button for user input
-
INA219 current sensors (one per channel)
-
Stepper motors + motor drivers (for mechanical voltage adjustment)
-
Potentiometers or analog regulators controlled via motor
-
3D printed enclosure
Closed-Loop Voltage Control
Voltage on each channel is regulated through mechanically adjusted potentiometers, driven by stepper motors. The ESP32 reads the output voltage and adjusts the motor position accordingly — forming a closed-loop feedback system. This approach combines digital precision with the flexibility of analog regulation, while still avoiding the complexity of high-frequency PWM filtering or linear heat dissipation.
Software Features
-
Clean, non-blocking Arduino code
-
Dynamic UI using TFT_eSPI
-
Rotary encoder navigation for preset selection
-
EEPROM saving of custom presets
-
OTA updates over Wi-Fi
-
Continuous tracking of maximum power draw
Voltage Preset System
Each channel provides four selectable presets:
-
3.3V
-
5V
-
7V
-
Custom (user-defined, stored in EEPROM)
Presets can be selected with the encoder. The custom preset is editable and saved permanently.
Displayed Information
The TFT screen shows, per channel:
-
Output voltage
-
Load current
-
Instantaneous power consumption
-
Peak power usage since last boot
All values refresh in real-time, offering an at-a-glance diagnostic view.
Applications
-
Bench power supply for electronics prototyping
-
DIY lab equipment
-
Embedded systems development
-
Smart power management and logging
Planned Features
-
SD card logging
-
USB-C power input
-
Serial terminal control
-
Overcurrent detection & protection
Németh József László
You could replace the potentiometers with digital pots, thus no more motors and a direct link between setup and result, moreover it should be costless. Great anyway.