CoRE - Get peer assistance here with setting up Pistons

Can anybody help please?

Set a boolean variable true on the initial push and use that as condition for the piston. Something like below.

IF
Doorbell is pushed
AND
Variable isPushed is false
Using location...
  > Set boolean variable isPushed = true (immeadiately set)
  > Your other tasks go here
  > Wait 15 secs
  > Set boolean variable isPushed = false
1 Like

You could possibly use the (sorry if not exact nomenclature, I don’t have my phone on me right now) the ā€œWASā€ command in CoRE. Something like:

IF Contact changes to open
AND
Contact WAS closed for at least 5 seconds

Something along those lines maybe?

1 Like

Any advice on this? I can delete and re-create the piston (hopefully), but I am worried that something is wrong with CoRE itself to prevent me from OPENING a piston to edit it. CoRE works, several other pistons work, but these two pistons can’t even be opened or edited.

I have not seen this one before, are you on most current version?

I’ve tried that. Have also tried removing the CoRE Smartapp from the
Smartthings app, but that didn’t sold the problem. Any other suggestions?

And if you are responding to me, I believe I am on the latest version:

def version() { return ā€œv0.3.169.20170104ā€ }

I’ve got one I can’t figure out. Basically I want a light to turn on after sunset and turn off before sunrise. The piston does not seem to work. Any ideas? Am I using the wrong mode?

Just use a simple piston
IF
Date and time between Sunset and Sunrise.
THEN
Turn On.
ELSE
Turn Off.
You can put an offset into the sunst and sunrise.

1 Like

Thank you! I’ll try that.

I’m sure you realise but in mine I have used when true and when false.
This can be done by enabling expert mode.

1 Like

Seems like the task evaluate the variable before change instead of the new one, causing the wrong event to be fired off. Please help

Hello, Hoping I can get some assistance, trying to setup a piston for my camera. Camera is at front door and has preset positions for Door, Stairs and Door # 2. Here is what I want it to do.
Camera is always at Position 1 before and after piston is run.
When Stairs Motion 2 goes active I want the camera to pan to position 2
When Stairs Motion 2 goes inactive return to position 1.
When door opens camera to position 3 and pan down
When door closes camera to position 1
When Hallway motion 2 goes active camera to position 3
When Hallway motion 2 goes inactive camera to position 1.

I can do this with multiple pistons, but want it all in one.

Hoping somebody can assist?

this is what i have so far

CoRE Piston #1
Or-If v0.3.169.20170104 v0.3.169.20170104 Tue, Feb 7 2017 @ 12:18 PM EST Tue, Feb 7 2017 @ 1:26 PM EST
IF
ā—¦ Stairs Motion 2 motion is active
When false…
Using Front Door Cam…
ā–ŗ Turn LED off
ā–ŗ āŒ‚ preset1()
THEN…
Using Front Door Cam…
ā–ŗ Set LED to Auto
ā–ŗ āŒ‚ preset2()
OR IF
ā—¦ Front Door contact is open
When false…
Using Front Door Cam…
ā–ŗ Turn LED off
ā–ŗ āŒ‚ preset1()
THEN…
Using Front Door Cam…
ā–ŗ Set LED to Auto
ā–ŗ āŒ‚ preset3()
ā–ŗ Pan camera down
ELSE
THEN…
Using Front Door Cam…
ā–ŗ Turn LED off
ā–ŗ āŒ‚ preset1()

I like the sound of EchoSistant. Will have to give that a try after a while.

It looks like I had previously installed Lock Code Manager but I wasn’t really sure how to use it. I set the Iris Keypad up as a ā€œlockā€ and ā€œkeypadā€, creating some user settings, but was kind of lost as to how I would actually use any of this for my system.

You’re saying that Lock Code Manager can be utilized to set up my routine after arming the system (having the keypad beep 3 times, temporarily disarm the system for 3 minutes, beep again, and set to Armed/Stay)? I wouldn’t have to initiate any of this through CORE?

Jason
It look like an IF then Else IF then Else piston (ELSE IF by name)

IF stairs motion 2
THEN goto position 2
ELSE IF door opens or hallway motion 2
THEN: goto position 2
Save door open close state in variable
Begin IF block
IF door open
THEN pan down
END IF Block
ELSE
goto position 1

You may need to turn on expert mode in CoRE settings to get to the if block functionality. Keep in mind I’m new to this too, but I hope this helps.

I’m struggling with a piston. Here it is:

I want to set my furnace to low temperature if a door is open (for a period of time). Then if the doors close I want to return it to its previous settings.
I am using a Trane tzemt400ab32maa thermostat and device handler by WRX Fanatic. I can set the temperature alright and I can save the old state. However I cannot get it to return to the previous state when the doors are closed. I’m not sure if the ELSE statement never executes, if I’m not handling the variables correctly, or if the device handler is not working correctly. Any help would be greatly appreciated.

Scott A

Can anyone help me with my problem below, please?
I created this simple piston to set the mode to Away and set the SHM to Armed/Away when everyone left and there is no motion in the house. I can see that the piston evaluation is true, however, the piston state is false and it is not changing the mode or the SHM states. What am I doing wrong?

Ok, have not gotten into saving variables yet, do you have anything to show me what this would look like? I am looking in the wiki and don’t see anything about setting variables.

Here is one I’m working on unfortunately it does not yet work. The variables save but I can’t seem to reset the thermostat in the else statement. Yours should work fine in that you only need the variable to test the door condition later.