#philip hue lamps
1 messages · Page 1 of 1 (latest)
template:
- sensor:
- name: "hue color spot 1 power"
state: >
{% if is_state('light.hue_color_spot_1', 'on') %}
5
{% else %}
0
{% endif %}
unit_of_measurement: "W"
device_class: energy
state_class: total_increasing
unique_id: "spot_1_slaapkamer_dylan"
icon: "mdi:lightbulb"- sensor:
- name: "Hue Color Spot 1 Energy"
unique_id: "hue_color_spot_1_energy"
state_class: total_increasing
unit_of_measurement: "kWh"
device_class: energy
state: "{{ (states('sensor.hue_color_spot_1_power') | float * 0.001 / 60) | round(6)}}"
- name: "Hue Color Spot 1 Energy"
- sensor:
when i try this i get wrong values