Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Does this work on service: scene. ? #235

Open
Gil80 opened this issue Aug 24, 2023 · 1 comment
Open

Does this work on service: scene. ? #235

Gil80 opened this issue Aug 24, 2023 · 1 comment

Comments

@Gil80
Copy link

Gil80 commented Aug 24, 2023

Does this work on scenes too?

This is what I have:

action:
  - choose:
        - conditions:
               - condition: template
                  value_template: "{{ trigger.to_state.state == 'on' }}"
          sequence:
              - service: scene.turn_on
                 target:
                    entity_id: scene.evning_light_color
                 metadata: {}

Will this work if I set it up like this?

action:
  - choose:
        - conditions:
               - condition: template
                  value_template: "{{ trigger.to_state.state == 'on' }}"
          sequence:
              - service: scene.turn_on
                 target:
                    entity_id: scene.evning_light_color
                    data_template:
                    entity_id: light.entity
                    kelvin: "{{ state_attr('sensor.circadian_values', 'colortemp') | int }}"
                   brightness_pct: "{{ state_attr('switch.circadian_lighting_[...]', 'brightness') | int }}"
                 metadata: {}
@claytonjn
Copy link
Owner

claytonjn commented Aug 24, 2023

This question doesn't actually relate to the integration; the template you described should translate into proper values for kelvin and brightness_pct.

Speaking generally, I don't believe the scene.turn_on service allows you to pass in entity_id, kelvin, brightness_pct, or anything else under data or data_template - have you seen the ability to do so documented anywhere? I'm also not sure what you're trying to accomplish by turning on a scene and also passing values from Circadian Lighting.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants