Getting Started
This page walks you from a fresh clone to a running Alp SDK example. If you already have a Zephyr toolchain, jump to step 3.
Pick whichever fits your workflow:
- Hand-written firmware — write C against
<alp/...>headers directly. The path covered below. - alp-studio codegen — drag-and-drop blocks; Studio emits the same
<alp/...>API. See alp-studio.
The flow at a glance:
Prerequisites
The SDK is supported equally on Linux, macOS, and Windows (native PowerShell or WSL2). Tooling versions are identical across hosts.
| Tool | Version | Notes |
|---|---|---|
| Zephyr | v4.4.0 | Pinned by the SDK's west.yml. |
| Python | 3.10+ | For west, the board.yaml loader, validators. |
| Python deps | pyyaml, jsonschema, imgtool | Installed by scripts/bootstrap.sh. |
| CMake | 3.20+ | find_package(Zephyr) minimum. |
| C compiler | GCC 11+ / Clang 14+ | native_sim builds; cross-toolchain for real silicon. |
| west | 1.2+ | pip install west if your distro doesn't ship it. |
Per-platform install one-liners:
- macOS
- Linux
- Windows (PowerShell)
- Windows (WSL2)
brew install cmake ninja python git
pip3 install west
sudo apt install -y cmake ninja-build python3 python3-pip git
pip3 install west
winget install -e --id Kitware.CMake
winget install -e --id Ninja-build.Ninja
winget install -e --id Python.Python.3.12
pip install west
wsl --install -d Ubuntu
Then follow the Linux tab inside your Ubuntu shell.
For real-silicon builds you'll also need the Zephyr SDK (zephyr-sdk-0.17.0) and a JTAG/SWD probe.
Step 1 — Clone and bootstrap
git clone https://github.com/alplabai/alp-sdk
cd alp-sdk
bash scripts/bootstrap.sh
source ../zephyrproject/.venv/bin/activate
export ZEPHYR_BASE="$PWD/../zephyrproject/zephyr"
scripts/bootstrap.sh creates a Zephyr workspace next to alp-sdk/, runs west update --narrow, installs west + the SDK's Python deps and an editable alp CLI into a workspace venv (zephyrproject/.venv — your system Python is never touched), and prints host-specific hints for the optional native libraries the Yocto backends need. It's idempotent, and it reuses an existing $ZEPHYR_BASE workspace when it's a compatible v4.4.x tree.
On native Windows, run the PowerShell-7+ companion instead — it lays down the same workspace + venv + editable alp CLI:
git clone https://github.com/alplabai/alp-sdk
cd alp-sdk
pwsh scripts\bootstrap.ps1
& ..\zephyrproject\.venv\Scripts\Activate.ps1
$env:ZEPHYR_BASE = "$PWD\..\zephyrproject\zephyr"
bootstrap.ps1 won't install git / CMake / Python / Ninja for you (it prints the matching winget install line and exits if one is missing) and leaves the Arm toolchain + Zephyr SDK as manual installs. native_sim isn't available on native Windows — use WSL2 for the simulator + Yocto halves. See Installation for the full walkthrough.
Step 2 — Set up the Zephyr workspace (alternative)
If you'd rather drive west directly:
mkdir alp-workspace && cd alp-workspace
west init -m https://github.com/alplabai/alp-sdk
west update --narrow -o=--depth=1
west zephyr-export
After this the workspace contains zephyr/, the standard Zephyr modules, and alp-sdk/ mounted as a Zephyr module.
Step 3 — Build the GPIO example
The alp CLI is the single front door — from inside a project it finds board.yaml, builds every core, and (on native_sim) runs the result in one step:
cd alp-sdk/examples/peripheral-io/gpio-button-led
alp run # build for native_sim + execute
Prefer driving west directly? The same build, spelled out:
cd alp-workspace
west alp-build -b native_sim/native/64 alp-sdk/examples/peripheral-io/gpio-button-led
west build -d build -t run
Expected output:
*** Booting Zephyr OS build v4.4.0 ***
[gpio] init button=BOARD_PIN_ENCODER_SW, led=BOARD_PIN_LED_RED
[gpio] led=0 status=0
[gpio] led=1 status=0
...
[gpio] done
Either front door validates the example's board.yaml, generates alp.conf + the build-time <alp_hw_info_build.h> companion header, and delegates to west build. See the board.yaml reference for the schema.
Step 4 — Target real hardware
For an Alp Lab EVK (or your own board), the alp front door builds every core from the project's board.yaml and programs the whole system over its registered flash backends:
cd alp-sdk/examples/peripheral-io/gpio-button-led
alp build && alp flash
Driving west directly instead — swap the board flag per family:
# AEN family on the E1M EVK
west alp-build -b alp_e1m_evk_aen alp-sdk/examples/peripheral-io/gpio-button-led
west flash
# V2N family on the E1M-X EVK
west alp-build -b alp_e1m_evk_v2n alp-sdk/examples/v2n/v2n-gd32-bridge-ping
west flash
Board files live in alplabai/alp-zephyr-modules; they are pulled in automatically by west update.
To order an Alp Lab EVK, request a dev kit.
What next?
- Firmware Quickstart — patterns per SoM family (PMICs, RTC, Ethernet PHYs, DEEPX, GD32 bridge)
board.yaml— single declarative project config- API reference — every
<alp/*.h>library - Examples catalogue — minimal apps, one per peripheral class
- VS Code extension — schema-aware editing, GUI configurator, west wrappers