This lib aims at providing a simple way to read temperature out of a w1_therm
compatible sensor connected to a linux machine. See the kernel documentation to know which devices are compatibles.
If you want a complete OneWire library, this crate is not the one you're looking for. Maybe Onewire.
It was a way to give nom a try.
This lib as passed the "work for me stage" but it has not been thoroughly tested. This is developed on my free tim and I'm not a seasoned developer. Feel free to create PRs.
``` extern crate w1thermreader; use w1thermreader::{readfromfile, readfromdevice, converttometric};
fn main() { // get the temperature from a file let t = readfromfile("/path/to/w1/").unwrap(); // get the temperature from device let t = readfromfile("10-000001").unwrap(); // get the temperature in °C instead of m°C let tmetric = convertto_metric(t); } ```