Help a newb with Life360 Presence and Lighting Automation?

Hey guys, it has been a while, but due to the future plans of Groovy and Smart Lighting App, I am revisiting all my automations.

I have a ‘relatively’ simple automation(s) I would like to perform, but not sure I follow the logic correctly in the Smartthings Automations. I currently have Life360 as our presence sensors with my wife and myself. Very simple automations occur when we both leave, the house turns to “away”, STHM ‘arms’, and the lights of choice shut off. When EITHER of us return home, the house turns to “home”, STHM ‘disarms’ and specific lights turn on. We also have a typical “Night” routine, that arms the STHM and shuts off all the lights.

We have a use case, where my wife comes home in the middle of the night from work at various times, where I would like the STHM to turn to “home”, so she can open the door without an alarm. (This currently is setup and works fine). But what I would like is for a different set of lights to turn on and dimmed at certain levels, knowing that the house was in ‘night’ mode, before it then flipped to ‘home’ mode. Since Smartthings doesn’t know it was in night mode prior, it changes to the standard ‘Home’ and all my lights come on.

I feel like I am missing something very easy here and I am happy to do multiple automations, I just can’t put my finger on the solution. Can any one provide suggestions?

Maybe I’m missing something (I don’t know the app very well), but can’t you just use night mode as a precondition?

And in order to keep your regular arrive home routine from running, you would have to add Away mode as a precondition to that.

That way one set of lights would come on if the previous mode was Away, and a different set if the previous mode was Night.

That is what I cannot test correctly. Is it still considered a ‘pre-condition’, if I am changing that condition in the middle of the automation?

Yes, it is a pre-condition to be in “Night”, but by the wife arriving home, it is changing to “home”. So doesn’t that nullify the pre-condition and thus nullify the automation?

The precondition is tested BEFORE the automation runs. Only if it is true do the next steps happen. So it shouldn’t matter that one of the next steps is changing the mode again. At least that’s how I think it works, but someone else will need to confirm.

Thanks, I will figure out a way to try it!

No, this doesn’t work. I can use the ‘Night’ as the pre-condition, but I cannot add another “location mode” as another condition. So I cannot say Pre-condition “Night”, then if mode changes to “home”, because I can only add one instance of the “location mode”.

I can try Pre-condition is ‘night’ and then if my wife arrives ‘home’ using her presence sensor, to adjust the lights. But then it is a timing game… is that pre-condition going to change to ‘home’ before the app updates her location?

Oh, I see. You are trying to put everything into one automation, and you’re right, that won’t work.

What we have done at our house for a somewhat similar use case was to have person A coming home turn on a virtual switch. Instead of changing the mode.

Then use that particular virtual switch coming on as the trigger for other things, which would also let you use the night mode as a precondition.

That might do it, but it’s definitely a lot more work to set up, so hopefully someone else has a better idea.


This is how we handled it. Coming home in the middle of the night was a special case - not a mode switch. So capture enough ‘prerequisites’ to identify this case happening, turn on VSwitch. On Vswitch on - do (All of these things / automations, etc)

You won’t do this in one automation btw. Don’t even try.


Interesting, so let me type out my thought process on here:

Person A arrives home, flips on “A Virtual Switch”.

  • If Mode was in pre-condition “Away” then if “A Virtual Switch” turns on.
  • Then change location mode to “Home” disarm STHM

Person A & B leave home, Flip off “A Virtual Switch” & “B Virtual Switch”

  • If “A Virtual Switch” & “B Virtual Switch” are both “off”
  • Then change location mode to “Away” arm STHM

Person A is home at night - Turn on “A Virtual Switch”. Person B is at work at night turn off “B Virtual Switch”. Person B plans to come home during Night mode.

  • If mode pre-condition is “Night” and if “B virtual Switch” is turned on
  • Then disarm STHM and turn on specific lights

Close but I personally think you’re trying to collapse too much. Break these down into atomic units that MUST go together.

Arrive / Depart is its own automation to control home away. No prereq for setting away but Away is a prereq for the home automation.

Set various automations to occur on home / away as normal.

The wife comes home scenario:
Your home is in night so it WON’T throw the Home / Away automation defined above. (At least one person is home)
Set a separate automation for her arrival with Night as precondition. It Turns on VSwitch and various automation you want to happen for her arrival experience - but the home is STILL in night mode. THe combination of precondition Night Mode and that VSwitch being on is your indication she just arrived and can be used to trigger whatever else you need. When that condition clears, turn off the vswitch.

1 Like

Ahhh. I think this statement is what I have been missing “No prereq for setting away but Away is a prereq for the home automation.”

Thank you! Let me think about it some more, but this may be the little piece I was missing. Really appreciate the help


This appears to have worked, thank you! Now another really dumb, quick question. When I was using the “Smart Lighting” app or “Webcore”, I had no issues with the lights coming on at a set dim level during these style routines.

Now, when I use the Smartthings standard Automation tab and I set a dimmer level, it appears that my bulbs turn on first (at full brightness) then quickly dim to my 10% level… rather than just coming on at 10%. Not ideal as a ‘night light’… any suggestions?

I’m surprised you’re not seeing this with Smart Lighting.

I haven’t started to convert my Smart Lighting routines to new Automations/Routines. I always see lights come on at whatever brightness level they were last set to followed by dimming to the desired level. If you look at the log in the IDE you’ll see two commands being sent, one to turn the dimmer on followed by one to set the level. I dislike it but there’s no fix.