ESP-12 bootloader modes and GPIO state at startup

Since I encountered some initial difficulties in programming the ESP-12 version of the ESP8266 module using the Arduino IDE, let me here summarise some findings based on information from [1,2,3] windows vista sp1 다운로드.

esp12-pinout

The ESP-12 module exposes 11 GPIOs 에이핑크 노래. Three of them are especially relevant, as they determine the bootloader mode at startup or following reset.

                                  | GPIO 0 | GPIO 2 | GPIO 15
----------------------------------|--------|--------|---------
Flash Startup (Normal)            |   1    |   1    |   0
UART Download Mode (Programming)  |   0    |   1    |   0
SD-Card Boot                      |   0    |   0    |   1

Furthermore, CHPD should be pulled up and RESET should be pulled up or should be floating 피고인 11회. If you connect RESET to ground, the module resets.

I have not yet figured out what the SD-Card boot means, so in my applications GPIO 2 should always be pulled up and GPIO 15 should always be pulled down amd overdrive 다운로드. I am using 10k resistors, but smaller values (e.g. 3.3k) should also work.

To facilitate development, I connected two push button switches to the GPIO 0 and RESET pins, shorting them to ground when pressed 왕좌의게임 시즌2. When the buttons are not pressed, they are both pulled up to 3.3V using a 10k resistor.

This allows me to do the following two-finger-action to restart in programming mode and allow the Arduino IDE to upload a new firmware:
– press reset button
– press programming button
– release reset button
– release programming button

References

[1] https://zoetrope.io/tech-blog/esp8266-bootloader-modes-and-gpio-state-startup
[2] http://www.instructables.com/id/Getting-Started-with-the-ESP8266-ESP-12/
[3] http://www.instructables.com/id/ESP8266-Using-GPIO0-GPIO2-as-inputs/

7 thoughts on “ESP-12 bootloader modes and GPIO state at startup

  1. Pingback: ESP-12 NodeMcu ESP8266 | 으잉 >_<

  2. Pingback: Consolidación de links para ESP8266 (y ESP32) | codesect

  3. Rodrigo Mendoza

    THANKYOU SO MUCH. I have to make a note that ch_pd, gpio15 & gpio 2 can be connected directly to gnd and source respectivelly. But the pull up and down on reset and gpio 0 are essential.

    Reply
  4. Pingback: Home Status Display – Qetesh's Workbench

  5. Pingback: WiFi Motion Detector – Qetesh's Workbench

  6. Pingback: Project HiveSUMMary | zeitwesentech blog

Leave a Reply

Your email address will not be published. Required fields are marked *