Hi, I set up a bunch of input_numbers so I could globally change values for brightness/kelvin/etc in my scripts and automations but lost as to how I’m supposed to feed those values into my light params.
Any examples or pointers to examples, I haven’t really had a chance yet to wrap my head fully round templates as I’m still new.
Thanks @tom_l I read through that section but I must just be missing some concept, I’m not getting any errors but when I put in the templates nothing happens.
Below is where I am trying to implement the template
brads_office_relax:
alias: Relax Brads Office
sequence:
- service: light.turn_on
data_template: ### <- NOTE data_template instead of data
entity_id: light.brads_office
brightness_pct: "{{ states('input_number.relax_lux') | int }}"
kelvin: 3000
Note, changing the input number will not change the brightness. The brightness will only change when this script is run. If you want the brightness to change when the input number is changed you will have to write an automation . e.g.
alias: change_brads_office_light_brightness
trigger:
platform: state
entity_id: input_number.relax_lux
action:
service: script.brads_office_relax
Thanks, @tom_l I was overlooking the need for data_template:
Also thanks for the additional info about needing automation to make the changes live, it’s not what I was going for now but I’ll be getting there soon enough.