einfacher:
Dynamic Power Limiter nur über einen Datenpunkt ein- und ausschalten.
Wird der DPL über ein Script ausgeschaltet, behält der Inverter das letzte Limit (non persistent) bei.
Deshalb wird im folgenden Blockly beim Auschalten des DPL auch das Limit wieder auf 100% gesetzt.
Der DPL kann einfach per Datenpunkt in einem Blockly ein- oder ausgeschaltet werden.
Dazu wird der Datenpunkt zum Einschalten aktualisiert mit wahr.
Zum Ausschalten mit falsch.

Im Blockly sind 2 Inverter zur DPL Steuerung berücksichtigt.
Wird nur 1 Inverter zur DPL Steuerung verwendet, kann die Variable und der Block gelöscht werden oder einfach bei beiden Variablen die gleiche Seriennummer eintragen.
Falls doch mal später 2 Inverter für DPL aktiviert werden sollen.
Seriennummer werden nur nach dem Ausschalten verwendet, damit der/die Inverter wieder volle Leistung liefern.
Werte werden nur non-persistent gesetzt, wie bei der DPL-Steuerung.
Für das Script wurde manuell 1 Verzeichnis und 1 Datenpunkt angelegt:
Verzeichnis:
openDTUoB
0_userdata.0.Datenpunkte.openDTUoB
Datenpunkt:
dplEinAus
"type": "boolean"
0_userdata.0.Datenpunkte.openDTUoB.dplEinAus
Vor dem Ausführen des Scripts müsen folgende Eintragungen vorgenommen werden:
IP OpenDTUon Battery
Password
1te Seriennummer des Inverters für die DPL-Steuerung
2te Seriennummer des Inverters, der auch DPL steuert (bei nur einem aktivierten Inverter einfach die gleiche Seriennummer vom ersten Inverter eintragen).

Blockly:
<xml xmlns="https://developers.google.com/blockly/xml">
<variables>
<variable id="P.,=V-_lWMTIt*,^9bWa">jsonObj</variable>
<variable id="?Ekt8|,iPfa0uAPY)N%A">attr</variable>
<variable id="y`qH:gKyqipx04VGZ@;=">val</variable>
<variable id="T[fn@X+yakzmBpi9]n*E">openDTUonBatteryIP</variable>
<variable id="nh}jM|3k}%Qhny;,Etjk">OpenDTUonBatteryPassword</variable>
<variable id="/X1](JXiM-@K#NE`C4,%">InverterSerial</variable>
<variable id="b+E=vG0=nXY*@8jhUpT1">InverterSerial2</variable>
<variable id="2|vbm;5buC6^$eogp=fe">urlDPLstate</variable>
<variable id="PWsI)BqL)EeZPzj!8-VY">set</variable>
<variable id="JppG`(9.sfDt)j^gha}{">cUrlLimitPart1</variable>
<variable id="Xy47v*SILC`=7N1mM,:5">cUrlLimitPart2</variable>
<variable id="_+8y375~59B=8rd!@Ae%">jsonObjekt</variable>
</variables>
<block type="comment" id="g{c,O//*067~CDT{26F+" x="212" y="-112">
<field name="COMMENT">OpenDTUonBattery&#10;DPL Ein/Aus</field>
<next>
<block type="on_ext" id="MpdxhvC3:):%?cL5ChV-">
<mutation xmlns="http://www.w3.org/1999/xhtml" items="1"></mutation>
<field name="CONDITION">ne</field>
<field name="ACK_CONDITION"></field>
<value name="OID0">
<shadow type="field_oid" id="j)L11f:Db#X;sEL6awg/">
<field name="oid">0_userdata.0.Datenpunkte.openDTUoB.dplEinAus</field>
</shadow>
</value>
<statement name="STATEMENT">
<block type="comment" id="wPs7.T(3#lmg-Q#YnMcz">
<field name="COMMENT">IP von OpenDTUonBattery:</field>
<next>
<block type="variables_set" id="xiC72+QQD{FQ44VC6wQn">
<field name="VAR" id="T[fn@X+yakzmBpi9]n*E">openDTUonBatteryIP</field>
<value name="VALUE">
<block type="text" id="3|rd+!6W]T02z}tGd1/m">
<field name="TEXT">192.170.178.250</field>
</block>
</value>
<next>
<block type="comment" id="8!|A_f5hyHJr/:f!|;r.">
<field name="COMMENT">OpenDTUonBattery Passwort:</field>
<next>
<block type="variables_set" id="ItJFflir$91[$;pF5+MA">
<field name="VAR" id="nh}jM|3k}%Qhny;,Etjk">OpenDTUonBatteryPassword</field>
<value name="VALUE">
<block type="text" id="xYm]l*(;=w@0xJQnWi5-">
<field name="TEXT">openDTU42</field>
</block>
</value>
<next>
<block type="variables_set" id="u:x]^bL1{Q9m2)/M*CRl">
<field name="VAR" id="/X1](JXiM-@K#NE`C4,%">InverterSerial</field>
<value name="VALUE">
<block type="text" id="m)|9(*pwq()mn.3Ron~:">
<field name="TEXT">11611111111</field>
</block>
</value>
<next>
<block type="variables_set" id="++@7g{b1u:LHh]h:CEq+">
<field name="VAR" id="b+E=vG0=nXY*@8jhUpT1">InverterSerial2</field>
<value name="VALUE">
<block type="text" id="m8cbvw?0pnZNAUaiU8Zq">
<field name="TEXT">112122222222</field>
</block>
</value>
<next>
<block type="comment" id="8ezl|ED@6X29f4k@:.2H">
<field name="COMMENT">----</field>
<next>
<block type="variables_set" id="!#IE.`!)HPf,NcPW*miy">
<field name="VAR" id="2|vbm;5buC6^$eogp=fe">urlDPLstate</field>
<value name="VALUE">
<block type="text_join" id="F#[x6:MOpP{a#hljyq@2">
<mutation items="5"></mutation>
<value name="ADD0">
<block type="text" id="!@~5;?O8`oIO%oN]bLJa">
<field name="TEXT">curl -u "admin:</field>
</block>
</value>
<value name="ADD1">
<block type="variables_get" id="SFT0:Zq378qj5]2?a5#b">
<field name="VAR" id="nh}jM|3k}%Qhny;,Etjk">OpenDTUonBatteryPassword</field>
</block>
</value>
<value name="ADD2">
<block type="text" id="5}ok+uklC%b/F}gtZr`^">
<field name="TEXT">" http://</field>
</block>
</value>
<value name="ADD3">
<block type="variables_get" id="C|ac)ks!*i8cZS5zb!0?">
<field name="VAR" id="T[fn@X+yakzmBpi9]n*E">openDTUonBatteryIP</field>
</block>
</value>
<value name="ADD4">
<block type="text" id="!=iiY$6m(O#=Q|km-7W1">
<field name="TEXT">/api/powerlimiter/config</field>
</block>
</value>
</block>
</value>
<next>
<block type="variables_set" id="Nw*-3DKlvV=)l.++!yg%">
<field name="VAR" id="PWsI)BqL)EeZPzj!8-VY">set</field>
<value name="VALUE">
<block type="text_join" id="b3+b3^R@5s5Vbpj^o9!6">
<mutation items="2"></mutation>
<value name="ADD0">
<block type="variables_get" id="%UJkDROf_mMO^oE4EKW.">
<field name="VAR" id="2|vbm;5buC6^$eogp=fe">urlDPLstate</field>
</block>
</value>
<value name="ADD1">
<block type="text" id="o}*[n$;A?-]x1P{Ppan.">
<field name="TEXT"> -d 'data=</field>
</block>
</value>
</block>
</value>
<next>
<block type="variables_set" id="1%5eOCEM.zYy[-sZ0a43">
<field name="VAR" id="JppG`(9.sfDt)j^gha}{">cUrlLimitPart1</field>
<value name="VALUE">
<block type="text_join" id="B,v7UaJQkq-DSzv41b;v">
<mutation items="5"></mutation>
<value name="ADD0">
<block type="text" id=";4j$FAn0X}CSE_D5:/kl">
<field name="TEXT">curl -u "admin:</field>
</block>
</value>
<value name="ADD1">
<block type="variables_get" id="Ea#Og5Jr^hwL!_Oh-[Ua">
<field name="VAR" id="nh}jM|3k}%Qhny;,Etjk">OpenDTUonBatteryPassword</field>
</block>
</value>
<value name="ADD2">
<block type="text" id="kBsI#4)FR#3@EAh.=@b]">
<field name="TEXT">" http://</field>
</block>
</value>
<value name="ADD3">
<block type="variables_get" id=",/9?^Tx*?hC1YP`-X]37">
<field name="VAR" id="T[fn@X+yakzmBpi9]n*E">openDTUonBatteryIP</field>
</block>
</value>
<value name="ADD4">
<block type="text" id="p5zvA0V{e$4V$#_9gWcY">
<field name="TEXT">/api/limit/config -d 'data={"serial":"</field>
</block>
</value>
</block>
</value>
<next>
<block type="variables_set" id="u|60ca%8U|+rvrL1*bdK">
<field name="VAR" id="Xy47v*SILC`=7N1mM,:5">cUrlLimitPart2</field>
<value name="VALUE">
<block type="text" id="`Z^Zv4qi(GN;drYs.f6I">
<field name="TEXT">","limit_value":100,"limit_type":1}'</field>
</block>
</value>
<next>
<block type="comment" id="Y+nX-p}*xExWw]O`OX~{">
<field name="COMMENT">aktueller DPL state:</field>
<next>
<block type="exec" id="I~3.fAPDzJ[1T(TlzoOT">
<mutation xmlns="http://www.w3.org/1999/xhtml" with_statement="true"></mutation>
<field name="WITH_STATEMENT">TRUE</field>
<field name="LOG"></field>
<value name="COMMAND">
<shadow type="text" id="9;-TT-}BY,qROECr/9_6">
<field name="TEXT"></field>
</shadow>
<block type="variables_get" id="i4]srTbBS]Jm}Z^t,,i^">
<field name="VAR" id="2|vbm;5buC6^$eogp=fe">urlDPLstate</field>
</block>
</value>
<statement name="STATEMENT">
<block type="variables_set" id="U*PNhv3v$WIWPSb|ja,I">
<field name="VAR" id="_+8y375~59B=8rd!@Ae%">jsonObjekt</field>
<value name="VALUE">
<block type="convert_json2object" id="y.{-xr4=@LsO?lm{BV16">
<value name="VALUE">
<block type="exec_result" id="6ho:XZ{%G?n+B=|[OsSQ">
<field name="ATTR">result</field>
</block>
</value>
</block>
</value>
<next>
<block type="comment" id="A(14glg}PvpJG@9qX7Z+">
<field name="COMMENT">DPL Ein:</field>
<next>
<block type="controls_if" id=")aeo4TK/:D$bt5(cFhVN">
<value name="IF0">
<block type="logic_compare" id="%pI.k62s._dcfZnb8SHC">
<field name="OP">EQ</field>
<value name="A">
<block type="on_source" id="C-u,UgBdHv4sZCblY)(F">
<field name="ATTR">state.val</field>
</block>
</value>
<value name="B">
<block type="logic_boolean" id="e..27D@{cN0JPJc_@bv;">
<field name="BOOL">TRUE</field>
</block>
</value>
</block>
</value>
<statement name="DO0">
<block type="procedures_callcustomnoreturn" id="D9g{#*qgs_-7rfz6|TYD">
<mutation name="change">
<arg name="jsonObj"></arg>
<arg name="attr"></arg>
<arg name="val"></arg>
</mutation>
<value name="ARG0">
<block type="variables_get" id="yi4H-8|bl|J[{ecr@w?*">
<field name="VAR" id="_+8y375~59B=8rd!@Ae%">jsonObjekt</field>
</block>
</value>
<value name="ARG1">
<block type="text" id="/1aiKrRmt}{2sRQ`BE^S">
<field name="TEXT">enabled</field>
</block>
</value>
<value name="ARG2">
<block type="logic_boolean" id="]!TrP#dnQ%e`r1%@n;)0">
<field name="BOOL">TRUE</field>
</block>
</value>
<next>
<block type="exec" id="xWQm84D2~+;KrfUenNP|">
<mutation xmlns="http://www.w3.org/1999/xhtml" with_statement="false"></mutation>
<field name="WITH_STATEMENT">FALSE</field>
<field name="LOG"></field>
<value name="COMMAND">
<shadow type="text" id="Y[J#ti:!)V_p[~D/~=BP">
<field name="TEXT">pwd</field>
</shadow>
<block type="text_join" id="?#1pjgc[4w-Nbot8xQpL">
<mutation items="3"></mutation>
<value name="ADD0">
<block type="variables_get" id=";wn*ZeQHpIf@a_40]mk$">
<field name="VAR" id="PWsI)BqL)EeZPzj!8-VY">set</field>
</block>
</value>
<value name="ADD1">
<block type="convert_object2json" id="`s4:$VMpnCx?$#E/lH89">
<field name="PRETTIFY">FALSE</field>
<value name="VALUE">
<block type="variables_get" id="akzUA)PF0iBQcIE,ZBTo">
<field name="VAR" id="_+8y375~59B=8rd!@Ae%">jsonObjekt</field>
</block>
</value>
</block>
</value>
<value name="ADD2">
<block type="text" id="tazI8QS$S%YmkBw8,!R]">
<field name="TEXT">'</field>
</block>
</value>
</block>
</value>
</block>
</next>
</block>
</statement>
<next>
<block type="comment" id="zV97]OnS?/IjoV1xAl_T">
<field name="COMMENT">DPL Aus:</field>
<next>
<block type="controls_if" id="7{aiQa33_g$QnlPw!:;F">
<value name="IF0">
<block type="logic_compare" id="XYHuB8ZNE3]RuqS}0zLa">
<field name="OP">EQ</field>
<value name="A">
<block type="on_source" id="kRJjzY0xkd07ZrzDPb1?">
<field name="ATTR">state.val</field>
</block>
</value>
<value name="B">
<block type="logic_boolean" id="{2pCy)Ah-nq3V.,{DVo1">
<field name="BOOL">FALSE</field>
</block>
</value>
</block>
</value>
<statement name="DO0">
<block type="procedures_callcustomnoreturn" id="-Hz0vX5GM=t[9OHH8]Wg">
<mutation name="change">
<arg name="jsonObj"></arg>
<arg name="attr"></arg>
<arg name="val"></arg>
</mutation>
<value name="ARG0">
<block type="variables_get" id="v[6xm8C%Otou%c3=g710">
<field name="VAR" id="_+8y375~59B=8rd!@Ae%">jsonObjekt</field>
</block>
</value>
<value name="ARG1">
<block type="text" id="tL?JD.@HaQSk5`{9Wm]{">
<field name="TEXT">enabled</field>
</block>
</value>
<value name="ARG2">
<block type="logic_boolean" id="WMimixsaaPP)fhHu2.J$">
<field name="BOOL">FALSE</field>
</block>
</value>
<next>
<block type="exec" id="/p+Uv~V#hIePApTb=KTR">
<mutation xmlns="http://www.w3.org/1999/xhtml" with_statement="false"></mutation>
<field name="WITH_STATEMENT">FALSE</field>
<field name="LOG"></field>
<value name="COMMAND">
<shadow type="text" id="Y[J#ti:!)V_p[~D/~=BP">
<field name="TEXT">pwd</field>
</shadow>
<block type="text_join" id="?fTh]i~D]=Ue}GsE8^;i">
<mutation items="3"></mutation>
<value name="ADD0">
<block type="variables_get" id="$!],od*U?4dNiG;_YIzl">
<field name="VAR" id="PWsI)BqL)EeZPzj!8-VY">set</field>
</block>
</value>
<value name="ADD1">
<block type="convert_object2json" id="|pyw%?Kwve~3iciql_#f">
<field name="PRETTIFY">FALSE</field>
<value name="VALUE">
<block type="variables_get" id="z0~!%^yv(pHWcQpw)5``">
<field name="VAR" id="_+8y375~59B=8rd!@Ae%">jsonObjekt</field>
</block>
</value>
</block>
</value>
<value name="ADD2">
<block type="text" id="/g9Zs!_,BY#!LKzHEF`/">
<field name="TEXT">'</field>
</block>
</value>
</block>
</value>
<next>
<block type="comment" id="ql1mac4Qf*!]/(y:*HR+">
<field name="COMMENT">DPLinverter01 Limit 100%</field>
<next>
<block type="exec" id="iNs^J_^oAm89Vr+p^dcU">
<mutation xmlns="http://www.w3.org/1999/xhtml" with_statement="false"></mutation>
<field name="WITH_STATEMENT">FALSE</field>
<field name="LOG"></field>
<value name="COMMAND">
<shadow type="text" id="C9zK,I#|DhseRSSl*?8X">
<field name="TEXT"></field>
</shadow>
<block type="text_join" id="~7~(vzW]+%{R35ES=iGn">
<mutation items="3"></mutation>
<value name="ADD0">
<block type="variables_get" id=".v]Hhm{LD(-@){kzp()2">
<field name="VAR" id="JppG`(9.sfDt)j^gha}{">cUrlLimitPart1</field>
</block>
</value>
<value name="ADD1">
<block type="variables_get" id="OZY@nUX[m`.Rp[12/e{g">
<field name="VAR" id="/X1](JXiM-@K#NE`C4,%">InverterSerial</field>
</block>
</value>
<value name="ADD2">
<block type="variables_get" id="]wG/EOqQ!/tw6ZlRcab0">
<field name="VAR" id="Xy47v*SILC`=7N1mM,:5">cUrlLimitPart2</field>
</block>
</value>
</block>
</value>
<next>
<block type="comment" id="aI[_!O+Ua%`p6/mqrCjz">
<field name="COMMENT">DPLinverter02 Limit 100%</field>
<next>
<block type="exec" id="v[cN9cA@.Ejy;Z1G81kX">
<mutation xmlns="http://www.w3.org/1999/xhtml" with_statement="false"></mutation>
<field name="WITH_STATEMENT">FALSE</field>
<field name="LOG"></field>
<value name="COMMAND">
<shadow type="text" id="C9zK,I#|DhseRSSl*?8X">
<field name="TEXT"></field>
</shadow>
<block type="text_join" id="Wd`VvP4NqCJ}/*|~IbTV">
<mutation items="3"></mutation>
<value name="ADD0">
<block type="variables_get" id="hy+6K,WWY.Y`%h-+p;v1">
<field name="VAR" id="JppG`(9.sfDt)j^gha}{">cUrlLimitPart1</field>
</block>
</value>
<value name="ADD1">
<block type="variables_get" id="W/O@o[J$nrG+r..LB`}A">
<field name="VAR" id="b+E=vG0=nXY*@8jhUpT1">InverterSerial2</field>
</block>
</value>
<value name="ADD2">
<block type="variables_get" id="q%FGBbHAZ^N/`|V3wzs%">
<field name="VAR" id="Xy47v*SILC`=7N1mM,:5">cUrlLimitPart2</field>
</block>
</value>
</block>
</value>
</block>
</next>
</block>
</next>
</block>
</next>
</block>
</next>
</block>
</next>
</block>
</statement>
</block>
</next>
</block>
</next>
</block>
</next>
</block>
</next>
</block>
</statement>
</block>
</next>
</block>
</next>
</block>
</next>
</block>
</next>
</block>
</next>
</block>
</next>
</block>
</next>
</block>
</next>
</block>
</next>
</block>
</next>
</block>
</next>
</block>
</next>
</block>
</statement>
</block>
</next>
</block>
<block type="procedures_defcustomnoreturn" id="nxZk[TB}x%yvkJ058U]o" x="738" y="862">
<mutation statements="false">
<arg name="jsonObj" varid="P.,=V-_lWMTIt*,^9bWa"></arg>
<arg name="attr" varid="?Ekt8|,iPfa0uAPY)N%A"></arg>
<arg name="val" varid="y`qH:gKyqipx04VGZ@;="></arg>
</mutation>
<field name="NAME">change</field>
<field name="SCRIPT">anNvbk9ialthdHRyXSA9IHZhbDs=</field>
<comment pinned="false" h="80" w="160">Beschreibe diese Funktion …</comment>
</block>
</xml>
Damit kann in jedem Script der Dynamic Power Limiter ein- oder ausgeschaltet werden.
Ist bestimmt brauchbar.
Vorschläge oder Verbesserungen willkommen.
Würde mich mal über eine Rückmeldung oder einen Beitrag freuen.
Nicht, dass ich hier Alleinunterhalter bin 