Tesla Powerwall und Gateway: Unterschied zwischen den Versionen

Aus FHEMWiki
(Added gplot examples)
Zeile 36: Zeile 36:


== Gplots ==
== Gplots ==
Zur Anzeige der Werte hier 2 gplots
Zur Anzeige der Werte hier zwei beispielhafte Diagramme:


==== Powerwall Kapazität ====
==== Powerwall Kapazität ====
[[Datei:PowerwallCapacity.jpg]]
[[Datei:PowerwallCapacity.jpg]]
gplot Datei:


<syntaxhighlight lang="perl">
<syntaxhighlight lang="perl">
Zeile 63: Zeile 65:


==== Powerwall Charge ====
==== Powerwall Charge ====
[[Datei:PowerwallLoads.jpg]]<syntaxhighlight lang="perl">
[[Datei:PowerwallLoads.jpg]]
 
gplot Datei:<syntaxhighlight lang="perl">
# Created by FHEM/98_SVG.pm, 2023-03-31 10:01:26
# Created by FHEM/98_SVG.pm, 2023-03-31 10:01:26
set terminal png transparent size <SIZE> crop
set terminal png transparent size <SIZE> crop

Version vom 31. März 2023, 10:40 Uhr

Einführung

Der Tesla Powerwall 2 wird als Batterie in eine Solaranlage integriert. Hier dient er als Energiespeicher. Es gibt eine App "Tesla" um den aktuellen Status als Benutzer auszulesen. Dazu gibt es noch eine lokale Webseite, die ebenfalls Zugriff auf den Status gibt.

Zusätzlich hat die Tesla Powerwall auch ein Web Api um Informationen auszulesen. Das kann genutzt werden, um die Powerwall auch in FHEM zu nutzen.

https://<ip-address powerwall>/api/system_status/soe
https://<ip-address powerwall>/api/meters/aggregates
https://<ip-address powerwall>/api/site_info
https://<ip-address powerwall>/api/sitemaster
https://<ip-address powerwall>/api/powerwalls
https://<ip-address powerwall>/api/networks
https://<ip-address powerwall>/api/system/networks
https://<ip-address powerwall>/api/operation
https://<ip-address powerwall>/api/status
https://<ip-address powerwall>/api/customer/registration

Es gibt aktuell mehrere Forumeinträge dazu:

Installation

Benötigt wird das FHEM Modul TeslaPowerwall2AC

Zur Installation definiere in FHEM die Powerwall:

define myPowerWall TeslaPowerwall2AC 192.168.x.y
attr myPowerWall emailaddr <your mail address used with Tesla gateway>

Danach muss noch das Passwort vom tesla Gateway gesetzt werden:

set myPowerwall setPassword pass=<your password>

Nach einem Shutdown/Restart sollte der Tesla Speicher im Status "ready" angezeigt werden.

Gplots

Zur Anzeige der Werte hier zwei beispielhafte Diagramme:

Powerwall Kapazität

PowerwallCapacity.jpg

gplot Datei:

# Created by FHEM/98_SVG.pm, 2023-03-31 09:05:52
set terminal png transparent size <SIZE> crop
set output '<OUT>.png'
set xdata time
set timefmt "%Y-%m-%d_%H:%M:%S"
set xlabel " "
set title '<L1>'
set ytics
set y2tics
set grid ytics
set ylabel "Battery (%)"
set y2label "Battery (KW)"

#FileLog_myPowerwall 4:myPowerWall.batteryLevel\x3a::
#FileLog_myPowerwall 4:myPowerWall.batteryPower\x3a::

plot "<IN>" using 1:2 axes x1y1 title 'Level' ls l2 lw 1 with lines,\
     "<IN>" using 1:2 axes x1y2 title 'Power' ls l0 lw 1 with lines

Powerwall Charge

PowerwallLoads.jpg

gplot Datei:

# Created by FHEM/98_SVG.pm, 2023-03-31 10:01:26
set terminal png transparent size <SIZE> crop
set output '<OUT>.png'
set xdata time
set timefmt "%Y-%m-%d_%H:%M:%S"
set xlabel " "
set title '<L1>'
set ytics
set y2tics
set grid ytics
set ylabel "Haus, Netz, Solar"
set y2label "Batterie"

#FileLog_myPowerwall 4:myPowerWall.aggregates-battery-instant_power\x3a::
#FileLog_myPowerwall 4:myPowerWall.aggregates-load-instant_power\x3a::
#FileLog_myPowerwall 4:myPowerWall.aggregates-site-instant_power\x3a::
#FileLog_myPowerwall 4:myPowerWall.aggregates-solar-instant_power\x3a::

plot "<IN>" using 1:2 axes x1y2 title 'Battery' ls l1 lw 1 with lines,\
     "<IN>" using 1:2 axes x1y1 title 'Haus' ls l2 lw 1 with lines,\
     "<IN>" using 1:2 axes x1y1 title 'Netz' ls l7 lw 1 with lines,\
     "<IN>" using 1:2 axes x1y1 title 'Solar' ls l8fill lw 1 with lines

Verschiedenes

  • ...

Links

Hinweise

  • ...