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

GatewayZigbee siliconESPHomeZ2M adapterZHA
ETH-52P / ETH-52P7CC2652P / P70.1.1zstackZNP
ETH-MG21 / MG24 (incl. PoE)EFR32MG21 / MG240.1.8emberEZSP

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

  1. Connect the ETH gateway to this computer with a USB data cable (Ethernet alone cannot flash the first image)
  2. Open ETH optional ESPHome flasher in Chrome or Edge
  3. Close anything using the serial port: ZHA / Zigbee2MQTT, serial monitors, and other tabs already on the flasher
  4. Note the Zigbee image type (coordinator / router / Thread) while the stock UI still opens. This page does not write the Zigbee chip
  5. Keep a way back to stock: Flash ETH dongle firmware

Power USB-C at 5V 1A and connect Ethernet to a router:

ETH USB-C 5V 1A power and 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

  1. Plug in Ethernet and wait for DHCP. Open http://<gateway-ip>/
  2. If neither Ethernet nor saved Wi-Fi is up for about a minute, a fallback AP starts: Inswift-ETH-MG on MG, Inswift-ETH-52P on 52P. Password for both is inswift123
  3. Check Ethernet IP on the page. MG Zigbee Chip reads EFR32MG21 or EFR32MG24. 52P shows the fixed string CC2652P2 / CC2652P7
  4. nc <IP> 6638 from a PC should connect. Then start Z2M or ZHA — only one client may hold port 6638

ETH-MG ESPHome device web page

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

ButtonWhat it does
Zigbee ResetNormal restart of the Zigbee SoC
Zigbee Enter BootloaderThen flash Zigbee firmware from a PC over socket://IP:6638
WiFi ConnectApply the SSID / password from the page
Restart / Factory Reset ESP32ESP32 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

FileUse
ETH-MG factory 0.1.8First USB install
ETH-MG OTA 0.1.8Web upgrade once ESPHome is running
ETH-52P factory 0.1.1First USB install
ETH-52P OTA 0.1.1Web 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.