]> git.giorgioravera.it Git - homeassistant.git/commitdiff
Added light global, bathroom lights and renamed bulb effecrs
authorGiorgio Ravera <giorgio.ravera@gmail.com>
Sun, 14 Apr 2019 12:46:48 +0000 (14:46 +0200)
committerGiorgio Ravera <giorgio.ravera@gmail.com>
Sun, 14 Apr 2019 12:46:48 +0000 (14:46 +0200)
components/google.yaml
light/all.yaml [new file with mode: 0644]
light/bagno.yaml [new file with mode: 0644]
light/corridoio.yaml
light/cucina.yaml
light/sala.yaml
lovelace/covers.yaml
ui-lovelace.yaml

index 6c275a9db4754203dda8eb7b2def0e3babf14da1..801ad4fe51c401119d6c3fa673818a4b35681ca7 100644 (file)
@@ -22,10 +22,13 @@ entity_config:
   light.luce_divano:
     room: Sala
     expose: true    
-# Tapparelle
-  cover.tapparella_globale:
-    room: Generale
+  light.luce_bagno:
+    room: Sala
+    expose: true    
+  light.luce_specchio:
+    room: Sala
     expose: true
+# Tapparelle
   cover.tapparella_cucina:
     room: Cucina
     expose: true
diff --git a/light/all.yaml b/light/all.yaml
new file mode 100644 (file)
index 0000000..f21d057
--- /dev/null
@@ -0,0 +1,12 @@
+######################################################################\r
+# Global Light\r
+######################################################################\r
+\r
+- platform: group\r
+  name: Luci Globale\r
+  entities:\r
+    - light.luce_corridoio\r
+    - light.luce_cucina\r
+    - light.luce_divano\r
+    - light.luce_bagno\r
+    - light.luce_specchio\r
diff --git a/light/bagno.yaml b/light/bagno.yaml
new file mode 100644 (file)
index 0000000..6e24966
--- /dev/null
@@ -0,0 +1,27 @@
+######################################################################\r
+# Bathroom Light\r
+######################################################################\r
+\r
+- platform: mqtt\r
+  name: Luce Bagno\r
+  command_topic: "shellies/shellyswitch25-7457D8/relay/0/command"\r
+  state_topic: "shellies/shellyswitch25-7457D8/relay/0"\r
+  payload_on: "on"\r
+  payload_off: "off"\r
+  retain: false\r
+  qos: 1\r
+  optimistic: false\r
+\r
+######################################################################\r
+# Bathroom Mirror Light\r
+######################################################################\r
+\r
+- platform: mqtt\r
+  name: Luce Specchio\r
+  command_topic: "shellies/shellyswitch25-7457D8/relay/1/command"\r
+  state_topic: "shellies/shellyswitch25-7457D8/relay/1"\r
+  payload_on: "on"\r
+  payload_off: "off"\r
+  retain: false\r
+  qos: 1\r
+  optimistic: false\r
index 925c16b2f85276046da42ddd7340961950fdeca5..113bb6c88df0282a72c0940f2c77e2b18048bbda 100644 (file)
@@ -1,5 +1,5 @@
 ######################################################################\r
-# Living Room Light (Color)\r
+# Corridor Light\r
 ######################################################################\r
 \r
 - platform: mqtt\r
index bf9c75effc7324de3b80e081a21241d0c74c23a8..9c2bd69afe9fab2d090806d6ad7d96b66f578594 100644 (file)
@@ -1,5 +1,5 @@
 ######################################################################\r
-# Kitchen Room Light\r
+# Kitchen Light\r
 ######################################################################\r
 \r
 - platform: mqtt\r
index e24740fc71cc7dc3454894b7c5fe6c80aa4b9400..3535ec748a54bc9a8c59fae4fa0fa39d25db0228 100644 (file)
         "gain": {{ (brightness/255*100) | int }},
       {%- endif -%}
       {%- if effect is defined -%}
-        {%- if effect == 'Meteor Shower' -%}
+        {%- if effect == 'Pioggia di Meteore' -%}
           "effect": 1
-        {%- elif effect == 'Gradual Change' -%}
+        {%- elif effect == 'Cambio Graduale' -%}
           "effect": 2
         {%- elif effect == 'Breath' -%}
           "effect": 3
         {%- elif effect == 'Flash' -%}
           "effect": 4
-        {%- elif effect == 'On/Off Gradual' -%}
+        {%- elif effect == 'On/Off Graduale' -%}
           "effect": 5
