[ CARTE ] Cartes diverses ( Livebox, NAS, RPI, BLE Proxy...) ( archive )

Ils sortent d’où ces sensors ?
je les vois pas dans ta citation:

dans mon code:

          - entity: sensor.0x00158d0005d299cf_papp
            attribute: linkquality
            name: LQI

j’utilise l’attribut de l’entité _papp. Tu dois utiliser l’entité linkquality, supprime la ligne attribute: linkquality

la ligne {{ HC + HP + HN| int(default=0) }} fait que comme mes compteurs HC et HP sont inexistants, il prend mon index de base, que j’ai appelé HN pour heures normales.
ca ma permet d’adapter mon environnement à tes scripts. ce qui est plus simple que l’inverse :wink:

finalement, mon zlinky_current_summation_derived_one_minute a fini par donner quelque chose, il devait pas avoir fini de récupérer ses billes.
et je vais me bricoler quelque chose qui lira l’état du relais du chauffe-eau pour avoir le HC HP.
faudra faire gaffe car un esp32 appréciera encore moins le 220V que moi :stuck_out_tongue_winking_eye:

J’ai ajouté du nom de la ville où est localisé la personne quand elle est absente.
Il faut amélioré : suivant la longueur du nom de la ville cela pourrait être trop long et voir pour re-centrer le nom suivant longueur du nom de la ville.
Voila certain ici doivent savoir si c’est possible et surtout comment faire.

locality

(J’ai enlevé l’état du wifi dans mon code)

type: custom:stack-in-card
mode: vertical
keep:
  box_shadow: true
  margin: false
  border_radius: true
  background: true
  outer_padding: false
cards:
  - type: custom:mod-card
    card_mod:
      style: |
        ha-card {
          --ha-card-background: rgba(85, 85, 85, 0.10);
          margin: 5px 5px 0px 5px;
        }
    card:
      type: horizontal-stack
      cards:
        - type: custom:button-card
          entity: person.starworld
          aspect_ratio: 1.7/1
          name: starworld
          show_entity_picture: true
          show_name: false
          state:
            - value: home
              styles:
                entity_picture:
                  - color: green
                  - border: 1px solid
            - value: not_home
              styles:
                card: null
                entity_picture:
                  - color: red
                  - border: 1px solid
            - value: unknown
              styles:
                card: null
                entity_picture:
                  - color: red
                  - border: 1px solid
          styles:
            entity_picture:
              - border-radius: 50px
              - top: 16%
              - left: 0%
              - width: 35%
            card:
              - border-radius: 50px
              - padding: 5%
              - color: gray
              - font-size: 16px
              - '--mdc-ripple-color': rgb(68, 115, 158)
              - '--mdc-ripple-press-opacity': 0.5
              - box-shadow: 2px 2px 4px 0px rgba(0,0,0,0.5)
              - border: 1px rgba(0,0,0,1.0) outset
            custom_fields:
              icon:
                - clip-path: circle()
                - width: 80%
                - border: 5px solid
                - border-color: gray
                - border-radius: 500px
                - opacity: 1
              status:
                - top: '-3%'
                - left: 36%
                - position: absolute
                - font-size: 12px
                - color: rgb(68, 115, 158)
              locality:
                - top: 25%
                - left: 41%
                - position: absolute
                - font-size: 9px
                - color: rgb(68, 115, 158)
              battery:
                - top: 69%
                - left: 37.5%
                - position: absolute
                - color: green
                - '--text-color-sensor': >-
                    [[[ if
                    (states["sensor.asus_rog_phone_niveau_de_batterie"].state <
                    25) return "#EF4F1A"; ]]]
          custom_fields:
            status: |
              [[[
                if (states['person.starworld'].state =='not_home') { 
                return `<ha-icon icon="mdi:home-export-outline"
                  style="width: 28px; height: 38px; color: red;">
                  </ha-icon><span> Absent</span>`;
                } 
                if (states['person.starworld'].state =='home') { 
                return `<ha-icon icon="mdi:home"
                  style="width: 28px; height: 38px; color: green;">
                  </ha-icon><span> Maison</span>`;
                } 
                else {
                return `<ha-icon icon="mdi:map-marker-radius"
                  style="width: 28px; height: 38px; color: red;">
                  </ha-icon><span> ${entity.state}</span>`;
                }
              ]]]
            locality: |
              [[[
                if (states['person.starworld'].state =='not_home') { 
                 if (states['sensor.asus_rog_phone_lieu_geocode'].attributes.locality)
                 {return `<span>${states['sensor.asus_rog_phone_lieu_geocode'].attributes.locality}</span>`;}
                 else{return `<span> </span>`;}
                } 
                if (states['person.starworld'].state =='home') { 
                 return `<span> </span>`;
                } 
                else {
                 if (states['sensor.asus_rog_phone_lieu_geocode'].attributes.locality)
                 {return `<span>${states['sensor.asus_rog_phone_lieu_geocode'].attributes.locality}</span>`;}
                 else{return `<span> </span>`;}
                }
              ]]]
            battery: |
              [[[
                if (states['binary_sensor.asus_rog_phone_en_charge'].state =='on') { 
                  return `<ha-icon icon="mdi:battery-charging"
                  style="width: 23px; height: 23px; color: #888888;">
                  </ha-icon> <span><span style="color: var(--text-color-sensor);">${states['sensor.asus_rog_phone_niveau_de_batterie'].state}%</span></span>`;
                } 
                else {
                  return `<ha-icon icon="mdi:battery"
                  style="width: 23px; height: 23px; color: green;">
                  </ha-icon> <span><span style="color: var(--text-color-sensor);">${states['sensor.asus_rog_phone_niveau_de_batterie'].state}%</span></span>`;
                }
              ]]]
