@danielr1996/led-lib
v1.0.1
Published
A node library to control RGB leds
Downloads
3
Readme
led-lib
led-lib is node.js library to control RGB leds
Usage
- led-lib depends on the pigpio C library which should be installed on most raspberry pis, if it is not installed follow the installation instructions at https://github.com/fivdi/pigpio#installation
- install with npm install @danielr1996/led.lib
- Example Usage:
//import the library
const led = require('@danielr1996/led-lib');
//Initialize the library with port 7 for the red pin, port 8 for the green pin and port 25 for the blue pin
led.init(7, 8, 25);
//Set the color to red 255 green 125 and blue 0
led.setColor(255,125,0);