Dear friends, I’ve spend a couple of days trying to create a blueprint from a (complex) automation.
Unfortunately, I didn’t get the created blueprint triggered by a template trigger (working well within “normal” automation).
Question in short version:
How to transform the template-trigger into blueprint version:
trigger:
- platform: template
value_template: "{{ states('sensor.room_t') |float > state_attr('climate.room_thermostat',
'temperature') |float }}"
sensor.room_t and climate.room_thermostat to be replaced.
Additionally I have troubles with condition comparing the name of entitiy:
- condition: template
value_template: '{{ trigger.from_state.entity_id == "sensor.room_t"}}'
What I’ve tried:
variables:
climate_target: !input climate_target
t_current_target: !input t_current_target
trigger:
- platform: template
value_template: "{{ states[t_current_target].state | float > state_attr(climate_target, 'temperature') |float}}"
The trigger above doesn’t trigger at all (but working correctly i.e. in variable section)
I guess, the main problem is wrong syntax in template-trigger (I’ve tried different possibilities).
Somehow, the variables defined above are empty / null in trigger section.
Maybe you have a hint for me, what I’m doing wrong.
Thank you