Global Time with I'm Back


#1

1) Give a description of the problem
I want to run a global time for the house which will change modes I have created… these should run within a 24 hour cycle… I want to do this in one piston, not one per mode. I also want to have the mode changed accordingly if “im back” is performed.

2) What is the expected behavior?
Mode automatically changes when we are at home and is set when someone arrives

3) What is happening/not happening?
Im having to run multiple pistons to get the same thing… just does not seem neat to me. At the very least would be good to have one piston for setting when we return or if we are in.

4) Post a Green Snapshot of the pistonimage
(UPLOAD YOUR IMAGE HERE)

5) Attach any logs (From ST IDE and by turning logging level to Full)
(PASTE YOUR LOGS HERE BETWEEN THE MARKS)

REMOVE BELOW AFTER READING

Thanks for your help


#2

Please edit the post to add your current pistons image.


#3

I didnt get that far, im really struggling to control anything other than physical devices at the moment…

The options just aren’t there to do what I was trying to do.

Sorry


#4

Actually I’ve found that all the options are there for what I’ve wanted to do…

You haven’t really explained what it is that you’re stuck on though, so we can’t exactly help you get started without more information.


#5

If I had to guess, I think he hasn’t added presence sensors yet?

@nickp - how many devices do you have added to webCoRE?


#6

Sorry guys, its a pretty poor effort on my part. Your right, i haven’t tried to build it at all yet…

This is what I want to try and do…

Sunrise - Mode Change Morning
0900 - Mode Change Daytime
-45 Sunset - Mode Change Twilight
Sunset - Mode Change Evening
Button Push - Night

I cant seem to do that in ios Core with 1 piston. Its across 5… However, what I want to have is one away setting but when we are back say at 1300 it executes mode change daytime or at 2100 (evening) mode change evening.

That would seem like a reliable way of having the house run to a set time where possible and execute to that time, if you return. All other pistons, lights etc etc are set to those modes.

Is that any clearer?
Thanks again, beer on me!
n


#7

This is my basically my mode changing piston… I don’t have an “away mode”…but rather in my external pistons that I’m calling I do things based on whether or not I’m home or away, or if there are guests over, or whether a light is on or off already. I do have a home and away routine…but my coming home routine does not have to change the mode to the right one because the house is always going to be in the right one. To me, doing it this way made more sense. But there are many ways to do this stuff…you just have to find the one that works best for you.


#8

Thanks @Mike1616

That is pretty much spot on what Im looking for! Just out of curiosity, how do you manage your home and away routine?

My reason for wanting it to change was that we use the holiday app if we are away after sunset to make it look like there is movement but this is disabled along with the alarm. So, if its 1800 and dark, we want the house to “be” like it would be if we were in, hallways, bedroom lamps, sitting room etc… but importantly, if I get home “half cut” at 0200 only the hallway lights… etc etc…

Or would you manage that differently to the mode?

N


#9

I would say that I’ve really geared my system up to mainly adjust lighting. So I am absolutely configuring what the lights will do and basing that on when I get home. So just as you’re saying, if I get home and it’s 2AM (which in my case would be when the Mode is Night), I can have fewer lights come on so that I’m not waking up the neighborhood The nice thing about webCoRE is that it works with various modes very easily. I plotted out for a while how I wanted things to work and I think it was “lighting based” that really jumped out at me.

I even have some switches in my house (with double-tap features) that work differently if mode is Evening or Night, versus Daybreak or Morning. That’s pretty easy to make an IF condition for that:

image

Also you can just tack on the “only while this mode” on the command itself.

Sort of like this…

image

There’s a way to do that in only one command with an expression…but i haven’t spent the time to redo it.

I even have some Virtual switches that I use in case guests are over so i don’t turn off all the lights on them if I have to run to the store or something. I use a virtual switch so that I can turn it on using the Echo, or by double-tapping a physical switch at my front door, or by hitting the shortcut button in the app.

It’s been a fun process building this all out so far and we have a very good and very helpful community here who’ve assisted me along the way.


#10

Hi Mike, in the example you have given me here, it has execute piston at the end of every action. I am guessing that if all i want is the mode changed, i can delete these?

Many thanks,
Nick


#11

This is where I am now… I am still stuck on the execute piston elements… are they actually needed? Are they controlling something in this piston or, are they controlling another piston?


#12

Yeah, those are calls to a different piston. So if you just want to only change the modes then delete those lines.

I use the other pistons to mainly set and reset dimmers. My future plans, when I get a few more sensors, are to add in some checks to see if I can turn some lights off if it gets bright enough, for example.


#13

Mike thanks for all your help on this.

The last thing I am trying to figure out, is how to set the mode using this logic if someone returns. I am guessing this needs to be in another piston but I am wondering how this can be referenced to provide the times etc.

N


#14

Read back my response #7 in this thread. I specifically DO NOT change modes based on presence in the setup that I’m choosing to use. So the modes I’m using continue in their cycle regardless of whether anyone is home. I elected to setup my stuff based mostly on time of day…and the sun.

Now, as I said before, I still do have a “Presence” piston that I use which works like this:

IF Presence changes to present (with some tests for false alarms)
And mode is any of Night, Evening, Daybreak
THEN
Turn on these lights

IF Presence changes to away (again with checks for false alarms)
THEN
If the Guest (virtual switch) is off
THEN
Run the full away routine (turn off everything)
ELSE
Run the mini away routine (turn of the garage lights and such…but don’t turn off all the lights)

Many people choose to use “Home” and “Away” as modes. I do not. But reading thru what those folks did it became clear to me that if your goal was to “Turn on some lights when I come home if it’s dark” and you left during the “day” and came home at “night” then you’d have to make several more modes to make that happen (Home-Day, Home-Evening, Home-Night, Away-Day, Away-Evening, etc). Then you’d have to, as the day went on, change the mode based on BOTH Presence and Time, it all seemed very cumbersome (again this is to me…many make it work just fine, but I didn’t like how that felt).

So…to recap…my modes don’t care about where the people that live in my house are…they only care about where the sun is in the sky / what time of day it is. I then react to people coming and going based on that.


#15

Your right - sorry mate, I didnt pick that up…
Is it really cheeky and (please excuse my ignorance) not per the forum to ask if I could see that piston?

Still learning the ropes, starting froms cratch is prooving a little too much!

N


#16

@Mike1616 thanks for sharing your mode setting piston. This is something I didn’t realize I needed until I saw it :slight_smile: This might be a good addition to the Examples area.


#17

I’ll attach the Home half of the piston, as it has more examples of how I’m using the various modes in it. As you can see, at this point I only bother doing anything if the mode indicates that I need lights on. So for me that’s Daybreak, Evening and Night. But I don’t want the hall light very bright if I come home late at night…so I handle that too.


#18

Mike, with this example, you have execute pistons at each of the time zones… I did the same, except the pistons run all the time.

Can you please explain how you can get them to only fire when the mode time changes?

Nick