howartp wrote:Have a go with
https://github.com/howartp84/VariableDeviceBeta/releasesCreate a new device > Variable Device
Pick which variable(s) you want to monitor within that device.
Then pick which of the variables should be the displayState, ie the value that shows in the UI.
Having spent all evening on it, i've just realised that "states" aren't visible in the Indigo Touch UI which is now annoying me greatly!
However the plugin does show the chosen displayState, together with the appropriate coloured blobs as it would for other devices, and does bring variables together into a nice device within the client UI so it's not a complete waste of time.
Comments welcome.
Peter
Ok so I had some time to try this out, I think this gets us most of the way there. I did noticed a couple things as I played around with this.
First the devices don't have the ability to tell Indigo what device type they are (ie motion sensor, temp sensor, etc) so the display in the UI is generic, ie the motion sensor looks like an on/off switch. After adding variable devices for four sensors values (motion, temp, humidity, and lux) I then added masquerade devices for each of the variable devices to apply proper formatting in the UI, In the image you can see how the masquerade plugin applies the proper device types and they are displayed as such in the UI.
Next you will notice in the attached image, the variable device for LUX is properly displaying the current ambient light value, but for some reason the Masquerade device that is based on the variable device is displaying 0. I have no idea why as it is set up exactly the same as the other three devices. I am guessing this has more to do with the masquerade plugin than variable devices.
If it would not be to difficult to add the ability to define the type of sensor directly in the variable devices plugin (or merge the two plugins together in some way?), that would eliminate the need to create a second device using masquerade making things less complex when adding /managing these devices and they would look like natively supported zwave/insteon sensors in the UI.
Thanks again for the work on this!
-Eric