BATEAR Web Flasher
ESP32-S3 • Acoustic Drone Detection

Flash firmware in 60 seconds

No toolchain. No drivers. Connect your ESP32-S3 board via USB and flash directly from the browser.

Requires Chrome 89+ or Edge 89+ on desktop — Web Serial API is not supported in Firefox or Safari.
Your browser does not support Web Serial. Please use Chrome or Edge on desktop.
loading...

Captures audio via ICS-43434 MEMS microphone, runs FFT-based harmonic analysis, and transmits drone alerts over encrypted LoRa.

I2S Mic + DSP LoRa TX (SX1262) AES-128-GCM Heltec WiFi LoRa 32 V3

Receives encrypted LoRa alerts from detectors, displays status on OLED, and forwards events to Home Assistant via MQTT over Wi-Fi.

LoRa RX (SX1262) SSD1306 OLED MQTT + HA Discovery Heltec WiFi LoRa 32 V3

Captures audio and publishes drone alerts directly over Ethernet to an MQTT broker. No gateway required — ideal for fixed installations with PoE.

I2S Mic + DSP W5500 Ethernet / PoE MQTT + HA Discovery LILYGO T-ETH-Lite S3
// Network Key
Same key must be used on all Detectors and the Gateway.
Unique per detector — the gateway shows which device triggered an alarm.

// Gateway — Wi-Fi / MQTT
Use mqtt:// or mqtts:// — e.g. mqtt://homeassistant.local:1883
Short identifier for MQTT topics — e.g. batear/nodes/gw01/status
Unique per detector — included in MQTT status payloads.

// MQTT / Home Assistant
Use mqtt:// or mqtts:// — e.g. mqtt://homeassistant.local:1883
Short identifier for MQTT topics — e.g. batear/nodes/wd01/status

// REST API / OTA
Bearer token for POST endpoints (/api/ota, /api/config, /api/reboot). Leave empty to allow unauthenticated access.
Optional — defaults to gateway address
No configuration entered — firmware will use compile-time defaults.
// Connection Guide
01

Connect via USB-C

Plug your Heltec WiFi LoRa 32 V3 / V4 or LILYGO T-ETH-Lite S3 into your computer using a USB-C data cable (not charge-only).

02

Choose Role & Configure

Select your firmware role in the tab selector above. Fill in any configuration fields, then click Install.

03

Pick Serial Port

A dialog will appear — select the serial port for your ESP32-S3 (usually CP2102 or USB JTAG).

04

Wait & Done

Flashing takes about 30–60 seconds. The device reboots automatically when complete.

// Sample Detection

Harmonic frequency analysis — real drone spectrograms available at
batear-io/batear-datasets

// Troubleshooting
No serial port appears in the dialog
Ensure you are using a data-capable USB-C cable (charge-only cables lack data lines). On Linux, your user may need to be in the dialout group: sudo usermod -aG dialout $USER, then log out and back in.
Flashing fails or times out
Hold the BOOT button on the board, press RST, then release BOOT to enter download mode. Try flashing again. If the issue persists, lower your baud rate or try a different USB port.
How do I configure the network key and device ID?
The AES-128 Network Key only applies to the Detector and Gateway roles — it secures the LoRa link between them. Enter a 32-character hex key (or click Generate) and flash every detector and the gateway with the same value. For detectors, assign a unique Device ID (0–255) so the gateway can identify which detector triggered an alarm. Both values are stored in NVS at offset 0x9000. To change LoRa frequency or sync word, build from source using idf.py menuconfig.
How do I configure the wired detector?
Select the Wired Detector tab and fill in MQTT broker URL, username, password, and a unique device ID. To assign a static IP instead of DHCP, check Use static IP and enter the IP, gateway, subnet mask, and optional DNS server. These values are written to NVS and applied on boot.

The Network Key field is intentionally hidden in this tab — the wired detector publishes directly to your MQTT broker over Ethernet, so it does not use the AES-128 LoRa key. Use mqtts:// + broker TLS if you need transport encryption.
How do I update the wired detector firmware remotely?
The wired detector includes a built-in REST API on port 8080. Upload a new firmware binary with: curl -X POST --data-binary @firmware.bin http://<ip>:8080/api/ota. If you set an HTTP auth token, add -H "Authorization: Bearer <token>". The device reboots automatically after a successful upload, and rolls back if the new firmware fails to start.
How do I connect the gateway to Home Assistant?
Select the Gateway tab and fill in your Wi-Fi credentials and MQTT broker URL (e.g. mqtt://192.168.1.100:1883). These are written to NVS and the gateway will connect to Wi-Fi & MQTT on boot. Home Assistant discovers the gateway automatically via MQTT Discovery — no manual YAML needed. The gateway publishes to batear/nodes/<id>/status.
Which boards are supported?
Heltec WiFi LoRa 32 V3 / V4 (ESP32-S3 + SX1262) — used for Detector and Gateway roles.
LILYGO T-ETH-Lite S3 (ESP32-S3 + W5500 Ethernet) — used for the Wired Detector role.