Installation instructions are valid for 09-05-2024 Installation procedure are based on Getting Started Guide
Go to official sites and download
- Cmake (3.29.3)
- Python (3.12.3)
- Ninja
winget install Ninja-build.Ninja
- 7-Zip
winget install 7z
- MSYS2
- Install gperf with msys2
pacman -S msys/gperf
- Install dtc with msys2
pacman -S msys/dtc
- Add
C:\msys64\usr\bin
to Environment variable so west can find dtc and gperf later
Commands are supposed to be run in cmd.exe
- Create a new virtual environment:
python -m venv zephyrproject\.venv
- Activate the virtual environment:
zephyrproject\.venv\Scripts\activate.bat
- Install west:
pip install west
- Get the Zephyr source code:
west init zephyrproject
cd zephyrproject
west update
- Export a Zephyr CMake package. This allows CMake to automatically load boilerplate code required for building Zephyr applications.
west zephyr-export
- Zephyr’s scripts\requirements.txt file declares additional Python dependencies.
pip install -r .\zephyrproject\zephyr\scripts\requirements.txt
Download Full SDK bundle from https://github.com/zephyrproject-rtos/sdk-ng/releases/tag/v0.16.6
Extract it in %HOMEPATH% your User home directory - zephyr-sdk-0.16.6
cd zephyr-sdk-0.16.6
setup.cmd
-
Go to
zephyrproject\zephyr
-
Run
west boards
to get the list of all supported boards. For me it's nucleo_l476rg -
Build with
west build -p always -b nucleo_l476rg samples\basic\blinky
west flash