I’d like to get something similar. I guess a new sensor was made to display the time? What I have at the moment is:
And the X hours ago does not correspond to the latest state change for open or closed, as when I check the history bar, the last state change happened 4 hours ago.
Card code is:
entities:
entity: binary_sensor.occupancy
name: Living beweging
secondary_info: last-changed
I did not reboot HA (wasn’t home when the time changed).
Please let’s focus on the actual question here which is how do I get that time as the displayed status for a given entity as is done on the HA Lovelace demo
You will find a link to @arsaboo’s repo in the demo, and editing the UI shows a sensor sensor.ring_front_door_last_motion.
Take a look there.
I assume it’s a timestamp from the ring component.
It looks like it, I do not have a Ring platform however so no luck there. I guess it must be possible to check for example at what time of day Occupancy was last true or when the door state was last open. Any ideas?
Invalid config for [sensor.template]: invalid template (TemplateSyntaxError: expected token ‘end of print statement’, got ‘x00158d00028ab3b7_occupancy’) for dictionary value @ data[‘sensors’][‘motion_living_lastseen’][‘value_template’]. Got ‘{{states.binary_sensor.0x00158d00028ab3b7_occupancy.occupancy.last_changed | timestamp_local}}’. (See ?, line ?). Please check the docs at https://home-assistant.io/components/sensor.template/