I have this code in my template helper sensor (created by :
</s> <s>binary_sensor:</s> <s> - platform: template</s> <s> sensors:</s> <s> zwavebryter_lyd_5:</s> <s> friendly_name: ZWaveBryter Lyd 5</s> <s> value_template: "{{ is_state('switch.zwavebryter_lyd_5', 'on') }}"</s> <s>
This is what it looks like:
But it’s off no matter what the state of the switch.zwavebryter_lyd_5 is. And there’s no error when adding the template sensor. I have also tried to edit the template to a simpler version,
</s> <s>zwavebryter_lyd_5:</s> <s> friendly_name: ZWaveBryter Lyd 5</s> <s> value_template: "{{ is_state('switch.zwavebryter_lyd_5', 'on') }}"</s> <s>
And even only use the value template:
</s> <s>"{{ is_state('switch.zwavebryter_lyd_5', 'on') }}"</s> <s>
The value template is correct, that gives me on and off in the Template Editor in Developer’s Tools. Can somebody see what I’m doing wrong?
Edit: Finally found it! It needed the value template without the quotes…
