Differentiate between someone leaving vs. entering the house through the main door, to trigger different actions

I had an idea, but I don’t know how to implement it. Maybe someone could figure out how to do this.
I want to install a door sensor at the front door, and I want to trigger Alexa to issue a greeting when I come back home, or when someone else comes home (in other words when the door i opened from the outside, as opposed to opening the door from the inside). Do you think it is possible such a thing?
Obviously I can easily trigger a contact opening to generate a standard message like “front door has been opened” any time the door is opened, but it would not be fun.
It should be nice to be able to detect if someone is coming in or living the house.
Do you think is possible?

  1. Set up a presence-based automation: when your phone / arrival sensor arrives, turn ON virtual switch “Titus Arriving”.
  2. Set up another automation: if contact “front door” opens AND “Titus Arriving” is ON, turn OFF virtual contact sensor “Titus is Home”.
  3. Set up an Alexa routine that says “Welcome home Titus” when “Titus is Home” opens.
  4. Create complementary routines to reset everything (turn OFF “Titus Arriving” and turn ON “Titus is Home”) either after a time-based delay or when you leave.
2 Likes

Sure, lots of ways to do it. :sunglasses:

  1. Which version of the mobile app do you have, Classic or “SmartThings (Samsung Connect)”?

  2. are you using anything now for presence?

  3. what are you currently using, if anything, to trigger a change in location.mode?

2 Likes

I have both apps. And no I did not purchase yet a presence sensor. This is a tough decision, because apparently the Samsung one is not working as supposed. I don’t know what to choose. The problem is that I don’t want to use the phone for presence because, I am not someone who religiously takes the phone with him, sometimes I leave ti home, or I forget to charge the battery. I would like something like a keyfob

I have the Samsung arrival sensor which I put on our spare set of keys for guests / our nanny. The battery life isn’t amazing (I started using it in January and I just got an alert that it’s at 15%) but otherwise I don’t have any complaints. It can be modified to use AAs for longer battery life but for my use case that makes it inconveniently bulky so I’m not going to worry about it…

Do you currently change the location.mode from away to home, and if so, how do you trigger the change?

(This is the mode you can use in the smart lighting feature in the classic app, not the security.mode, which is the armed Status for SHM.)

And are you using webcore at all?

Yes I am using webcore, all my routines are there, and now I like it more than the old Core.

For now I created a virtual switch in ST which is triggered by an Alexa routine.
When we leave home, and nobody remains at home, we say a phrase like Alexa good bye, this changes the location mode to away after a 30 sec. delay, and runs all the away pistons. I like this, it works perfectly and is the easiest and simplest way I found to implement the switch to away.

What I would like to implement as well location switch from away to home mode. But I didn’t figure out yet the best way to do it. As I wrote previously I don’t want to use the iPhone

If you’re happy to rely on that (and assume that you’re the only one arriving after you put the system in “away”) then you can use my approach above:
In Step 1, use your existing virtual switch in place of my “Titus Arriving” switch.
In Step 2, add the mode change to home.
In Step 4, add the virtual contact sensor to your existing Goodbye routine so that it’s reset for next time.

If you want to get more detailed, like greeting different residents separately, you would need a way to distinguish between their arriving presences; the most straightforward approaches are to use your phones or multiple arrival sensors (or equivalent tags / fobs).

1 Like

Here’s one possible way: a motion and contact sensor configuration.

Contact sensor on the door. Place the motion sensor inside, such that it does not sense when the door opens enough to trigger the contact sensor but senses a person by the door. Then the logic: if door opens after motion is sensed, INSIDE routine. If door opens before motion is sensed, then OUTSIDE routine.

Another way would be if you have a connected smart lock. If door is unlocked using any code or arrival sensor, then OUTSIDE routine. If door is unlocked by any other method, then INSIDE routine.

Yes thanks, that’s a good idea. I didn’t think about this

Good advise, thanks, that’s how I’ll do it. I just have to decide on what presence sensor to use. As I said, I don’t want to use neither the phone, nor the Samsung keyfob for the price it costs and battery life it provides. I think is not worth it.
Anyone has experience with BT beacons + Wifi Gateway with Smartthings? Using a a Gateway would avoid using a phone an app to detect the beacon proximity.
That would be great (I was reading a bit about iBeacon technology), I could keep the beacon on the keychain, and the Wifi Gateway inside the house could somehow (I don’t know how) announce the presence to the smartthings hub. This could be the most elegant solution
Has this been implemented by someone in the community?

https://community.smartthings.com/search?context=topic&context_id=159011&q=Presence%20ibeacon&skip_context=true

Digging in the community posts I found this very useful post about iBeacons from Mr. JDRoberts:

I will research and try to follow this path with beacons… I have a tablet in the house that I can use where to install the app
Thanks Mr JD

1 Like

Hi JD, I know you have multiple sensors (beacon, floor mat, etc.) for but have you ever tried implementing the presence using the iphone itself.
I have turned on “Use Phone Location” in ST, then set Geolocation in the ST app, but the Mode does not switch from Home to Away automatically (as it’s supposed) when I leave home with my phone. I don’t know why.
Is it absolutely necessary to create a WebCore presence sensor using the Webcore app?
People are complaining that they have to keep the WebCore app open all the time otherwise the detection does not happen.
Thanks

I keep hearing that geopresence is not working well with the new app. :disappointed_relieved:

As to how well it works with the classic app, see the following FAQ (the topic title is a clickable link)

I personally didn’t use the phone for presence because I want a smaller detection area than it offers. :sunglasses:

Also, just to be clear, even with the classic app the mode does not change automatically just because you have defined the phone as a presence sensor. You have to set up a specific rule to do that.

Usually people did this with a routine.

OK I understand now, it’s not automatic, I have to create a rule. Thanks a lot.

1 Like