Hi, testing the Beta version with no issues so far. I am now experimenting with scenes and need some guidance on how to create a tile that toggles a scene on and off (and shows if the scene is on or off with glow or some sort of indicator).
I have created a scene with a virtual device tile that works turning a particular scene ON but cannot figure how to toggle back to OFF using the same tile.
I think this should be a seperate topic, since it’s not directly related to the Next-Gen integration.
But anyways, there are a few ways to achieve this.
What I would do is make a variable that checks if the scene is on or off (eg: if it’s a bunch of lights, check if all the lights are on or off, set variable accordingly). You can use this variable as a tile to show status and change the “tap” action to a rule that switches the scene on and off.
For your virtual switch, I’d suggest a momentary switch to simply trigger the scene. I’m assuming you have a regular switch at the moment. Set it up to run the scene when “on”, this way it will run it if it’s on or off, the variable handles your visual representation.
If you don’t feel like making a momentary virtual switch, you can add a switch “off” after a second to turn it back off.
Thanks for posting! I appreciate you erring on the side of caution and putting this into the beta thread – we generally prefer to keep beta related discussions within the beta. Since we recently made the Next Gen SmartThings integration available to all new SharpTools users (which has access to Scenes), I’m moving this into public discussion so other people can benefit from it!
It looks like @Sgt.Flippy_PJ and @Automated_House have you pointed in the right direction. Scenes are basically a preset configuration / set of commands that run and they don’t really have a concept of ‘on’ and ‘off’ state.
As was mentioned, you could create a Variable or Virtual Switch and use that as a proxy for tracking two different Scenes (eg. an ‘on’ scene and and ‘off’ scene). There were some neat Groovy SmartApps for syncing light state, but with Groovy going away on September 30th I would stay away from any SmartApps that require Groovy.