I’d like to be able to set up routines that happen not just between relative times (sunset and sunrise) or between fixed times, but as a combination of both: lights turn on with motion from sunset to 11pm. I read ways of doing that with virtual switches but that seems to be gone in SmartThings. Anybody figure something else out?
Yes, virtual switches are the way to go. Use them to represent your desired time period by turning on and off with Routines and then checking if the virtual switch is on as part of another Routine. You can create virtual switches using the ST Advanced Web App or community developed ST API Browser+. Those will run in the cloud. You can also use Edge driver based virtual switches by installing the [ST Edge] vEdge Creator: a virtual device generator for end users driver.
Sorry, call me ignorant. Can’t find the ability to create virtual switches anywhere anymore, not even in the ST Advanced Web App.
I suggest using the driver I suggested so that your virtual devices will run local to your hub as well as your Routines if the devices used in the Actions also run local.
If you want to create them in the Web App, go to the Devices page and click on the “+Add a new Device”. It’s not really obvious because it should really be labeled “Add a new Virtual Device”.
There’s a FAQ for that…