Hello guest, if you read this it means you are not registered. Click here to register in a few simple steps, you will enjoy all features of our Forum.
Hi Guest this is an announcement for guests !!!

Note de ce sujet :
  • Moyenne : 0 (0 vote(s))
  • 1
  • 2
  • 3
  • 4
  • 5
3. Carte Plotly graphique
#1
Aujourd'hui on va mettre la carte potly pour des graphique ha un peut plus poussés

   

Pour commencer il faudra Hacs (voir mon tuto carte sumsynk)
https://smartphoton.ch/forum/thread-715.html

Une fois que vous avez installé hacs, aller dans le menu à gauche et hacs => interface => le + en bas à droite
Et vous recherchez Plotly Graph Card
Vous pouvez l'installer


Maintenant rdv dans notre beau tableau de bord

3 petits points en haut à droite => Modifier le tableau de bord => Ajouter une carte et recherché Plotly 

Afficher le code et on colle les petits capteurs de Smartphoton ci dessous 

Code :
type: custom:plotly-graph
defaults:
  entity:
    show_value: true
entities:
  - entity: sensor.voltronic_1_conso_maison_watt
    name: Conso
    fill: tozeroy
    extend_to_present: false
    line:
      width: 0.5
      color: '#e74c3c'
      shape: spline
    filters:
      - resample: 2m
  - entity: sensor.voltronic_1_pv_watt
    name: Prod
    fill: tozeroy
    line:
      width: 1
      color: orange
      shape: spline
    filters:
      - resample: 1m
  - entity: sensor.voltronic_1_batt_charge_watt
    name: Charge
    fill: tozeroy
    line:
      width: 0.5
      color: dodgerblue
      shape: spline
    filters:
      - resample: 1m
  - entity: sensor.voltronic_1_batt_decharge_watt
    name: Decharge
    fill: tozeroy
    line:
      width: 0.5
      color: '#9b59b6'
      shape: spline
    filters:
      - resample: 1m
hours_to_show: 2
refresh_interval: auto
layout:
  xaxis:
    rangeselector:
      'y': 1.2
      buttons:
        - count: 1
          step: minute
        - count: 1
          step: hour
        - count: 2
          step: hour
        - count: 6
          step: hour
        - count: 12
          step: hour
        - count: 1
          step: day
        - count: 7
          step: day


Ou en négatif pour la décharge
   

Code :
type: custom:plotly-graph
defaults:
  entity:
    show_value: true
entities:
  - entity: sensor.voltronic_1_conso_maison_watt
    name: Conso
    fill: tozeroy
    extend_to_present: false
    line:
      width: 0.5
      color: '#e74c3c'
      shape: spline
    filters:
      - resample: 2m
  - entity: sensor.voltronic_1_pv_watt
    name: Prod
    fill: tozeroy
    line:
      width: 1
      color: orange
      shape: spline
    filters:
      - resample: 1m
  - entity: sensor.voltronic_1_batt_charge_decharge_watt
    name: Charge Decharge
    fill: tozeroy
    line:
      width: 0.5
      color: dodgerblue
      shape: spline
    filters:
      - resample: 1m
hours_to_show: 2
refresh_interval: auto
layout:
  xaxis:
    rangeselector:
      'y': 1.2
      buttons:
        - count: 1
          step: minute
        - count: 1
          step: hour
        - count: 2
          step: hour
        - count: 6
          step: hour
        - count: 12
          step: hour
        - count: 1
          step: day
        - count: 7
          step: day

   

Voila un petit graphique bien sympas, qui peux etres encore améliorer. ;)
Like Répondre
#2
1 Dashboard
https://smartphoton.ch/forum/thread-714.html

1.1 Onduleur Parallèles
https://smartphoton.ch/forum/thread-795-...ml#pid6357

2 Carte sumsynk
https://smartphoton.ch/forum/thread-715.html

3. Suite carte graphique
https://smartphoton.ch/forum/thread-719.html

4. Thème
https://smartphoton.ch/forum/thread-720.html
Like Répondre
#3
oui là ça a de l'allure. Merci pour le tuto
Jean-Luc
Like Répondre
#4
Bon je rajoute pour ceux qui veulent du négatif
   

Code :
type: custom:plotly-graph
defaults:
  entity:
    show_value: true