card_mod:
  style: |
    ha-card {
      box-shadow: 2px 2px 4px 0px rgba(0,0,0,0.5) !important;
      border: 1px rgba(0,0,0,1.0) outset;
    }
1 « J'aime »

Bonjour
La carte de mon routeur


Phil

Hello,
Merci pour l’idée et pour le cazou^^ la ligne availability devrait se changer en:


availability: "{{ (states('sensor.zlinky_hchc')|is_number 
              and states('sensor.zlinky_hchp')) 
              or states('sensor.zlinky_base')|is_number }}"
1 « J'aime »

Bonjour,

C’est une donnée du module Lixee ou un calcul ?

Salut,
c’est un calcul avec dérivative.

ça m’intéresse si ça ne t’ennuie pas partager ton code, j’ai fait quelque chose mais ça ne me convient pas

merci beaucoup

Voila comment j’ai fais:

Je suis en HP/HC. J’ai addition les HP + HC et les est convertie en Wh.
Et j’ai créer un sensor derivative avec comme source le template hp+hc.

1 « J'aime »

désolé, d’avoir redemander, tu avais effectivement pris la peine de tous détailler dans l’autre post.
Bonne journée

@WarC0zes : Alors et cette V2 ? :wink:

J’avais oublier :sweat_smile:
je la mettrais demain.

1 « J'aime »

Et au passage, tu utilises l’info
image
qui se paramètre dans le module energie ?

Non, j’utilise pas ça.

1 « J'aime »

Suite du message pour les cartes V2 ( limite atteinte sur le message :frowning: ).

Carte Linky :

Code
type: custom:vertical-stack-in-card
cards:
  - type: entities
    entities:
      - type: custom:text-divider-row
        text: LINKY
        align: center
    card_mod:
      style: |
        ha-card {
          top: -15px;
          background: none;
        }
  - type: custom:vertical-stack-in-card
    horizontal: true
    card_mod:
      style: |
        ha-card {
          margin-top: -50px;
          background: none;
        }
    cards:
      - type: custom:mushroom-template-card
        primary: Conso
        secondary: ' '
        icon: mdi:eye
        icon_color: '#44739E'
        fill_container: true
        layout: horizontal
        tap_action:
          action: none
        card_mod:
          style:
            mushroom-shape-icon$: |
              .shape {
                box-shadow: 2px 2px 4px 0px rgba(0,0,0,0.5) !important;
                border: 1px rgba(0,0,0,1.0) outset;
                --shape-color: rgba(32,32,32,0.2) !important;
              }
            .: |
              ha-card {
                background: none;
                width: 130px;
              }              
      - type: vertical-stack
        cards:
          - type: custom:mushroom-chips-card
            chips:
              - type: entity
                entity: sensor.zlinky_current_summation_derived_one_minute
                tap_action:
                  action: more-info
                hold_action:
                  action: none
                double_tap_action:
                  action: none
                icon: mdi:home-lightning-bolt
                content_info: state
                icon_color: '#44739e'
                card_mod:
                  style: |
                    ha-card {
                      box-shadow: 2px 2px 4px 0px rgba(0,0,0,0.5) !important;
                      border: 1px rgba(0,0,0,1.0) outset !important;
                    }
              - type: entity
                entity: sensor.0x00158d0005d299cf_papp
                tap_action:
                  action: more-info
                hold_action:
                  action: none
                double_tap_action:
                  action: none
                icon: mdi:lightning-bolt-circle
                icon_color: '#44739e'
                content_info: state
                card_mod:
                  style: |
                    ha-card {
                      box-shadow: 2px 2px 4px 0px rgba(0,0,0,0.5) !important;
                      border: 1px rgba(0,0,0,1.0) outset !important;
                    }
              - type: entity
                entity: sensor.0x00158d0005d299cf_iinst
                tap_action:
                  action: more-info
                hold_action:
                  action: none
                double_tap_action:
                  action: none
                icon: mdi:lightning-bolt-circle
                icon_color: '#44739e'
                content_info: state
                card_mod:
                  style: |
                    ha-card {
                      box-shadow: 2px 2px 4px 0px rgba(0,0,0,0.5) !important;
                      border: 1px rgba(0,0,0,1.0) outset !important;
                    }                   
            alignment: end
            card_mod:
              style: |
                ha-card {top:60%;right:5%;margin-left: -100px;}
  - type: custom:vertical-stack-in-card
    horizontal: true
    card_mod:
      style: |
        ha-card {
          margin-top: -15px;
          background: none;
        }
    cards:
      - type: custom:mushroom-template-card
        primary: Index
        secondary: ' '
        icon: mdi:transmission-tower
        icon_color: '#44739E'
        fill_container: true
        layout: horizontal
        tap_action:
          action: none
        card_mod:
          style:
            mushroom-shape-icon$: |
              .shape {
                box-shadow: 2px 2px 4px 0px rgba(0,0,0,0.5) !important;
                border: 1px rgba(0,0,0,1.0) outset;
                --shape-color: rgba(32,32,32,0.2) !important;
              }
            .: |
              ha-card {
                background: none;
                width: 130px;
              }              
      - type: vertical-stack
        cards:
          - type: custom:mushroom-chips-card
            chips:
              - type: template
                icon: >
                  {% if
                  is_state('sensor.0x00158d0005d299cf_active_register_tier_delivered',
                  'HP..') %}
                    mdi:lightning-bolt
                  {% else %}
                    mdi:lightning-bolt-outline
                  {% endif %}                 
                entity: sensor.0x00158d0005d299cf_active_register_tier_delivered
                content: >
                  {% if
                  is_state('sensor.0x00158d0005d299cf_active_register_tier_delivered',
                  'HP..') %}
                    HP
                  {% else %}
                    HC
                  {% endif %}
                icon_color: >-
                  {% if
                  is_state('sensor.0x00158d0005d299cf_active_register_tier_delivered',
                  'HP..') %} 
                    red
                  {% else %}
                    green
                  {% endif %}                
                tap_action:
                  action: more-info
                card_mod:
                  style: |
                    ha-card {
                      box-shadow: 2px 2px 4px 0px rgba(0,0,0,0.5) !important;
                      border: 1px rgba(0,0,0,1.0) outset !important;
                    }
              - type: template
                icon: mdi:lightning-bolt
                entity: sensor.0x00158d0005d299cf_hchp
                content: 'HP: {{ states("sensor.0x00158d0005d299cf_hchp") |round(0) }}'
                icon_color: red
                tap_action:
                  action: more-info
                card_mod:
                  style: |
                    ha-card {
                      box-shadow: 2px 2px 4px 0px rgba(0,0,0,0.5) !important;
                      border: 1px rgba(0,0,0,1.0) outset !important;
                    }                    
              - type: template
                icon: mdi:lightning-bolt-outline
                entity: sensor.0x00158d0005d299cf_hchc
                content: 'HC: {{ states("sensor.0x00158d0005d299cf_hchc") |round(0)  }}'
                icon_color: green
                tap_action:
                  action: more-info
                card_mod:
                  style: |
                    ha-card {
                      box-shadow: 2px 2px 4px 0px rgba(0,0,0,0.5) !important;
                      border: 1px rgba(0,0,0,1.0) outset !important;
                    }                   
            alignment: end
            card_mod:
              style: |
                ha-card {top:60%;right:5%;margin-left: -130px;}
  - type: custom:vertical-stack-in-card
    horizontal: true
    card_mod:
      style: |
        ha-card {
          margin-top: -15px;
          background: none;
        }
    cards:
      - type: custom:mushroom-template-card
        primary: Total
        secondary: ' '
        icon: mdi:flash
        icon_color: '#44739E'
        fill_container: true
        layout: horizontal
        tap_action:
          action: none
        card_mod:
          style:
            mushroom-shape-icon$: |
              .shape {
                box-shadow: 2px 2px 4px 0px rgba(0,0,0,0.5) !important;
                border: 1px rgba(0,0,0,1.0) outset;
                --shape-color: rgba(32,32,32,0.2) !important;
              }
            .: |
              ha-card {
                background: none;
                width: 130px;
              }              
      - type: vertical-stack
        cards:
          - type: custom:mushroom-chips-card
            chips:
              - type: template
                icon: mdi:matrix
                icon_color: >
                  {% if
                  is_state('sensor.0x00158d0005d299cf_active_register_tier_delivered',
                  'HP..') %} 
                    red
                  {% else %}
                    green
                  {% endif %}                
                tap_action:
                  action: fire-dom-event
                  browser_mod:
                    service: browser_mod.popup
                    data:
                      browser_id: THIS
                      size: normal
                      style: |
                        --popup-border-radius: 10px;
                        --popup-padding-x: 5px;
                        --popup-padding-y: -15px;                        
                      content:
                        type: custom:vertical-stack-in-card
                        cards:
                          - type: picture
                            image: /local/images/wled.png
                            card_mod:
                              style: |
                                ha-card {
                                  border-radius: 0px;
                                }
                          - type: custom:vertical-stack-in-card
                            horizontal: true
                            card_mod:
                              style: |
                                ha-card {
                                  margin-top: -5px;
                                  background: none;
                                }    
                            cards:
                              - type: custom:mushroom-template-card
                                primary: IP interne
                                secondary: ' '
                                icon: mdi:ip-network
                                icon_color: '#44739E'
                                fill_container: true
                                layout: horizontal
                                tap_action:
                                  action: none
                                card_mod:
                                  style:
                                    mushroom-shape-icon$: |
                                      .shape {
                                        box-shadow: 2px 2px 4px 0px rgba(0,0,0,0.5) !important;
                                        border: 1px rgba(0,0,0,1.0) outset;
                                        --shape-color: rgba(32,32,32,0.2) !important;
                                      }
                                    .: |
                                      ha-card {
                                        background: none;
                                        width: 140px;
                                      }
                              - type: vertical-stack
                                cards:
                                  - type: custom:mushroom-chips-card
                                    chips:
                                      - type: template
                                        icon: mdi:ip
                                        entity: sensor.wled_ip
                                        content: '{{ states("sensor.wled_ip") }}'
                                        icon_color: '#44739E'
                                        tap_action:
                                          action: more-info
                                        card_mod:
                                          style: |
                                            ha-card {
                                              box-shadow: 2px 2px 4px 0px rgba(0,0,0,0.5) !important;
                                              border: 1px rgba(0,0,0,1.0) outset !important;
                                            }            
                                      - type: template
                                        entity: sensor.wled_wi_fi_signal
                                        icon: mdi:wifi
                                        icon_color: '#44739E'
                                        content: >-
                                          {{ states("sensor.wled_wi_fi_signal") }}
                                          %
                                        tap_action:
                                          action: more-info
                                        card_mod:
                                          style: |
                                            ha-card {
                                              box-shadow: 2px 2px 4px 0px rgba(0,0,0,0.5) !important;
                                              border: 1px rgba(0,0,0,1.0) outset !important;
                                            }
                                    alignment: end
                                    card_mod:
                                      style: >
                                        ha-card {top:60%;right:5%;margin-left:
                                        -100px;}
                          - type: custom:vertical-stack-in-card
                            horizontal: true
                            card_mod:
                              style: |
                                ha-card {
                                  margin-top: -15px;
                                  background: none;
                                }
                            cards:
                              - type: custom:mushroom-template-card
                                primary: Statut
                                secondary: ' '
                                icon: mdi:clock-start
                                icon_color: '#44739E'
                                fill_container: true
                                layout: horizontal
                                tap_action:
                                  action: none
                                card_mod:
                                  style:
                                    mushroom-shape-icon$: |
                                      .shape {
                                        box-shadow: 2px 2px 4px 0px rgba(0,0,0,0.5) !important;
                                        border: 1px rgba(0,0,0,1.0) outset;
                                        --shape-color: rgba(32,32,32,0.2) !important;
                                      }
                                    .: |
                                      ha-card {
                                        background: none;
                                      }              
                              - type: vertical-stack
                                cards:
                                  - type: custom:mushroom-chips-card
                                    chips:
                                      - type: template
                                        icon: mdi:wan
                                        entity: device_tracker.wled
                                        icon_color: >
                                          {% if states("device_tracker.wled") ==
                                          'home' %} 
                                            green
                                          {% else %}
                                            red
                                          {% endif
                                          %}                                        
                                        content: >
                                          {% if states("device_tracker.wled") ==
                                          "home" %}
                                            Maison
                                          {% else %}
                                            Absent
                                          {% endif %}
                                        tap_action:
                                          action: more-info
                                        card_mod:
                                          style: |
                                            ha-card {
                                              box-shadow: 2px 2px 4px 0px rgba(0,0,0,0.5) !important;
                                              border: 1px rgba(0,0,0,1.0) outset !important;
                                            }            
                                      - type: template
                                        icon: mdi:clock-start
                                        entity: sensor.wled_uptime
                                        icon_color: '#44739E'
                                        content: >-
                                          {% set uptime = (now()| as_timestamp -
                                          states('sensor.wled_uptime') |
                                          as_timestamp ) %} {% set jours = (uptime
                                          / 86400) | int(0) %} {%- if jours > 0
                                          -%} {{ jours }}j {{ (uptime - (jours *
                                          86400)) | int(0) | timestamp_custom('%Hh
                                          %Mm', false) }} {%- else -%} {{ uptime |
                                          int(0) | timestamp_custom('%Hh %Mm',
                                          false) }} {%- endif -%}
                                        tap_action:
                                          action: more-info
                                        card_mod:
                                          style: |
                                            ha-card {
                                              box-shadow: 2px 2px 4px 0px rgba(0,0,0,0.5) !important;
                                              border: 1px rgba(0,0,0,1.0) outset !important;
                                            }
                                    alignment: end
                                    card_mod:
                                      style: |
                                        ha-card {
                                          top: 60%;
                                          right: 5%;
                                        }
                          - type: custom:vertical-stack-in-card
                            horizontal: true
                            card_mod:
                              style: |
                                ha-card {
                                  margin-top: -15px;
                                  background: none;
                                }    
                            cards:
                              - type: custom:mushroom-template-card
                                primary: Led
                                secondary: ' '
                                icon: mdi:led-strip-variant
                                icon_color: '#44739E'
                                fill_container: true
                                layout: horizontal
                                tap_action:
                                  action: none
                                card_mod:
                                  style:
                                    mushroom-shape-icon$: |
                                      .shape {
                                        box-shadow: 2px 2px 4px 0px rgba(0,0,0,0.5) !important;
                                        border: 1px rgba(0,0,0,1.0) outset;
                                        --shape-color: rgba(32,32,32,0.2) !important;
                                      }
                                    .: |
                                      ha-card {
                                        background: none;
                                        width: 110px;
                                      }
                              - type: vertical-stack
                                cards:
                                  - type: custom:mushroom-chips-card
                                    chips:
                                      - type: template
                                        entity: sensor.wled_led_count
                                        icon: mdi:led-strip
                                        icon_color: '#44739E'
                                        content: '{{ states("sensor.wled_led_count") }}'
                                        tap_action:
                                          action: more-info
                                        card_mod:
                                          style: |
                                            ha-card {
                                              box-shadow: 2px 2px 4px 0px rgba(0,0,0,0.5) !important;
                                              border: 1px rgba(0,0,0,1.0) outset !important;
                                            }            
                                      - type: template
                                        entity: sensor.wled_estimated_current
                                        icon: mdi:current-ac
                                        icon_color: '#44739E'
                                        content: >-
                                          {{
                                          states("sensor.wled_estimated_current")
                                          }} mA
                                        tap_action:
                                          action: more-info
                                        card_mod:
                                          style: |
                                            ha-card {
                                              box-shadow: 2px 2px 4px 0px rgba(0,0,0,0.5) !important;
                                              border: 1px rgba(0,0,0,1.0) outset !important;
                                            }
                                      - type: action
                                        icon_color: '#44739E'
                                        tap_action:
                                          action: none
                                        hold_action:
                                          action: none
                                        double_tap_action:
                                          action: none
                                        icon: mdi:slash-forward
                                        card_mod:
                                          style: |
                                            ha-card {
                                              box-shadow: 2px 2px 4px 0px rgba(0,0,0,0.5) !important;
                                              border: 1px rgba(0,0,0,1.0) outset !important;
                                            }                
                                      - type: template
                                        entity: sensor.wled_max_current
                                        icon: mdi:current-ac
                                        icon_color: '#44739E'
                                        content: >-
                                          {{ states("sensor.wled_max_current") }}
                                          mA
                                        tap_action:
                                          action: more-info
                                        card_mod:
                                          style: |
                                            ha-card {
                                              box-shadow: 2px 2px 4px 0px rgba(0,0,0,0.5) !important;
                                              border: 1px rgba(0,0,0,1.0) outset !important;
                                            }
                                    alignment: end
                                    card_mod:
                                      style: >
                                        ha-card {top:60%;right:5%;margin-left:
                                        -130px;}
                          - type: entities
                            entities:
                              - type: custom:text-divider-row
                                text: Paramètres
                                align: center
                            card_mod:
                              style: |
                                ha-card {
                                  margin-top: -25px;
                                  margin-bottom: -30px;
                                  background: none;
                                }
                          - type: custom:vertical-stack-in-card
                            horizontal: true
                            card_mod:
                              style: |
                                ha-card {
                                  margin-top: -25px;
                                  background: none;
                                }    
                            cards:
                              - type: custom:mushroom-template-card
                                primary: WLED Matrix
                                secondary: ' '
                                icon: mdi:led-strip-variant
                                icon_color: '#44739E'
                                fill_container: true
                                layout: horizontal
                                tap_action:
                                  action: none
                                card_mod:
                                  style:
                                    mushroom-shape-icon$: |
                                      .shape {
                                        box-shadow: 2px 2px 4px 0px rgba(0,0,0,0.5) !important;
                                        border: 1px rgba(0,0,0,1.0) outset;
                                        --shape-color: rgba(32,32,32,0.2) !important;
                                      }
                                    .: |
                                      ha-card {
                                        background: none;
                                        width: 160px;
                                      }
                              - type: vertical-stack
                                cards:
                                  - type: custom:mushroom-chips-card
                                    chips:
                                      - type: template
                                        icon: mdi:led-strip-variant
                                        entity: light.wled
                                        icon_color: >
                                          {% if states("light.wled") == 'on' %} 
                                            green
                                          {% else %}
                                            red
                                          {% endif
                                          %}                                        
                                        content: |
                                          {% if is_state('light.wled','on') %}
                                           Allumé
                                          {% else %}
                                           Éteint
                                          {% endif %}
                                        card_mod:
                                          style: |
                                            ha-card {
                                              box-shadow: 2px 2px 4px 0px rgba(0,0,0,0.5) !important;
                                              border: 1px rgba(0,0,0,1.0) outset !important;
                                            }            
                                      - type: template
                                        entity: automation.wled_matrix_hphc
                                        icon: mdi:robot
                                        icon_color: >
                                          {% if
                                          states("automation.wled_matrix_hphc") ==
                                          'on' %} 
                                            green
                                          {% else %}
                                            red
                                          {% endif
                                          %}                                        
                                        content: >
                                          {% if
                                          is_state('automation.wled_matrix_hphc','on')
                                          %}
                                           Allumé
                                          {% else %}
                                           Éteint
                                          {% endif %}
                                        tap_action:
                                          action: more-info
                                        card_mod:
                                          style: |
                                            ha-card {
                                              box-shadow: 2px 2px 4px 0px rgba(0,0,0,0.5) !important;
                                              border: 1px rgba(0,0,0,1.0) outset !important;
                                            }
                                    alignment: end
                                    card_mod:
                                      style: >
                                        ha-card {top:60%;right:5%;margin-left:
                                        -100px;}
                          - type: custom:mushroom-number-card
                            entity: number.wled_intensity
                            layout: horizontal
                            display_mode: buttons
                            icon_color: '#44739e'
                            card_mod:
                              style:
                                mushroom-shape-icon$: |
                                  .shape {
                                    box-shadow: 2px 2px 4px 0px rgba(0,0,0,0.5) !important;
                                    border: 1px rgba(0,0,0,1.0) outset;
                                    --shape-color: rgba(32,32,32,0.2) !important;
                                  }
                                mushroom-number-value-control$:
                                  mushroom-input-number$: |
                                    #container {
                                      box-shadow: 2px 2px 4px 0px rgba(0,0,0,0.5) !important;
                                      border: 1px rgba(0,0,0,1.0) outset;
                                      border-radius: 25px;
                                      width: 65%;
                                      margin-left: 90px;
                                    }            
                                .: |
                                  ha-card {
                                    margin-top: -15px;          
                                    background: none;
                                  }
                          - type: custom:mushroom-number-card
                            entity: number.wled_speed
                            layout: horizontal
                            display_mode: buttons
                            icon_color: '#44739E'
                            card_mod:
                              style:
                                mushroom-shape-icon$: |
                                  .shape {
                                    box-shadow: 2px 2px 4px 0px rgba(0,0,0,0.5) !important;
                                    border: 1px rgba(0,0,0,1.0) outset;
                                    --shape-color: rgba(32,32,32,0.2) !important;
                                  }
                                mushroom-number-value-control$:
                                  mushroom-input-number$: |
                                    #container {
                                      box-shadow: 2px 2px 4px 0px rgba(0,0,0,0.5) !important;
                                      border: 1px rgba(0,0,0,1.0) outset;
                                      border-radius: 25px;
                                      width: 65%;
                                      margin-left: 90px;
                                    }
                                .: |
                                  ha-card {
                                    margin-top: -15px;
                                    margin-bottom: -12px;
                                    background: none;
                                  }
                          - type: custom:vertical-stack-in-card
                            horizontal: true
                            card_mod:
                              style: |
                                ha-card {
                                  background: none;
                                }    
                            cards:
                              - type: custom:mushroom-select-card
                                entity: select.wled_preset
                                layout: horizontal
                                icon_color: '#44739E'
                                card_mod:
                                  style:
                                    mushroom-shape-icon$: |
                                      .shape {
                                        box-shadow: 2px 2px 4px 0px rgba(0,0,0,0.5) !important;
                                        border: 1px rgba(0,0,0,1.0) outset !important;
                                        --shape-color: rgba(32,32,32,0.2) !important;
                                      }            
                                    mushroom-select-option-control$:
                                      mushroom-select$: |
                                        .mdc-select__anchor{
                                          box-shadow: 2px 2px 4px 0px rgba(0,0,0,0.5) !important;
                                          border: 1px rgba(0,0,0,1.0) outset !important;
                                          border-radius: 25px !important;
                                        }
                                        .mdc-line-ripple::before,
                                        .mdc-line-ripple::after {
                                        border-bottom-style: none !important;
                                        }
                                      .: |
                                        ha-card {
                                          background: none;
                                        }           
                          - type: custom:vertical-stack-in-card
                            horizontal: true
                            card_mod:
                              style: |
                                ha-card {
                                  margin-top: -17px;
                                  background: none;
                                }    
                            cards:
                              - type: custom:mushroom-template-card
                                primary: WLED Texte
                                secondary: ' '
                                icon: mdi:text
                                icon_color: '#44739E'
                                fill_container: true
                                layout: horizontal
                                tap_action:
                                  action: none
                                card_mod:
                                  style:
                                    mushroom-shape-icon$: |
                                      .shape {
                                        box-shadow: 2px 2px 4px 0px rgba(0,0,0,0.5) !important;
                                        border: 1px rgba(0,0,0,1.0) outset;
                                        --shape-color: rgba(32,32,32,0.2) !important;
                                      }
                                    .: |
                                      ha-card {
                                        background: none;
                                        width: 160px;
                                      }
                              - type: vertical-stack
                                cards:
                                  - type: entities
                                    entities:
                                      - entity: input_text.wled_matrix_text
                                        icon: ' '
                                    state_color: true
                                    show_header_toggle: false
                                    card_mod:
                                      style: |
                                        ha-card {
                                          background: none;
                                          margin-left: -130px;
                                          margin-bottom: -5px;
                                        }
                card_mod:
                  style: |
                    ha-card {
                      box-shadow: 2px 2px 4px 0px rgba(0,0,0,0.5) !important;
                      border: 1px rgba(0,0,0,1.0) outset !important;
                    }
              - type: template
                icon: mdi:gauge-full
                entity: sensor.zlinky_metering_hc_hp_sum
                content: >-
                  {{ (states('sensor.zlinky_metering_hc_hp_sum') |int(0) /1000 )
                  | round(0) }}
                icon_color: '#44739E'
                tap_action:
                  action: more-info
                card_mod:
                  style: |
                    ha-card {
                      box-shadow: 2px 2px 4px 0px rgba(0,0,0,0.5) !important;
                      border: 1px rgba(0,0,0,1.0) outset !important;
                    }                    
              - type: template
                icon: mdi:zigbee
                entity: sensor.0x00158d0005d299cf_hchc
                content: >-
                  {{ state_attr("sensor.0x00158d0005d299cf_papp","linkquality")
                  }}
                icon_color: '#44739E'
                tap_action:
                  action: more-info
                card_mod:
                  style: |
                    ha-card {
                      box-shadow: 2px 2px 4px 0px rgba(0,0,0,0.5) !important;
                      border: 1px rgba(0,0,0,1.0) outset !important;
                    }                   
            alignment: end
            card_mod:
              style: |
                ha-card {top:60%;right:5%;margin-left: -130px;}
  - type: custom:energy-overview-card
    entities:
      - power: sensor.zlinky_current_summation_derived_one_minute
        current: sensor.0x00158d0005d299cf_iinst
        label_leading: Enedis
        label_trailing: Maison
        icon_leading: mdi:transmission-tower
        icon_trailing: mdi:home-lightning-bolt
        color: '#488fc2'
        animation:
          power: 1000
          min_duration: 1
          max_duration: 10
    card_mod:
      style: |
        :host {
          --card-mod-icon-color: #44739e;
          --mdc-icon-size: 26px;
        }
        ha-card {
          margin-top: -10px;
          background: transparent;
        }        
  - type: custom:mod-card
    card_mod:
      style:
        .: |
          ha-card {
            margin: -20px 10px 0px 0px;
          }
    card:
      type: energy-date-selection
      card_mod:
        style:
          hui-energy-period-selector$:
            mwc-button$: |
              #button {
                box-shadow: 2px 2px 4px 0px rgba(0,0,0,0.5);
                border: 1px rgba(0,0,0,1.0) outset;
                border-radius: 25px;
              }
          .: |
            ha-card {
              background: none;
            }
  - type: energy-usage-graph
    card_mod:
      style: |
        ha-card {
          --divider-color: #44739e;
          margin-top: -20px;
          background: transparent;
        }
  - type: energy-sources-table
    card_mod:
      style: |
        ha-card {
          box-shadow: none;
          margin-top: -19px;
        }     
card_mod:
  style: |
    ha-card {
      box-shadow: 0 0 0 1px gray;
      overflow: visible !important;
    }

Cartes V2 message principal >>> [ CARTE ] Cartes diverses ( Livebox, NAS, RPI, BLE Proxy...) - #174 par WarC0zes

1 « J'aime »

Bonjour
Le code d’addition ne semble pas complet sur ce post
Merci d’avance
Philippe

J’ai corrigé, mais le code original est dans le sujet a la base. J’ai fais un mauvais copier la sélection.

Je ne trouve pas ?
Je ne trouve qu’un message mais avec un code incomplet
Et le dernier post renvoie vers le post principal qui renvoie vers ce post etc ……
Merci d’avance
Philippe

C’est le code complet, pour additionné les HP+HC:

pour le template:

template:
  - sensor:
      - name: zlinky_metering_HC_HP_sum
        unit_of_measurement: "Wh"
        device_class: energy
        state_class: total_increasing
        state: >-
          {% set HC = states('sensor.0x00158d0005d299cf_hchc')|float(default=0)*1000 %}
          {% set HP = states('sensor.0x00158d0005d299cf_hchp')|float(default=0)*1000 %}
          {{ HC + HP |int(default=0) }}
        availability: > 
          {{ states('sensor.0x00158d0005d299cf_hchc')|is_number
          and states('sensor.0x00158d0005d299cf_hchp')|is_number }}

Et le sensor dérivative, pour avoir les watts par minute:

sensor:
  - platform: derivative
    source: sensor.zlinky_metering_HC_HP_sum
    name: zlinky_current_summation_derived_one_minute
    round: 0
    unit_time: h
    unit: W
    time_window: "00:01:00"

Merci
J’ai trop l’habitude des 6 sensors avec Tempo
Voilà le code pour tempo sur base esphome


- name: "linky metering HC HP sum"
  unit_of_measurement: "Wh"
  device_class: energy
  state_class: total_increasing
  state: >-
          {% set HCB = states('sensor.linky_tempo_index_bbrhcjb')|float(default=0)*1000 %}
          {% set HPB = states('sensor.linky_tempo_index_bbrhpjb')|float(default=0)*1000 %}
          {% set HCW = states('sensor.linky_tempo_index_bbrhcjw')|float(default=0)*1000 %}
          {% set HPW = states('sensor.linky_tempo_index_bbrhpjw')|float(default=0)*1000 %}
          {% set HCR = states('sensor.linky_tempo_index_bbrhcjr')|float(default=0)*1000 %}
          {% set HPR = states('sensor.linky_tempo_index_bbrhpjr')|float(default=0)*1000 %}
          {{ HCB + HPB + HCW + HPW + HCR + HPR |int(default=0) }}
  availability: > 
          {{ states('sensor.linky_tempo_index_bbrhcjb')|is_number and states('sensor.linky_tempo_index_bbrhpjb')|is_number and states('sensor.linky_tempo_index_bbrhcjw')|is_number and states('sensor.linky_tempo_index_bbrhpjw')|is_number and states('sensor.linky_tempo_index_bbrhcjr')|is_number and states('sensor.linky_tempo_index_bbrhpjr')|is_number }}

La dérivée je la fais plutôt avec l’intégration dérivée qu’avec du yaml

Je progresse sur la carte qui demande à être considérablement modifiée

Phil