Struggling with a basic IFTTT piston


#1

Hi, new to webcore and doing any sort of code writing or anything like it. I can use IFTTT no probs. I can do most of what I want to do in Stringify and it works but I don’t get the full choices that are available using webcore, for example the different beeps using the Aeon labs siren.
I am struggling to get a simple if that then this working on webcore, there are so many options I don’t know which to use. Maybe because I have never done any coding or whatever it’s called I don’t know. In SmartThings I can do all the if this then that but only if and then this then that Etc Etc But using this I can’t seem to do a simple “if this opens then do that”. Also in Stringify I can do "If gate opens and it’s between 11pm and 8am then flash lights in Bedroom red 10 times and send push notification to phone. Also sound alarm for 10 seconds then stop. etc etc but can’t do any of this in webcore. I know it’s not webcore, it’s me. Why am I struggling? (apart from being thick). Is there a learners section do do very basic/simple stuff to get me started?
I can’t even get this to work.


#2

What are you trying to achieve.
Is it a beep everytime the contact opens and closes?
If so, change the IF statement to contact sensor changes. Then everytime it opens or closes the piston will fire.
No need to save to a variable.
Also there is a wiki. Click on the ‘W’ at the top. There is also an example category where people share their pistons. This is a good place to start for ideas.


#3

Yes, a dead simple if gate opens then beep once. I don’t think you could get more simpler than that. It should take seconds to do, just like IFTTT. But using Webcore to me it’s like trying to understand the small print in a terms and conditions document for an insurance policy. If I can just get the gist of a couple of simple ones I’m sure it will all fall into place. I read the “Conditions and Triggers: What’s the difference?” 3 times and to me it’s like lawyers gobildy gook. I also looked for an example that just does the basics, but found none.
But thanks for your input.


#4

You can import this using the code and just change to use your devices.
Ignore the ping part as I cannot do custombeep with my player.


#6

I did what you suggested. I saved and when I click test nothing happens. When I took a snapshot of the piston to post on here, the “music player” was showing in the snapshot not the Gate sensor which I replaced the music player with.
So when I save it it shows my Siren but when I save a screenshot your music player is back in the place where my siren should be.
The ping has gone and been replaced with my beep command. But still shows your music player.
I tried it 4 times and it still does the same.


#7

The Snapshot facility anonamizes the piston to remove specific devices and puts in generic names to protect the users information.
If there is no sensative information in the piston just take a screenshot.


#8

This is what I did from yours.


#9

When you open the piston and click on the garden gate, you should get to a drop down with your devices. You then select your contact sensor. Is this not happening?


#10

Yes it is, I then tick contact then tick changes to open then compare to tick value then tick open.
then in next part I choose my siren then do custom beep.
When I look at logging it says it’s working, but it’s not see attach

I tried a couple of different beeps which all work when I press them in the Android SmartThings app.


#11

I just used the full logging and it shows false for a couple of things, do these matter/ see attached.
Capture3


#12

Test will not work as the trigger is changes to open. Hence the false you are seeing.
You need to open the gate to test it.
Alternatively change the trigger to something that you can do without opening the gate.
What people do is configure a virtual switch to use for testing. They then turn it off and on to trigger the piston.
Do you have motion sensors or a light switch you can turn on and off to test the piston. Just replace your contact sensor with something you can easily use for testing purposes then amend again with your contact sensor.


#13

I think I need to appologise, I have been using the “TEST” button to see if it worked. Not actually doing the Piston., IE: I just opened the gate and it worked without problem.
Another thing while I was trying different things today, when I first tried to do a new piston, an option box popped up like this


which never appeared before. I think this was why I was struggling, I had nowhere to start from so to speak. Anyway I think (touch wood) I can suss it now. For some reason I wasn’t getting the whole picture.
Thanks very much for your patience and your help.


#14

Ah. Got ya.
Should have mentioned in your settings when amending a piston to click on advanced statements. This opens up a lot more options for you.


#15

As posted after this, I didn’t realise it wasn’t a real time test. Yes I have a few sensors both multi and motion. I will use one of these for future testing. Thanks again for your help.


#16

Starting to get the hang of it now, still struggling with some of the terms (I am having to go back and forth a fair bit with trial and error), but enjoying experimenting with all the settings available.
I have just finished piston number seven, nothing too extravagant but they are working (so far).