entities:
  - entity: sensor.voltronic_1_conso_maison_watt
    name: Conso
    fill: tozeroy
    extend_to_present: false
    line:
      width: 0.5
      color: '#e74c3c'
      shape: spline
    filters:
      - resample: 2m
  - entity: sensor.voltronic_1_pv_watt
    name: Prod
    fill: tozeroy
    line:
      width: 1
      color: orange
      shape: spline
    filters:
      - resample: 1m
  - entity: sensor.voltronic_1_batt_charge_decharge_watt
    name: Charge Decharge
    fill: tozeroy
    line:
      width: 0.5
      color: dodgerblue
      shape: spline
    filters:
      - resample: 1m
hours_to_show: 2
refresh_interval: auto
layout:
  xaxis:
    rangeselector:
      'y': 1.2
      buttons:
        - count: 1
          step: minute
        - count: 1
          step: hour
        - count: 2
          step: hour
        - count: 6
          step: hour
        - count: 12
          step: hour
        - count: 1
          step: day
        - count: 7
          step: day
Like Répondre
#5
Ajout petit carte production journalière

   

Code :
type: custom:plotly-graph
entities:
  - entity: sensor.production_pv_wh_heure
    name: Production Jour
    type: bar
    statistic: state
    texttemplate: '%{y:.2f}'
    period: hour
    number:
      suffix: ' kWh'
      valueformat: '0.11'
    textfont:
      color: white
      size: 10
    marker:
      color: '#f39c12'
      opacity: 0.6
hours_to_show: current_day
time_offset: 1h
refresh_interval: auto
layout:
  paper_bgcolor: rgba(0,0,0,0)
  plot_bgcolor: rgba(0,0,0,0)
  barmode: relative
  bargap: 0.1
  uniformtext:
    minsize: 12
    mode: show
  modebar:
    orientation: h
    remove: pan
  margin:
    t: 10
    l: 1
    r: 1
  height: 300
  legend:
    'y': -0.25
    x: 0.02
  xaxis:
    gridcolor: rgba(238,235,235,0.3)
    showgrid: false
    linewidth: 0
    linecolor: null
    nticks: 8
  yaxis:
    visible: false
Like Répondre
#6
inarrêtable, là ça devient du lourd. Perso ça me plait !  Thumbsup
Jean-Luc
Like Répondre
#7
merci ! 
super

comment inverser le sens des ions entre onduleur et batterie ?
et comment agrandir le tout ?
   

trouvé dans General Options !
Like Répondre
#8
Pour inverser le sens de la carte sumsynk :
- modifier la carte
- Batterie options
- invert power

Pour mettre en plus gros tout dépend de la taille de ton écran
Mais tu as la solution de faire une nouvelle vue et en type tu met panneau (1 carte)
Like Répondre
#9
Petite amélioration du graph production jour :


   

Code :
type: custom:plotly-graph
entities:
  - entity: sensor.production_pv_wh_jour
    name: production Jour
    offset: 1
    type: bar
    statistic: state
    texttemplate: '%{y:.2f}'
    period: hour
    number:
      suffix: ' kWh'
      valueformat: '0.11'
    textfont:
      color: white
      size: 10
    opacity: 0.9
    marker:
      color: '#2980b9'
      opacity: 0.6
  - entity: sensor.production_pv_wh_heure
    name: Production heure
    type: bar
    offset: 1
    statistic: state
    texttemplate: '%{y:.2f}'
    period: hour
    number:
      suffix: ' kWh'
      valueformat: '0.11'
    textfont:
      color: white
      size: 10
    opacity: 1
    marker:
      color: '#f39c12'
      opacity: 0.6
  - entity: sensor.production_pv_wh_jour
    name: Hier Jour
    offset: 2
    type: bar
    visible: legendonly
    statistic: state
    time_offset: +1.0d
    texttemplate: '%{y:.2f}'
    period: hour
    number:
      suffix: ' kWh'
      valueformat: '0.11'
    textfont:
      color: white
      size: 10
    opacity: 0.5
    marker:
      color: '#95a5a6'
      opacity: 0.6
  - entity: sensor.production_pv_wh_heure
    name: Hier Heure
    offset: 1
    type: bar
    time_offset: +1.0d
    visible: legendonly
    statistic: state
    texttemplate: '%{y:.2f}'
    period: hour
    number:
      suffix: ' kWh'
      valueformat: '0.11'
    textfont:
      color: white
      size: 10
    opacity: 1
    marker:
      color: grey
      opacity: 0.6
