Only check specific device class?
Closed this issue · 3 comments
tispokes commented
Like in #16
but I would like to only check device_class "battery". I don't want to check sensors with fixed power supply.
Wasn't able to reduce the results to this.
Regards :-)
tispokes commented
Like this item, from the expanded list:
<template TemplateState(<state sensor.briefkasten_ms_power=unavailable; state_class=measurement, unit_of_measurement=%, device_class=battery, friendly_name=Briefkasten power @ 2023-03-02T08:53:59.750493+01:00>)>
jazzyisj commented
|selectattr('attributes.device_class','defined')
|selectattr('attributes.device_class','eq','battery')
tispokes commented
Oh I forgot attributes.
Thanks