Introduction
Before You Begin
Before installing any toolchain, take ten minutes to verify your system and install the universal prerequisites. Getting this right now saves hours of debugging later.
System Requirements
All guides are tested on the following OS versions. Older versions may work but are not supported.
| OS | Minimum Version | Recommended |
|---|---|---|
| Windows | Windows 10 (64-bit, build 1903+) | Windows 11 22H2+ |
| Ubuntu / Debian | Ubuntu 22.04 LTS | Ubuntu 24.04 LTS |
| macOS | macOS 13 Ventura | macOS 14 Sonoma / 15 Sequoia |
| Raspberry Pi OS | Bullseye (64-bit) | Bookworm (64-bit) |
64-bit required — no exceptions
All toolchains (ESP-IDF, STM32CubeIDE, GCC cross-compilers, TensorFlow Lite) require a 64-bit OS and a 64-bit CPU. A 32-bit system will fail during installation.
Minimum Hardware
| Component | Minimum | Recommended |
|---|---|---|
| CPU | x86-64 or ARM64 | 4+ cores |
| RAM | 4 GB | 8 GB or more |
| Disk space | 10 GB free | 30 GB free (ESP-IDF + STM32 + Docker) |
| USB port | USB-A or USB-C | — |
1. Python 3 (3.13 — Latest Stable)
Python is required by ESP-IDF, esptool, OpenOCD scripts, and all ML/data-science sections. Always install the latest stable release (3.13 as of 2025).
Check what you have
python3 --version
# Target: Python 3.13.x
Install Python 3.13
Ubuntu / Debian / Raspberry Pi OS
# Ubuntu 24.04 ships Python 3.12 by default.
# Add the deadsnakes PPA to get 3.13:
sudo apt update
sudo apt install -y software-properties-common
sudo add-apt-repository ppa:deadsnakes/ppa
sudo apt update
sudo apt install -y python3.13 python3.13-venv python3.13-dev python3-pip
# Make 3.13 the default python3
sudo update-alternatives --install /usr/bin/python3 python3 /usr/bin/python3.13 1
python3 --version # Python 3.13.x
Windows
- Download the latest Python 3.13.x Windows installer (64-bit) from python.org/downloads
- Run the installer
- Tick "Add Python to PATH" before clicking Install — this is the most commonly missed step
- Tick "Install for all users" (recommended)
- Click "Install Now"
Verify in a new terminal (PowerShell or Command Prompt):
python --version
# Python 3.13.x
pip --version
# pip 24.x from C:\...\Python313\...
macOS
# Option A: Homebrew (recommended)
brew install python@3.13
echo 'export PATH="$(brew --prefix python@3.13)/bin:$PATH"' >> ~/.zshrc
source ~/.zshrc
python3 --version # Python 3.13.x
# Option B: Official installer
# Download from python.org/downloads → macOS installer
Virtual Environments (always use one)
Never install project-specific packages into the system Python. Use a virtual environment for every project.
# Create
python3 -m venv .venv
# Activate — Linux / macOS
source .venv/bin/activate
# Activate — Windows PowerShell
.venv\Scripts\Activate.ps1
# Your prompt changes:
# (.venv) $
# Install packages (no sudo needed)
pip install numpy pandas scikit-learn tensorflow
# Save dependencies
pip freeze > requirements.txt
# Deactivate
deactivate
2. Git
Git is required by every toolchain — ESP-IDF, STM32CubeIDE scripts, and the course repositories all use it.
Check what you have
git --version
# git version 2.x.x
Install Git
Ubuntu / Raspberry Pi OS
sudo apt update && sudo apt install -y git git-lfs
git config --global user.name "Your Name"
git config --global user.email "you@example.com"
Windows
Download Git for Windows from git-scm.com. During installation:
- Select "Git from the command line and also from 3rd-party software"
- Select "Use Windows' default console window"
- All other defaults are fine
git --version # git version 2.x.x
macOS
# macOS will auto-prompt to install Xcode Command Line Tools when you run:
git --version
# Click "Install" on the dialog, or run:
xcode-select --install
Essential Git Configuration
Run these once on any new machine:
git config --global user.name "Your Name"
git config --global user.email "you@example.com"
git config --global core.editor "code --wait" # VS Code as default editor
git config --global init.defaultBranch main
git config --global pull.rebase false
# Verify
git config --list
3. USB-to-Serial Drivers
Most ESP32 and some STM32 boards communicate over USB via a dedicated USB-UART bridge chip. You must install the correct driver for your chip.
Identify Your Chip
Look at the small IC near the USB connector on your board:
| Chip | Common Boards | Download |
|---|---|---|
| CP2102 / CP2104 | Most ESP32 DevKit, ESP32-S3 boards | Silicon Labs CP210x |
| CH340 / CH341 | Budget ESP32 clones, Arduino Nano | WCH CH341SER |
| FTDI FT232RL | Older STM32 boards, SparkFun products | FTDI VCP |
| ST-LINK V2/V3 | All STM32 NUCLEO and Discovery boards | Built into STM32CubeIDE |
| USB-C native (JTAG) | ESP32-S3 DevKit-C with native USB | No driver needed — Windows 11 / macOS / Linux auto-detect |
Driver not needed on Linux
Linux kernels 3.x and later include drivers for all common USB-UART chips. On Ubuntu/Raspberry Pi OS, simply plug in the board and run dmesg | tail to see the device name (ttyUSB0, ttyACM0).
4. Verify USB Connection
Windows
- Open Device Manager (right-click Start → Device Manager)
- Expand Ports (COM & LPT)
- Your board appears as
COMx(e.g.,COM3,COM9) - Note the COM number — you will use it in flash commands
Ubuntu / Linux / Raspberry Pi OS
# Before plugging in the board
ls /dev/ttyUSB* /dev/ttyACM* 2>/dev/null
# Plug in the board, then run again — a new entry should appear
ls /dev/ttyUSB* /dev/ttyACM* 2>/dev/null
# /dev/ttyUSB0
# If you get "Permission denied":
sudo usermod -aG dialout $USER
# Log out and back in for the group change to take effect
# Watch the kernel detect the board live:
dmesg | tail -10
# [ 4523.192] cp210x converter now attached to ttyUSB0
macOS
ls /dev/cu.*
# /dev/cu.usbserial-0001 (CP2102/FTDI)
# /dev/cu.SLAB_USBtoUART (CP2104)
# /dev/cu.wchusbserial14310 (CH340)
5. Visual Studio Code
VS Code is the recommended editor across all platforms and all sections of this documentation.
Download: code.visualstudio.com
Install for Ubuntu via snap (easiest)
sudo snap install code --classic
code --version
Install for Ubuntu via apt (official Microsoft repo)
wget -qO- https://packages.microsoft.com/keys/microsoft.asc | gpg --dearmor > packages.microsoft.gpg
sudo install -D -o root -g root -m 644 packages.microsoft.gpg /etc/apt/keyrings/
echo "deb [arch=amd64 signed-by=/etc/apt/keyrings/packages.microsoft.gpg] https://packages.microsoft.com/repos/code stable main" \
| sudo tee /etc/apt/sources.list.d/vscode.list
sudo apt update && sudo apt install -y code
Recommended Extensions
Install these immediately after VS Code is open:
Ctrl+Shift+X → Search and install:
| Extension | Publisher | Purpose |
|---|---|---|
| ESP-IDF | Espressif Systems | ESP32 build, flash, monitor |
| C/C++ | Microsoft | IntelliSense, debugging |
| CMake Tools | Microsoft | CMake project support |
| Python | Microsoft | Python language support |
| Pylance | Microsoft | Fast Python type checking |
| Serial Monitor | Microsoft | Built-in serial terminal |
| GitLens | GitKraken | Enhanced Git history |
| Remote - SSH | Microsoft | SSH into Raspberry Pi from VS Code |
| Docker | Microsoft | Dockerfile and container management |
Install all via terminal
code --install-extension ms-vscode.cpptools
code --install-extension ms-vscode.cmake-tools
code --install-extension espressif.esp-idf-extension
code --install-extension ms-python.python
code --install-extension ms-python.pylance
code --install-extension ms-vscode.serial-monitor
code --install-extension eamodio.gitlens
code --install-extension ms-vscode-remote.remote-ssh
code --install-extension ms-azuretools.vscode-docker
6. Build Tools (All Platforms)
These are needed for compiling C/C++ code locally, building Docker images, and running ESP-IDF.
Ubuntu / Raspberry Pi OS
sudo apt update
sudo apt install -y \
build-essential \
gcc \
g++ \
make \
cmake \
ninja-build \
pkg-config \
libssl-dev \
libffi-dev \
libusb-1.0-0-dev \
gdb \
openocd
macOS
# Install Homebrew if not present
/bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/HEAD/install.sh)"
# Install build tools
brew install cmake ninja gcc openssl libusb pkg-config
Windows
Install via winget (built into Windows 11):
winget install --id Kitware.CMake
winget install --id Ninja-build.Ninja
winget install --id GnuWin32.Make
Or install MSYS2 from msys2.org for a full Linux-like build environment on Windows.
Quick Verification Checklist
Run these in a terminal once everything is set up. Every line should return a version number.
python3 --version # Python 3.13.x
pip --version # pip 24.x
git --version # git 2.x.x
cmake --version # cmake 3.x.x
ninja --version # 1.x.x
gcc --version # gcc x.x.x
code --version # 1.x.x (if VS Code is in PATH)
What's Next?
Choose your platform and jump in:
| Path | Start Here |
|---|---|
| ESP32 firmware on Windows | ESP-IDF Windows Setup |
| ESP32 firmware on Ubuntu | ESP-IDF Ubuntu Setup |
| ESP32 firmware on macOS | ESP-IDF macOS Setup |
| STM32 Nucleo / Discovery | STM32 Windows Setup |
| Raspberry Pi SBC | Flashing the OS |
| Raspberry Pi Pico | Pico Introduction |
| MicroPython | Thonny IDE Setup |
| Docker builds | Why Docker? |

