Use this forum to chat about hardware specific topics for the ESP8266 (peripherals, memory, clocks, JTAG, programming)

User avatar
By vazquezjm
#90025 Hi All.

I uploaded a piece of code to a Wemos D1 mini from Home Assistant (OTA) which is causing the device to do an infinite loop (restart), thus, I cannot upload new code OTA or through the COM port (which never becomes available).

Any idea before I donate it to a museum?

TIA and Happy 2021!
User avatar
By AcmeUK
#90027
Any idea before I donate it to a museum?

YES!
In ESPHome compile your code (three dots top right corner)
Then download and save the binary.
Download the appropriat version of ESPHome Flasher from here:- https://github.com/esphome/esphome-flasher/releases
Then flash the chip.
Job done. It worked for me!
User avatar
By vazquezjm
#90033 Thanks for the reply @AcmeUK

I solved it in a different way

- Unplugged everything
- Connected the Wemos to a USB-to-Serial adapter (TX, RX, GND, Pwr pins)
- Flashed WiFi Scan example with Arduino IDE
- Now the USB (COM port) connection is available again on the Wemos
- Flashed a previous (working) version of my YAML code with ESPHome Flasher

Now everything is back to normal. Phew!