Blinkt
Blinkt is a Rust library that provides an interface for the Pimoroni Blinkt!, and any similar APA102 strips or boards, on a Raspberry Pi.
Blinkt accesses the BCM2708/BCM2709 GPIO peripheral either through /dev/gpiomem
(preferred) or /dev/mem
. Both the original APA102, and the alternate version with a smaller, darker die, are supported. The APA102 RGB LED/driver ICs are referred to as pixels throughout the code and documentation.
Documentation
All documentation can be found at doc.golemparts.com/blinkt.
Usage
Add a dependency for blinkt
to your Cargo.toml
.
[]
= "0.1"
Link and import blinkt
from your crate root.
extern crate blinkt;
Call Blinkt::new()
to create a new Blinkt with the default settings. In production code, you'll want to parse the result rather than unwrap it.
use Blinkt;
let mut blinkt = new.unwrap;
Example
extern crate blinkt;
use ;
use Duration;
use Blinkt;
Copyright and license
Copyright (c) 2016 Rene van der Meer. Released under the MIT license.