UNPKG

johnny-five-electron

Version:

Temporary fork to support Electron (to be deprecated)

17 lines (13 loc) 373 B
var five = require("../lib/johnny-five"); five.Board().on("ready", function() { var temperature = new five.Temperature({ controller: "LM35", pin: "A0" }); temperature.on("data", function() { console.log(this.celsius + "°C", this.fahrenheit + "°F"); }); }); // @markdown // - [LM35 - Temperature Sensor](http://www.ti.com/product/lm35) // @markdown