Quantcast
Channel: Configuration - Home Assistant Community
Viewing all articles
Browse latest Browse all 95387

Different behaviour color_temp and brightness

$
0
0

@mvieleers wrote:

Hi,
First post and very new to all of this, but willing to learn :wink:

Running HA on Raspi 4b. Installed RaspBee II. Have a IKEA Tradfri remote and light bulb which can be manipulated from HA.

Now I’m trying to assign the normal functionality to the buttons of the remote. I know I can do this from within deCONZ, but I want to keep everything in HA.

These are the automations I use for that:

- id: '1587459801036'
  alias: Increase Color Temp
  description: Increase Color Temperature of lamp from remote
  trigger:
  - event_data:
      event: 5002
      id: remote_bureau_marc
    event_type: deconz_event
    platform: event
  condition: []
  action:
  - data_template:
      color_temp: '{{state_attr(''light.bureau_marc'', ''color_temp'') + 25}}'
    entity_id: light.bureau_marc
    service: light.turn_on
- id: '1587461216277'
  alias: Decrease Color Temp
  description: Decrease Color Temperature of lamp from remote
  trigger:
  - event_data:
      event: 4002
      id: remote_bureau_marc
    event_type: deconz_event
    platform: event
  condition: []
  action:
  - data_template:
      color_temp: '{{state_attr(''light.bureau_marc'', ''color_temp'') - 25}}'
    entity_id: light.bureau_marc
    service: light.turn_on
- id: '1586459801036'
  alias: Increase Brightness
  description: Increase Brightness of lamp from remote
  trigger:
  - event_data:
      event: 2002
      id: remote_bureau_marc
    event_type: deconz_event
    platform: event
  condition: []
  action:
  - data_template:
      brightness: '{{state_attr(''light.bureau_marc'', ''brightness'') + 10}}'
    entity_id: light.bureau_marc
    service: light.turn_on
- id: '1586461216277'
  alias: Decrease Brightness
  description: Decrease Brightness of lamp from remote
  trigger:
  - event_data:
      event: 3002
      id: remote_bureau_marc
    event_type: deconz_event
    platform: event
  condition: []
  action:
  - data_template:
      brightness: '{{state_attr(''light.bureau_marc'', ''brightness'') - 10}}'
    entity_id: light.bureau_marc
    service: light.turn_on
- id: '1586460637104'
  alias: Turn On normal
  description: ''
  trigger:
  - event_data:
      event: 1002
      id: remote_bureau_marc
    event_type: deconz_event
    platform: event
  condition:
  - condition: device
    device_id: 1598707957774db3830c017f782fc5c9
    domain: light
    entity_id: light.bureau_marc
    type: is_off
  action:
  - data:
      brightness_pct: 50
    entity_id: light.bureau_marc
    service: light.turn_on
- id: '1586460691667'
  alias: Turn On Bright
  description: ''
  trigger:
  - event_data:
      event: 1001
      id: remote_bureau_marc
    event_type: deconz_event
    platform: event
  condition: []
  action:
  - data:
      brightness_pct: 100
    entity_id: light.bureau_marc
    service: light.turn_on
- id: '1586460791735'
  alias: Turn Off
  description: ''
  trigger:
  - event_data:
      event: 1002
      id: remote_bureau_marc
    event_type: deconz_event
    platform: event
  condition:
  - condition: device
    device_id: 1598707957774db3830c017f782fc5c9
    domain: light
    entity_id: light.bureau_marc
    type: is_on
  action:
  - data: {}
    entity_id: light.bureau_marc
    service: light.turn_off

The frustrating part is that changing brightness works like a charm, changing color_temp does nothing. Instead of color_temp, I’ve also tried kelvin. Same issue.
If I don’t try to use a function for color_temp, but simply set it to an integer, it works. As soon as I try to do the formule, it stops working.

Any help appreciated to get this working.

Posts: 11

Participants: 3

Read full topic


Viewing all articles
Browse latest Browse all 95387

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>