How to set up the Arduino IDE to program ESP8266 boards and modules
Posted by David Husselmann on
The ESP8266 can be programmed using the Arduino IDE, so this makes coding for the platform really easy. There are a few steps to getting this to work:
-
Download and install the latest Arduino IDE. You'll need a recent version to access the new Board Manager features, so if you have a version older than 1.8.3, now is a great time to update.
- Install the ESP8266 board package. Follow these steps:
- In File > Preferences, add the following URL into the Additional Board Manager URLs.
http://arduino.esp8266.com/stable/package_esp8266com_index.json
This is what it should look like:
- Click OK to save, then go to Tools > Board: xxx > Boards Manager.
- Type esp8266 into the Filter your search box, and you should see the esp8266 package (by ESP8266 Community). Click on the Install button.
- Go to Tools > Board: xxx and select the Generic ESP8266 Module if you are using our ESP8266 breakout.
- Now connect your FTDI adapter to your computer. You'll need to know the serial port that this is linked to, it will be something like COM5 (or higher if you have had other devices connected before). In Windows you can find this out in Device Manager (open up Ports and have a look for USB adapters).
- In Tools > Port select the serial port of your FTDI adapter.
- While you hook up the FTDI to the ESP board, disconnect the FTDI cable from your computer.
- Connect your FTDI to the ESP8266 board. Ensure that you've got a 3.3V FTDI adapter, or if you have a 3.3V/5V selectable one, make sure the selector switch is set to 3.3V. Make the following connections (breakout shown without ESP board):

- Reconnect the FTDI cable to your computer. Check that the ESP board does not get too hot - if it does, disconnect and check your wiring and supply voltage.
- Finally, hit the Upload button in the Arduino IDE, it should compile and upload your code to your ESP board.

