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.
Supported ICs[ RTL8721F ]
SDK Design
Ameba Rust SDK follows the standard interfaces and conventions of the Rust embedded ecosystem, so drivers and applications written against it interoperate naturally with the broader Rust embedded ecosystem. Underneath these standard interfaces, drivers access hardware through the svd2rust-generated PAC and FFI calls into C functions fixed in chip ROM.
Where ROM FFI is used, it gives deep integration with the Realtek hardware ecosystem and zero
additional Flash usage, at the cost of a small amount of unsafe code.
The whole development flow needs only the Rust toolchain: linking uses rust-lld, and image
packaging and UART flashing are implemented by the SDK’s ameba-flash tool. The prebuilt Bootloader
and Wi-Fi core firmware the application runs alongside ship with the Rust SDK.
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: For operations that call C functions fixed in chip ROM, the linker resolves them directly to fixed addresses at no extra cost.
Wi-Fi support: WHC IPC dual-core communication, STA mode (Open / WPA2-PSK), SoftAP, and an
embassy-netdriver so applications open their own TCP/UDP sockets (DHCP, TCP, UDP, and protocols on top such as MQTT).OTA: Dual-slot (A/B) application update over HTTP, with slot selection and signature verification handled by the Bootloader.
Pure Rust toolchain: Stable Rust only, with packaging and UART flashing done by the SDK’s own
ameba-flashtool.Strict no_std: No heap allocator, and a 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 |
Prebuilt, shipped in the Rust SDK |
Not open for user development |
Wi-Fi core firmware |
Prebuilt, shipped in the Rust SDK |
Not open for user development |
App firmware |
Built by Rust SDK |
Target of Rust development |