Flutter FFI 与 Rust 进阶实战
当我们需要在 Flutter 中引入高性能、内存安全且具备强大异步生态的语言时,Rust 成了最佳选择。本文将从最简单的同步调用出发,逐步深入到基于 Tokio 的完整异步 Runtime 架构,通过多种不同的 Flutter-Rust FFI 交互模式进行深度对比与性能测试。 ...
当我们需要在 Flutter 中引入高性能、内存安全且具备强大异步生态的语言时,Rust 成了最佳选择。本文将从最简单的同步调用出发,逐步深入到基于 Tokio 的完整异步 Runtime 架构,通过多种不同的 Flutter-Rust FFI 交互模式进行深度对比与性能测试。 ...
Most serial port libraries in Rust are synchronous and blocking — fine for scripts, but not for a real-time system where you need to read and react to serial data with sub-millisecond latency. This post walks through how cycbox-serialport wraps a patched fork of serialport-rs to expose a proper tokio::io::AsyncRead / AsyncWrite interface, with platform-native async I/O on both POSIX and Windows. ...