Nodemcu Arduino IDE setup and LED Blink.

    Hello guys, Welcome back to my SriTu Hobby blog. Today we are going to learn the first Nodemcu lesson. This lesson mainly focuses on how to set up Arduino IDE for the Nodemcu board and how to blink a LED bulb using the Nodemcu board.

What is the Nodemcu board?

    Nodemcu board is a development board. It is an open-source platform. But this board is different from the other boards. Because it has WIFI technology. We can use this board for IoT technology. IoT technology is known as the Internet of Things. The Internet of Things is the control of all electronic devices in the home through the Internet. This could also be called the next revolution in technology.
Okay, let’s talk about this board structure. The ESP-12E module is used to create this board. Also, this board includes an ESP8266 chip. This chip consists of a microprocessor called a Tensilica Xtensa 32-bit LX106 RISC. It can be changed in the frequency range of 80MHz – 160MHz. Also, this board includes 4MB of memory. we can see different types of Nodemcu boards in the market. But, most commonly, the following two types are used.

 

The pin diagrams on both of these boards are similar. But there are two main differences between these boards. The first one is the USB interface. The board in the first picture includes a CP2102 USB drive chip. It does not require drivers for connecting to the computer. The board in the second picture includes a CH340 USB drive chip. For this, you must have CH340 / 341 drivers installed on your computer. The second difference is the size of these boards. The board in the first picture we can easily attach to the breadboard and the second board difficult to be attached to the breadboard. So, now we look at the other features in these Nodemcu boards.

Features.

  • Wireless 802.11 b / g / n standards;
  • Support STA / AP / STA + AP three operating modes;
  • Built-in TCP / IP protocol stack to support multiple TCP Client connection (5 MAX);
  • D0 ~ D8, SD1 ~ SD3: used as GPIO, PWM, IIC, etc. Port Drive 15mA;
  • AD0: 1 channel ADC;
  • Power input: 4.5V ~ 9V (10VMAX), USB-powered, providing USB debugging interface;
  • Current job: keep sending: ≈70mA (200mA MAX), Standby:
  • Transfer rate: 110-460800bps;
  • Support UART / GPIO data communication interface;
  • Remote firmware upgrade (OTA);
  • Smart Link supports intelligent networking capabilities;
  • Operating temperature: -40 ℃ ~ + 125 ℃;
  • Drive Type: Dual high-power H-bridge driver
  • Module Weight: about 7g
  • Board Name: NodeMCU 1.0 (ESP-12E Module)
  • USB-to-UART bridge chip: CP2102
Let us now look at the Nodemcu Pin diagram.
These Nodemcu boards include 9 digital pins and 1 analog pin. This is the same for all Nodemcu boards. So, we have now explained a lot of information about these Nodemcu boards. Next, we set up the Arduino IDE for the Nodemcu program.
Ok, let’s do it step by step.

Step 1

Open your Arduino IDE.

Step 2

After, following the steps below. First, click File –> Preferences and include Additional Board Manager URLs. For that, use this link —
http://arduino.esp8266.com/stable/package_esp8266com_index.json

 

Step 3

Next click Tools -> Board Manager. After, Search Nodemcu and install its latest version.

 

Right now the Arduino IDE setup is complete. Now you can use the Nodemcu board through the Arduino IDE.
OK, we try to blink an LED bulb using the Nodemcu board. The components required for this are as follows. You can easily purchase these components using the links provided.

Components.

Ok, how to do this project? let’s learn step by step.

Step 1

Let’s identify these components.
Nodemcu board.
 
This component is described above.
LED bulb

180-ohm Resistor

This component is used to control the current flowing through the LED bulb.
Jumper wires
These are used to easily connect components. Two male-to-male jumper wires were used for this project.
Breadboard.
The breadboard is used to easily attach the components.

Step 2

Next, connect these components using the below circuit diagram.

Step 3

Then, connect this circuit to the computer using a USB cable. Now let’s look at the code. For that, I’m using a simple LED bulb blink code.
void setup() {
  pinMode(D0, OUTPUT);
}
 
void loop() {
  digitalWrite(D0, HIGH);
  delay(1000);
  digitalWrite(D0, LOW);
  delay(1000);
}

Step 4

Select the correct board and port.

 

Step 5

Finally, upload this code.

The full video guide is given below. Please watch it. We will meet in the next post. Have a good day. Bye-bye.

Related Posts

Leave a Reply

Your email address will not be published. Required fields are marked *