it's all up and running.... well one bulb linked to one temp sensor and the temp sensor isn't in the freezer yet... but you get the idea :-)
- id: '1660686610046'
alias: change bulb
description: ''
trigger:
- platform: state
entity_id: sensor.temp1
condition: []
action:
service: light.turn_on
target:
entity_id: light.wiz_rgbw_tunable_44a1ea
data:
rgb_color: >
{% if states.sensor.temp1.state | int <= -25 %} [0, 0, 255]
{% elif states.sensor.temp1.state | int <= -20 %} [51, 51, 255]
{% elif states.sensor.temp1.state | int <= -15 %} [102, 102, 255]
{% elif states.sensor.temp1.state | int <= -10 %} [153, 153, 255]
{% elif states.sensor.temp1.state | int <= -5 %} [204, 204, 255]
{% elif states.sensor.temp1.state | int <= -0 %} [255, 102, 78]
{% elif states.sensor.temp1.state | int <= 5 %} [255, 51, 51]
{% else %} [255, 0, 0]
{% endif %}
brightness_pct: 100
took a while to get the hang of the coding, a lot of examples online are for older versions etc. and there's 50 different ways to do everything
but loving home assistant so far :-)