Channel Apps
[Markdown] 

Photovoltaik und Co: SolarEdge Wechselrichter

Im Solaredge Wechselrichter kann man Modbus als Protokoll freischalten. ModBus ist ein altes Protokoll (aus den 70'er Jahren) zur Steuerung von Industrieanlagen. Es benutzt keine Authentifizierung und auch keine Verschlüsselung. Aus IT-Security-Sicht ist die Benutzung dieses Protokoll bedenklich.

Wenn jemand anderes per ModBus an Eure Anlage kommt, kann er diese durch eine Fehlkonfiguration physikalisch schrotten. Der Zugriff hier erfolgt nur lesend.

Aus diesem Grund betreibe ich den Ethernetanschluß des Wechselrichters in einer DMZ und reglementiere den Netzwerkzugriff.

Für Fhem gibt es bereits ein ModBus Modul. Dies habe ich wie folgt ein gebunden:

define pvwechselrichter ModbusAttr 1 30 10.10.11.34:502 TCP
attr pvwechselrichter userattr dev-h-defPoll obj-h40000-len obj-h40000-reading obj-h40000-unpack obj-h40004-len obj-h40004-reading obj-h40004-unpack obj-h40020-len obj-h40020-reading obj-h40020-unpack obj-h40044-len obj-h40044-reading obj-h40044-unpack obj-h40052-len obj-h40052-reading obj-h40052-unpack obj-h40068-reading obj-h40069-reading obj-h40070-reading obj-h40071-expr obj-h40071-reading obj-h40072-expr obj-h40072-reading obj-h40073-expr obj-h40073-reading obj-h40074-expr obj-h40074-reading obj-h40075-reading obj-h40075-unpack obj-h40076-expr obj-h40076-reading obj-h40077-expr obj-h40077-reading obj-h40078-expr obj-h40078-reading obj-h40079-expr obj-h40079-reading obj-h40080-expr obj-h40080-reading obj-h40081-expr obj-h40081-reading obj-h40082-reading obj-h40082-unpack obj-h40083-expr obj-h40083-reading obj-h40083-unpack obj-h40084-reading obj-h40084-unpack obj-h40085-expr obj-h40085-reading obj-h40086-reading obj-h40086-unpack obj-h40087-expr obj-h40087-reading obj-h40087-unpack obj-h40088-reading obj-h40088-unpack obj-h40089-expr obj-h40089-reading obj-h40089-unpack obj-h40090-reading obj-h40090-unpack obj-h40091-expr obj-h40091-reading obj-h40091-unpack obj-h40092-reading obj-h40092-unpack obj-h40093-expr obj-h40093-len obj-h40093-reading obj-h40093-unpack obj-h40095-reading obj-h40096-expr obj-h40096-reading obj-h40097-reading obj-h40097-unpack obj-h40098-expr obj-h40098-reading obj-h40099-reading obj-h40099-unpack obj-h40100-expr obj-h40100-reading obj-h40100-unpack obj-h40101-reading obj-h40101-unpack obj-h40103-expr obj-h40103-reading obj-h40103-unpack obj-h40106-reading obj-h40106-unpack obj-h40107-reading obj-h40108-reading
attr pvwechselrichter dev-h-defPoll 1
attr pvwechselrichter obj-h40000-len 4
attr pvwechselrichter obj-h40000-reading C_SunSpec_ID
attr pvwechselrichter obj-h40000-unpack (a4)
attr pvwechselrichter obj-h40004-len 16
attr pvwechselrichter obj-h40004-reading C_Manufacturer
attr pvwechselrichter obj-h40004-unpack (a16)
attr pvwechselrichter obj-h40020-len 16
attr pvwechselrichter obj-h40020-reading C_Model
attr pvwechselrichter obj-h40020-unpack (a16)
attr pvwechselrichter obj-h40044-len 8
attr pvwechselrichter obj-h40044-reading C_Version
attr pvwechselrichter obj-h40044-unpack (a8)
attr pvwechselrichter obj-h40052-len 16
attr pvwechselrichter obj-h40052-reading C_SerialNumber
attr pvwechselrichter obj-h40052-unpack (a16)
attr pvwechselrichter obj-h40068-reading C_DeviceAddress
attr pvwechselrichter obj-h40069-reading C_PhaseDesign
attr pvwechselrichter obj-h40070-reading C_SunSpec_Length
attr pvwechselrichter obj-h40071-expr $val * (10 ** ReadingsNum ('pvwechselrichter' ,'I_AC_Current_SF',0))
attr pvwechselrichter obj-h40071-reading I_AC_Current
attr pvwechselrichter obj-h40072-expr $val * (10 ** ReadingsNum ('pvwechselrichter' ,'I_AC_Current_SF',0))
attr pvwechselrichter obj-h40072-reading I_AC_CurrentA
attr pvwechselrichter obj-h40073-expr $val * (10 ** ReadingsNum ('pvwechselrichter' ,'I_AC_Current_SF',0))
attr pvwechselrichter obj-h40073-reading I_AC_CurrentB
attr pvwechselrichter obj-h40074-expr $val * (10 ** ReadingsNum ('pvwechselrichter' ,'I_AC_Current_SF',0))
attr pvwechselrichter obj-h40074-reading I_AC_CurrentC
attr pvwechselrichter obj-h40075-reading I_AC_Current_SF
attr pvwechselrichter obj-h40075-unpack s>
attr pvwechselrichter obj-h40076-expr $val * (10 ** ReadingsNum ('pvwechselrichter' ,'I_AC_Voltage_SF',0))
attr pvwechselrichter obj-h40076-reading I_AC_VoltageAB
attr pvwechselrichter obj-h40077-expr $val * (10 ** ReadingsNum ('pvwechselrichter' ,'I_AC_Voltage_SF',0))
attr pvwechselrichter obj-h40077-reading I_AC_VoltageBC
attr pvwechselrichter obj-h40078-expr $val * (10 ** ReadingsNum ('pvwechselrichter' ,'I_AC_Voltage_SF',0))
attr pvwechselrichter obj-h40078-reading I_AC_VoltageCA
attr pvwechselrichter obj-h40079-expr $val * (10 ** ReadingsNum ('pvwechselrichter' ,'I_AC_Voltage_SF',0))
attr pvwechselrichter obj-h40079-reading I_AC_VoltageAN
attr pvwechselrichter obj-h40080-expr $val * (10 ** ReadingsNum ('pvwechselrichter' ,'I_AC_Voltage_SF',0))
attr pvwechselrichter obj-h40080-reading I_AC_VoltageBN
attr pvwechselrichter obj-h40081-expr $val * (10 ** ReadingsNum ('pvwechselrichter' ,'I_AC_Voltage_SF',0))
attr pvwechselrichter obj-h40081-reading I_AC_VoltageCN
attr pvwechselrichter obj-h40082-reading I_AC_Voltage_SF
attr pvwechselrichter obj-h40082-unpack s>
attr pvwechselrichter obj-h40083-expr $val * (10 ** ReadingsNum ('pvwechselrichter' ,'I_AC_Power_SF',0))
attr pvwechselrichter obj-h40083-reading I_AC_Power
attr pvwechselrichter obj-h40083-unpack s>
attr pvwechselrichter obj-h40084-reading I_AC_Power_SF
attr pvwechselrichter obj-h40084-unpack s>
attr pvwechselrichter obj-h40085-expr $val * (10 ** ReadingsNum ('pvwechselrichter' ,'I_AC_Frequency_SF',0))
attr pvwechselrichter obj-h40085-reading I_AC_Frequency
attr pvwechselrichter obj-h40086-reading I_AC_Frequency_SF
attr pvwechselrichter obj-h40086-unpack s>
attr pvwechselrichter obj-h40087-expr $val * (10 ** ReadingsNum ('pvwechselrichter' ,'I_AC_VA_SF',0))
attr pvwechselrichter obj-h40087-reading I_AC_VA
attr pvwechselrichter obj-h40087-unpack s>
attr pvwechselrichter obj-h40088-reading I_AC_VA_SF
attr pvwechselrichter obj-h40088-unpack s>
attr pvwechselrichter obj-h40089-expr $val * (10 ** ReadingsNum ('pvwechselrichter' ,'I_AC_VAR_SF',0))
attr pvwechselrichter obj-h40089-reading I_AC_VAR
attr pvwechselrichter obj-h40089-unpack s>
attr pvwechselrichter obj-h40090-reading I_AC_VAR_SF
attr pvwechselrichter obj-h40090-unpack s>
attr pvwechselrichter obj-h40091-expr $val * (10 ** ReadingsNum ('pvwechselrichter' ,'I_AC_PF_SF',0))
attr pvwechselrichter obj-h40091-reading I_AC_PF
attr pvwechselrichter obj-h40091-unpack s>
attr pvwechselrichter obj-h40092-reading I_AC_PF_SF
attr pvwechselrichter obj-h40092-unpack s>
attr pvwechselrichter obj-h40093-expr $val * (10 ** ReadingsNum ('pvwechselrichter' ,'I_AC_Energy_WH_SF',0))
attr pvwechselrichter obj-h40093-len 2
attr pvwechselrichter obj-h40093-reading I_AC_Energy_WH
attr pvwechselrichter obj-h40093-unpack I>
attr pvwechselrichter obj-h40095-reading I_AC_Energy_WH_SF
attr pvwechselrichter obj-h40096-expr $val * (10 ** ReadingsNum ('pvwechselrichter' ,'I_DC_Current_SF',0))
attr pvwechselrichter obj-h40096-reading I_DC_Current
attr pvwechselrichter obj-h40097-reading I_DC_Current_SF
attr pvwechselrichter obj-h40097-unpack s>
attr pvwechselrichter obj-h40098-expr $val * (10 ** ReadingsNum ('pvwechselrichter' ,'I_DC_Voltage_SF',0))
attr pvwechselrichter obj-h40098-reading I_DC_Voltage
attr pvwechselrichter obj-h40099-reading I_DC_Voltage_SF
attr pvwechselrichter obj-h40099-unpack s>
attr pvwechselrichter obj-h40100-expr $val * (10 ** ReadingsNum ('pvwechselrichter' ,'I_DC_Power_SF',0))
attr pvwechselrichter obj-h40100-reading I_DC_Power
attr pvwechselrichter obj-h40100-unpack s>
attr pvwechselrichter obj-h40101-reading I_DC_Power_SF
attr pvwechselrichter obj-h40101-unpack s>
attr pvwechselrichter obj-h40103-expr $val * (10 ** ReadingsNum ('pvwechselrichter' ,'I_Temp_SF',0))
attr pvwechselrichter obj-h40103-reading I_Temp_Sink
attr pvwechselrichter obj-h40103-unpack s>
attr pvwechselrichter obj-h40106-reading I_Temp_SF
attr pvwechselrichter obj-h40106-unpack s>
attr pvwechselrichter obj-h40107-reading I_Status
attr pvwechselrichter obj-h40108-reading I_Status_Vendor
attr pvwechselrichter userReadings uI_Status:I_Status.* {my $om=ReadingsNum($name,'I_Status',-1);;($om==2?'night':($om==4?'day':'off'))},\
attr pvwechselrichter verbose 3
define FileLog_pvwechselrichter FileLog ./log/pvwechselrichter-%Y-%m.log pvwechselrichter
attr FileLog_pvwechselrichter room Logfiles

Weitere Infos und Ansätze sind hier zu finden:

Seite 12 und 13: https://github.com/jbuehl/solaredge

https://github.com/lizardking/SolarEdge.net