SDK Introduction

Ameba Rust SDK is Realtek’s official Rust embedded firmware development kit for Ameba series chips. Built on the Embassy async runtime with a no_std design, it targets IoT applications where memory efficiency and type safety are critical.

SDK Design

The Rust SDK is essentially a safe Rust wrapper over C ROM functions, bridged to the Embassy async runtime — not a pure-Rust HAL built from scratch. Low-level hardware operations still rely on C functions fixed in chip ROM, called through FFI.

This design gives deep integration with the Realtek hardware ecosystem and zero additional Flash usage, at the cost of a small amount of unsafe code and a dependency on ameba-rtos prebuilt artifacts.

Key Features

  • Embassy async runtime: Cooperative scheduling with no RTOS thread-switch overhead, well-suited for event-driven applications.

  • embedded-hal 1.0 compatible: GPIO, I2C, SPI, UART, Timer, and other peripherals implement standard traits, enabling reuse of community drivers.

  • Zero-overhead ROM FFI: Low-level hardware operations call C functions fixed in chip ROM; the linker resolves them directly to fixed addresses at no extra cost.

  • WiFi support: WHC IPC dual-core communication + smoltcp network stack, supporting STA mode, DHCP, TCP, and UDP.

  • Strict no_std: No heap allocator; predictable memory footprint suitable for SRAM-constrained targets.

Firmware Composition

A complete Ameba firmware image consists of three components. Only the App firmware is open for development through the Rust SDK:

Firmware

Source

Description

Bootloader firmware

ameba-rtos prebuilt

Not open for user development

WiFi core firmware

ameba-rtos prebuilt

Not open for user development

App firmware

Built by Rust SDK

Target of Rust development

Supported Chips

Chip

Description

RTL8721F (AmebaGreen2)

Currently supported. Dual-core Cortex-M33; AP core runs the Rust App firmware.