Assignment 1: Installing Visual Studio Code and ESP-IDF Plugin
To be able to handle all tasks in this workshop, you will need Visual Studio Code and the installed ESP-IDF framework. The first task will therefore be to install all the necessary tools.
In both cases, we will follow the instructions on the GitHub pages of the ESP-IDF plugin for VS Code.
Installation for Windows
- Install Visual Studio Code
- Install the necessary drivers
- In VS Code, open Extensions (Ctrl + Shift + X or ⇧ + ⌘ + X)
- Find the ESP-IDF plugin and install it
- Open View -> Command Palette (Ctrl + Shift + P or ⇧ + ⌘ + P) and type Configure ESP-IDF Extension in the newly opened line
- Select the Express option and then select Github as download server and release/v5.5 as ESP-IDF version
- Click “Install”
Installation for Linux and Mac
- Install Visual Studio Code
- Install prerequisites according to your distribution (Only step 1, the entire guide deals with installing standalone ESP-IDF, which we don’t need right now)
- In VS Code, open Extensions (Ctrl + Shift + X or ⇧ + ⌘ + X)
- Find the ESP-IDF plugin and install it
- Open View -> Command Palette (Ctrl + Shift + P or ⇧ + ⌘ + P) and type Configure ESP-IDF Extension in the newly opened line
- Select the Express option and then select Github as download server and release/v5.5 as ESP-IDF version
- Click “Install”
Installing ESP BLE Prov
During one of the tasks, we will also try Wi-Fi provisioning. For this we will need an application through which we will tell our ESP chip the SSID and password for the network.
You can either search for the app in the app store of the respective system, or through the links below:
- Android: ESP BLE Provisioning
- iOS: ESP BLE Provisioning
VSCode, ESP-IDF plugin and ESP-IDF itself
You now have both the ESP-IDF plugin and ESP-IDF itself installed. How do these two things actually relate?
ESP-IDF is a standalone framework that can be used without VSCode and plugin. It is controlled from the command line (so it has no GUI) and contains all the logic for building, flashing and monitoring the application. So when you press e.g. the Build button in ESP-IDF Explorer (don’t worry, we’ll explain what that means in the next lessons), the idf.py build command is called in the end.
The ESP-IDF plugin is a wrapper/adapter that makes ESP-IDF functionality available in VSCode. In other words, it connects VSCode and the ESP-IDF framework: it creates a GUI in the form of ESP-IDF Explorer and at the same time ensures that the buttons perform their function, the output of commands is correctly displayed in VSCode, that the framework configuration is correctly reflected and so on. However, it needs the framework that runs in the background to function.
You should now have a working ESP-IDF plugin for VSCode and ESP-IDF set up. So we can start with the second part of the tutorial: