Skip to content

Instantly share code, notes, and snippets.

Last active February 23, 2023 05:35
What would you like to do?
ESP-IDF on Ubuntu 20.04.1

ESP-IDF on Ubuntu 20.04.1

This is commands used in youtube video

How to setup ESP-IDF on Ubuntu 20.04.1


sudo apt update && sudo apt upgrade -y
sudo update-alternatives --install /usr/bin/python python /usr/bin/python3 1
sudo apt install -y python3-pip
sudo update-alternatives --install /usr/bin/pip pip /usr/bin/pip3 1
sudo apt install -y git wget flex bison gperf python-setuptools cmake ninja-build ccache libffi-dev libssl-dev dfu-util
cd ~
mkdir esp
cd esp
git clone --recursive
cd esp-idf
. ./
pip install --upgrade pip
. ./
nano ~/.profile

Append next line to ~/.profile script:

. $HOME/esp/esp-idf/

To save press CTRL+X, Y, ENTER

sudo usermod -a -G dialout,tty $USER

Restart machine. If you are on virtual machine then shutdown completely and start it again.

ls /dev/ttyUSB*
cd ~/Desktop
cp -r $IDF_PATH/examples/get-started/hello_world .
cd hello_world set-target esp32 menuconfig build

Put ESP32 into programming mode. -p /dev/ttyUSB0 flash monitor

To exit monitor press CTRL+]

Copy link

kampi0 commented Oct 23, 2022

Amazing video - thanks a lot.

I want to share what was not working in my case:
. ./ causing terminal crash, works with
chmod +x
flashing return error related, the solution was pressing BOOT button and executing -p /dev/ttyUSB0 flash
and monitor return error, works with monitor -p /dev/ttyUSB0

issues are probably related to my setup (Ubuntu VM on Parallels + ES-WROOM-32)

Copy link

abobija commented Oct 23, 2022

Thank you @kampi0

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment