Step 2: Installing the USB-to-Serial Bridge Driver
There are numerous ESP8266-based development boards available. Depending on the design, you may need to install additional drivers for your USB-to-serial converter before you are able to upload code to your ESP8266.
For example, the ESP8266 NodeMCU uses the CP2102 to convert USB signals to UART signals, whereas the WeMos D1 Mini uses the CH340G. The ESP-01, on the other hand, lacks an onboard USB-to-serial converter and requires a separate module.
Make sure to inspect your board carefully to identify the USB-to-serial converter that is present. You’ll probably have either CP2102 or CH340 populated on the board.
If you’ve never installed drivers for these USB-to-serial converters on your computer before, you should do so right now.
CP210x USB to UART Bridge VCP Drivers
Prerequisites: Arduino IDE Installed
Before starting this installation procedure, make sure you have the latest version of the Arduino IDE installed in your computer. If you don’t, uninstall it and install it again. Otherwise, it may not work.
Having the latest Arduino IDE software installed from arduino.cc/en/Main/Software, continue with this tutorial.
Do you need an ESP8266 board? You can buy it here.
Wrapping Up
This is a quick guide that shows how to prepare Arduino IDE 2.0 for the ESP8266 Boards on a Windows PC, Mac OS X, or Linux computer.
Next, you might want to read: Getting started with ESP8266 or learn more about the ESP8266 board with our resources:
There are several development platforms available for programming the ESP8266. You can go with:
- Arduino IDE – intended for those who are familiar with Arduino
- Espruino – JavaScript SDK and firmware closely emulating Node.js
- Mongoose OS – An operating system for IoT devices that is recommended by Espressif Systems and Google Cloud IoT
- MicroPython – Implementation of Python 3 for microcontrollers
- SDK provided by Espressif – Official SDK to take advantage of all ESP8266 features
When compared to other platforms, the Arduino IDE is the most user-friendly for beginners. While it may not be the ideal platform for working with the ESP8266, it is a program that most people are already familiar with, which makes getting started much easier.
Before you can use the Arduino IDE to program the ESP8266, you must first install the ESP8266 board (also known as the ESP8266 Arduino Core) via the Arduino Board Manager. This guide will walk you through the process of downloading, installing, and testing the ESP8266 Arduino Core.
What is a Core?
The cores are required to make new microcontrollers compatible with your Arduino IDE as well as existing sketches and libraries. Arduino develops the cores for the microcontrollers (Atmel AVR MCUs) used on their boards, but anyone can develop a core for their own boards as long as they follow the rules and requirements set by Arduino.
Some development boards require the installation of an additional core; therefore, Arduino developed the Boards Manager as a tool to add cores to the Arduino IDE.
For more information on how to use the Arduino IDE Boards Manager, check out their tutorial.
Using PlatformIO¶
PlatformIO is an open source ecosystem for IoT development with a cross-platform build system, a library manager, and full support for Espressif (ESP8266) development. It works on the following popular host operating systems: macOS, Windows, Linux 32/64, and Linux ARM (like Raspberry Pi, BeagleBone, CubieBoard).
-
PlatformIO Core (command line tool)
-
Advanced usage – custom settings, uploading to LittleFS, Over-the-Air (OTA), staging version
-
Using Arduino Framework Staging Version – install development version of the Core
-
Integration with Cloud and Standalone IDEs – Cloud9, Codeanywhere, Eclipse Che (Codenvy), Atom, CLion, Eclipse, Emacs, NetBeans, Qt Creator, Sublime Text, VIM, Visual Studio, and VSCode
This is the suggested installation method for end users.
http://arduino.esp8266.com/stable/package_esp8266com_index.jsoninto Additional Board Manager URLs field. You can add multiple URLs, separating them with commas.
You may optionally use staging boards manager package link:
http://arduino.esp8266.com/staging/package_esp8266com_index.json
. This may contain some new features, but at the same time, some things might be broken.
This is the suggested installation method for contributors and library developers.
/Arduino), or the directory of Arduino application itself, the choice is up to you.
Clone this repository into hardware/esp8266com/esp8266 directory. Alternatively, clone it elsewhere and create a symlink, if your OS supports them.
cd hardware mkdir esp8266com cd esp8266com git clone https://github.com/esp8266/Arduino.git esp8266
You should end up with the following directory structure:
Arduino | --- hardware | --- esp8266com | --- esp8266 | --- bootloaders --- cores --- doc --- libraries --- package --- tests --- tools --- variants --- platform.txt --- programmers.txt --- README.md --- boards.txt --- LICENSE
Download binary tools
cd esp8266/tools python get.py
Restart Arduino
There is a new Arduino IDE—Arduino IDE 2.0 (beta version). In this tutorial, you’ll learn how to install the ESP8266 boards in Arduino IDE 2.0 and upload code to the board. This tutorial is compatible with Windows, Mac OS X, and Linux operating systems.
Accordingly to the Arduino website: “The Arduino IDE 2.0 is an improvement of the classic IDE, with increased performance, improved user interface and many new features, such as autocompletion, a built-in debugger and syncing sketches with Arduino Cloud“.
If you want to install the ESP8266 boards on the “classic” Arduino IDE, follow the next tutorial instead:
If you prefer programming the ESP8266 using VS Code + PlatformIO, go to the following tutorial:
- Getting Started with VS Code and PlatformIO IDE for ESP32 and ESP8266 (Windows, Mac OS X, Linux Ubuntu)
You might also like reading the ESP32 Guide: Installing ESP32 Board in Arduino IDE 2.0 (Windows, Mac OS X, Linux)
Wrapping Up
This is a quick guide that illustrates how to prepare your Arduino IDE for the ESP8266 on a Windows PC, Mac OS X, or Linux computer.
Next, you might want to read: Getting started with ESP8266.
That’s it, you’re ready to start building your own IoT projects with the ESP8266!
- Home Automation Using ESP8266
- ESP8266 Web Server Step-by-step
- ESP8266 Wi-Fi Button – DIY Amazon Dash Button Clone
- ESP8266 Daily Task – Publish Temperature Readings to ThingSpeak
- ESP8266 Weather Forecaster
- Nextion Display with ESP8266 – Touchscreen User Interface for Node-RED
- More ESP8266 projects…
Do you have any questions? Leave a comment below!
Thanks for reading. If you like this post probably you might like my next ones, so subscribe to my newsletter.
Arduino core for ESP8266 WiFi chip
Quick links
Arduino on ESP8266
This project brings support for the ESP8266 chip to the Arduino environment. It lets you write sketches, using familiar Arduino functions and libraries, and run them directly on ESP8266, with no external microcontroller required.
ESP8266 Arduino core comes with libraries to communicate over WiFi using TCP and UDP, set up HTTP, mDNS, SSDP, and DNS servers, do OTA updates, use a file system in flash memory, and work with SD cards, servos, SPI and I2C peripherals.
Contents
Installing with Boards Manager
Starting with 1.6.4, Arduino allows installation of third-party platform packages using Boards Manager. We have packages available for Windows, Mac OS, and Linux (32 and 64 bit).
-
Download and install Arduino IDE 1.x or 2.x
- Start Arduino and open the Preferences window
-
Enter
https://arduino.esp8266.com/stable/package_esp8266com_index.json
into the File>Preferences>Additional Boards Manager URLs field of the Arduino IDE. You can add multiple URLs, separating them with commas. - Open Boards Manager from Tools > Board menu and install esp8266 platform (and don’t forget to select your ESP8266 board from Tools > Board menu after installation).
Latest release
Boards manager link:
https://arduino.esp8266.com/stable/package_esp8266com_index.json
Documentation:
https://arduino-esp8266.readthedocs.io/en/3.1.2/
Using git version
Also known as latest git or master branch.
Using PlatformIO
PlatformIO
is an open source ecosystem for IoT
development with a cross-platform build system, a library manager, and full support
for Espressif (ESP8266) development. It works on the following popular host operating systems: macOS, Windows,
Linux 32/64, and Linux ARM (like Raspberry Pi, BeagleBone, CubieBoard).
Building with make
makeEspArduino
is a generic makefile for any ESP8266 Arduino project.
Using make instead of the Arduino IDE makes it easier to do automated and production builds.
Documentation
Documentation for latest development version:
https://arduino-esp8266.readthedocs.io/en/latest/
Issues and support
ESP8266 Community Forum
is a well-established community for questions and answers about Arduino for ESP8266. Stackoverflow is also an alternative. If you need help, have a “How do I…” type question, have a problem with a 3rd party library not hosted in this repo, or just want to discuss how to approach a problem, please ask there.
If you find the forum useful, please consider supporting it with a donation.
If you encounter an issue which you think is a bug in the ESP8266 Arduino Core or the associated libraries, or if you want to propose an enhancement, you are welcome to submit it here on Github:
https://github.com/esp8266/Arduino/issues
.
Please provide as much context as possible, as well as the information requested in the issue template:
- ESP8266 Arduino core version which you are using (you can check it in Boards Manager)
-
your sketch code; please wrap it into a code block, see
Github markdown manual
- when encountering an issue that happens at run time, attach the serial output. Wrap it into a code block, just like the code.
- for issues that happen at compile time, enable verbose compiler output in the IDE preferences, and attach that output (also inside a code block)
- ESP8266 development board model
- IDE settings (board choice, flash size)
- etc
Contributing
For minor fixes of code and documentation, please go ahead and submit a pull request. A gentle introduction to the process can be found
here
.
Check out the list of issues that are easy to fix —
easy issues pending
. Working on them is a great way to move the project forward.
Larger changes (rewriting parts of existing code from scratch, adding new functions to the core, adding new libraries) should generally be discussed by opening an issue first. PRs with such changes require testing and approval.
Feature branches with lots of small commits (especially titled “oops”, “fix typo”, “forgot to add file”, etc.) should be squashed before opening a pull request. At the same time, please refrain from putting multiple unrelated changes into a single pull request.
License and credits
Arduino IDE is developed and maintained by the Arduino team. The IDE is licensed under GPL.
ESP8266 core includes an xtensa gcc toolchain, which is also under GPL.
Esptool.py was initially created by Fredrik Ahlberg (@themadinventor, @kongo), and is currently maintained by Angus Gratton (@projectgus) under GPL 2.0 license.
Espressif’s NONOS SDK
included in this build is under Espressif MIT License.
ESP8266 core files are licensed under LGPL.
SPI Flash File System (SPIFFS)
written by Peter Andersson is used in this project. It is distributed under the MIT license.
umm_malloc
memory management library written by Ralph Hempel is used in this project. It is distributed under the MIT license.
SoftwareSerial
library and examples written by Peter Lerup. Distributed under LGPL 2.1.
BearSSL
library written by Thomas Pornin, built from
https://github.com/earlephilhower/bearssl-esp8266
, is used in this project. It is distributed under the
MIT License
.
LittleFS
library written by ARM Limited and released under the
BSD 3-clause license
.
uzlib
library written and (c) 2014-2018 Paul Sokolovsky, licensed under the ZLib license (
https://www.zlib.net/zlib_license.html
). uzlib is based on: tinf library by Joergen Ibsen (Deflate decompression); Deflate Static Huffman tree routines by Simon Tatham; LZ77 compressor by Paul Sokolovsky; with library integrated and maintained by Paul Sokolovsky.
Other useful links
Serial Monitor Arduino IDE plugin
Original discussion
here
, quick download
there
.
Arduino core for ESP8266 WiFi chip
Quick links
Arduino on ESP8266
This project brings support for the ESP8266 chip to the Arduino environment. It lets you write sketches, using familiar Arduino functions and libraries, and run them directly on ESP8266, with no external microcontroller required.
ESP8266 Arduino core comes with libraries to communicate over WiFi using TCP and UDP, set up HTTP, mDNS, SSDP, and DNS servers, do OTA updates, use a file system in flash memory, and work with SD cards, servos, SPI and I2C peripherals.
Contents
Installing with Boards Manager
Starting with 1.6.4, Arduino allows installation of third-party platform packages using Boards Manager. We have packages available for Windows, Mac OS, and Linux (32 and 64 bit).
-
Download and install Arduino IDE 1.x or 2.x
- Start Arduino and open the Preferences window
-
Enter
https://arduino.esp8266.com/stable/package_esp8266com_index.json
into the File>Preferences>Additional Boards Manager URLs field of the Arduino IDE. You can add multiple URLs, separating them with commas. - Open Boards Manager from Tools > Board menu and install esp8266 platform (and don’t forget to select your ESP8266 board from Tools > Board menu after installation).
Latest release
Boards manager link:
https://arduino.esp8266.com/stable/package_esp8266com_index.json
Documentation:
https://arduino-esp8266.readthedocs.io/en/3.1.2/
Using git version
Also known as latest git or master branch.
Using PlatformIO
PlatformIO
is an open source ecosystem for IoT
development with a cross-platform build system, a library manager, and full support
for Espressif (ESP8266) development. It works on the following popular host operating systems: macOS, Windows,
Linux 32/64, and Linux ARM (like Raspberry Pi, BeagleBone, CubieBoard).
Building with make
makeEspArduino
is a generic makefile for any ESP8266 Arduino project.
Using make instead of the Arduino IDE makes it easier to do automated and production builds.
Documentation
Documentation for latest development version:
https://arduino-esp8266.readthedocs.io/en/latest/
Issues and support
ESP8266 Community Forum
is a well-established community for questions and answers about Arduino for ESP8266. Stackoverflow is also an alternative. If you need help, have a “How do I…” type question, have a problem with a 3rd party library not hosted in this repo, or just want to discuss how to approach a problem, please ask there.
If you find the forum useful, please consider supporting it with a donation.
If you encounter an issue which you think is a bug in the ESP8266 Arduino Core or the associated libraries, or if you want to propose an enhancement, you are welcome to submit it here on Github:
https://github.com/esp8266/Arduino/issues
.
Please provide as much context as possible, as well as the information requested in the issue template:
- ESP8266 Arduino core version which you are using (you can check it in Boards Manager)
-
your sketch code; please wrap it into a code block, see
Github markdown manual
- when encountering an issue that happens at run time, attach the serial output. Wrap it into a code block, just like the code.
- for issues that happen at compile time, enable verbose compiler output in the IDE preferences, and attach that output (also inside a code block)
- ESP8266 development board model
- IDE settings (board choice, flash size)
- etc
Contributing
For minor fixes of code and documentation, please go ahead and submit a pull request. A gentle introduction to the process can be found
here
.
Check out the list of issues that are easy to fix —
easy issues pending
. Working on them is a great way to move the project forward.
Larger changes (rewriting parts of existing code from scratch, adding new functions to the core, adding new libraries) should generally be discussed by opening an issue first. PRs with such changes require testing and approval.
Feature branches with lots of small commits (especially titled “oops”, “fix typo”, “forgot to add file”, etc.) should be squashed before opening a pull request. At the same time, please refrain from putting multiple unrelated changes into a single pull request.
License and credits
Arduino IDE is developed and maintained by the Arduino team. The IDE is licensed under GPL.
ESP8266 core includes an xtensa gcc toolchain, which is also under GPL.
Esptool.py was initially created by Fredrik Ahlberg (@themadinventor, @kongo), and is currently maintained by Angus Gratton (@projectgus) under GPL 2.0 license.
Espressif’s NONOS SDK
included in this build is under Espressif MIT License.
ESP8266 core files are licensed under LGPL.
SPI Flash File System (SPIFFS)
written by Peter Andersson is used in this project. It is distributed under the MIT license.
umm_malloc
memory management library written by Ralph Hempel is used in this project. It is distributed under the MIT license.
SoftwareSerial
library and examples written by Peter Lerup. Distributed under LGPL 2.1.
BearSSL
library written by Thomas Pornin, built from
https://github.com/earlephilhower/bearssl-esp8266
, is used in this project. It is distributed under the
MIT License
.
LittleFS
library written by ARM Limited and released under the
BSD 3-clause license
.
uzlib
library written and (c) 2014-2018 Paul Sokolovsky, licensed under the ZLib license (
https://www.zlib.net/zlib_license.html
). uzlib is based on: tinf library by Joergen Ibsen (Deflate decompression); Deflate Static Huffman tree routines by Simon Tatham; LZ77 compressor by Paul Sokolovsky; with library integrated and maintained by Paul Sokolovsky.
Other useful links
Serial Monitor Arduino IDE plugin
Original discussion
here
, quick download
there
.
Installing¶
Step 5: Testing the Installation
Once you’ve finished the preceding steps, you are ready to test your first program with your ESP8266! Launch the Arduino IDE. If you disconnected your board, plug it back in.
The ESP8266 Arduino core includes several examples that demonstrate everything from scanning for nearby networks to building a web server. To access the example sketches, navigate to File > Examples > ESP8266.
You will see a selection of example sketches. You can choose any of them to load the sketch into your IDE and begin experimenting.
Let’s upload the most basic sketch of all – Blink! Navigate to File > Examples > ESP8266, and open the Blink sketch.
This sketch uses the on-board LED that most ESP8266 development boards have. This LED is typically connected to digital pin D0, and its number may vary from board to board.
void setup() { pinMode(D0, OUTPUT); } void loop() { digitalWrite(D0, HIGH); delay(500); digitalWrite(D0, LOW); delay(500); }
If everything worked, the on-board LED on your ESP8266 should now be blinking! To execute the sketch, you may need to press the RST button on your ESP8266.
Congratulations! You have just programmed your first ESP8266!
Kết luận
Như vậy, thông qua bài viết trên, các bạn đã hiểu rõ hơn ESP8266 là gì? và esp8266 dùng để làm gì? – nó một module esp8266 mạnh mẽ và được sử dụng rộng rãi trong các ứng dụng IoT. Bên cạnh đó, chúng ta cũng đã được hướng dẫn chi tiết về cách lập trình ESP8266 bằng Arduino IDE, từ cách cài đặt thư viện, đến cách kết nối và nạp code esp8266 nodemcu. Hy vọng những thông tin này sẽ giúp các bạn có thể bắt đầu tìm hiểu và sử dụng ESP8266 cho các dự án của mình một cách dễ dàng và hiệu quả.
Install ESP8266 Add-on in Arduino IDE
To install the ESP8266 board in your Arduino IDE, follow these next instructions:
-
In your Arduino IDE, go to File> Preferences
-
Enter http://arduino.esp8266.com/stable/package_esp8266com_index.json into the “Additional Boards Manager URLs” field as shown in the figure below. Then, click the “OK” button:
Note: if you already have the ESP32 boards URL, you can separate the URLs with a comma as follows:
https://dl.espressif.com/dl/package_esp32_index.json, http://arduino.esp8266.com/stable/package_esp8266com_index.json
-
Open the Boards Manager. Go to Tools > Board > Boards Manager…
-
Search for ESP8266 and press install button for the “ESP8266 by ESP8266 Community“:
-
That’s it. It should be installed after a few seconds.
ESP8266 Example: WiFi Scan
Let’s try to run another ESP8266 example sketch, which demonstrates how to use the ESP8266WiFi library to scan nearby WiFi networks and print the results.
You can find this example under File > Examples > ESP8266WiFi > WiFiScan.
Load the WiFiScan sketch from the example sketches into your Arduino IDE.
#include
void setup() { Serial.begin(115200); Serial.println(F("\nESP8266 WiFi scan example")); // Set WiFi to station mode WiFi.mode(WIFI_STA); // Disconnect from an AP if it was previously connected WiFi.disconnect(); delay(100); } void loop() { String ssid; int32_t rssi; uint8_t encryptionType; uint8_t* bssid; int32_t channel; bool hidden; int scanResult; Serial.println(F("Starting WiFi scan...")); scanResult = WiFi.scanNetworks(/*async=*/false, /*hidden=*/true); if (scanResult == 0) { Serial.println(F("No networks found")); } else if (scanResult > 0) { Serial.printf(PSTR("%d networks found:\n"), scanResult); // Print unsorted scan results for (int8_t i = 0; i < scanResult; i++) { WiFi.getNetworkInfo(i, ssid, encryptionType, rssi, bssid, channel, hidden); Serial.printf(PSTR(" %02d: [CH %02d] [%02X:%02X:%02X:%02X:%02X:%02X] %ddBm %c %c %s\n"), i, channel, bssid[0], bssid[1], bssid[2], bssid[3], bssid[4], bssid[5], rssi, (encryptionType == ENC_TYPE_NONE) ? ' ' : '*', hidden ? 'H' : 'V', ssid.c_str()); delay(0); } } else { Serial.printf(PSTR("WiFi scan error %d"), scanResult); } // Wait a bit before scanning again delay(5000); }
Once you have uploaded the sketch, open the serial monitor at baud rate 115200 and press the RST button on the ESP8266. You should see the SSID, RSSI, WiFi channel, and encryption for each discovered network.
ESP8266 là gì? Hướng dẫn lập trình ESP8266 bằng Arduino IDE
ESP8266 là gì?, ESP Wifi là gì? và ESP8266 dùng để làm gì? là những câu hỏi được rất nhiều bạn mới tiếp cận với ESP8266 hỏi mình, để giải thích cho những câu hỏi trên. Trong bài viết ngày hôm nay, hãy cùng tìm mình hiểu về ESP8266 và hướng dẫn cách lập trình bằng Arduino IDE. Nếu bạn đang quan tâm đến việc phát triển các ứng dụng IoT, đây chắc chắn là một bài viết bạn không nên bỏ qua!
Thư viện ESP8266
ESP8266 arduino là một vi điều khiển phổ biến trong các ứng dụng IoT, nó hỗ trợ Wi-Fi và có thể được lập trình để kết nối với các thiết bị trên internet. Các thư viện ESP8266 cung cấp các hàm để thực hiện các chức năng liên quan đến Wi-Fi, TCP/IP, MQTT và nhiều chức năng khác.
Dưới đây là các thư viện phổ biến cho ESP8266 bao gồm:
- ESP8266WiFi: Thư viện này cung cấp các chức năng để kết nối với mạng Wi-Fi và thực hiện các hoạt động như phát hiện mạng, kết nối đến mạng, ngắt kết nối và kiểm tra kết nối.
- ESP8266HTTPClient: Thư viện này cung cấp các chức năng để thực hiện các yêu cầu HTTP, bao gồm cả GET, POST, PUT, DELETE và PATCH.
- PubSubClient: Thư viện này cung cấp các chức năng để kết nối và giao tiếp với một máy chủ MQTT, cho phép truyền tải dữ liệu giữa ESP8266 và máy chủ.
- ESPAsyncWebServer: Thư viện này cung cấp các chức năng để tạo và quản lý một máy chủ web, cho phép truy cập và điều khiển ESP8266 thông qua trình duyệt web.
- ArduinoJson: Thư viện này cung cấp các chức năng để xử lý JSON, cho phép ESP8266 đọc và ghi dữ liệu dưới định dạng JSON.
- Adafruit MQTT Library: Thư viện này cung cấp các chức năng để kết nối và giao tiếp với một máy chủ MQTT, cho phép truyền tải dữ liệu giữa ESP8266 và máy chủ.
Step 3: Upload DS18b20 Temperature Sensor Data to Thingspeak From Esp8266 (nodemcu)
Hello all in this tutorial you will know how to use Ds18b20 Temperature data to thingspeak.com, you can follow above fritzing circuit diagram to control the Ds18b20 temperature sensor, This sensor follows one wire protocol which means you can connect many sensors as you want to the single pin and access temperature data calling the sensor by address.check the video below on how to work with this sensor and also proof of code working .
There is no much work to get work with this sensor, as there are plenty of example library that already available in the internet which anyone can make use and get started to work with this sensor.
Test the below code to know check whether you can get reading from the temperature sensor with ESP8266 or Nodemcu
if you get any error , make sure you have downloaded library for Ds18b20 Temperature sensor.
copy paste above code to your Arduino IDE and upload to your ESP8266 or Nodemcu if you are not sure about how to do this please check the video about to know how things work, if you don’t know yet to search search on this blog for getting started with Esp8266 in Arduino IDE.
below you can see the code for sending temperature data to thingspeak.com from Esp8266 or Nodemcu to do this you need have thingspeak api key which can get easily by registering to the website.
change SSID and password to your router password and also update the Nodemcu api key.
————————————————————————————————————————–
————————————————————————————————————————–
if you like the above tutorial and if you want try out with cool projects you can also check this link here , that’s the amazon book link where you can use that book to make IoT with Esp8266 or Nodemcu, that books gives you basic coverage on how to do simple things and get yourself started with arduino and goes on developing projects like sending data to webserver and creating a webserver, uploading and controlling data from a webpage, how to interface TFT LCD and I2C devices and many more things can find on the link.
Introduction: Quick Start to Nodemcu (ESP8266) on Arduino IDE
Thanks to the guys those who ported the Esp8266 into Arduino IDE and helping all the arduino users happy to the core. Yes it’s been long time since they did and this post is bit later to thanks the good hearted work by the guys out there.
Lets begin with Installing the Esp8266 support for the Arduino and see how to blink an LED ( the hello world in the electronics )
check out the video to know step by step tutorial on how to get started with our favourite chip Esp8266
Firstly open the Arduino IDEGo to files and click on the preference in the Arduino IDE
copy the below code in the Additional boards Managerhttp://arduino.esp8266.com/stable/package_esp8266com_index.jsonclick OK to close the preference Tab.
After completing the above steps , go to Tools and board, and then select board Manager
Navigate to esp8266 by esp8266 community and install the software for Arduino.
Once all the above process been completed we are read to program our esp8266 with Arduino IDE.
For this example I have used NodeMCU esp8266 and if you are using any other vendor wifi chips or generic wifi module please check with the esp8266 Pin mapping which is very essential to make things works.
The reason why I used D7 pin for this example is , I uploaded the basic blink program that comes with the examples program in the arduino IDE which is connected with 13 pin of arduino. The 13th pin is mapped into D7 pin of NodeMCU.
go to board and select the type of esp8266 you are using. and select the correct COM port to run the program on your esp8266 device.
void setup() { // initialize digital pin 13 as an output. pinMode(13, OUTPUT); }
// the loop function runs over and over again forever void loop() { digitalWrite(13, HIGH); // turn the LED on (HIGH is the voltage level) delay(1000); // wait for a second digitalWrite(13, LOW); // turn the LED off by making the voltage LOW delay(1000); // wait for a second }
upload the program and see the results.
if you like the above tutorial and if you want try out with cool projects you can also check this link here , that’s the amazon book link where you can use that book to make IoT with Esp8266 or Nodemcu, that books gives you basic coverage on how to do simple things and get yourself started with arduino and goes on developing projects like sending data to webserver and creating a webserver, uploading and controlling data from a webpage, how to interface TFT LCD and I2C devices and many more things can find on the link.
Step 2: Control Electrical Devices From User Web Browser Using Esp8266 Nodemcu
Make sure all the devices are connected to the same router, this example doesn’t include a port forwarding function which will not allow us to control the device from outside the home network.
Components that you need for completing this project are very simple, you need to have an esp8266 wifi module and a relay, make sure you buying a 5v relay which very easy to use with esp chips doesn’t require external supply too. we can make use of the Vin pin of the nodemcu or if you are using a generic chip, you need to supply an external 5v to the relay.
For this example project I have used only 2 relay circuit, but the actual program wrote for connecting four relay module.
You can check the above video on how this thing works and how to connect your browser to the ip address returned from esp and all the details are included in this video.
Copy the below arduino code and paste into your Arduino IDE and upload the program to your nodemcu or any other esp devices that you are using, make sure to choose the correct port and device name from the board. also don’t forget to change the SSID and password to your Wi-fi settings.
This program for the esp8266 wrote to return the status of the device , which will in turn notify us with the device state in the browser which will also make the user to know which device has currently turned on or off.
Copy the above code and complete the process. Share and let others know about this tiny chip which can do dozens of magic.
if you like the above tutorial and if you want try out with cool projects you can also check this link here , that’s the amazon book link where you can use that book to make IoT with Esp8266 or Nodemcu, that books gives you basic coverage on how to do simple things and get yourself started with arduino and goes on developing projects like sending data to webserver and creating a webserver, uploading and controlling data from a webpage, how to interface TFT LCD and I2C devices and many more things can find on the link.
Testing the Installation
To test the ESP8266 add-on installation, we’ll upload a simple code that blinks the on-board LED (GPIO 2).
Copy the following code to your Arduino IDE:
/********* Rui Santos Complete project details at https://RandomNerdTutorials.com/vs-code-platformio-ide-esp32-esp8266-arduino/ *********/ #include
#define LED 2 void setup() { // put your setup code here, to run once: Serial.begin(115200); pinMode(LED, OUTPUT); } void loop() { // put your main code here, to run repeatedly: digitalWrite(LED, HIGH); Serial.println("LED is on"); delay(1000); digitalWrite(LED, LOW); Serial.println("LED is off"); delay(1000); }
Uploading the Sketch
On the top drop-down menu, select the “unknown” board. A new window, as shown below, will open.
You should select your ESP8266 board model and the COM port. In our example, we’re using the NodeMCU 1.0 board. Click OK when you’re done.
Now, you just need to click on the Upload button.
After a few seconds, the upload should be complete.
The ESP8266 on-board LED should be blinking every second.
Serial Monitor
You can click on the Serial Monitor icon to open the Serial Monitor tab.
That’s it! You’ve installed the ESP8266 Boards successfully in Arduino IDE 2.0.
ESP8266 là gì?
ESP8266 là một module Wi-Fi với khả năng kết nối Internet và được tích hợp sẵn trên một số board nhúng như NodeMCU, Wemos, và ESP-01. ESP8266 có thể hoạt động như một điểm truy cập (access point), một client kết nối đến một điểm truy cập khác, hoặc cả hai đều được. Nó được sử dụng rộng rãi trong các ứng dụng IoT (Internet of Things) như cảm biến thông minh, hệ thống kiểm soát thiết bị, hoặc các ứng dụng điều khiển từ xa. Module này có giá thành rẻ và rất dễ sử dụng, cùng với đó là khả năng tương thích với nhiều loại vi điều khiển khác nhau.
Using git version¶
This is the suggested installation method for contributors and library developers.
Prerequisites¶
-
Internet connection
-
Arduino IDE 1.x or 2.x (https://www.arduino.cc/en/software)
-
git (https://git-scm.com)
-
Python ≥3.7 (https://python.org)
-
terminal, console, or command prompt (depending on your OS)
-
Uninstalling any core version installed via Board Manager
Instructions – Windows 10¶
-
First, make sure you don’t already have an ESP8266 core version installed using the Board Manager (see above). If you do, uninstall it from the Board Manager before proceeding. It is also advisable to erase the Arduino15 contents.
-
Install git for Windows (if not already; see https://git-scm.com/download/win)
-
Open a command prompt (cmd) and go to Arduino default directory. This is typically the sketchbook directory (usually
C:\Users\{username}\Documents\Arduino
where the environment variable
%USERPROFILE%
usually contains
C:\Users\{username}
) -
Clone this repository into hardware/esp8266com/esp8266 directory.
cd %USERPROFILE%\Documents\Arduino\ if not exist hardware mkdir hardware cd hardware if not exist esp8266com mkdir esp8266com cd esp8266com git clone https://github.com/esp8266/Arduino.git esp8266
You should end up with the following directory structure in
C:\Users\{your username}\Documents\
Arduino | — libraries — hardware | — esp8266com | — esp8266 | — bootloaders — cores — doc — libraries — package — tests — tools — variants — platform.txt — programmers.txt — README.md — boards.txt — LICENSE
-
Initialize submodules to fetch external libraries
cd %USERPROFILE%\Documents\Arduino\hardware\esp8266com\esp8266 git submodule update –init
Not doing this step would cause build failure when attempting to include
SoftwareSerial.h
,
Ethernet.h
, etc. See our .gitmodules file for the full list.
-
Download binary tools
cd tools python3 get.py
-
Restart Arduino
-
If using the Arduino IDE for Visual Studio (https://www.visualmicro.com/), be sure to click Tools – Visual Micro – Rescan Toolchains and Libraries
-
When later updating your local library, goto the esp8266 directory and do a git pull
cd %USERPROFILE%\Documents\Arduino\hardware\esp8266com\esp8266 git status git pull
Note that you could, in theory install in
C:\Program Files (x86)\Arduino\hardware
however this has security implications, not to mention the directory often gets blown away when re-installing Arduino IDE. It does have the benefit (or drawback, depending on your perspective) – of being available to all users on your PC that use Arduino.
Instructions – Other OS¶
-
First, make sure you don’t already have an ESP8266 core version installed using the Board Manager (see above). If you do, uninstall it from the Board Manager before proceeding. It is also advisable to erase the .arduino15 (Linux) or Arduino15 (MacOS) contents.
-
Open the console and go to Arduino directory. This can be either your sketchbook directory (usually
/Arduino
), or the directory of Arduino application itself, the choice is up to you. -
Clone this repository into hardware/esp8266com/esp8266 directory. Alternatively, clone it elsewhere and create a symlink, if your OS supports them.
cd hardware mkdir esp8266com cd esp8266com git clone https://github.com/esp8266/Arduino.git esp8266
You should end up with the following directory structure:
Arduino | — hardware | — esp8266com | — esp8266 | — bootloaders — cores — doc — libraries — package — tests — tools — variants — platform.txt — programmers.txt — README.md — boards.txt — LICENSE
-
Initialize submodules to fetch external libraries
cd esp8266 git submodule update –init
Not doing this step would cause build failure when attempting to include
SoftwareSerial.h
,
Ethernet.h
, etc. See our .gitmodules file for the full list.
-
Download binary tools
cd tools python3 get.py
If you get an error message stating that python3 is not found, you will need to install it (most modern UNIX-like OSes provide Python 3 as part of the default install). To install you will need to use
sudo yum install python3
,
sudo apt install python3
, or
brew install python3
as appropriate. On the Mac you may get an error message like:python3 get.py Platform: x86_64-apple-darwin Downloading python3-macosx-placeholder.tar.gz Traceback (most recent call last): File “/Library/Frameworks/Python.framework/Versions/3.7/lib/python3.7/urllib/request.py”, line 1317, in do_open encode_chunked=req.has_header(‘Transfer-encoding’)) … File “/Library/Frameworks/Python.framework/Versions/3.7/lib/python3.7/ssl.py”, line 1117, in do_handshake self._sslobj.do_handshake() ssl.SSLCertVerificationError: [SSL: CERTIFICATE_VERIFY_FAILED] certificate verify failed: unable to get local issuer certificate (_ssl.c:1056)This is because Homebrew on the Mac does not always install the required SSL certificates by default. Install them manually (adjust the Python 3.7 as needed) with:
cd “/Applications/Python 3.7/” && sudo “./Install Certificates.command”
-
Restart Arduino
-
When later updating your local library, goto the esp8266 directory and do a git pull
cd hardware\esp8266com\esp8266 git status git pull
Maintaining¶
To keep up with the development branch
git switch –recurse-submodules –discard-changes master git pull –recurse-submodules cd tools python3 get.py
Pull requests¶
To test not yet merged Pull Request, first you have to find its ID number. This is the sequence of digits right after the pull request title.
Open terminal and cd into the directory where the repository was previously cloned. For example, 12345 is the Pull Request ID
git fetch origin pull/12345/head git switch –detach –recurse-submodules –discard-changes FETCH_HEAD
When Pull Request updates packaged tools, make sure to also fetch their latest versions.
cd tools python3 get.py
To go back to using the development branch
git switch –recurse-submodules –discard-changes master git pull –recurse-submodules
Step 4: Selecting the Board and Port
After installing the ESP8266 Arduino Core, restart your Arduino IDE and navigate to Tools > Board to ensure you have ESP8266 boards available.
Now select your board in the Tools > Board menu (in our case, it’s the NodeMCU 1.0 (ESP-12E Module)). If you are unsure which board you have, select the Generic ESP8266 Module.
Finally, connect the ESP8266 NodeMCU to your computer and select the Port.
That’s it! You can now begin writing code for your ESP8266 in the Arduino IDE.
You should make sure you always have the most recent version of the ESP8266 Arduino core installed.
Simply navigate to Tools > Board > Boards Manager, search for ESP8266, and verify the version you have installed. If a newer version is available, you should install it.
Testing the Installation
To test the ESP8266 add-on installation, let’s see if we can blink an LED with the ESP8266 using the Arduino programming language.
Parts Required
Here’s the hardware that you need to complete this project:
If you’re using an ESP8266-01, you also need an FTDI programmer to upload code.
You can use the preceding links or go directly to MakerAdvisor.com/tools to find all the parts for your projects at the best price!
Boards Manager¶
This is the suggested installation method for end users.
Prerequisites¶
-
Internet connection
-
Arduino IDE 1.x or 2.x (https://www.arduino.cc/en/software)
-
(macOS/Linux only) Python ≥3.7 (https://python.org)
Instructions¶
-
Start Arduino and open Preferences window.
-
Enter
https://arduino.esp8266.com/stable/package_esp8266com_index.json
into Additional Board Manager URLs field. You can add multiple URLs, separating them with commas. -
Open Boards Manager from Tools > Board menu and find esp8266 platform.
-
Select the version you need from a drop-down box.
-
Click install button.
-
Don’t forget to select your ESP8266 board from Tools > Board menu after installation.
For more information on the Arduino Board Manager, see:
Các phiên bản phổ biến của ESP8266 trên thị trường
Board | Mua hàng |
ESP-01 | Shopee |
ESP-12E | Shopee |
ESP8266 NodeMCU | Shopee |
Wemos D1 Mini | Shopee |
NodeMCU ESP32 | Shopee |
ESP8266 WIFI ESP-01
ESP8266 ESP-01 là một module IoT được thiết kế dựa trên vi điều khiển ESP8266 của công ty Espressif Systems. Đây là phiên bản module nhỏ gọn nhất trong các phiên bản của ESP8266 với kích thước chỉ 24mm x 14mm.
ESP-01 có tích hợp sẵn một bộ phát WiFi, đủ để kết nối với mạng internet và truyền dữ liệu. Module này còn được tích hợp một cổng giao tiếp chuẩn UART, cho phép truyền dữ liệu giữa ESP8266 và các thiết bị khác như Arduino, Raspberry Pi, hoặc máy tính thông qua cổng COM. ESP8266 01 cũng có khả năng lập trình và nạp firmware thông qua cổng UART, giúp cho việc phát triển ứng dụng IoT trở nên đơn giản hơn.
Thông số kỹ thuật của Module Wifi ESP8266 ESP-01:
- Chip Wi-Fi: ESP8266EX
- Nguồn cấp: 3.0V ~ 3.6V DC
-
Tiêu thụ dòng điện:
- Chế độ hoạt động: 80mA ~ 170mA
- Chế độ chờ: < 1.0mA
- Chuẩn giao tiếp: Wi-Fi 802.11 b/g/n
- Tốc độ truyền dữ liệu: 110 ~ 460800bps (tùy chọn)
- Điện áp: 3.3V DC
- Kích thước: 24mm x 14mm x 3mm
- Anten: PCB Anten hoặc IPEX anten ngoài (tùy chọn)
Sơ đồ chân ESP8266 ESP-01
ESP8266 WIFI ESP-12E
ESP-12E là một trong những phiên bản nâng cấp của ESP8266, có tích hợp thêm bộ khuếch đại công suất (PA) và bộ lọc tín hiệu RF (LNA), giúp tăng cường khả năng thu phát sóng Wi-Fi. Ngoài ra, ESP-12E còn tích hợp nhiều chân IO (Input/Output) và hỗ trợ giao tiếp SPI, I2C, UART, ADC, PWM và các tính năng GPIO. Với các tính năng này, ESP8266 12E rất phổ biến trong các ứng dụng IoT và các dự án điện tử thông minh.
Thông số kỹ thuật của Module Wifi ESP-12E
- SoC: ESP8266EX
- CPU: Tensilica L106 32-bit RISC
- Tần số hoạt động: 80 MHz
- Điện áp hoạt động: 3.0 – 3.6 V
- Flash: 4 MB
- SRAM: 80 KB
- WiFi: 802.11 b/g/n 2.4 GHz, hỗ trợ WPA/WPA2
- Anten: PCB anten tích hợp
- GPIO: 16 GPIO được gán số, hỗ trợ chức năng GPIO, PWM, I2C, SPI, ADC
- Kích thước: 24.8 x 14.3 x 3mm
Sơ đồ chân Module Wifi ESP8266-12E
ESP8266 WIFI NodeMCU
ESP8266 NodeMCU là một nền tảng IoT mã nguồn mở, được phát triển bởi một nhóm kỹ sư tại Trung Quốc. Nền tảng này được xây dựng trên ESP8266, một vi điều khiển Wi-Fi SoC (System on a Chip) được sản xuất bởi Espressif Systems. NodeMCU cung cấp một bộ SDK để lập trình cho ESP8266 bằng ngôn ngữ Lua hoặc C++. Với các tính năng như Wi-Fi, GPIO, ADC, I2C, SPI, PWM và một số tính năng khác, NodeMCU ESP 8266 được sử dụng rộng rãi trong các ứng dụng IoT như kiểm soát thiết bị, thu thập dữ liệu và giao tiếp với các thiết bị khác.
Thông số kỹ thuật của NodeMCU
- Microcontroller: ESP8266EX
- Điện áp hoạt động: 3.3V DC
- Số chân I/O: 17 chân GPIO
- Kết nối mạng: WiFi 802.11 b/g/n
- Giao diện mạng: TCP/IP
- Đồng hồ thời gian thực (RTC): không tích hợp
- Bộ nhớ trong: 4MB
- RAM: 80KB
- Cổng nạp: Micro-USB
- Hỗ trợ các giao thức: MQTT, CoAP, HTTP/HTTPS
- Kích thước: 49 x 24.5 x 13mm
Sơ đồ chân ESP8266 NodeMCU
Xem ngay: Sơ đồ chân ESP8266 NodeMCU
Wemos D1 Mini
Wemos D1 Mini là một board phát triển IoT nhỏ gọn, dựa trên module wifi ESP8266EX. Nó được thiết kế để dễ dàng sử dụng và lập trình thông qua cổng micro USB và trình biên dịch Arduino IDE. Wemos D1 Mini có đầy đủ các tính năng cần thiết cho các ứng dụng IoT, bao gồm kết nối wifi, GPIO, ADC, SPI, I2C…, và rất thích hợp cho các dự án DIY IoT.
Thông số kỹ thuật của Wemos D1 Mini:
- MCU: ESP8266EX
- Kích thước: 34.2mm x 25.6mm
- Điện áp hoạt động: 3.3V
- Pin đầu vào tối đa: 3.3V
- Điện áp USB: 5V DC
- Pin đầu ra tối đa: 3.3V/1A
- GPIO: 11 GPIO (đều hỗ trợ PWM, I2C, 1-Wire)
- ADC: 1 (10 bit)
- Tốc độ xung nhịp: 80MHz/160MHz
- Bộ nhớ trong: 4MB
- Wi-Fi: IEEE 802.11 b/g/n
- Kết nối USB: Micro-USB
- Hỗ trợ OTA (Over The Air) để nạp chương trình không cần dây cáp.
Sơ đồ chân Wemos D1 Mini
NodeMCU ESP32
NodeMCU ESP32 là một module IoT (Internet of Things) với khả năng kết nối Wi-Fi và Bluetooth. Nó là phiên bản nâng cấp của ESP8266 với nhiều tính năng mới và cải tiến, bao gồm hai nhân xử lý Tensilica Xtensa LX6, bộ nhớ Flash lên đến 4MB, RAM lên đến 520KB, tốc độ xử lý lên đến 240 MHz và hỗ trợ nhiều giao tiếp như SPI, I2C, UART, CAN và Ethernet. ESP32 được sử dụng rộng rãi trong các ứng dụng IoT, bao gồm điều khiển thiết bị, cảm biến, hệ thống đo lường và giám sát.
Thông số kỹ thuật của NodeMCU ESP32:
- Vi xử lý: Tensilica Xtensa LX6, hai nhân, lên đến 240 MHz
- Bộ nhớ trong: 520 KB SRAM
- Bộ nhớ ngoài: 4MB Flash Memory
- Wi-Fi: 802.11 b/g/n/e/i (2,4 GHz)
- Bluetooth: v4.2 BR/EDR và BLE
- GPIO: 36
- UART, SPI, I2C, I2S, DAC, ADC, PWM, GPIO
- Cổng kết nối: micro USB
- Nguồn điện: 2.2V – 3.6V DC
- Kích thước: 18 x 25.5 mm
Sơ đồ chân của NodeMCU ESP32
Troubleshooting
If you try to upload a new sketch to your ESP8266 and you get this error message “esptool.FatalError: Failed to connect to ESP8266: Timed out waiting for packet header“. It means that your ESP8266 is not in flashing/uploading mode.
Having the right board name and COM port selected, follow these steps:
- Hold-down the “BOOT/FLASH” button in your ESP8266 development board
- Press the “Upload” button in the Arduino IDE to upload your sketch:
- When you see the “Connecting….” message in your Arduino IDE, release the finger from the “BOOT/FLASH” button
- After that, you should see the “Done uploading” message
Your ESP8266 should have the new sketch running. Press the “ENABLE/RESET” button to restart the ESP8266 and run the new uploaded sketch.
Prerequisites: Arduino IDE 2.0 Installed
Before proceeding make sure you have Arduino IDE 2.0 installed on your computer.
Go to the Arduino website and download the version for your operating system.
- Windows: run the file downloaded and follow the instructions in the installation guide.
- Mac OS X: copy the downloaded file into your application folder.
- Linux: extract the downloaded file, and open the arduino-ide file that will launch the IDE.
If you have doubts, you can go to the Arduino Installation Guide.
Do you need an ESP8266 board? You can buy it here.
Recommended reading: Best ESP8266 Boards Comparison
Uploading the Sketch
Uploading the Sketch to the ESP-12E
If you’re using an ESP-12E NodeMCU Kit, uploading the sketch is very simple, since it has built-in programmer. Plug your board to your computer. Make sure you have the right board selected:
You also need to select the Port:
Then, copy the code provided:
/********* Rui Santos Complete project details at https://randomnerdtutorials.com *********/ int pin = 2; void setup() { // initialize GPIO 2 as an output. pinMode(pin, OUTPUT); } // the loop function runs over and over again forever void loop() { digitalWrite(pin, HIGH); // turn the LED on (HIGH is the voltage level) delay(1000); // wait for a second digitalWrite(pin, LOW); // turn the LED off by making the voltage LOW delay(1000); // wait for a second }
Click the “Upload” button in the Arduino IDE and wait a few seconds until you see the message “Done uploading.” in the bottom left corner.
Uploading the Sketch to the ESP-01
Uploading code to the ESP-01 requires establishing a serial communication between your ESP8266 and a FTDI Programmer as shown in the schematic diagram below.
The following table shows the connections you need to make between the ESP8266 and the FTDI programmer.
ESP8266 | FTDI programmer |
RX | TX |
TX | RX |
CH_PD | 3.3V |
GPIO 0 | GND |
VCC | 3.3V |
GND | GND |
If you have a brand new FTDI Programmer and you need to install your FTDI drivers on Windows PC, visit this website for the official drivers: http://www.ftdichip.com/Drivers/VCP.htm.
Then, you just need to connect the FTDI programmer to your computer, and upload the sketch to your ESP8266 board. You should see the “Done Uploading” message after a few seconds.
Step 3: Installing the ESP8266 Arduino Core
Launch the Arduino IDE and navigate to File > Preferences.
Fill in the “Additional Board Manager URLs” field with the following.
http://arduino.esp8266.com/stable/package_esp8266com_index.json
Then, click the “OK” button.
Now navigate to Tools > Board > Boards Manager…
Filter your search by entering ‘esp8266‘. Look for ESP8266 by ESP8266 Community. Click on that entry, and then choose Install.
Step 1: Control an LED From Web Browser
In this blog, we will see How to “Turn On and Turn Off” an LED that has connected to the Esp8266, the esp8266 has programmed from Arduino IDE to control the LED.We will connect the Esp8266 to the Wi-Fi router using SSID and password of our Home network Wifi , where the esp8266 connect to our wifi and create a webserver, which can be accessed by looking through the serial Monitor of the Arduino window or you can also log into your Wifi router and check for the list of clients connected to your Wi-Fi router.Here’s a window which explains the step by step procedure to connect the Esp8266 to the Wi-fi server and How to access the Webpage and control the LED connected to the Esp8266
For the above video I have used NodeMcu, you can use any type of Esp8266 to make this thing work in your web browser.
look for the mapping of pins in with your Esp8266 vendor, if the program not working properly for you , the fault will be with the pin mapping functionalities, Here I used the D7 pin which mapped to 13th pin when program from the Arduino IDE.
Connect your Esp8266 to Arduino IDE and Select the correct COM Port and board type and
upload the program.
Note change the SSID to your WiFi Name and password to your Wifi password. if you forget to change it , esp8266 will not connect connect your wifi.
————————————————————————————————————————–
If everything completed you can turn to your serial monitor and check for the ip address that your devices has connected to . you will presented with an serial monitor that look exactly to the picture below.
if you like the above tutorial and if you want try out with cool projects you can also check this link here , that’s the amazon book link where you can use that book to make IoT with Esp8266 or Nodemcu, that books gives you basic coverage on how to do simple things and get yourself started with arduino and goes on developing projects like sending data to webserver and creating a webserver, uploading and controlling data from a webpage, how to interface TFT LCD and I2C devices and many more things can find on the link.
Install ESP8266 NodeMCU Add-on in Arduino IDE
To install the ESP8266 board in your Arduino IDE, follow these next instructions:
1. In your Arduino IDE 2.0, go to File > Preferences.
2. Copy and paste the following line to the Additional Boards Manager URLs field.
http://arduino.esp8266.com/stable/package_esp8266com_index.json
Note: if you already have the ESP32 boards URL, you can separate the URLs with a comma, as follows:
http://arduino.esp8266.com/stable/package_esp8266com_index.json, https://raw.githubusercontent.com/espressif/arduino-esp32/gh-pages/package_esp32_index.json
3. Open the Boards Manager. You can go to Tools > Board > Boards Manager… or you can simply click the Boards Manager icon in the left-side corner.
4. Search for ESP8266 and press the install button for esp8266 by ESP8266 Community.
That’s it. It should be installed after a few seconds.
Hướng dẫn nạp code cho ESP8266 NodeMCU
Để có thể nạp code cho ESP8266 NodeMCU bạn cần tải phần mềm Arduino IDE về. Thông thường phần mềm mới tải về thì chưa có board esp822 nên các bạn cần làm theo các bước dưới đây.
Bước 1: Mở Arduino IDE lên, click vào File trên thanh công cụ chọn Preferences(Ctrl+Comma).
Bước 2: Copy đường Link bên dưới bỏ vào ô tô màu vàng và nhấn OK là xong.
- Copy Link tại đây: http://arduino.esp8266.com/stable/package_esp8266com_index.json
Bước 3: Vào Tools > Board > Boards Manager
Bước 4: Cửa sổ mở lên ta Seach “Esp8266” để tải danh mục của các Board về. Nhấn Install để tiến hành cài đặt.
Như vậy, là mình vừa xong phần thiết lập cho board, bây giờ các bạn chỉ cần viết code và nhấn Upload chương trình xuống là xong.
Lưu ý: Chọn đúng PORT và Board nhé, ở đây mình dùng ESP822 NodeMCU 1.0 (ESP-12E Module)
Keywords searched by users: esp8266 link for arduino
Categories: Có được 87 Esp8266 Link For Arduino
See more here: kientrucannam.vn
See more: https://kientrucannam.vn/vn/