Installing ESP-IDF

Detailed installation instructions can be found on the project website: ESP-IDF Installation for Linux and macOS.

Below is a brief instruction on how to install ESP-IDF on Ubuntu Linux.

Setting Dependencies

Install additional packages required for ESP-IDF to work:

sudo apt-get install git wget flex bison gperf python3 python3-venv cmake ninja-build ccache libffi-dev libssl-dev dfu-util libusb-1.0-0

Loading ESP-IDF

Download the ISP-IDF source code:

mkdir -p ~/esp
cd ~/esp
git clone --recursive https://github.com/espressif/esp-idf.git

Tool kit installation

Install in the ISP-IDF the necessary set of tools (compiler, debugger, libraries, etc.) needed to build projects for a specific microcontroller (in this example - ESP32 microcontroller):

cd ~/esp/esp-idf
./install.sh esp32

Setting up environment variables

Configure the environment variables necessary for ESP-IDF to work:

. $HOME/esp/esp-idf/export.sh

Setting up environment variables must be done in each terminal in which the project will be built under ESP-IDF.