Homeassistant noob here,
I’m going crazy trying to work with template sensors.
I’ve got several Xiaomi binary door sensors integrated into my setup.
I would like to see the last opended state in my lovelace frontend.
The following is not displaying any value:
door_last_open:
friendly_name: 'Door opended last'
value_template: "{{ states.sensor.my_sensor.last_changed }}"
Neither is the following:
states('sensor.my_sensor.attributes['last_changed']')
Is there an issue I’m not seeing here using these sensors?
Related: is there a way to debug this kind of sensors / attributes without editing the configuration.yaml file each time & restarting? That would really be useful