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 10,262 20-01-2026, 10:40 PM
Dernier message: Samsara32

Atteindre :


Utilisateur(s) parcourant ce sujet : 1 visiteur(s)
[-]
discussions récentes
Voici une toute nouvelle vers...
Pour la documentation exhausti...jlm — 03:53 PM
Voici une toute nouvelle vers...
Pour l'installation de ce nouv...jlm — 03:09 PM
Voici une toute nouvelle vers...
Bonjour à tous. Voici enfin...jlm — 02:56 PM
Voici une toute nouvelle versi...
jlm — 02:43 PM
renault 5 avec v2l vers entré...
Salut, le V2L en vrai ça ma...Velkaro — 12:51 PM
Présentation
Bonjour à tous, Originaire de...Velkaro — 12:45 PM
Creation automatisme
Bonjour, Le début est bon j...Chassin — 08:56 PM
Smartphoton ne démarre plus
C'est une nouvelle encouragean...Merlin — 08:20 PM
Creation automatisme
Bonjours, voilà j'essaye ...Sylvain — 05:48 PM
Smartphoton ne démarre plus
Bonjour a tous pour infos d'ic...Tapion — 10:37 PM
demarrage addon smartphoton
Bonjour a tous pour infos d'ic...Tapion — 10:33 PM

[-]
Rechercher








(Advanced Search)

[-]
Who's Online
There are currently 58 online users. [Complete List]
» 1 Member(s) | 57 Guest(s)
Avatar

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

[-]
Statistics
» Members: 935
» Latest member: kethanscib
» Forum threads: 822
» Forum posts: 7,631

Full Statistics

[-]
Latest Threads
Voici une toute nouvelle version de Smar...
Last Post: jlm
Hier 03:53 PM
» Replies: 3
» Views: 87
renault 5 avec v2l vers entrée onduleur
Last Post: Velkaro
20-02-2026 12:51 PM
» Replies: 6
» Views: 1376
Présentation
Last Post: Velkaro
20-02-2026 12:45 PM
» Replies: 0
» Views: 51
Creation automatisme
Last Post: Chassin
19-02-2026 08:56 PM
» Replies: 2
» Views: 131
Smartphoton ne démarre plus
Last Post: Merlin
19-02-2026 08:20 PM
» Replies: 4
» Views: 259
demarrage addon smartphoton
Last Post: Tapion
18-02-2026 10:33 PM
» Replies: 6
» Views: 334
le courant passe ou pas
Last Post: Nathaniel
17-02-2026 11:49 AM
» Replies: 3
» Views: 973
Un mini ordinateur pour supporter home a...
Last Post: chama98
15-02-2026 04:31 PM
» Replies: 14
» Views: 10305
Impact de la hausse des prix du kWh aux ...
Last Post: Nathaniel
13-02-2026 11:55 AM
» Replies: 10
» Views: 2017
Nouveau par ici
Last Post: Nathaniel
12-02-2026 01:05 PM
» Replies: 0
» Views: 95

>