An open-source, all-in-one electronics laboratory instrument running on a single Original ESP32 (ESP32-D0WD-V3), providing a browser-based, zero-install interface over Wi-Fi.
| Instrument | Underlying Hardware | Status | Tested & Recommended Limits | Theoretical Limits |
|---|---|---|---|---|
| Frequency Counter | PCNT0 + Hardware Timer | Validated |
Tested: Recommended: |
Up to |
| Signal Generator | LEDC High-Speed PWM | Validated |
Tested: Recommended: |
Up to |
| Logic Analyzer (4-CH) | I2S0 DMA Parallel Capture | Validated |
Tested: 2 MS/s maximum validated capture rate under documented test setup |
Up to |
| Logic Analyzer (8-CH) | I2S0 DMA Parallel Capture | Implemented / Experimental | Implemented in driver; 8-channel physical capture not fully validated | 8 parallel channels |
| UART Protocol Decoder | Browser JavaScript | Validated |
Tested: |
Up to |
| IΒ²C Protocol Decoder | Browser JavaScript | Validated |
Tested: Standard Mode ( |
Fast Mode ( |
| SPI Protocol Decoder | Browser JavaScript | Validated |
Tested: Modes 0, 1, 2, 3 (CPOL 0/1, CPHA 0/1), |
Synchronous edge decode |
| Digital Multimeter (0β3.3V / 0β5V) | ADC1 (GPIO 34) + 128x Oversample | Implemented / Experimental |
Tested: Absolute External Accuracy: NOT VERIFIED (Pending independent external voltage standard) |
|
| DMM High-Voltage (12V / 24V) | Dedicated Divider Network | Planned / Deferred | Requires external high-voltage front-end |
|
| Current Measurement | Shunt Resistor + Op-Amp | Planned | Out of scope for current hardware baseline | Low-side shunt |
| Oscilloscope | ADC1 DMA + Timer | Planned | Dual-channel analog waveform capture, time/div, volt/div, trigger | Single/Dual channel |
| Spectrum Analyzer (FFT) | Dual-Core DSP Engine | Planned | Audio/PWM/ripple magnitude spectrum | Real-time FFT |
| Pin | Function / Instrument | Direction | Electrical Characteristics & Validation Status |
|---|---|---|---|
| GPIO 18 | Frequency Counter Input (PCNT) / LA CH0 | Input |
|
| GPIO 19 | Signal Generator Output (LEDC) / UART TX | Output | Push-pull square wave test reference output (Validated) |
| GPIO 12 | Logic Analyzer CH1 | Input |
|
| GPIO 13 | Logic Analyzer CH2 | Input |
|
| GPIO 14 | Logic Analyzer CH3 | Input |
|
| GPIO 25 | Logic Analyzer CH4 | Input |
|
| GPIO 26 | Logic Analyzer CH5 | Input |
|
| GPIO 27 | Logic Analyzer CH6 | Input |
|
| GPIO 32 | Logic Analyzer CH7 | Input |
|
| GPIO 34 | Analog DMM Input (ADC1_CH6) | Input | Input-only analog pin, |
- PlatformIO Core or VSCode with PlatformIO IDE
- Original ESP32 development board (e.g. ESP32-WROOM-32 / ESP32-D0WD-V3)
# Clone the repository
git clone https://github.com/Ishu1519/ESP32-Digital-Lab.git
cd ESP32-Digital-Lab
# Build and flash via PlatformIO
pio run -t upload --upload-port COM7- Connect your PC or mobile device to the ESP32 Wi-Fi Access Point:
- SSID:
ESP32-Digital-Lab - Password: Configured in
include/system_config.h(default:digitallab123; change this default before deployment)
- SSID:
- Open your web browser and navigate to:
http://192.168.4.1orhttp://esp32.local
- Loopback Quick Test: Connect a jumper wire between GPIO 19 (Generator Output) and GPIO 18 (Counter Input / Logic Analyzer CH0) to verify loopback frequency counting and digital waveform capture.
+-------------------------------------------------------------------------+
| Browser UI |
| Single-Page Vanilla HTML5 / CSS3 / Canvas (Zero External Dependencies)|
+-------------------------------------------------------------------------+
β²
β WebSockets (JSON Control & Telemetry)
βΌ
+-------------------------------------------------------------------------+
| ESP32 Firmware Core |
| |
| +--------------------+ +---------------------+ +----------------+ |
| | Instrument Manager |<->| Web / Async Server |<->| Wi-Fi SoftAP | |
| +--------------------+ +---------------------+ +----------------+ |
| β |
| βΌ Hardware Abstraction Layer (HAL) |
| +-------------------+ +-------------------+ +---------------------+ |
| | PCNT Counter HAL | | LEDC Generator HAL| | I2S DMA LA Engine | |
| | (PCNT0 Reciprocal)| | (1Hz - 5MHz PWM) | | (4/8-CH Parallel) | |
| +-------------------+ +-------------------+ +---------------------+ |
| | ADC1 DMM HAL | |
| | (12-bit Oversamp) | |
| +-------------------+ |
+-------------------------------------------------------------------------+
- Zero-Install Web Experience: Complete web dashboard is compiled directly into ESP32 flash memory (
PROGMEM) as a compressed asset (<20KB gzipped). No internet connection or cloud service required. - Collision-Free Hardware Management: The
InstrumentManagerenforces exclusive ownership over shared GPIOs, timers, and DMA channels, preventing peripheral conflicts across operating modes. - Hardware-Accelerated I2S DMA Engine: Logic Analyzer samples digital channels in parallel via I2S parallel slave DMA, bypassing CPU interrupt overhead (2 MS/s maximum validated capture rate under the documented test setup).
- Client-Side Protocol Decoding: High-bandwidth digital captures are decoded on the client browser using Web Workers and Canvas renderers, keeping ESP32 CPU free for real-time sampling.
-
Low-Voltage Electronics Only: This instrument is intended strictly for low-voltage electronics prototyping (
$0β3.3\text{ V} / 0β5.0\text{ V}$ ). NEVER connect directly to household AC mains. -
DMM Input Protection & Electrical Stress:
- The DMM input uses a
$10\text{ k}\Omega$ series resistor and BAT54S dual Schottky clamp to$3.3\text{ V}$ and GND. - At a
$30\text{ V}$ input fault, the$10\text{ k}\Omega$ resistor limits calculated clamp current to$\approx 2.64\text{ mA}$ ($P_R = 69.4\text{ mW}$ ) assuming a$3.65\text{ V}$ clamp. - This is an electrical-stress calculation, NOT a guaranteed safe-input rating.
- The 30 V input is NOT rated for continuous operation. Maximum allowable input voltage and transient capability remain UNSPECIFIED until the complete protection network, 3.3 V rail behavior, and board-level failure modes are validated.
- The DMM input uses a
-
Metrology Transparency:
-
Frequency Counter: Validated from
$1\text{ Hz}$ to$5.0\text{ MHz}$ via internal loopback. -
Logic Analyzer & UART: 4 channels validated at
$100\text{ kS/s} \text{ to } 2.0\text{ MS/s}$ ; UART validated up to$115200\text{ baud}$ . - Digital Multimeter: Implemented + functionally tested on hardware; absolute external accuracy is NOT VERIFIED pending physical multi-point calibration against an independent precision voltage standard.
- Detailed metrology benchmarks and limits are documented in
docs/performance.mdanddocs/limitations.md.
-
Frequency Counter: Validated from
βββ platformio.ini # PlatformIO environment configuration
βββ data/
β βββ index.html # Source Web Dashboard (HTML5, CSS3, Canvas)
βββ include/
β βββ system_config.h # Pin mappings, buffer sizes, network constants
β βββ instrument_manager.h # Central peripheral collision prevention
β βββ wifi_manager.h # SoftAP & mDNS configuration
β βββ web_server.h # Async HTTP & WebSocket server
β βββ web_assets.h # Packaged PROGMEM web dashboard
β βββ hal/ # Hardware Abstraction Layer headers
β β βββ hal_pcnt.h # Pulse counter HAL
β β βββ hal_ledc_gen.h # Signal generator HAL
β β βββ hal_i2s_la.h # I2S parallel DMA capture HAL
β β βββ hal_adc_dmm.h # ADC1 DMM HAL
β βββ instruments/ # High-level instrument logic
β βββ freq_counter.h # Frequency counter instrument
β βββ logic_analyzer.h # Logic analyzer instrument
β βββ dmm.h # Digital multimeter instrument
βββ src/ # Implementation source files
βββ benchmarks/ # Python automated hardware test & validation suite
βββ docs/ # Detailed engineering documentation
β βββ architecture.md # System design & FreeRTOS task layout
β βββ limitations.md # 3-tier limits, silicon physics & safety boundaries
β βββ performance.md # Complete validation test suites & benchmarks
β βββ build.md # Build, flashing & troubleshooting instructions
βββ README.md
This project is open-source under the MIT License.