hours_to_show: current_day
refresh_interval: auto
layout:
  paper_bgcolor: rgba(0,0,0,0)
  plot_bgcolor: rgba(0,0,0,0)
  bargap: 0.1
  uniformtext:
    minsize: 12
    mode: show
  modebar:
    orientation: h
    remove: pan
  margin:
    t: 10
    l: 1
    r: 1
  height: 300
  legend:
    'y': -0.25
    x: 0.02
  xaxis:
    gridcolor: rgba(238,235,235,0.3)
    showgrid: false
    linewidth: 0
    linecolor: null
    nticks: 8
  yaxis:
    visible: false
Like Répondre
#10
Amélioration graphique avec filtre journée d'hier

   

charge et décharge  en positif
Code :
type: custom:plotly-graph
defaults:
  entity:
    show_value: true
entities:
  - entity: sensor.voltronic_1_conso_maison_watt
    time_offset: +1.0d
    name: Conso hier
    visible: legendonly
    fill: tozeroy
    extend_to_present: false
    line:
      width: 0.5
      color: '#bdc3c7'
      shape: spline
    filters:
      - resample: 2m
  - entity: sensor.voltronic_1_conso_maison_watt
    name: Conso
    fill: tozeroy
    extend_to_present: false
    line:
      width: 0.5
      color: '#e74c3c'
      shape: spline
    filters:
      - resample: 2m
  - entity: sensor.voltronic_1_pv_watt
    name: Prod hier
    visible: legendonly
    time_offset: +1.0d
    fill: tozeroy
    line:
      width: 1
      color: '#2ecc71'
      shape: spline
    filters:
      - resample: 1m
  - entity: sensor.voltronic_1_pv_watt
    name: Prod
    fill: tozeroy
    line:
      width: 1
      color: orange
      shape: spline
    filters:
      - resample: 1m
  - entity: sensor.voltronic_1_batt_charge_watt
    name: Charge
    fill: tozeroy
    line:
      width: 0.5
      color: dodgerblue
      shape: spline
    filters:
      - resample: 1m
  - entity: sensor.voltronic_1_batt_decharge_watt
    name: Decharge
    fill: tozeroy
    line:
      width: 0.5
      color: '#9b59b6'
      shape: spline
    filters:
      - resample: 1m
hours_to_show: 2
refresh_interval: auto
layout:
  margin:
    autoexpand: true
    b: 80
  xaxis:
    showgrid: false
    rangeselector:
      'y': -0.4
      x: 0.2
      bordercolor: '#eeeeee50'
      borderwidth: 1
      bgcolor: '#eeeeee00'
      activecolor: '#0000ff30'
      buttons:
        - count: 1
          step: minute
        - count: 1
          step: hour
        - count: 2
          step: hour
        - count: 6
          step: hour
        - count: 12
          step: hour
        - count: 1
          step: day
        - count: 7
          step: day

Charge positif et décharge négatif
Code :
type: custom:plotly-graph
defaults:
  entity:
    show_value: true
entities:
  - entity: sensor.voltronic_1_conso_maison_watt
    time_offset: +1.0d
    name: Conso hier
    visible: legendonly
    fill: tozeroy
    extend_to_present: false
    line:
      width: 0.5
      color: '#bdc3c7'
      shape: spline
    filters:
      - resample: 2m
  - entity: sensor.voltronic_1_conso_maison_watt
    name: Conso
    fill: tozeroy
    extend_to_present: false
    line:
      width: 0.5
      color: '#e74c3c'
      shape: spline
    filters:
      - resample: 2m
  - entity: sensor.voltronic_1_pv_watt
    name: Prod hier
    visible: legendonly
    time_offset: +1.0d
    fill: tozeroy
    line:
      width: 1
      color: '#2ecc71'
      shape: spline
    filters:
      - resample: 1m
  - entity: sensor.voltronic_1_pv_watt
    name: Prod
    fill: tozeroy
    line:
      width: 1
      color: orange
      shape: spline
    filters:
      - resample: 1m
  - entity: sensor.voltronic_1_batt_charge_decharge_watt
    name: Charge
    fill: tozeroy
    line:
      width: 0.5
      color: dodgerblue
      shape: spline
    filters:
      - resample: 1m
