I have several sensors that only look different at the end, such as:
- binary_sensor.uptime_abc
- binary_sensor.uptime_dce
- binary_sensor.uptime_fgh
New binary sensors are added regularly.
they have an attribute: Monitor response time
for which I want to create separate sensors (for all)
is there a smart way to combine all sensors in 1 template? (and so that new ones are added automatically?)
sensor:
- platform: template
sensors:
uptime_response_time:
friendly_name: 'Uptime Response time'
value_template: "{{ state_attr('binary_sensor.uptime*', 'responsetime') }}"
a * after binary_sensor.uptime is not going to work?