fribse
(Kenneths Teknik)
February 3, 2021, 5:16pm
1
I have this card, and it works ok, it lists the devices that has low battery level, but when it’s very low (critical) then it is shown as blue and not red?
type: 'custom:auto-entities'
card:
type: entities
sort:
method: state
numeric: true
critical: 25
warning: 40
filter:
exclude:
- entity_id: '*mobil*'
- entity_id: '*h8*'
- entity_id: '*life360*'
- entity_id: '*netatmo*'
- state: '> 50'
include:
- entity_id: '*_battery'
options:
type: 'custom:battery-entity-row'
- entity_id: '*_battery_level'
options:
type: 'custom:battery-entity-row'
- entity_id: '*_batteriniveau'
options:
type: 'custom:battery-entity-row'
- entity_id: '*_battery_charge'
options:
type: 'custom:battery-entity-row'
tom_l
February 3, 2021, 5:44pm
2
What does it look like in a normal entities card?
1 Like
m0wlheld
(Christoph Dahlen)
February 3, 2021, 6:01pm
3
Don‘t know about this custom card, but with the regular gauge card, the values for red, yellow, green are lower thresholds.
So, this should mark values between 0 and 25 as critical:
critical: 0
warning: 25
1 Like
fribse
(Kenneths Teknik)
February 3, 2021, 9:56pm
4
Hmmm, can’t make it react like I want, I wonder where I got this from, because the statements are not in the documentation, have to dig a bit into this in the weekend.
fribse
(Kenneths Teknik)
February 14, 2021, 2:33pm
5
I finally got a condition with all three states:
The yaml looks like this:
type: 'custom:auto-entities'
card:
type: entities
sort:
method: state
numeric: true
critical: 25
warning: 40
filter:
exclude:
- entity_id: '*mobil*'
- entity_id: '*h8*'
- entity_id: '*life360*'
- entity_id: '*netatmo*'
- entity_id: binary_sensor.*
- state: '> 50'
include:
- entity_id: '*_battery'
options:
type: 'custom:battery-entity-row'
- entity_id: '*_battery_level'
options:
type: 'custom:battery-entity-row'
- entity_id: '*_batteriniveau'
options:
type: 'custom:battery-entity-row'
- entity_id: '*_battery_charge'
options:
type: 'custom:battery-entity-row'
I didn’t see an effect from chaning them like @m0wlheld suggested.
And @tom_l , the standard entities card shows it like this:
petro
(Petro)
February 14, 2021, 2:35pm
6
That’s a basic card, it’ll never show other colors than the active icon color.
Edit: nevermind ignore my response. It’s wrong
1 Like
fribse
(Kenneths Teknik)
February 21, 2021, 6:06pm
7
Ok, got it sorted, it’s the template that’s wrong.