Rust is being used in a DIY robotics project to control a graduation cap's LED display and motorized movement. The project leverages Rust's memory safety guarantees and concurrency features, utilizing the Tokio runtime and async-std library to achieve real-time, low-latency system performance.
Overview
The project involves a Digispark ATtiny85, 48 WS2812B LEDs, wires, a reed switch, and a magnet to detect tassel movement, as well as a USB-C Power Delivery trigger board and a power bank. The code was written in Rust and took about 2 hours to complete, with the hardware side taking around 3+ hours.
What it does
The project detects when the tassel is moved away and lights up the bottom-side of the cap. The code is available on GitHub at https://github.com/ericswpark/gradcap-rs. The project's use of Rust highlights the language's growing adoption in the embedded systems and robotics communities.
Tradeoffs
The project's creator notes that using Rust and the ATtiny85 board presented some challenges, including the need to fork and patch the avr-hal and ws2812-avr libraries to support the board. However, the creator was committed to using Rust and the ATtiny85 board to achieve the desired outcome.
The creator has decided not to wear the cap to their graduation, citing its tacky appearance. The project demonstrates the potential of Rust in real-time, low-latency systems and its growing adoption in the embedded systems and robotics communities.
In practical terms, this project shows that Rust can be used to create complex, interactive systems with a relatively small amount of code and hardware. Developers interested in exploring Rust's capabilities in embedded systems and robotics can learn from this project and its use of the Tokio runtime and async-std library. By leveraging Rust's memory safety guarantees and concurrency features, developers can create reliable and efficient systems for a wide range of applications.
{ "headline": "Rust Powers DIY Graduation Cap Project", "synthesis": "Rust is being used in a DIY robotics project to control a graduation cap's LED display and motorized movement. The project leverages Rust's memory safety guarantees and concurrency features, utilizing the Tokio runtime and async-std library to achieve real-time, low-latency system performance. The project involves a Digispark ATtiny85, 48 WS2812B LEDs, wires, a reed switch, and a magnet to detect tassel movement, as well as a USB-C Power Delivery trigger board and a power bank. The code was written in Rust and took about 2 hours to complete, with the hardware side taking around 3+ hours. The project detects when the tassel is moved away and lights up the bottom-side of the cap. The code is available on GitHub at https://github.com/ericswpark/gradcap-rs. The project's use of Rust highlights the language's growing adoption in the embedded systems and robotics communities. The project's creator notes that using Rust and the ATtiny85 board presented some challenges, including the need to fork and patch the avr-hal and ws2812-avr libraries to support the board. However, the creator was committed to using Rust and the ATtiny85 board to achieve the desired outcome. The creator has decided not to wear the cap to their graduation, citing its tacky appearance. The project demonstrates the potential of Rust in real-time, low-latency systems and its growing adoption in the embedded systems and robotics communities. In practical terms, this project shows that Rust can be used to create complex, interactive systems with a relatively small amount of code and hardware. Developers interested in exploring Rust's capabilities in embedded systems and robotics can learn from this project and its use of the Tokio runtime and async-std library. By leveraging Rust's memory safety guarantees and concurrency features, developers can create reliable and efficient systems for a wide range of applications.", "tags": ["Rust", "DIY", "Robotics"], "sources_used": ["https://ericswpark.com/blog/2026/2026-05-12-my-graduation-cap-runs-rust/"]