ESP8266 Thing Development Board Hookup Guide

Pages
Contributors: jimblom
Favorited Favorite 11

Example Sketch: Blink

Example 1: Blink

To verify that everything works, try uploading the old standard: Blink. But instead of blinking pin 13, toggle pin 5, which is attached to the onboard LED.

language:c
#define ESP8266_LED 5

void setup() 
{
  pinMode(ESP8266_LED, OUTPUT);
}

void loop() 
{
  digitalWrite(ESP8266_LED, HIGH); // LED off
  delay(500);
  digitalWrite(ESP8266_LED, LOW); // LED on
  delay(500);
}

Upload Fails – Troubleshooting

If every upload attempt results in an error ending with something like error: espcomm_open failed

Try changing the board to Generic ESP8266 Module, and in the sub menus, make sure the following sub-menu's are also set: