ArduinoIDE for esp8266

How configure Arduino IDE to compile the code for ESP8266 and NodeMCU

 

Install Arduino IDE for ESP8266 and NodeMCU

Step1: downloading Arduino IDE

  • First download the Arduino IDE to ensure that you have the latest software version (some older versions won’t work), visit the following URL: https://www.arduino.cc/en/Main/Software

Step2: installing the ESP8266 Board

  • To install the ESP8266 board in your Arduino IDE, follow these next instructions:
  • Open the preferences window from the Arduino IDE. Go to File > Preferences
  • Enter http://arduino.esp8266.com/stable/package_esp8266com_index.json into the “Additional Board Manager URLs” field as shown in the figure below. Then, click the “OK” button.
  • Open boards manager. Go to Tools > Board > Boards Manager
  • Scroll down, select the ESP8266 board menu and install “esp8266”
  • Choose your ESP8266 board from Tools > Board >
    • Generic ESP8266 Module
    • NodeMCU v1.0

Step3: close ArduinoIDE and finally, re-open it

Step4: if you are using NodeMCU v1.0, download the right driver


Compiling code for NodeMCU: select the following:


Compiling code for ESP8266 (for SonOff):

 

Select the below option before compiling:

  • CPU: 80Mhz
  • Crystal:20Mhz
  • Flash: 1M (64SPIFFS)
  • Flash Mode: DOUT (important for SonOff)


 

 

 

Comments are closed.