robosmart

A node.js library for the RoboSmart

npm install robosmart
2 downloads in the last day
34 downloads in the last week
147 downloads in the last month

node-robosmart

A node.js library for the RoboSmart by Smart Home Labs.

Special thanks to @mrose17 for sending me a bulb!

Install

npm install robosmart

Usage

var RoboSmart = require('robosmart');

Discover

RoboSmart.discover(callback(roboSmart));

Connect

roboSmart.connect(callback);

Disconnect

roboSmart.disconnect(callback);

Discover Services and Characteristics

roboSmart.discoverServicesAndCharacteristics(callback);

isOn

roboSmart.isOn(callback(on));

switchOn

roboSmart.switchOn(callback);

switchOff

roboSmart.switchOff(callback);

getDim

roboSmart.getDim(callback(dim));

setDim

roboSmart.setDim(dim, callback); // dim: 0 - 255

getPowerConsumed

roboSmart.getPowerConsumed(callback(powerConsumed)); // watts per hour

getLightName

roboSmart.getLightName(callback(lightName));

setLightName

roboSmart.setLightName(lightName, callback(lightName)); // lightName is string

getGroupName

roboSmart.getGroupName(callback(groupName));

setGroupName

roboSmart.setGroupName(groupName, callback(groupName)); // groupName is string

getRoomName

roboSmart.getRoomName(callback(roomName));

setRoomName

roboSmart.setRoomName(roomName, callback(roomName)); // roomName is string
npm loves you