johnny-five
Version:
The JavaScript Robotics and Hardware Programming Framework. Use with: Arduino (all models), Electric Imp, Beagle Bone, Intel Galileo & Edison, Linino One, Pinoccio, pcDuino3, Raspberry Pi, Particle/Spark Core & Photon, Tessel 2, TI Launchpad and more!
26 lines (22 loc) • 433 B
JavaScript
var five = require("../lib/johnny-five.js");
five.Board().on("ready", function() {
// Create a new `IR.Reflect` hardware instance.
//
// five.IR.Reflect();
//
// (Alias of:
// new five.IR({
// device: "QRE1113GR",
// freq: 50
// });
// )
//
var ir = new five.IR.Reflect();
// "data"
//
// Fires continuously, every 66ms.
//
ir.on("data", function() {
console.log("data");
});
});