Hi! I have three doors in our home and they all have a magnet sensor. I want to get information in a markdown card which door is open. And if no doors is open it will write out “no doors open”.
I have all doors in a group and I want to select the door that has status on and write it out. And if a second door is open this door will also write out as open.
Exempel - one door open
“Door 1 is open”
Exempel - two doors open
“Door 1 and 2 is open”
Exempel - three doors open
“Door 1,2 and 3 is open”
Exactly. Is it possible to get the first sensor to have capital? The first sensor in the code will be placed first, but if this door isn’t open can the first sensor have a capital letter?
The template uses the binary_sensor’s friendly_name. If it’s “Front Door” then that’s how it will appear. Ensure your three binary_sensors all have a friendly_name (with a capitalized first letter)
If the binary_sensor doesn’t have a friendly_name then the template will use its object_id. For example, if it’s binary_sensor.rear_door, it will appear as “rear_door”.
Hi , may I ask how you managed to have your entities displayed with the device class for “Open/Closed” for the “door and window closed state” card? I’m stuck at it showing the On state.
You need to set device_class to either door or window.
If you set it up in yaml just add device_class, if it is in through an integration then you might have to use customize.yaml to change/add the device class.