-        {%- elif effect == 'Red/Green Change' -%}
+        {%- elif effect == 'Rosso/Verde' -%}
           "effect": 6
         {%- else -%}
           "effect": 0
@@ -45,8 +45,7 @@
   command_off_template: >
     {
       "turn": "off",
-      "mode": "color",
-      "effect": 0
+      "mode": "color"
     }  
   state_template: >
     {% if value_json.ison == true and value_json.mode == "color" %}
   white_value_template: '{{ value_json.white }}'    
   effect_template: >
     {%- if value_json.effect == 1 -%}
-      Meteor Shower
+      Pioggia di Meteore
     {%- elif value_json.effect == 2 -%}
-      Gradual Change
+      Cambio Graduale
     {%- elif value_json.effect == 3 -%}
       Breath
     {%- elif value_json.effect == 4 -%}
       Flash
     {%- elif value_json.effect == 5 -%}
-      On/Off Gradual
+      On/Off Graduale
     {%- elif value_json.effect == 6 -%}
-      Red/Green Change
+      Rosso/Verde
     {%- else -%}
       Off
     {%- endif -%}
   effect_list:
     - "Off"
-    - Meteor Shower
-    - Gradual Change
+    - Pioggia di Meteore
+    - Cambio Graduale
     - Breath
     - Flash
-    - On/Off Gradual
-    - Red/Green Change
+    - On/Off Graduale
+    - Rosso/Verde
   retain: false
   qos: 1
   optimistic: false
@@ -94,8 +93,8 @@
 - platform: mqtt
   name: Luce Divano Bianca
   schema: template
-  command_topic: "shellies/shellybulb-<deviceid>/color/0/set"
-  state_topic: "shellies/shellybulb-<deviceid>/color/0/status"
+  command_topic: "shellies/shellybulb-BC8610/color/0/set"
+  state_topic: "shellies/shellybulb-BC8610/color/0/status"
   command_on_template: >
     {
       "turn": "on",
index 124ef69db2e0d273ec6cec4843e96f698cd4bc61..654d894f2ab32c6b481d8788559890954287f9a9 100644 (file)
@@ -12,7 +12,7 @@
       title: Comandi tapparelle
       show_header_toggle: false
       entities:
-        - cover.all_covers
+        - cover.tapparella_globale
         - cover.tapparella_cucina
         - cover.tapparella_sala
         - cover.tapparella_studio
index 41a297da1a3439ec7a2c34847a729d3c32fb2146..b620b8679276b0d461f280f3c7ffdfb7615221d2 100644 (file)
@@ -11,7 +11,6 @@ views:
 ######################################################################
   - title: Principale
     id: main
-    #icon: mdi:home-assistant
     icon: mdi:home
     badges:
       - device_tracker.google_maps_115265981849847357125
@@ -38,6 +37,7 @@ views:
       image: /local/rooms/sala.jpg
       entities: 
       - light.luce_divano
+      - light.luce_divano_bianca
       - cover.tapparella_sala
       - climate.sala_termostato_sala
       - media_player.tv_sala
@@ -59,6 +59,8 @@ views:
       show_state: true
       image: /local/rooms/bagno.jpg
       entities: 
+      - light.luce_bagno
+      - light.luce_specchio
       - climate.bagno_termostato_bagno
 
     - type: picture-glance
@@ -97,16 +99,40 @@ views:
   - title: Luci
     id: light
     icon: mdi:lightbulb
+    badges:
+      - light.luce_cucina
+      - light.luce_corridoio
+      - light.luce_divano
+      - light.luce_bagno
+      - light.luce_specchio
     cards:
     - type: light
-      entity: light.luce_cucina
+      name: Luci Globale
+      entity: light.luci_globale
+
+    - type: light
       name: Luce Cucina
+      entity: light.luce_cucina
+
     - type: light
-      entity: light.luce_corridoio
       name: Luce Corridoio
+      entity: light.luce_corridoio
+
     - type: light
-      entity: light.luce_divano
       name: Luce Divano
+      entity: light.luce_divano
+
+    - type: light
+      name: Luce Divano Bianca
+      entity: light.luce_divano_bianca
+
+    - type: light
+      name: Luce Bagno
+      entity: light.luce_bagno
+
+    - type: light
+      name: Luce Specchio
+      entity: light.luce_specchio
 
 ######################################################################
 # Covers