Lt.Pixel
(Peter van Hees)
1
I’m creating a script to set the “start-up behavior”, “start-up color temperature” and “start-up current level” of all my Hue lights.
The “start-up color temperature” and “start-up current level” are working fine…
hue_default_values:
alias: "Hue Default Values"
sequence:
- service: number.set_value
target:
entity_id: number.hall_hue_start_up_color_temperature
data:
value: 500
- service: number.set_value
target:
entity_id: number.hall_hue_downstairs_start_current_level
data:
value: 100
Any idea how I can set “start-up behavior”?
The value is a drop-down list with the options “Off”, “On”, “Toggle” and “PreviousValue”.
Heinz
2
If you have an ‘Input Select’ for these 4 values, you can use ’ input_select.select_option
to set the desired option. See here for example:
https://www.home-assistant.io/integrations/input_select/
Lt.Pixel
(Peter van Hees)
3
I tried this, but it’s not working…
- service: input_select.select_option
target:
entity_id: select.hall_hue_start_up_behavior
data:
option: PreviousValue
Heinz
4
it should be something like:
- service: input_select.select_option
target:
entity_id: input_select.hall_hue_start_up_behavior
data:
option: Off
tom_l
5
‘Off’ and ‘On’ must be quoted (or they will be converted to boolean states) and check your indentation.
- service: input_select.select_option
target:
entity_id: input_select.hall_hue_start_up_behavior
data:
option: 'Off'
Lt.Pixel
(Peter van Hees)
6
It’s still not working.
The entity name is “select.hall_hue_start_behavior”, but should I use “input_select” as domain for the entity?
entity_id: input_select.hall_hue_start_behavior
or
entity_id: select.hall_hue_start_behavior
tom_l
7
No. That is the wrong service for a select entity, use this:
- service: select.select_option
target:
entity_id: select.hall_hue_start_behavior
data:
option: 'Off'