I am trying to create a vertical stack card, using auto-entity cards, to show:
- Only lights which are on
- Only batteries which are low, and
- Only doors or windows which are open
The first two appear to work (although I have no low batteries at the moment), but the third is only populated by one entity, even though I know other doors are open.
Can anyone tell me what I am doing wrong - I am still pretty new to HA.
The code is (the whole card, although I guess you can skip down to the third card only, which I have moved down one line here just to help visually)
type: vertical-stack
cards:
- type: custom:auto-entities
card:
title: Lights On
type: grid
columns: 1
square: false
card_param: cards
filter:
include:
- domain: light
state: 'on'
options:
type: custom:mushroom-light-card
exclude: []
show_empty: false
- type: custom:auto-entities
card:
show_header_toggle: false
title: Low Batteries
type: entities
filter:
include:
- attributes:
device_class: battery
state: <= 10
exclude:
- name: /[Ll]ow/
- name: /[Ss]tate/
sort:
method: state
numeric: true
- type: custom:auto-entities
card:
show_header_toggle: false
title: Open Doors and Windows
type: entities
filter:
include:
- domain: binary_sensor
state: 'on'
attributes:
device_class: window
- domain: binary_sensor
state: 'on'
attributes:
device_class: door
I have created a group for all door and window sensors:
binary_sensor.contact_sensors
Would it be better / possible to use this instead, although the status of this is “on”, which I assume derives from the fact that one or more of the sensors is on.
Thank you