Skip to content

Set colours and effects on a Playbulb Bluetooth Candle using Node.js

Notifications You must be signed in to change notification settings

danielsmith-eu/playbulb-live

Repository files navigation

Playbulb-live

NPM

Node.js module for sending commands to the bluetooth Playbulb Candle and Playbulb Color.

Uses noble for BLE communication, and protocol from https://github.com/Phhere/Playbulb/blob/master/protocols/color.md

Usage:

var Playbulb = require('playbulb');
var pb = new Playbulb.PlaybulbCandle();
pb.ready(function () {
    pb.setColor(0, 255, 0, 255); // set fixed color in Saturation, R, G, B
});

Twitter Demo

There is a demo in demo-twitter.js that opens a continuous stream of tweets, performs sentiment analysis on the text, and turns the light green if the sentiment is positive, and red if it is negative.

To get this working, copy demo-twitter-config.js.example to demo-twitter-config.js and fill in your access keys from https://apps.twitter.com/

About

Set colours and effects on a Playbulb Bluetooth Candle using Node.js

Resources

Stars

Watchers

Forks

Packages

No packages published