NodeMCU - Getting Started
NodeMCU - Getting Started
1
Node MCU
2
1. Download Arduino IDE
• In the Preferences window, go to the field: “Additional Board Managers URL:” type
the following in the text box:
http://arduino.esp8266.com/stable/package_esp8266com_index.json
4
3. Configure Arduino IDE for Node MCU
• Click “Tools -> Board -> Boards Manager” menu option
5
4. Configure Arduino IDE for Node MCU
• Click “Tools -> Board -> Node MCU 1.0 (ESP-12E Module)” option
• Click “Tools -> Port -> <port number>” where <port number> is the
USB port on your computer to which you have connected the Node
MCU board
• Click on “Download VCP” link to download the CP210x USB to UART Bridge VCP Driver
appropriate to your Operating System. For e.g., if your laptop runs Windows 10 OS, please
select the driver software from the “Download for Windows 10 Universal” section. Similarly
for other operating systems.
• Once the Driver Zip file downloads on your laptop, open the Zip file and double click on:
CP210xVCPInstaller_x64.exe or CP210xVCPInstaller_x86.exe (as appropriate) and follow the
step-by-step instructions on the Installation Wizard to complete the Driver installation.
• Note: You will need administrative privilege on your computer to install the driver.
7
6. Blink the On-board LED on NodeMCU
Copy and paste the below sketch to Arduino IDE (one after the other)
// the loop function runs over and over again forever
/* ESP8266 Blink by Simon Peter Blink the blue LED on the void loop() {
ESP-01 module. This example code is in the public domain. digitalWrite(LED_BUILTIN, LOW);
// Turn the LED on (Note that LOW is the voltage level
The blue LED on the ESP-01 module is connected to GPIO1 // but actually the LED is on; this is because
(which is also the TXD pin; so we cannot use Serial.print() at
// it is active low on the ESP-01)
the same time).
Note that this sketch uses LED_BUILTIN to find the pin with delay(1000); // Wait for a second
the internal LED */ digitalWrite(LED_BUILTIN, HIGH);
void setup() { // Turn the LED off by making the voltage HIGH
// Initialize the LED_BUILTIN pin as an output
delay(2000);
pinMode(LED_BUILTIN, OUTPUT);
}
// Wait for two seconds (to demonstrate the active low
LED)
}
8
7. Upload the code to Node MCU board
Click the upload button () on the Arduino IDE to upload the code (sketch) to Node MCU board
As soon as the code is uploaded to Node MCU board, the on-board LED starts blinking. 9