Samples

From webCoRE Wiki - Web-enabled Community's own Rule Engine
Revision as of 16:26, 26 October 2017 by Ahndee (talk | contribs) (Weather Tiles)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to: navigation, search
Share on FacebookShare on TwitterShare on Google+Share on LinkedInShare on DiggShare on deliciousShare on redditShare on StumbleUpon

This is an ongoing library of examples so please let me know what else you would like to see on here. Please get a hold of @c1arkbar on the ST forums if you would like to see anything added to this page.

Simple Pistons

These are going to be pretty basic beginner level pistons.

Motion Based

  • Simple Motion Piston
When the motion sensor changes to active, a light will turn on. hsv3h
Simplemotion.png
  • Complex Motion Piston
This piston will turn on a light with motion and off after 2 minutes of no motion. p3rz7
Complexmotionv2.png

Motion Based EXCEPT When Manually Turned On

  • Advanced Motion Piston
This piston will turn on a light with motion and off after 5 minutes of no motion. But if user switches the light on it will not be turned off by motion, instead user will need to turn if off. If motion turned on the light and you want it to stay on till you turn it off, just switch the light off and on. The isBetween check sets the light level to 100% when between 4am to 11pm otherwise to 10% only when turned on by motion. note that while i use a light in this example it could be any device controlled by motion. edsh2
Advancedmotionv1.png

Time Based

  • Happens At (with offset)
This piston will execute at the specified time daily. Used an expression to fire this piston off 1 hour before sunset. 1citwt
Happensat.png
  • Time Between
This piston will execute between the specified times. x3pcd
Timebetween.png

Presence Tiles

  • Presence Tiles
Presence tiles piston, what i use myself. More on the piston in the piston comments.v78tz
People Presence Tiles Example Piston.png

Weather Tiles

  • Weather Tiles
The following two pistons show the weather forecast for the next few days & nights as well as the hourly forecast for the next 16 hours (conditions, chance of rain, temperature, and humidity). The background of the tiles changes based on average temperature (the colors and values for the coldest and warmest temperatures can be adjusted in the pistons - values between those two will be interpolated). The pistons can be easily changed to use °C instead of °F and use AM/PM rather the 24h time display by changing the respective boolean variables at the top of the piston.
Here is what the tiles for those two pistons look like (during a somewhat boring forecast with not a lot of temperature variation):
Sample display for weather tiles on webCORE dashboard
Piston for the daily forecast tiles gkws
Daily forecast piston
Piston for the hourly forecast tiles s66j
Hourly forecast piston

Misc

  • Mirrored Switch
This piston will mirror one switch to another. 1ai665
Mirrorswitch.png
  • Weather
This piston will change the color of a bulb to blue if weather is below freezing. hmfm5
Weather.png

Advanced Pistons

@c1arkbar

  • House Scheduler
This is one of two pistons that controls my home's mode and SHM. This is time based with presence as additional conditions. I currently have 7 modes for my house. Away - (Dawn/Day/Night), Home - (Dawn/Day/Night) and Sleep. As the day progresses the mode will change based on the time and presence of myself and/or girlfriend.1hj33x
Myschedule.png
  • Magic Home
This is one of two pistons that controls my home's mode and SHM. This piston works the opposite of the above in that the main driver of this piston is presence with time as additional conditions. When myself or my girlfriend get home, it checks to see who is arriving and which vehicle is missing for that person to determine which garage to open. After that it will assign the correct mode to the house and then send a push notification welcoming you home and letting you know that the garage is opening for you unless it is already open. Similarly when one of us leaves the house will give a goodbye message but if both of us are gone then it will alert the last person that all the lights have been turned off. dyf6
Magichomev2.png