#Opposite of "FOR:" in conditions

1 messages · Page 1 of 1 (latest)

glass grove
#

So, I am currently using "Templates" like "{% set elapsed = (now() - states.person.***.last_changed).total_seconds() %} {{ elapsed < 6 * 60 }}"

But there has to be an easier way of doing that, isn't there?

Simply I want Trigger that automation only if the condition "Person in Home Zone for less than 10 minutes" is true. The template works perfectly fine though, but I want to make things easier to read and configure

high leaf
#

There's a not condition, you can use that?

#

So you can say:

and:
  - person is home
  - not:
      - person is home for 10 minutes
glass grove
#

Why haven't I even thought of that

#

It sounds like it should work the way I described tbh, gonna test that in practice, but seems promising