Wrong boot mode detected in esp32 wemos d1r32

Sketch uses 896412 bytes (68%) of program storage space. Maximum is 1310720 bytes.
Global variables use 46156 bytes (14%) of dynamic memory, leaving 281524 bytes for local variables. Maximum is 327680 bytes.
esptool.py v4.8.1
Serial port COM5
Connecting......................................

A fatal error occurred: Failed to connect to ESP32: Wrong boot mode detected (0x13)! The chip needs to be in download mode.
For troubleshooting steps visit: https://docs.espressif.com/projects/esptool/en/latest/troubleshooting.html
Failed uploading: uploading error: exit status 2

This is what comes out when i try to upload a code into an esp32 wemos d1r32.
But i have never had to do or pressed anything to upload. The only difference now is that I´m using a different computer.

Hi @doczpa. Please try this:

  1. Select Sketch > Upload from the Arduino IDE menus.
  2. Watch the black output panel at the bottom of the Arduino IDE window until you see this text printed:
    Connecting...
    
  3. Press and hold the button on your ESP32 board.
  4. Wait about one second.
  5. Release the button.

Please let us know whether the upload finishes successfully.

Yes, pressing it until the dots slow down works. Thank you.

You are welcome. I'm glad you are able to achieve a successful upload with this technique.

The ESP32 boards typically have a special circuit that automatically puts the board into boot mode when an upload process starts. I have a cheap ESP32 board that I can sometimes upload to without pressing the button, and other times it fails if I don't press it. It might be that the circuitry of that board is designed in a way that makes its operation unreliable.

If you have any external circuitry, wiring, modules, etc. connected to the board, disconnect it and try uploading to the board again without pressing the button. It is possible that problems with external circuitry could interfere with the automatic boot mode triggering circuitry on the board.

This topic was automatically closed 180 days after the last reply. New replies are no longer allowed.