Newer fan controller

This commit is contained in:
Martin Donnelly 2018-01-23 20:58:05 +00:00
parent 30987e3117
commit cc189000c9
5 changed files with 790 additions and 686 deletions

View File

@ -40,8 +40,8 @@ Aida.prototype.init = function() {
this.lights.on('found', (d) => {
if (devices.lights.get(d.id) === undefined) {
logger.debug('Adding to light list');
devices.lights.set(d.id, d);
// logger.debug('Adding to light list');
// devices.lights.set(d.id, d);
}
});

View File

@ -1,4 +1,4 @@
const Hs100Api = require('hs100-api');
const Hs100Api = require('tplink-smarthome-api');
const client = new Hs100Api.Client();
const em = require('events').EventEmitter;

View File

@ -11,6 +11,7 @@ const LightController = function() {
// const devices = new Map();
client.on('light-new', light => {
logger.debug('New light found.');
logger.debug('>>', light);
logger.debug(`ID: ${ light.id}`);
logger.debug(`IP: ${ light.address }:${ light.port}`);

1438
package-lock.json generated

File diff suppressed because it is too large Load Diff

View File

@ -13,26 +13,27 @@
"author": "",
"license": "ISC",
"devDependencies": {
"babel-eslint": "^8.0.0",
"eslint": "^4.7.1",
"express": "^4.15.4",
"ws": "^3.2.0"
"babel-eslint": "^8.2.1",
"eslint": "^4.16.0",
"express": "^4.16.2",
"ws": "^4.0.0"
},
"dependencies": {
"bg-hive-api": "^1.0.5",
"body-parser": "^1.18.1",
"body-parser": "^1.18.2",
"cookieparser": "^0.1.0",
"errorhandler": "^1.5.0",
"express-session": "^1.15.5",
"hs100-api": "^0.14.0",
"express-session": "^1.15.6",
"hs100-api": "^0.19.1",
"lodash": "^4.17.4",
"log4js": "^2.3.3",
"method-override": "^2.3.9",
"morgan": "^1.8.2",
"mqtt": "^2.14.0",
"log4js": "^2.5.2",
"method-override": "^2.3.10",
"morgan": "^1.9.0",
"mqtt": "^2.15.1",
"node-lifx": "^0.8.0",
"tplink-smarthome-api": "^0.22.0",
"trend": "^0.3.0",
"wemo-client": "^0.14.0"
"wemo-client": "^0.15.0"
},
"jspm": {
"directories": {