[Custom Component] Battery Notes

It is tricky to test automations with trigger event data, because I do it a lot I have an ESP Home device with a knob I can simulate it.
To setup a test rig in software I think this would work
Create a number helper with 0-100 range
Create a template sensor helper that takes the number helper value
{{ states("input_number.my_numeric_helper") }}
and has a unit of measurement of %, device class Battery and State Class Measurement, attach it to a device to test the device name element (I use Sun a lot)
Finally add a battery note to that device.
Adjust the number helper and you should get your automation trigger.

1 Like