State.last_changed

I cannot control battery status the sensors which are battery powered
Some fibaros multi sensors are 100% some 0 % and all do work
So im thinking of, make an automation that triggers on “last changed” of sensor Motion Sensor: Air temperature. This sensor is every 30min updated by fibaro

If state.last_changed > 1h then some action should be done( send a pushover or ect )
But how can a manage that ?

does somebody know?

Hi,

You could do something like the below:

{{ as_timestamp(now()) - as_timestamp(states.yourmotionsensorentity.last_changed) >= 3600}}

Thx Toby1

I will try that

{{ now() - states.sensor.your_sensor.last_changed > timedelta(hours=1) }}

even shorter, thx Taras