Friday, 20 November 2015 22:46

Upload sketch to the ESP8266 (ESP-07/ESP-12) using Arduino IDE

ESP 07 Arduino IDE
The ESP-07/ESP-12 is a generic ESP8266 module which have no bootstapping resistors on board, insufficient decoupling capacitors, no reset circuit, and no USB-serial adapter. This is an article shows you how to connect the bootstapping resistor to the ESP-07 module and upload sketches onto the ESP-07/ESP-12 using the familiar Arduino IDE.

In order to use the ESP-07/ESP-12 module, you need to solder 4 pcs 10K ohms resistors & a filtering capacitor onto the module as shown in figure below.

ESP 07
JP1 and SW1 is required when uploading sketch, you can remove them after sketch has been uploaded.


Power the ESP-07/ESP-12 module

The ESP-07/ESP-12 module is a 3.3V device. Power the ESP-07/ESP-12 module from the USB port (5V) without a 3.3V regulator could damage the module.

During uploading sketch, I'm power the module from my USB-Serial adapter which the voltage is switched to 3.3V. However, using the power available from USB to Serial adapter is not recommended.


Hardware setup

As shown in table below is the connection between USB-Serial adapter & ESP-07/ESP-12

USB-Serial adapter ESP-07/ESP-12 module
VCC (3.3V) VCC

usb serial


Testing the ESP-07/ESP-12 module

The ESP-07/ESP-12 comes pre-programmed with AI-Thinkers firmware, it has the AT command set preinstalled. Before uploading sketch to the ESP-07/ESP-12, it's important to test it directly via a serial interface.

Assumes you already have Arduino IDE running on your computer. If you do not have Arduino IDE software on your computer, please download it from Arduino official website & install it to your computer.

  1. Complete the hardware setup as described in the Hardware Setup
  2. Plug in the USB-serial adapter to computer via USB
  3. Run the Arduino IDE
  4. Click on Tools from the Arduino IDE menu
  5. Choose the correct COM port for your USB-Serial adapter
  6. Open the Serial Monitor
  7. Choose the correct baud rate, mine is 9600
  8. Push the SW1 to reset the ESP-07/ESP-12, you should see the following output on the serial console

    [ Version:]


  9. Congratulation! Your ESP-07 is working.

Installing ESP8266 package for Arduino IDE 1.6.4 or 1.6.5

Do not use Arduino 1.6.2 and 1.6.6, if you do not have Arduino IDE1.6.4 or 1.6.5 software on your computer, please download it from Arduino official website.

  • Choose Preferences from the File menu in the Arduino IDE
  • Enter into Additional Board Manager URLs field
  • Choose Board from the Tools menu in the Arduino IDE, click on Boards Manager from the dropdown menu
  • Use the Board manager to install the ESP8266 package
    Board Manager
  • Restart the Arduino once completed installation


Uploading sketch to ESP-07/ESP-12

  • Select the correct configuration for the ESP-07/ESP-12 as shown in figure belowArduino IDE settings
  • Load a sketch into the Arduino IDE editor windows.
  • .As described in the Hardware Setup, place a jumper (JP1) between GPIO0 and GND in order to start the bootload mode.
  • Push the SW1 button to reset the ESP-07/ESP-12.
  • Click on Upload button from the Arduino IDE, the blue LED which is wired to TXD (GPIO1) will start blinking rapidly indicated uploading process is going on.
  • Remove JP1 after successfully uploading.

8 LEDs light up in sequence

8 LEDs light up in sequence

Read 123884 times Last modified on Sunday, 12 June 2016 11:47
Back to Top