-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathbme280.js
More file actions
17 lines (17 loc) · 741 Bytes
/
Copy pathbme280.js
File metadata and controls
17 lines (17 loc) · 741 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
const I2C_BME280_SENSOR_ADDR = (0x76);
var multi = new five.Multi({
controller: "BME280",
address: I2C_BME280_SENSOR_ADDR
});
multi.on("change", function () {
console.log("Thermometer:");
console.log(" celsius : ", this.thermometer.celsius);
console.log(" fahrenheit : ", this.thermometer.fahrenheit);
console.log(" kelvin : ", this.thermometer.kelvin);
console.log(" Pressure : ", this.barometer.pressure);
console.log(" Humidity : ", this.hygrometer.relativeHumidity);
console.log("Altimeter");
console.log(" feet : ", this.altimeter.feet);
console.log(" meters : ", this.altimeter.meters);
console.log("--------------------------------------");
});