Skip to content

Getting started guide for Windows environment

Zhiyuan edited this page Oct 30, 2025 · 13 revisions

Zephyr supports command-line development environment on Ubuntu, macOS and Windows. This page will introduce how to get started quickly with command-line on Windows using Realtek's evaluation board. Specifically, it includes:

  1. How to set-up the Zephyr command-line development environment on Windows.

  2. How to cross-compile and generate the Zephyr binary image.

  3. How to download images into Realtek's evaluation board and test if you are running to the Zephyr application.

Prerequisites

J-Link Setup

Since "west flash" command on Realtek Bee Series SoCs is relying on the J-Link, so it is important to setup J-Link correctly. Please refer to J-Link Setup Guide for a step-by-step instruction.

Install dependencies

Please follow the steps in Install dependencies. Make sure you have installed all the dependencies:

Tool Min. Version
CMake 3.20.5
Python 3.10
Devicetree compiler 1.4.6
Ninja /
Gperf /
Git /
wget /
7zip /

Note: You can use the --version flag to verify installation and versions. For example, use python --version to check whether the version meets the requirements.

Get Realtek Zephyr Package

Most of the steps in the Get Zephyr and install Python dependencies can be referenced and followed except the step "Get the Zephyr source code". Please use the following instructions instead of the steps on "Get the Zephyr source code" in the Zephyr official getting-started guide.

west init -m https://github.com/rtkconnectivity/realtek-zephyr-project zephyrproject
cd zephyrproject
west update

Unlike downloading the entire official Zephyr package, these three steps help you to fetch the Realtek Zephyr Package — which already contains Realtek SoC support—and import the required modules.

Install a toolchain

The Zephyr Software Development Kit (SDK) contains toolchains for each of Zephyr's supported architectures, which include a compiler, assembler, linker and other programs required to build Zephyr applications. Follow the instructions in Install the Zephyr SDK to install the toolchain.

Note: Make sure that the Zephyr SDK version you have installed is compatible with Zephyr v3.7. For the full list of compatible Zephyr and Zephyr SDK versions, refer to the Zephyr SDK Version Compatibility Matrix.

Build a Zephyr Sample

After installing the dependencies, fetching the Realtek Zephyr package, and setting up the toolchain, try building a Zephyr sample to verify that everything is configured correctly.

  • For board rtl87x2g_evb

    west build -b rtl87x2g_evb samples/hello_world

  • For board rtl8752h_evb/rtl8752htv

    west build -b rtl8752h_evb/rtl8752htv samples/hello_world

  • For board rtl8752h_dongle

    west build -b rtl8752h_dongle samples/hello_world

Then, the target files zephyr.bin & zephyr.hex will be generated in build/zephyr folder.

Image Download and Execution

Download Realtek images

Before burning the Zephyr image into flash, you need to burn some essential images released by Realtek to make the SoC work normally.

Image Function RTL87x2G RTL8752H
System Config It is used to configure various parameters and settings related to the device, such as the Bluetooth address, the number of links, and other relevant configurations. It is generated by MPTool. ✔️ ✔️
OTA Header It defines Flash Bank layout, which is generated by MPTool. ✔️ ✔️
Boot Patch It ensures the security and integrity of the system startup process through verification and encryption technologies. ✔️ ✔️ (named as FSBL, Flash Secure Bootloader)
System Patch The ROM code reserves the Patch function entry point, which allows modifications to the behavior of the ROM code and the expansion of ROM code functionality. ✔️ ✔️
BT Stack Patch It supports features related to the BT Controller stack. ✔️ ✔️

MPTool developed by Realtek is recommended to download these essential images.

Hardware Connection for MPTool Download and its method, please refer to:

  1. RTL87X2G (EVB model A)
  2. RTL8752H EVB
  3. RTL8752H Dongle (WIP)

Note: You can find the default images in the bin folder of the realtek-zephyr-project repo.

Download Zephyr image

For Zephyr image, we recommend to use "west flash" command. "west flash" is a built-in command in zephyr. To use "west flash", you need to configure J-Link and connect the CPU to J-Link. Please refer to J-Link Setup.

Make sure you have correctly configured J-link and connected CPU with J-Link.

Hardware connection for J-Link downloading, please refer to:

  1. RTL87X2G (EVB model A)
  2. RTL8752H EVB
  3. RTL8752H Dongle (WIP)

Then, you can use the command to flash the Zephyr image to the board:

west flash

View Zephyr log

To view the log printed by Zephyr, connect a serial host tool to device's UART.

SoC Default Log UART Tx Pin Rx Pin Baudrate
RTL87X2G UART2 P3_2 P3_3 2000000
RTL8752H UART2 P3_0 P3_1 2000000

Press the reset key, then you will see:

***** Booting Zephyr OS build xxxx *****

Hello World! rtl87x2g_evb

If you see these logs, then congratulations!

Reference

  1. RTL87x2G Online Document
  2. RTL8752H Online Document

Appendix