hours_to_show: 2
refresh_interval: auto
layout:
  margin:
    autoexpand: true
    b: 80
  xaxis:
    showgrid: false
    rangeselector:
      'y': -0.4
      x: 0.2
      bordercolor: '#eeeeee50'
      borderwidth: 1
      bgcolor: '#eeeeee00'
      activecolor: '#0000ff30'
      buttons:
        - count: 1
          step: minute
        - count: 1
          step: hour
        - count: 2
          step: hour
        - count: 6
          step: hour
        - count: 12
          step: hour
        - count: 1
          step: day
        - count: 7
          step: day
Like Répondre


Sujets apparemment similaires…
Sujet Auteur Réponses Affichages Dernier message
  2. Carte sumsynk NOLAK 18 14,248 20-01-2026, 10:40 PM
Dernier message: Samsara32

Atteindre :


Utilisateur(s) parcourant ce sujet : 1 visiteur(s)
[-]
discussions récentes
Wallbox DYI 32 Ampères avec g...
Pour le moment je n'ai pas enc...Marco202 — 10:50 AM
Double MPTT
OK il ne redémarre que le ve...sharaid — 04:41 PM
Voici une toute nouvelle vers...
Salut le monde, J'utilise S...jeanserien — 07:17 PM
Présentation de Martine
Salut tout le monde, je m'appe...Martiney — 12:12 PM
Vous utilisez l'IA pour mieux ...
Salut tout le monde, depuis qu...Martiney — 12:09 PM
Wallbox DYI 32 Ampères avec g...
Bonjour, J'ai des difficultées...Vangelius — 12:40 PM
Impact de la hausse des prix ...
C'est clairVangelius — 12:38 PM
Wisewand IA pour gérer sa prod...
Salut! Je sais pas si vous con...ColeQe — 08:37 AM
Présentation Cole
Salut tout le monde, je m'appe...ColeQe — 08:35 AM
Vous utilisez ChatbotGPT pour ...
Salut, Ça fait genre trois se...Lennys — 04:29 PM
Optimiser un local batterie, ...
Bonjour à tous, Je m'appelle ...Aryann — 10:14 AM

[-]
Rechercher








(Advanced Search)

[-]
Who's Online
There are currently no members online.

[-]
goals
78.3% of the way to our goal of 10,000 posts!
Only 2,169 posts left to go!

[-]
Statistics
» Members: 1,031
» Latest member: Kawaland
» Forum threads: 858
» Forum posts: 7,831

Full Statistics

[-]
Latest Threads
Wallbox DYI 32 Ampères avec gestion dyna...
Last Post: Marco202
26-05-2026 10:50 AM
» Replies: 59
» Views: 36476
Double MPTT
Last Post: sharaid
24-05-2026 04:41 PM
» Replies: 31
» Views: 10849
Voici une toute nouvelle version de Smar...
Last Post: jeanserien
21-05-2026 07:17 PM
» Replies: 60
» Views: 12535
Présentation de Martine
Last Post: Martiney
19-05-2026 12:12 PM
» Replies: 0
» Views: 145
Vous utilisez l'IA pour mieux faire du t...
Last Post: Martiney
19-05-2026 12:09 PM
» Replies: 0
» Views: 151
Impact de la hausse des prix du kWh aux ...
Last Post: Vangelius
18-05-2026 12:38 PM
» Replies: 12
» Views: 4617
Wisewand IA pour gérer sa prod solaire, ...
Last Post: ColeQe
13-05-2026 08:37 AM
» Replies: 0
» Views: 149
Présentation Cole
Last Post: ColeQe
13-05-2026 08:35 AM
» Replies: 0
» Views: 152
Vous utilisez ChatbotGPT pour vos projet...
Last Post: Lennys
12-05-2026 04:29 PM
» Replies: 0
» Views: 165
Optimiser un local batterie, entre choix...
Last Post: Aryann
12-05-2026 10:14 AM
» Replies: 1
» Views: 395

>