Expand description
Rust version of access to adafruit MPR121 capacitive touch sensor HAT under Linux. Completely inspired by this and that original adafruit repos. It only works with 12 input touch, numbered from 0 to 11 product info.
Default initialization:
use adafruit_mpr121::Mpr121;
let mut touch_sensor = Mpr121::new_default(1).expect("Failed to initialize sensor");
let status = touch_sensor.touch_status().unwrap();
println!("Touch status: {}", status);
Structs§
- Mpr121
- Manages adafruit MPR121 capacitive sensor HAT I2C device.
- Mpr121
Touch Status - Touch status for all pins
- Mpr121
Touch Status Iterator - Convenient iterator for pins in
Mpr121TouchStatus
Constants§
- MPR121_
I2CADDR_ DEFAULT - Default I2C address for MPR121
- MPR121_
RELEASE_ THRESHOLD_ DEFAULT - Default release threshold set for MPR121
- MPR121_
TOUCH_ THRESHOLD_ DEFAULT - Default touch threshold set for MPR121
Type Aliases§
- Mpr121
Error - Basic error type, mostly I2C errors