From ab796295e488e174d27459483fba6f6bfc0173af Mon Sep 17 00:00:00 2001 From: Jon Maddox Date: Mon, 18 May 2015 22:09:08 -0400 Subject: [PATCH] loop through platforms in config to fetch all supported devices to register them MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit This adds an additional loop to fetch devices by platform. This saves time and effort in that it returns all the devices a platform can ‘see’ on for your Home Automation, rather than making you define each one individually. --- app.js | 35 +++++++++++++++++++++++++++++++++++ 1 file changed, 35 insertions(+) diff --git a/app.js b/app.js index ea12358..533619c 100644 --- a/app.js +++ b/app.js @@ -24,6 +24,41 @@ function loadAccessories() { var accessories = []; + console.log("Loading " + config.platforms.length + " platforms..."); + for (var i=0; i