Open kidhasmoxy opened 8 years ago
Very cool, would love to see this.
OOooh, that would be quite cool. I'm in favor of this. I don't have any plans to add it personally, but I can see it certainly helping users out quite a bit. Do you want to give a PR to add this?
I was thinking about something similar, but where the handler on Smartthings side would publish a list of all enabled devices to a single topic along with their configs, and then on the Hass side you just specify that discovery topic and it can then find everything else from there. Not sure which approach would be better.
I can paste my node-red flow here, but I haven't modified the code for this app. I ended up changing the SmartApp to have subscribe push a block of device info. That's what I'm using in the Node-RED flow and calling in the template (checking for capabilities of the device to build the all the device blocks.)
Do you have any plans to automatically generate a config file (or set of includes) based on the information about the devices and their capabilities for the smart apps?
I rebuilt the functionality of your bridge in Node Red to learn it (and run the bridge on a Pi), and figured I would create a flow to automatically update the HA config file and optionally restart HA when new devices are found. Here's my ugly mustache template to give an idea of what I've hacked together so far: