[OBSOLETE ] Virtual Presence Sensor

Going back to basics:

The Location Modes have default values of Home, Away and Night. These are typically used to represent someone being present at your Location, no one being present at your Location, and your Location being occupied overnight. However you can use the Modes to mean whatever you want and you can add, delete and rename Modes. The key thing is that is down to you to specify what the ‘current’ Location Mode is, either manually or by creating automations to set it. The effect is really like setting a variable from a defined range of values.

Your SmartThings app is capable of acting as a presence sensor for the logged in user. If you go to the app settings and turn on the location sensing it will use the phone’s host location services to set up a geofence using the geolocation centre and radius in your Location settings. When you enter and leave that geofence the app is notified and it will set a presence sensor device to Present or Not Present. Not everyone finds it reliable.

This presence sensor device is usually given the same name as your phone but isn’t visible as a device in the app. In Routines it is dressed up as the Member Location instead. It does appear in Smart Lighting though.

A virtual presence sensor is essentially a wrapper around the presenceSensor capability that can be set, manually or automatically, to present or not present. That is something you have to arrange. A popular use for one is to mirror the phone presence settings so they are more visible in the app.

Okay,
New to all this but can someone please help with how many routines I need and what they should include to have the following:

  1. When I am home then presence is set to HOME
  2. When I am away then presence is set to AWAY

Do I need a routine to turn on or off HOME and AWAY then another routine for sensor ON or OFF?

Thanks

@John_Agius You can do this a couple different ways. You will need routines to set virtual presence AND location modes.

Must have routines:

  1. IF member location is at house
    THEN turn virtual presence sensor on
  2. IF member location is not at house
    THEN turn virtual presence sensor off

Options:

  1. Add set location mode home/away in the above then actions. Upside, fewer routines. Downside, cant set location mode manually by turning on/off the virtual presence sensor
  2. Create 2 more routines that set the location mode based on the virtual presence sensor turning on/off

Personally I keep the 2 must have routines by themselves and use the virtual presence sensor changing state in all my other routines. That means that if I have to turn on/off/mess with the phone geofencing for some reason I only have 2 routines to fix.

1 Like

Agree. When using a virtual device(s) in a routine to track state (member home, specific time period, etc), it is better/cleaner for that routine to only change the state of the virtual device and use separate routines to trigger actions based on that state. It provides a clear separation between the control plane (the state managed by the virtual devices) and the actions the control plane is managing based on the state.

Hi,
Great thank you I do have those set up but just to clarify - when you mention “IF member location is at house” do you mean the presence sensor is present?

Thanks

Let’s say you are ‘John’, your phone is ‘John Mobile’ and your Location is ‘Home’.

If you configure your SmartThings app on your phone to ‘get the location on this phone’ it will create a presence sensor device named ‘John Mobile’ that should report ‘present’ when you enter the geofence surrounding your Location, and ‘not present’ when you leave it.

In Routines you can’t use this device directly. Instead you have to use ‘Member Location’. This prompts you for three pieces of information:

Who
You will be presented with a list of all of the members of your Location and their individual devices that have been enabled to get presence. You choose which devices you are interested in. So for just your phone it is ‘John Mobile’ belonging to member ‘John’.

Where
This will typically just be your Location which we called ‘Home’.

The reason it is even an option is because you if have a Samsung Galaxy phone it is possible to create three extra ‘Linked Places’. So this selection would allow you to choose which of up to four places you are interested in.

When
This allows you to say whether you are interested in the device(s) being at the place you chose for ‘Where’ (which corresponds to the actual presence devices reporting present) or if you are interested in being away from this place (not present).

If you chose more than one member/device for ‘Who’ you can say whether you want all of the devices to be in or away from the place, or whether one will suffice.

1 Like

Okay so I tried the below when away from the house but the presence sensor will not go off once I leave the specified area:

Any advice please?

The way it is written is that the location mode AND the phone must be Away before the presence sensor will change.

Remove location mode from the If section and move it the the Then section.

IF John phone is away
ThEN set John off, set location mode Away

If you are worried about your privacy you might have to make some other changes :smiley:

Perfect!
Thank you so much it works now
and thanks top everyone else for their input too!
This home automation lark gets addictive lol

1 Like

Ah bugger lol

2 Likes