mirror of
https://github.com/GeorgeSG/sarah.git
synced 2026-06-09 23:02:59 +00:00
Replace PC light
This commit is contained in:
@@ -36,7 +36,7 @@ light:
|
||||
brightness_scale: 254
|
||||
|
||||
- platform: "mqtt"
|
||||
name: "hue_white_4"
|
||||
name: "pc"
|
||||
state_topic: "z2m_deconz/hue_white_4"
|
||||
availability_topic: "z2m_deconz/bridge/state"
|
||||
brightness: true
|
||||
@@ -286,14 +286,14 @@ sensor:
|
||||
value_template: "{{ value_json['update']['state'] }}"
|
||||
|
||||
- platform: "mqtt"
|
||||
name: "hue_white_4_lqi"
|
||||
name: "pc_lqi"
|
||||
state_topic: "z2m_deconz/hue_white_4"
|
||||
availability_topic: "z2m_deconz/bridge/state"
|
||||
value_template: "{{ value_json.linkquality }}"
|
||||
unit_of_measurement: "lqi"
|
||||
icon: "mdi:signal"
|
||||
- platform: "mqtt"
|
||||
name: "hue_white_4_update_state"
|
||||
name: "pc_update_state"
|
||||
state_topic: "z2m_deconz/hue_white_4"
|
||||
availability_topic: "z2m_deconz/bridge/state"
|
||||
icon: "mdi:update"
|
||||
@@ -428,7 +428,7 @@ sensor:
|
||||
|
||||
binary_sensor:
|
||||
- platform: "mqtt"
|
||||
name: "hue_white_1_update_available"
|
||||
name: "pc_update_available"
|
||||
state_topic: "z2m_deconz/hue_white_1"
|
||||
availability_topic: "z2m_deconz/bridge/state"
|
||||
payload_on: true
|
||||
|
||||
@@ -108,34 +108,6 @@ light:
|
||||
qos: 1
|
||||
retain: false
|
||||
|
||||
- platform: mqtt
|
||||
name: "pc"
|
||||
state_topic: "tele/light_lohas_1/STATE"
|
||||
state_value_template: "{{ value_json.POWER }}"
|
||||
command_topic: "cmnd/light_lohas_1/POWER"
|
||||
payload_on: "ON"
|
||||
payload_off: "OFF"
|
||||
availability_topic: "tele/light_lohas_1/LWT"
|
||||
payload_available: "Online"
|
||||
payload_not_available: "Offline"
|
||||
on_command_type: "brightness"
|
||||
brightness_command_topic: "cmnd/light_lohas_1/Dimmer"
|
||||
brightness_state_topic: "tele/light_lohas_1/STATE"
|
||||
brightness_scale: 100
|
||||
brightness_value_template: "{{ value_json.Dimmer }}"
|
||||
hs_command_topic: "cmnd/light_lohas_1/HSBColor"
|
||||
hs_state_topic: "tele/light_lohas_1/STATE"
|
||||
hs_value_template: "{{ value_json.HSBColor.split(',')[0:2]|join(',') }}"
|
||||
color_temp_command_topic: "cmnd/light_lohas_1/CT"
|
||||
color_temp_state_topic: "tele/light_lohas_1/STATE"
|
||||
color_temp_value_template: "{{ value_json.CT }}"
|
||||
rgb_command_topic: "cmnd/light_lohas_1/Color"
|
||||
rgb_state_topic: "tele/light_lohas_1/STATE"
|
||||
rgb_command_template: "{{ '%02X%02X%02X=' | format(red, green, blue)}}"
|
||||
rgb_value_template: "{{ (value_json.Color[0:2]|int(base=16),value_json.Color[2:4]|int(base=16),value_json.Color[4:6]|int(base=16)) | join(',')}}"
|
||||
qos: 1
|
||||
retain: false
|
||||
|
||||
- platform: mqtt
|
||||
name: "light_lohas_2"
|
||||
state_topic: "tele/light_lohas_2/STATE"
|
||||
@@ -365,16 +337,6 @@ sensor:
|
||||
unit_of_measurement: "%"
|
||||
value_template: "{{ value_json.Wifi.RSSI }}"
|
||||
|
||||
- platform: mqtt
|
||||
name: "pc_wifi"
|
||||
availability_topic: "tele/light_lohas_1/LWT"
|
||||
device_class: signal_strength
|
||||
payload_available: "Online"
|
||||
payload_not_available: "Offline"
|
||||
state_topic: "tele/light_lohas_1/STATE"
|
||||
unit_of_measurement: "%"
|
||||
value_template: "{{ value_json.Wifi.RSSI }}"
|
||||
|
||||
- platform: mqtt
|
||||
name: "light_lohas_2_wifi"
|
||||
availability_topic: "tele/light_lohas_2/LWT"
|
||||
@@ -491,17 +453,6 @@ switch:
|
||||
state_topic: "stat/light_le_4/RESULT"
|
||||
value_template: "{{ value_json.Fade }}"
|
||||
|
||||
- platform: mqtt
|
||||
name: "pc_fade"
|
||||
availability_topic: "tele/light_lohas_1/LWT"
|
||||
command_topic: "cmnd/light_lohas_1/FADE"
|
||||
icon: mdi:gradient
|
||||
payload_available: "Online"
|
||||
payload_not_available: "Offline"
|
||||
qos: 1
|
||||
state_topic: "stat/light_lohas_1/RESULT"
|
||||
value_template: "{{ value_json.Fade }}"
|
||||
|
||||
- platform: mqtt
|
||||
name: "light_lohas_2_fade"
|
||||
availability_topic: "tele/light_lohas_2/LWT"
|
||||
|
||||
Reference in New Issue
Block a user