finds.dev

rust-embedded/rust-sysfs-gpio

A Rust Interface to the Linux sysfs GPIO interface (https://www.kernel.org/doc/Documentation/gpio/sysfs.txt)

View on GitHub

★ 397RustApache-2.0updated Feb 2026

// the take

A Rust wrapper around the Linux sysfs GPIO interface — the old `/sys/class/gpio` kernel API for controlling pins from userspace. Targets embedded Linux boards like Raspberry Pi and BeagleBone. Small, focused, and backed by the rust-embedded working group.

Async support via both mio and Tokio is a genuine differentiator — interrupt-driven GPIO without busy-waiting is exactly what you want for battery-constrained or event-driven hardware. The `with_exported` RAII pattern handles pin cleanup automatically, which prevents the common bug of leaving exported GPIO state behind after a crash. Active CI with MSRV guarantees (1.84+) means it won't silently break your cross-compile toolchain. Dual Apache/MIT licensing is the pragmatic embedded choice.

This wraps a kernel interface that has been officially deprecated since Linux 4.8 in favor of the character device API (`/dev/gpiochipN` via libgpiod). Sysfs GPIO is still present in most kernels but is on borrowed time — new SoC drivers are not required to implement it. Active-low pin configuration is still listed as unimplemented in the feature checklist, which is a real gap for anyone using open-drain or inverted-logic hardware. At 397 stars and a fairly thin codebase, the blast radius of maintainer attrition is high — if the rust-embedded Embedded Linux team moves focus, this crate could go stale quickly.

We read the README, the directory tree and a key source file in June 2026. Nobody pays to be listed. How we judge →

// at a glance

Stars
397
Forks
47
Language
Rust
License
Apache-2.0
Last commit
20 Feb 2026

// nearby

If rust-sysfs-gpio isn't quite it.

All repos →