It seems as if uses some intermediate value of the replacement rather than the final results to send the notification. Is this a command optimization issue or something else I can do on my side (other than assigning to another variable first)?
I’m wanting to do a Piston which when you run a routine, waits for “no activity” for 2 minutes then switches a light off, I’d have thought the below would work.
Add webCoRE to github https://wiki.webcore.co/GitHub_Install
Then when you update (in IDE), goto SmartApp-Update from Repo-webCoRE-then select webCore and the Child Apps and be sure to click publish then execute.
That’s exactly what that will do. If there is motion within the 2 minute wait period, the counter will reset. Cancel on Condition State Change is on by default.
I am new to webCoRE since I just discovered this after getting into CoRE.
Do I have to always first define my devices at the beginning of the program/script before including them into my condition or action? I would just first review the webCoRE wiki as i did with CoRE’s, but it looks like it’s down as write this.
Anyway, i know in CoRE there are predefined devices that i already have listed in Smartthings. I was wondering if i can just do a lookup for the devices in webCoRE UI, while i write out my script rather than manually type all my devices out?
Have you actually used webCoRE yet? Or is this a preemptive question?
You don’t type** into webCoRE, the output display looks typed.
You pick triggers, conditions, actions, select devices, etc. from menus. You then get that typed output as a result of your selections.
It’s been some time since I set it all up, but I believe you install the webCoRE apps, run through the setup on your phone, make the devices available to webCoRE, and then you can get to work on the web interface.
** NOTE, there will be typing, as in, variables, comments, etc. As you get more advanced.
If you go into the settings for WebCoRE you can define your various devices by attribute.
Motion sensor, switch, light etc.
Then when you define a piston, you can pick the various devices from a drop down list.
Makes it very easy.
Edit. As said above.
You don’t have to define any variables (unless your piston has a complexity that really calls for variables) - some people define variables and put their devices in those variables because they later down the script use the variable instead of the actual devices. The main benefit of this is you can later change that variable to contain more, less, or different devices, as you need. It just makes it much easier to add/remove/swap devices at a later time, as you only have to change one spot. But you don’t have to do that. Programmer-like-thinkers do that.
As you can see $devices is a variable. I was just hoping to limit typing there would be a link of some kind for devices that map to my actual devices that i have in the Smartthings app. if i have to declare all the devices, sobeit.
EDIT: I found where you need to identify the smart devices you have already configured with smartthings, to add to webCoRE’s configuration. it’s found in the webCoRE smart app itself; under Settings.
$devices is a system maintained variable - it will be automatically populated with all devices in use in the current with block - you cannot set that variable and you have no control over its contents, other than selecting which devices go into the with block. If you want to use a variable to avoid selecting the same device list several times, add your own, define it as device-typed and choose your devices in there.