CoRE - Get peer assistance here with setting up Pistons

What kind of piston is that (how do I make that) and any ideas on what is wrong with my piston?

Everything I know about setting up CoRE routines, pistons, loops, and variables has been picked up here on the boards. So, Iā€™m thinking Iā€™ve totally overcomplicated this piston to set up a simple Christmas color loop test with one of my Hue Blooms.

Hereā€™s the piston, using a virtual switch as the trigger:


It worked the first and second times, cycling through the colors. But, turning the switch on and off threw out this exception:

Iā€™m at a loss. Help!

Oh sorryā€¦ Thatā€™s a basic piston. Make sure you turn on expert mode in the settings.

I would remove the loop at the bottom, the Boolean, and the variable.

Then replace the loop at the bottom with ā€œfollow up with pistonā€ and choose this piston to follow up in itself after x number of seconds or minutes.

Should work just fine.

Ok, I must be missing something in my brainā€™s translation from RM to CoREā€¦

I have a very simple need - turn on the Christmas lights on my balcony (Z-Wave external outlet) if Time is after Sunset.

Simple Basic Pistonā€¦ If-Thenā€¦ however, Iā€™m not sure when/how often this is evaluated, since it seems to refuse to fire after sunset time comes and goes. I searched the Wiki for an example on this, but didnā€™t find anything.

Thoughts anyone?

Thanks.

you can do this two waysā€¦ firstā€¦

is the switch on your local devices list? if yes, just use smart lightingā€¦ then it runs local.

if notā€¦

use CoREā€¦

basic pistonā€¦

 IF
 Date & Time "happens at" sunset 
 THEN
  using "outside switch"
      > turn on
1 Like

The start and end of the times you specified would be the two times it would be evaluated. I cheat sometimes and add a device in the mix that I know would have some activity like a temperature sensor to force evaluation of the piston.

1 Like

So, I have been reading for the past few hours and have now published CoRE to my IDE through github integration.
I bought some OSRAM lightify bulbs yesterday and created virtual switches for red and green colors which can be activated using Alexa. I am looking to setup a scenario where a bulb stays on and alternates between red and green every 5 minutes once I tell Alexa to ā€˜turn on christmasā€™.
Could someone please walk me through how to setup this scenario using CoRE?
Thanks.

Hey Guys, Iā€™m trying to sync circadian rhythms with turnable white Commercial Electric Zigbee Downlightsā€¦

Essentailly this is want I want to write with coreā€¦ kind of simple, but Iā€™m new.

If LightA becomes ONLINE
then If its Daytime, set value to BrightWhite (bluey white)
Else set value to SoftWhite (yellowy white)
End IF
end if

Its important that this doesnā€™t start with the ā€œwhen light turns ONā€ because from the application side this light is always on, in either a OFFLINE or ONLINE state (hooked up to a DUMB Swtich).

Thanks!

Hello, looking for assistance. Is there a way to have core intercept a signal sent to a light so it wonā€™t turn on? I have several lights in the stairs that turn on with motion and there are 2 fixtures I want to not come on at certain times, any suggestions?

Check out the thread below @bubagump, just follow the examples with your color choice.

Iā€™m not sure if thatā€™s even possible. Why not create a piston that excludes those lights during certain times or create a virtual switch that you can turn on/off to exclude those lights.

How do you know Light A is online?

Still no go. I mustā€™ve placed the ā€œfollow up with pistonā€ incorrectly. I tried putting it under ā€œusing locationā€ as well as under the lights as a task right after the last color change.

The lights cycle through the colors once but will not repeat. What am I missing?

Make this a basic piston. Delete the but if section.
And make the wait time for the follow up 20 seconds

@Lisa_262

I found my exampleā€¦ Set it up like thisā€¦ sort ofā€¦ g this Iā€™ve sets three bulbs to three different colors and changes every few secondsā€¦

You can try a BASIC piston:
IF motion changes to active THEN
task 1: turn on all lights (turn on action restrictions: from time to time)
task 2: turn on all lights except the 2 fixtures (turn on action restrictions: from time to time)

Thanks @eibyerā€¦ This is great!

In the IDE, thereā€™s a field that sales, OFFLINE, ONLINE, ACTIVE, INACTIVE.

[cid:image001.png@01D24A38.EB9AA410]

When you build a piston in CoRE, where does this light fall under? Switches? Relay? Iā€™ve never used one of this so please bear with all the questions :slight_smile: