On this page
On this page
Optional ESPHome firmware for ETH gateways
Stock firmware remains the default and stays fully supported. This page is an optional open-source ESPHome host image for people who already use Home Assistant / ESPHome and want the native API on the same ETH gateway. Flashing replaces the stock ESP32 web UI. The Zigbee radio is not rewritten.
Source and notes live in inswift-eth under optional-firmware. Flash and downloads: ETH optional ESPHome flasher. To restore stock, use Flash ETH dongle firmware.
Models
| Gateway | Zigbee silicon | ESPHome | Z2M adapter | ZHA |
|---|---|---|---|---|
| ETH-52P / ETH-52P7 | CC2652P / P7 | 0.1.1 | zstack | ZNP |
| ETH-MG21 / MG24 (incl. PoE) | EFR32MG21 / MG24 | 0.1.8 | ember | EZSP |
Both YAMLs share the same ESP32 Ethernet pins. Do not flash the MG package onto a 52P, or the other way around. The Zigbee TCP port stays 6638, 115200, no flow control — same as stock.
You get Ethernet first, Wi-Fi fallback, a device web page, the Home Assistant native API, Home Assistant Bluetooth Proxy, and Zigbee Reset / Enter Bootloader from the web UI or HA.
Before you start
- Connect the ETH gateway to this computer with a USB data cable (Ethernet alone cannot flash the first image)
- Open ETH optional ESPHome flasher in Chrome or Edge
- Close anything using the serial port: ZHA / Zigbee2MQTT, serial monitors, and other tabs already on the flasher
- Note the Zigbee image type (coordinator / router / Thread) while the stock UI still opens. This page does not write the Zigbee chip
- Keep a way back to stock: Flash ETH dongle firmware
Power USB-C at 5V 1A and connect Ethernet to a router:

Flash the ESP32
Open ETH optional ESPHome flasher, click Connect device, pick this ETH serial port, then Install firmware. Wait until it finishes; do not unplug.
The two families are not interchangeable. PoE and non-PoE share the same ESP32 image; MG21 vs MG24 still matters for the Zigbee chip.
Without browser serial, download the factory file and use esptool:
esptool.py --chip esp32 write_flash 0x0 inswift-eth-mg-esphome-0.1.8.factory.bin
For 52P / 52P7 use inswift-eth-52p-esphome-0.1.1.factory.bin. On Windows the port is COMx.
First boot
- Plug in Ethernet and wait for DHCP. Open
http://<gateway-ip>/ - If neither Ethernet nor saved Wi-Fi is up for about a minute, a fallback AP starts:
Inswift-ETH-MGon MG,Inswift-ETH-52Pon 52P. Password for both isinswift123 - Check Ethernet IP on the page. MG Zigbee Chip reads
EFR32MG21orEFR32MG24. 52P shows the fixed stringCC2652P2 / CC2652P7 nc <IP> 6638from a PC should connect. Then start Z2M or ZHA — only one client may hold port 6638

After this ESPHome image is running, do not re-flash factory to upgrade: upload the matching .ota.bin under OTA Update on the device page. That path is not for Zigbee .gbl / .hex files.
Zigbee2MQTT / ZHA
The port pattern matches stock. Use the IP shown on the ESPHome page; dongle.local may not resolve.
ETH-MG (including PoE):
serial:
port: tcp://192.168.x.x:6638
adapter: ember
baudrate: 115200
rtscts: false
ETH-52P / 52P7: set adapter to zstack.
ZHA: socket://192.168.x.x:6638. Radio type EZSP on MG, ZNP on 52P. Do not point ZHA and Z2M at the same gateway.
Web buttons
| Button | What it does |
|---|---|
| Zigbee Reset | Normal restart of the Zigbee SoC |
| Zigbee Enter Bootloader | Then flash Zigbee firmware from a PC over socket://IP:6638 |
| WiFi Connect | Apply the SSID / password from the page |
| Restart / Factory Reset ESP32 | ESP32 only; does not erase Zigbee flash |
Stop Z2M / ZHA before touching Zigbee firmware. MG needs a matching EmberZNet NCP .gbl; 52P needs a matching CC2652 coordinator image. Web OTA on this build writes ESP32 only.
Downloads
| File | Use |
|---|---|
| ETH-MG factory 0.1.8 | First USB install |
| ETH-MG OTA 0.1.8 | Web upgrade once ESPHome is running |
| ETH-52P factory 0.1.1 | First USB install |
| ETH-52P OTA 0.1.1 | Web upgrade once ESPHome is running |
YAML and components/stream_server: ETH-MG · ETH-52P. When building in the Home Assistant ESPHome add-on, use ESPHome 2026.9.1 (or a compatible 2026.9.x).
FAQ
The stock web UI is gone. That is expected. Open the ESPHome page, or join the fallback AP. To restore stock, flash official host firmware with Flash ETH dongle firmware.
Z2M / ZHA cannot open 6638. Wait for the ESP32 to finish booting; keep a single client; MG still uses ember, 52P still uses zstack. Try Zigbee Reset.
Need a new Zigbee coordinator image. Stop Z2M / ZHA → Zigbee Enter Bootloader → PC tool on socket://IP:6638. Do not upload .gbl / .hex to ESPHome OTA.
No Ethernet address. Check the cable, or wait for the fallback AP and set Wi-Fi. MG AP Inswift-ETH-MG, 52P AP Inswift-ETH-52P, password inswift123.