simple/
simple.rs

1extern crate sensors;
2
3use sensors::Sensors;
4
5fn main() {
6	let sensors = Sensors::new();
7	for chip in sensors {
8		println!(
9			"{} (on {})",
10			chip.get_name().unwrap(),
11			chip.bus().get_adapter_name().unwrap()
12		);
13		for feature in chip {
14			println!("  - {}", feature.get_label().unwrap());
15			for subfeature in feature {
16				println!(
17					"    - {} = {}",
18					subfeature.name(),
19					subfeature.get_value().unwrap()
20				);
21			}
22		}
23	}
24}