I setup an automation to read the battery level of my door lock but I’m getting errors in the log about it. 17-03-22 10:08:39 WARNING (MainThread) [homeassistant.components.sensor.template] Could not render template Front Door Battery, the state is unknown. 17-03-22 10:08:40 WARNING (MainThread) [homeassistant.helpers.condition] Value cannot be processed as a number:
Here is my code. Does anyone see where I went wrong? Its reading back a value of 90% all the time.
If you have home assistant running, under the developer tools one of the buttons will link to template editor. (down at the bottom of the sidebar on left hand side)
Just paste in your {{ states.sensor.kwikset_touchpad_electronic_deadbolt_alarm_level_8_1.attributes.battery_level }}
into the text box to see if it renders correctly, you should see the battery level in the output on the right side
Zwave node is getting its own entity with many attributes, including battery level.
For automation and alerts it is enough.
A separate sensor is just for visuals - this can be still done with a template sensor.