Last active
July 30, 2019 03:50
-
-
Save ajfisher/c97b65be9c3b0cefeaf0d91c7bd68e06 to your computer and use it in GitHub Desktop.
BT LED Blinker
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Ensure that you've done npm install johnny-five before you run this. | |
const five = require('johnny-five'); | |
const board = new five.Board({port: process.argv[2]}); | |
board.on("ready", function() { | |
// Create a standard `led` component instance | |
var led = new five.Led(13); | |
// "blink" the led in 500ms | |
// on-off phase periods | |
led.blink(500); | |
}); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment