Registry / networking / tokio-serial

tokio-serial

JSON →
library5.4.5rscratesunverified

A serial port implementation for tokio, enabling async serial communication.

# Cargo.toml [dependencies] tokio-serial = "5.4.5"
INSTALL
IMPORT
SIG · TOKIO-SERIAL
T
tokio-serial
networkingrustv5.4.5
harness data pending
Install & Compatibility
Where this runs

No compatibility data collected yet for this library.

Code
Verified usage

Verified import paths — ran on the pinned version, not inferred.

SerialStream
use tokio_serial::SerialStream;

Open a serial port as an async stream using tokio-serial.

use tokio_serial::SerialStream; #[tokio::main] async fn main() { let port = SerialStream::open("/dev/ttyUSB0").unwrap(); // Use port for async read/write }
Debug
Known issues
gotchaRequires tokio runtime to be active.
fix
Wrap code in #[tokio::main] or manually create a tokio runtime.
affects: >=5.0.0
Upgrade
Version history
5.4.5latest on crates.io
Audit
Dependencies

No dependency data recorded yet.

Agent activity
31 hits · last 30 days
node
26
Amazon
1
OpenAI (training)
1
Resources
tokio-serial — cargo add tokio-serial · libregistry