Installation fails no RTS pin available

I’m trying to install esphome on a Sonoff 4CH Pro R3. I soldered a 5-pin header into the board, wired it up to a 3.3V USB-serial device (connecting TX-RX, RX-TX, GND-GND, 3.3V-3.3V), and connected to USB while holding down button 0 to put it in programming mode. So far so good, everything seems to work.

Then I tried to flash it with esphome run mydev.yaml, where the YAML file contains something like this:

esphome:
  name: myesp

esp8266:
  board: esp8285

# Enable logging
logger:

# Enable Home Assistant API
api:
  password: "secret"

ota:
  password: "secret"

wifi:
  ssid: "mySSID"
  password: "WiFi password"

  # Enable fallback hotspot (captive portal) in case wifi connection fails
  ap:
    ssid: "myespFallback"
    password: "APpassword"

captive_portal:

At first, it looks like it’s working, but then the installation process hangs with:

Uploading stub...
Running stub...
Stub running...
Changing baud rate to 460800
Changed.
Configuring flash size...
Auto-detected Flash size: 1MB
Flash will be erased from 0x00000000 to 0x00062fff...
Compressed 402896 bytes to 284168...
Wrote 402896 bytes (284168 compressed) at 0x00000000 in 6.5 seconds (effective 495.6 kbit/s)...
Hash of data verified.

Leaving...
Hard resetting via RTS pin...
INFO Successfully uploaded program.
INFO Starting log output from /dev/ttyUSB1 with baud rate 115200

Of course, I have no RTS pin, so I don’t know how it would expect to hard reset the device like this. If I try to reset it by removing the 3.3V power pin temporarily, then esphome exits immediately with an error. Can someone tell me how to work around this issue? I’m sure it’s something silly, but I’m new to esphome so haven’t gotten it working yet. Thanks.

I have the same query when flashing a Sonoff TH16. When I flashed a D1_mini_pro hosting a Dallas DS18B20 the required sensor address was displayed in the log after flashing and the D1_mini_pro restarted. This does not happen with the ESP8266 in the TH16. The same ‘Hard Reset via RTS’ message appears after a successful flashing session but the TH16 is not restarted resulting in no log being produced. There is no way to fix this as far as I can determine by altering the code as the code does not run. Perhaps there is some method within ESPHome to change the behavior of the flashing session such that it does not attempt the reset via the RTS line.

Update:

There is a workaround by using OTA to flash the device. The device boots normally after flashing via OTA. Trying different flash modes in the yaml file did not resolve this when using COM port to flash the device.

Did you solve this?
I’m experiencing the same issue … it stalls on “INFO Starting log … with baud rate 115200”
Much appreciated!

I think it kind of solved itself, like I rebooted the device in non-programming mode and it came on line.