ESP32 Web FlasherWEBSERIAL API
🔌

ESP32 + OpenWrt Kiosk Web Flasher

OpenWrt Wireless Satellite (Tested on Ruijie RG-EW1200G Pro) · Microsecond Coin Interrupts · 100% Free

v1.0.0 Stable

OpenWrt routers (compatible with any OpenWrt device, tested and verified on the Ruijie RG-EW1200G Pro) are gigabit powerhouses for captive paywall routing, but lack built-in GPIO headers for coin acceptors. The ESP32 + OpenWrt Combo solves this: a low-cost $3 ESP32 acts as an autonomous wireless coin acceptor satellite, capturing microsecond pulses and reporting coin drops over Wi-Fi to your OpenWrt router.

✓ Any OpenWrt Router (Tested on Ruijie EW1200G Pro)✓ Multi-Coinslot Wireless Mesh✓ 10kΩ Resistor ProtectedZero Pi Needed
1

ESP32 + OpenWrt Architecture

OPENWRT SATELLITE
ESP32 Wireless Satellite (Multi-Coinslot)
OFFICIAL BUILD

Connects wirelessly over Wi-Fi directly to your OpenWrt router (tested and verified with Ruijie RG-EW1200G Pro, or any OpenWrt device) at http://10.0.0.1:4000. Handles coin interrupt pulses, debounces with hardware timer accuracy, and engages the coin inhibit relay when no customer is inserting coins.

Coin Signal: GPIO 4Inhibit Relay: GPIO 5OLED/LCD: GPIO 21 / 22Physical Button: GPIO 15

Why ESP32 + OpenWrt instead of Raspberry Pi?

A Raspberry Pi already features its own 40-pin GPIO header. In OpenPisoWiFi, the ESP32 is designed specifically to pair with OpenWrt Gigabit Routers (tested and verified on the Ruijie RG-EW1200G Pro, or other OpenWrt-supported models) so you can build a complete commercial vending machine with high-power AC1200 Wi-Fi without buying an expensive Raspberry Pi or SBC!

⚠️Hardware Wiring Schematic (ESP32 to Coinslot)

The CL-168 coin acceptor signal wire emits a 12V pulse. You MUST insert an in-line 10kΩ series resistor between the coin acceptor white wire and ESP32 GPIO 4 to protect the 3.3V chip from overvoltage.

[12V Power Supply] ---> OpenWrt Router (12V Direct - e.g. Ruijie EW1200G Pro)
[12V Power Supply] ---> Coinslot (+12V DC)
[12V Power Supply] ---> Buck Converter (12V->5V) ----> ESP32 VIN (5V)
[Common Ground]    ---> Shared GND (PSU, Coinslot, ESP32)
[Coinslot WHITE]   ---> [ 10kΩ Resistor ] -----------> ESP32 GPIO 4
[Coinslot INHIBIT] <--- Transistor / MOSFET Gate <---- ESP32 GPIO 5
2

Connect & Flash ESP32

USB PLUGGED
1Plug your ESP32 into a USB port using a known-working USB data cable (avoid charge-only cables).
2Click the "INSTALL OPENPISO ESP32" button below.
3Select your board's COM port (usually CP2102, CH340, or USB-JTAG) from the browser prompt.
4Stuck on "Connecting..."? Hold down the physical BOOT button on your ESP32 board for 2 seconds while clicking Connect, then release it.
⚡

Ready to Flash: ESP32 OpenWrt Wireless Satellite

Manifest: /firmware/manifest-esp32-satellite.json

WebSerial is not supported in this browser. Please use Chrome or Edge.Serial connection not allowed. Ensure this page is running over HTTPS or localhost.

Flashing takes ~35 seconds. Your ESP32 will auto-reboot when finished.

Prefer compiling in Arduino IDE / PlatformIO?View .INO Source

Customize Parameters (NVS Flash)

Configure without re-compiling code · Stored in ESP32 Flash

PERSISTENT

Must be unique per coin acceptor box so your OpenWrt router tracks separate cash totals.

Label displayed on the customer captive portal and OLED/LCD screen.

Matches the SATELLITE_SECRET configured in your OpenWrt Admin Portal.

💡 Tip: Click "Connect Serial Monitor" below first so the browser can send parameters directly over USB to your ESP32 board.

Live WebSerial Console & Pulse Diagnostics

Read serial logs, inspect Wi-Fi connection, and verify coin pulse accuracy (115200 baud)

[11:56:44 AM]WebSerial monitor ready. Plug your ESP32 into a USB port and click "Open Serial Monitor" to view live pulse telemetry.
Quick Test:

Frequently Asked Questions & Troubleshooting

1. The flasher says "Failed to initialize. Try resetting your device"?

Many ESP32 DevKit boards (especially budget CH340 or CP2102 clones) lack an automatic auto-reset capacitor circuit. To enter flashing mode: hold the BOOT (or IO0) button down, click Connect in the browser, wait 2 seconds until the erase prompt appears, then release the button.

2. No serial ports appear in the Chrome popup?

Ensure your USB cable is a data cable, not a charge-only cord from a phone charger. If on Windows, make sure you have installed the standard USB UART driver for your chip: CH340 Driver or Silicon Labs CP210x VCP Driver.

3. Can I use other ESP variants like ESP32-S2, ESP32-S3, or ESP32-C3?

Yes! The OpenWrt Satellite firmware is compatible across ESP32, ESP32-S2, ESP32-S3, and ESP32-C3 microcontrollers. They all possess native hardware interrupt timers to capture microsecond coin pulses and report directly to your OpenWrt router over Wi-Fi.

4. How do I change the Wi-Fi credentials in the Satellite?

After flashing, you can either configure the Wi-Fi via ESP Web Tools Improv Wi-Fi prompt, or compile the sketch in Arduino IDE with your custom SSID and password in firmware/esp32-satellite/esp32-satellite.ino.