https://github.com/rust-embedded-community/sensehat-rs
Rust support for the Raspberry Pi Sense Hat
https://github.com/rust-embedded-community/sensehat-rs
Last synced: 4 months ago
JSON representation
Rust support for the Raspberry Pi Sense Hat
- Host: GitHub
- URL: https://github.com/rust-embedded-community/sensehat-rs
- Owner: rust-embedded-community
- License: other
- Created: 2017-02-17T22:28:12.000Z (over 9 years ago)
- Default Branch: master
- Last Pushed: 2024-11-23T19:04:47.000Z (over 1 year ago)
- Last Synced: 2026-01-14T11:39:32.349Z (5 months ago)
- Language: Rust
- Size: 64.5 KB
- Stars: 30
- Watchers: 4
- Forks: 16
- Open Issues: 7
-
Metadata Files:
- Readme: README.md
- License: LICENSE-APACHE
Awesome Lists containing this project
README
# sensehat-rs
Rust support for the [Raspberry Pi Sense
HAT](https://www.raspberrypi.org/products/sense-hat/). The Sense HAT is a
sensor board for the Raspberry Pi. It features an LED matrix, a humidity and
temperature sensor, a pressure and temperature sensor, a joystick and a
gyroscope. See for details
on the Sense HAT.
See for the official Python driver. This one tries to follow the same API as the Python version.
See for some workshop materials which use this driver.
## Supported components:
* Humidity and Temperature Sensor (an HTS221)
* Pressure and Temperature Sensor (a LPS25H)
* Gyroscope (an LSM9DS1, requires the RTIMU library)
* LED matrix (partial support for scrolling text only)
## Currently unsupported components:
* Joystick
## Example use
```
use sensehat::{Colour, SenseHat};
if let Ok(mut hat) = SenseHat::new() {
println!("{:?}", hat.get_pressure());
hat.text("Hi!", Colour::RED, Colour::WHITE);
}
```