1.0.3 • Published 8 years ago
rpi-temp
Licence
ISC
Version
1.0.3
Deps
0
Size
3 kB
Vulns
0
Weekly
0
Rpi-Temp
Install
$ npm i rpi-temp
Description
Get Temperature of CPU in Celsius, Fahrenheit or Kelvin
API
| Functions | Arguments |
|---|---|
| getCelsius() | callback(err, stdoutpu, stderror), decimal INT |
| getFahrenheit() | callback(err, stdoutput, stderror), decimal INT |
| getKelvin() | callback(err, stdoutput, stderror), decimal INT |
How to use
var rpiTemp = require('rpi-temp');
//callback method
rpiTemp.getCelsuis(function(error,output,stderr){
console.log(output + " C");
})
//specify decimal
rpiTemp.getCelsuis(function(error,output,stderr){
console.log(output + " C");
}, 2);