Navigation

    Logo
    • Register
    • Login
    • Search
    • Recent
    • Tags
    • Unread
    • Categories
    • Unreplied
    • Popular
    • GitHub
    • Docu
    • Hilfe
    1. Home
    2. Deutsch
    3. Skripten / Logik
    4. Blockly
    5. KWL Zeitsteuerung WT / Sa+So+Ft

    NEWS

    • Wir empfehlen: Node.js 22.x

    • Neuer Blog: Fotos und Eindrücke aus Solingen

    • ioBroker goes Matter ... Matter Adapter in Stable

    KWL Zeitsteuerung WT / Sa+So+Ft

    This topic has been deleted. Only users with topic management privileges can see it.
    • SLang77
      SLang77 last edited by

      Hallo zusammen,

      Leider komme ich bei einer Zeitsteuerung nicht weiter.
      Ich habe eine KWL und die möchte ich zeitgesteuert ein und ausschalten. Nach folgendem Muster soll das passieren:

      Jeden Tag (egal ob Feiertag (Ft) oder Wochenende (Sa/So) soll die KWL um 04:00 Uhr eingeschaltet werden.

      Von Montag bis Freitag (wenn kein Feiertag Mo- Fr) soll die KWL um 08:00 Uhr ausgeschaltet werden.

      Am Samstag, Sonntag und Feiertag soll die KWL um 10:00 Uhr ausgeschaltet werden.

      Von Montag bis Freitag (wenn kein Feiertag Mo- Fr) soll die KWL um 14:00 Uhr eingeschaltet werden.

      Am Samstag, Sonntag und Feiertag soll die KWL um 16:00 Uhr eingeschaltet werden.

      Jeden Tag (egal ob Feiertag (Ft) oder Wochenende (Sa/So) soll die KWL um 22:30 Uhr ausgeschaltet werden.

      Leider komme ich hier nicht weiter. Ich habe bereits diverse Scripte versucht. Dennoch funktioniert es einfach nicht. Ich befürchte das ich hier die falsche herangehensweise habe.
      Entweder der korrekte Tag wird gar nicht erkannt, oder es ist ein anderes Problem woran ich nicht denke.

      Was passiert:
      Jeden tag wird um 04 Uhr ein und um 22:30 Uhr ausgeschaltet. Das funktioniert und ist einfach.
      Leider wird aber auch am Wochenende, also Sa und Sonntag um 08:00 Uhr die Anlage ausgeschaltet, was nicht sein soll. Dementsprechend wird die Anlage auch bereits um 14:00 Uhr eingeschaltet, was ich nicht verstehe, denn laut dem vorliegenden Blockly weist nichts darauf hin dass das passieren soll..

      Ich bitte euch daher um Hilfe.
      KWL.jpg

      <xml xmlns="https://developers.google.com/blockly/xml">
        <block type="comment" id="OcNDtM_|x]FIPA#XlGy-" x="88" y="-362">
          <field name="COMMENT">Jeden Tag</field>
          <next>
            <block type="schedule" id=".3$gO5a%R[|]aBABFkD~">
              <field name="SCHEDULE">0 4 * * *</field>
              <statement name="STATEMENT">
                <block type="comment" id="mw1*:Xt0=T)g`ZII$bM+">
                  <field name="COMMENT">KWL jeden Tag um 04:00 Uhr einschalten</field>
                  <next>
                    <block type="control" id="m~`*62THEx;^O+|?-lNL">
                      <mutation xmlns="http://www.w3.org/1999/xhtml" delay_input="false"></mutation>
                      <field name="OID">shelly.0.SHSW-PM#F4CFA2E3AFE9#1.Relay0.Switch</field>
                      <field name="WITH_DELAY">FALSE</field>
                      <value name="VALUE">
                        <block type="logic_boolean" id="#(7K_cFCpST[G[PC/:xB">
                          <field name="BOOL">TRUE</field>
                        </block>
                      </value>
                    </block>
                  </next>
                </block>
              </statement>
              <next>
                <block type="schedule" id="Em.rM9*v])A+PW|:041V">
                  <field name="SCHEDULE">30 22 * * *</field>
                  <statement name="STATEMENT">
                    <block type="comment" id="drNqF9B*A5pL{D%68Hl^">
                      <field name="COMMENT">KWL jeden Tag um 22:30 Uhr ausschalten</field>
                      <next>
                        <block type="control" id="gvj$Pf=JySy|`b*0i=fr">
                          <mutation xmlns="http://www.w3.org/1999/xhtml" delay_input="false"></mutation>
                          <field name="OID">shelly.0.SHSW-PM#F4CFA2E3AFE9#1.Relay0.Switch</field>
                          <field name="WITH_DELAY">FALSE</field>
                          <value name="VALUE">
                            <block type="logic_boolean" id="RE1@AmhUaFG[n*)cet0a">
                              <field name="BOOL">FALSE</field>
                            </block>
                          </value>
                        </block>
                      </next>
                    </block>
                  </statement>
                </block>
              </next>
            </block>
          </next>
        </block>
        <block type="controls_if" id="pv:y-jmXSco[h^JXqIf}" x="88" y="-13">
          <mutation elseif="3"></mutation>
          <value name="IF0">
            <block type="logic_operation" id="iD7NT(e8sNH]j`%mU.o;" inline="false">
              <field name="OP">OR</field>
              <value name="A">
                <block type="logic_operation" id="MMa_lUz6~gJj}@[t[H3$" inline="false">
                  <field name="OP">OR</field>
                  <value name="A">
                    <block type="logic_operation" id="ZbQ]GI6*=M0ZO_Rbrja5" inline="false">
                      <field name="OP">OR</field>
                      <value name="A">
                        <block type="logic_compare" id="6{Sr+y`m,96?Q3PW8qm2">
                          <field name="OP">EQ</field>
                          <value name="A">
                            <block type="time_get" id="r`V+3tqV=5kL1X~+kRIv">
                              <mutation xmlns="http://www.w3.org/1999/xhtml" format="false" language="false"></mutation>
                              <field name="OPTION">wd</field>
                            </block>
                          </value>
                          <value name="B">
                            <block type="math_number" id="b7PBS$](W]YIN~f+kt0c">
                              <field name="NUM">1</field>
                            </block>
                          </value>
                        </block>
                      </value>
                      <value name="B">
                        <block type="logic_compare" id="TIsyz5RAV!01Dr^+2OyY">
                          <field name="OP">EQ</field>
                          <value name="A">
                            <block type="time_get" id="rgk-CPP)sx.YXX(zl[tJ">
                              <mutation xmlns="http://www.w3.org/1999/xhtml" format="false" language="false"></mutation>
                              <field name="OPTION">wd</field>
                            </block>
                          </value>
                          <value name="B">
                            <block type="math_number" id="I:3R-nh^rAn}sJr{[8F@">
                              <field name="NUM">2</field>
                            </block>
                          </value>
                        </block>
                      </value>
                    </block>
                  </value>
                  <value name="B">
                    <block type="logic_compare" id="pog::[c/:3zEWGPw]h^g">
                      <field name="OP">EQ</field>
                      <value name="A">
                        <block type="time_get" id="l=moWb6PzAYtxCx_#!;;">
                          <mutation xmlns="http://www.w3.org/1999/xhtml" format="false" language="false"></mutation>
                          <field name="OPTION">wd</field>
                        </block>
                      </value>
                      <value name="B">
                        <block type="math_number" id="P~_WC@d$/iF={(=nhu5[">
                          <field name="NUM">3</field>
                        </block>
                      </value>
                    </block>
                  </value>
                </block>
              </value>
              <value name="B">
                <block type="logic_operation" id="Sc$:I=}!jsF48q~t]I.6" inline="false">
                  <field name="OP">OR</field>
                  <value name="A">
                    <block type="logic_compare" id="+0uk2P:|hWKt~SPY8e88">
                      <field name="OP">EQ</field>
                      <value name="A">
                        <block type="time_get" id="dMHK0@2VnpkGniEVl]KI">
                          <mutation xmlns="http://www.w3.org/1999/xhtml" format="false" language="false"></mutation>
                          <field name="OPTION">wd</field>
                        </block>
                      </value>
                      <value name="B">
                        <block type="math_number" id="=U-+aj{*%Iyrry.(yePd">
                          <field name="NUM">4</field>
                        </block>
                      </value>
                    </block>
                  </value>
                  <value name="B">
                    <block type="logic_compare" id=".3`9%#Dh[/0p_byi:F}b">
                      <field name="OP">EQ</field>
                      <value name="A">
                        <block type="time_get" id="+YeX!^pj.^7E~Bv:8P!?">
                          <mutation xmlns="http://www.w3.org/1999/xhtml" format="false" language="false"></mutation>
                          <field name="OPTION">wd</field>
                        </block>
                      </value>
                      <value name="B">
                        <block type="math_number" id="]:ui97f30,3WNX.L#?qr">
                          <field name="NUM">5</field>
                        </block>
                      </value>
                    </block>
                  </value>
                </block>
              </value>
            </block>
          </value>
          <statement name="DO0">
            <block type="comment" id="f]n$;QYr/jNhRcEPpgu?">
              <field name="COMMENT">KWL Mo-Fr um 08:00 Uhr ausschalten</field>
              <next>
                <block type="procedures_callnoreturn" id="vdxu`rTR+t85:+CH2v[/">
                  <mutation name="KWL Mo-Fr aus"></mutation>
                </block>
              </next>
            </block>
          </statement>
          <value name="IF1">
            <block type="logic_operation" id="[z];0S0aut)^4Vo`jBEP" inline="false">
              <field name="OP">OR</field>
              <value name="A">
                <block type="logic_compare" id="yj4+Z:z9cI]Vh2]Ddp]M">
                  <field name="OP">EQ</field>
                  <value name="A">
                    <block type="get_value" id="0qvQZP,U^L!bhIVjMMSN">
                      <field name="ATTR">val</field>
                      <field name="OID">feiertage.0.heute.boolean</field>
                    </block>
                  </value>
                  <value name="B">
                    <block type="logic_boolean" id="-tH,,.n*w6,f4{YLO!93">
                      <field name="BOOL">TRUE</field>
                    </block>
                  </value>
                </block>
              </value>
              <value name="B">
                <block type="logic_operation" id="6PL]8XDHE)KbR)5:3I|U" inline="false">
                  <field name="OP">OR</field>
                  <value name="A">
                    <block type="logic_compare" id="Oenr64s$TkzGw+UH]+f:">
                      <field name="OP">EQ</field>
                      <value name="A">
                        <block type="time_get" id="AZFpD0.s7^isIk@c#~Ud">
                          <mutation xmlns="http://www.w3.org/1999/xhtml" format="false" language="false"></mutation>
                          <field name="OPTION">wd</field>
                        </block>
                      </value>
                      <value name="B">
                        <block type="math_number" id=".UcR_6^}}4NJiAI:`m64">
                          <field name="NUM">6</field>
                        </block>
                      </value>
                    </block>
                  </value>
                  <value name="B">
                    <block type="logic_compare" id="-_{b(6@,fU]q{mcK)XaX">
                      <field name="OP">EQ</field>
                      <value name="A">
                        <block type="time_get" id="tJ=}L;l1@;Q`:(!?t@jd">
                          <mutation xmlns="http://www.w3.org/1999/xhtml" format="false" language="false"></mutation>
                          <field name="OPTION">wd</field>
                        </block>
                      </value>
                      <value name="B">
                        <block type="math_number" id="4iOH8vrR[v!_,[mz}pIu">
                          <field name="NUM">0</field>
                        </block>
                      </value>
                    </block>
                  </value>
                </block>
              </value>
            </block>
          </value>
          <statement name="DO1">
            <block type="comment" id="wt41P?T{J0uFtC@53|m!">
              <field name="COMMENT">KWL Sa+So+Ft um 10:00 Uhr ausschalten</field>
              <next>
                <block type="procedures_callnoreturn" id="^;RtT#QKkHy3dT*]:=ys">
                  <mutation name="KWL Sa+So+Ft aus"></mutation>
                </block>
              </next>
            </block>
          </statement>
          <value name="IF2">
            <block type="logic_operation" id="@j406f%w#=}93VE_{*=)" inline="false">
              <field name="OP">OR</field>
              <value name="A">
                <block type="logic_operation" id="S^$~sRV6oscb*PB]H~oq" inline="false">
                  <field name="OP">OR</field>
                  <value name="A">
                    <block type="logic_operation" id="L0xux-uDujZd?uVGIJ[/" inline="false">
                      <field name="OP">OR</field>
                      <value name="A">
                        <block type="logic_compare" id="ZmUGNGQ-,M#gS9`+]bCA">
                          <field name="OP">EQ</field>
                          <value name="A">
                            <block type="time_get" id="`wkQrH^6%s6UO0=}1mt*">
                              <mutation xmlns="http://www.w3.org/1999/xhtml" format="false" language="false"></mutation>
                              <field name="OPTION">wd</field>
                            </block>
                          </value>
                          <value name="B">
                            <block type="math_number" id="y_*:2Hx~%9D_c%{$.=K.">
                              <field name="NUM">1</field>
                            </block>
                          </value>
                        </block>
                      </value>
                      <value name="B">
                        <block type="logic_compare" id="xMj/53s;W,WF~U165),7">
                          <field name="OP">EQ</field>
                          <value name="A">
                            <block type="time_get" id="tQ^9KLIDh$WHuPmwE8~!">
                              <mutation xmlns="http://www.w3.org/1999/xhtml" format="false" language="false"></mutation>
                              <field name="OPTION">wd</field>
                            </block>
                          </value>
                          <value name="B">
                            <block type="math_number" id="AGm{n#xkP@LfcFx;M#ML">
                              <field name="NUM">2</field>
                            </block>
                          </value>
                        </block>
                      </value>
                    </block>
                  </value>
                  <value name="B">
                    <block type="logic_compare" id="^***Lz2oIsCs?uBNco*u">
                      <field name="OP">EQ</field>
                      <value name="A">
                        <block type="time_get" id="Qzfkz-{~+BM*G9)!A8Ca">
                          <mutation xmlns="http://www.w3.org/1999/xhtml" format="false" language="false"></mutation>
                          <field name="OPTION">wd</field>
                        </block>
                      </value>
                      <value name="B">
                        <block type="math_number" id="x7hp{$wuD_1]39?nS70-">
                          <field name="NUM">3</field>
                        </block>
                      </value>
                    </block>
                  </value>
                </block>
              </value>
              <value name="B">
                <block type="logic_operation" id="%g2$;Wq,90iPh$k!HIpy" inline="false">
                  <field name="OP">OR</field>
                  <value name="A">
                    <block type="logic_compare" id="rmTeUNDm7u[27x*,lF={">
                      <field name="OP">EQ</field>
                      <value name="A">
                        <block type="time_get" id="j5owN(VY#A2arKf]mJVk">
                          <mutation xmlns="http://www.w3.org/1999/xhtml" format="false" language="false"></mutation>
                          <field name="OPTION">wd</field>
                        </block>
                      </value>
                      <value name="B">
                        <block type="math_number" id="L*4oP!ONkz,$oS[WBy$Z">
                          <field name="NUM">4</field>
                        </block>
                      </value>
                    </block>
                  </value>
                  <value name="B">
                    <block type="logic_compare" id="7krY=mbaMu5Et[shPtQ6">
                      <field name="OP">EQ</field>
                      <value name="A">
                        <block type="time_get" id="s14?XOfONTG9,+N5iN(r">
                          <mutation xmlns="http://www.w3.org/1999/xhtml" format="false" language="false"></mutation>
                          <field name="OPTION">wd</field>
                        </block>
                      </value>
                      <value name="B">
                        <block type="math_number" id="=x}DUnw.nM{yP%z]Hgd/">
                          <field name="NUM">5</field>
                        </block>
                      </value>
                    </block>
                  </value>
                </block>
              </value>
            </block>
          </value>
          <statement name="DO2">
            <block type="comment" id="oH(@8v$(3}32]D{xUwwJ">
              <field name="COMMENT">KWL Mo-Fr um 14:00 Uhr einschalten</field>
              <next>
                <block type="procedures_callnoreturn" id="e=evcUe.z~J+jY!_wYG7">
                  <mutation name="KWL Mo-Fr Nachmittag ein"></mutation>
                </block>
              </next>
            </block>
          </statement>
          <value name="IF3">
            <block type="logic_operation" id="ET}2tYBf`sggpi?b/lj]" inline="false">
              <field name="OP">OR</field>
              <value name="A">
                <block type="logic_compare" id="tJw_#*CqsM^L0]K|#$CN">
                  <field name="OP">EQ</field>
                  <value name="A">
                    <block type="get_value" id="=1qUIy7+e;vCggNAI=Gh">
                      <field name="ATTR">val</field>
                      <field name="OID">feiertage.0.heute.boolean</field>
                    </block>
                  </value>
                  <value name="B">
                    <block type="logic_boolean" id="_]O88GKfni=E-@?UjV99">
                      <field name="BOOL">TRUE</field>
                    </block>
                  </value>
                </block>
              </value>
              <value name="B">
                <block type="logic_operation" id="%l`JOWzmBPrfT*j8RTz," inline="false">
                  <field name="OP">OR</field>
                  <value name="A">
                    <block type="logic_compare" id="d65PRM,5O@yY%b;FyMiI">
                      <field name="OP">EQ</field>
                      <value name="A">
                        <block type="time_get" id="9U2vGhi}zXmjgS!z1oKP">
                          <mutation xmlns="http://www.w3.org/1999/xhtml" format="false" language="false"></mutation>
                          <field name="OPTION">wd</field>
                        </block>
                      </value>
                      <value name="B">
                        <block type="math_number" id="Ut4c)^i}0)jRPsW*b#@~">
                          <field name="NUM">6</field>
                        </block>
                      </value>
                    </block>
                  </value>
                  <value name="B">
                    <block type="logic_compare" id=":In8qHe{x}MI67Wqm2m{">
                      <field name="OP">EQ</field>
                      <value name="A">
                        <block type="time_get" id="!-Ic-5Np@a@iVeJ%w0`L">
                          <mutation xmlns="http://www.w3.org/1999/xhtml" format="false" language="false"></mutation>
                          <field name="OPTION">wd</field>
                        </block>
                      </value>
                      <value name="B">
                        <block type="math_number" id="jV9bP2CJ_qv]+Y^hjHeG">
                          <field name="NUM">0</field>
                        </block>
                      </value>
                    </block>
                  </value>
                </block>
              </value>
            </block>
          </value>
          <statement name="DO3">
            <block type="comment" id="hw4qG_=9(.Au_0(!C)tr">
              <field name="COMMENT">KWL Sa+So+Ft um 16:00 Uhr einschalten</field>
              <next>
                <block type="procedures_callnoreturn" id="ZGom`%?!Jf%;/SK9sW.e">
                  <mutation name="KWL Sa+So+Ft Nachmittag ein"></mutation>
                </block>
              </next>
            </block>
          </statement>
        </block>
        <block type="procedures_defnoreturn" id="0h-pTMB,8$CLzxx8?|^$" x="863" y="-12">
          <field name="NAME">KWL Mo-Fr aus</field>
          <comment pinned="false" h="80" w="160">Beschreibe diese Funktion …</comment>
          <statement name="STACK">
            <block type="schedule" id="z2qzIkP+:svgre1LpmgV">
              <field name="SCHEDULE">0 8 * * *</field>
              <statement name="STATEMENT">
                <block type="control" id="HrG;mbWf1%?aGHz^rvky">
                  <mutation xmlns="http://www.w3.org/1999/xhtml" delay_input="false"></mutation>
                  <field name="OID">shelly.0.SHSW-PM#F4CFA2E3AFE9#1.Relay0.Switch</field>
                  <field name="WITH_DELAY">FALSE</field>
                  <value name="VALUE">
                    <block type="logic_boolean" id="IwvvODz5GPLi@_6l1*)^">
                      <field name="BOOL">FALSE</field>
                    </block>
                  </value>
                </block>
              </statement>
            </block>
          </statement>
        </block>
        <block type="procedures_defnoreturn" id="X2a]?{%kPpe*e5LU!,m`" x="862" y="237">
          <field name="NAME">KWL Sa+So+Ft aus</field>
          <comment pinned="false" h="80" w="160">Beschreibe diese Funktion …</comment>
          <statement name="STACK">
            <block type="schedule" id="LOP|kKkemfn.OCbNbr40">
              <field name="SCHEDULE">0 10 * * *</field>
              <statement name="STATEMENT">
                <block type="control" id="Pm5m[a~69A_BwR]vE#y$">
                  <mutation xmlns="http://www.w3.org/1999/xhtml" delay_input="false"></mutation>
                  <field name="OID">shelly.0.SHSW-PM#F4CFA2E3AFE9#1.Relay0.Switch</field>
                  <field name="WITH_DELAY">FALSE</field>
                  <value name="VALUE">
                    <block type="logic_boolean" id="AP[0=2{z6j5CWgo2aaJ=">
                      <field name="BOOL">FALSE</field>
                    </block>
                  </value>
                </block>
              </statement>
            </block>
          </statement>
        </block>
        <block type="procedures_defnoreturn" id="G2I%Nn2~Vp]5uc[7~^/G" x="862" y="412">
          <field name="NAME">KWL Mo-Fr Nachmittag ein</field>
          <comment pinned="false" h="80" w="160">Beschreibe diese Funktion …</comment>
          <statement name="STACK">
            <block type="schedule" id="d#Lyp3$?M;1J)lWH#)o[">
              <field name="SCHEDULE">0 14 * * *</field>
              <statement name="STATEMENT">
                <block type="control" id="~MH9}mmB!nc/T9}$ZRVS">
                  <mutation xmlns="http://www.w3.org/1999/xhtml" delay_input="false"></mutation>
                  <field name="OID">shelly.0.SHSW-PM#F4CFA2E3AFE9#1.Relay0.Switch</field>
                  <field name="WITH_DELAY">FALSE</field>
                  <value name="VALUE">
                    <block type="logic_boolean" id="Wb|6`-BIX$5g#{sa+JCC">
                      <field name="BOOL">TRUE</field>
                    </block>
                  </value>
                </block>
              </statement>
            </block>
          </statement>
        </block>
        <block type="procedures_defnoreturn" id="UX{P?NYzYr4v#pR:$o+_" x="863" y="663">
          <field name="NAME">KWL Sa+So+Ft Nachmittag ein</field>
          <comment pinned="false" h="80" w="160">Beschreibe diese Funktion …</comment>
          <statement name="STACK">
            <block type="schedule" id="U}1t$n6sM+!?J6j#=Aqd">
              <field name="SCHEDULE">0 16 * * *</field>
              <statement name="STATEMENT">
                <block type="control" id="]1f0NE)N`A0+ft60W,o=">
                  <mutation xmlns="http://www.w3.org/1999/xhtml" delay_input="false"></mutation>
                  <field name="OID">shelly.0.SHSW-PM#F4CFA2E3AFE9#1.Relay0.Switch</field>
                  <field name="WITH_DELAY">FALSE</field>
                  <value name="VALUE">
                    <block type="logic_boolean" id="bcwu}t0u.B0RBO+w`m_!">
                      <field name="BOOL">TRUE</field>
                    </block>
                  </value>
                </block>
              </statement>
            </block>
          </statement>
        </block>
      </xml>
      
      paul53 1 Reply Last reply Reply Quote 0
      • paul53
        paul53 @SLang77 last edited by paul53

        @slang-0
        Mo-Fr kann man im CRON mit angeben. Weitere Abfragen müssen innerhalb der Zeitpläne erfolgen. Vorschlag:

        Blockly_temp.JPG

        <xml xmlns="https://developers.google.com/blockly/xml">
         <block type="comment" id="OcNDtM_|x]FIPA#XlGy-" x="88" y="-362">
           <field name="COMMENT">Jeden Tag</field>
         </block>
         <block type="schedule" id=".3$gO5a%R[|]aBABFkD~" x="88" y="-238">
           <field name="SCHEDULE">0 4 * * *</field>
           <statement name="STATEMENT">
             <block type="comment" id="mw1*:Xt0=T)g`ZII$bM+">
               <field name="COMMENT">KWL jeden Tag um 04:00 Uhr einschalten</field>
               <next>
                 <block type="control" id="m~`*62THEx;^O+|?-lNL">
                   <mutation xmlns="http://www.w3.org/1999/xhtml" delay_input="false"></mutation>
                   <field name="OID">shelly.0.SHSW-PM#F4CFA2E3AFE9#1.Relay0.Switch</field>
                   <field name="WITH_DELAY">FALSE</field>
                   <value name="VALUE">
                     <block type="logic_boolean" id="#(7K_cFCpST[G[PC/:xB">
                       <field name="BOOL">TRUE</field>
                     </block>
                   </value>
                 </block>
               </next>
             </block>
           </statement>
           <next>
             <block type="schedule" id="d#Lyp3$?M;1J)lWH#)o[">
               <field name="SCHEDULE">0 14 * * 1-5</field>
               <statement name="STATEMENT">
                 <block type="comment" id="oH(@8v$(3}32]D{xUwwJ">
                   <field name="COMMENT">KWL Mo-Fr um 14:00 Uhr einschalten</field>
                   <next>
                     <block type="controls_if" id="N#yvFVdjPev5^%]MEFht">
                       <value name="IF0">
                         <block type="logic_negate" id="[Z)Gn3M6rN[KqvZ3)5r3">
                           <value name="BOOL">
                             <block type="get_value" id="0qvQZP,U^L!bhIVjMMSN">
                               <field name="ATTR">val</field>
                               <field name="OID">feiertage.0.heute.boolean</field>
                             </block>
                           </value>
                         </block>
                       </value>
                       <statement name="DO0">
                         <block type="control" id="~MH9}mmB!nc/T9}$ZRVS">
                           <mutation xmlns="http://www.w3.org/1999/xhtml" delay_input="false"></mutation>
                           <field name="OID">shelly.0.SHSW-PM#F4CFA2E3AFE9#1.Relay0.Switch</field>
                           <field name="WITH_DELAY">FALSE</field>
                           <value name="VALUE">
                             <block type="logic_boolean" id="Wb|6`-BIX$5g#{sa+JCC">
                               <field name="BOOL">TRUE</field>
                             </block>
                           </value>
                         </block>
                       </statement>
                     </block>
                   </next>
                 </block>
               </statement>
               <next>
                 <block type="schedule" id="U}1t$n6sM+!?J6j#=Aqd">
                   <field name="SCHEDULE">0 16 * * *</field>
                   <statement name="STATEMENT">
                     <block type="comment" id="hw4qG_=9(.Au_0(!C)tr">
                       <field name="COMMENT">KWL Sa+So+Ft um 16:00 Uhr einschalten</field>
                       <next>
                         <block type="controls_if" id="eAbdAo,-jkq|{y9I4f_p">
                           <value name="IF0">
                             <block type="logic_operation" id="[z];0S0aut)^4Vo`jBEP" inline="false">
                               <field name="OP">OR</field>
                               <value name="A">
                                 <block type="get_value" id="`ag3J/Ci2|F?vhGSr+AF">
                                   <field name="ATTR">val</field>
                                   <field name="OID">feiertage.0.heute.boolean</field>
                                 </block>
                               </value>
                               <value name="B">
                                 <block type="logic_compare" id="Oenr64s$TkzGw+UH]+f:">
                                   <field name="OP">GTE</field>
                                   <value name="A">
                                     <block type="time_get" id="AZFpD0.s7^isIk@c#~Ud">
                                       <mutation xmlns="http://www.w3.org/1999/xhtml" format="false" language="false"></mutation>
                                       <field name="OPTION">wd</field>
                                     </block>
                                   </value>
                                   <value name="B">
                                     <block type="math_number" id=".UcR_6^}}4NJiAI:`m64">
                                       <field name="NUM">6</field>
                                     </block>
                                   </value>
                                 </block>
                               </value>
                             </block>
                           </value>
                           <statement name="DO0">
                             <block type="control" id="]1f0NE)N`A0+ft60W,o=">
                               <mutation xmlns="http://www.w3.org/1999/xhtml" delay_input="false"></mutation>
                               <field name="OID">shelly.0.SHSW-PM#F4CFA2E3AFE9#1.Relay0.Switch</field>
                               <field name="WITH_DELAY">FALSE</field>
                               <value name="VALUE">
                                 <block type="logic_boolean" id="bcwu}t0u.B0RBO+w`m_!">
                                   <field name="BOOL">TRUE</field>
                                 </block>
                               </value>
                             </block>
                           </statement>
                         </block>
                       </next>
                     </block>
                   </statement>
                 </block>
               </next>
             </block>
           </next>
         </block>
         <block type="schedule" id="Em.rM9*v])A+PW|:041V" x="888" y="-238">
           <field name="SCHEDULE">30 22 * * *</field>
           <statement name="STATEMENT">
             <block type="comment" id="drNqF9B*A5pL{D%68Hl^">
               <field name="COMMENT">KWL jeden Tag um 22:30 Uhr ausschalten</field>
               <next>
                 <block type="control" id="gvj$Pf=JySy|`b*0i=fr">
                   <mutation xmlns="http://www.w3.org/1999/xhtml" delay_input="false"></mutation>
                   <field name="OID">shelly.0.SHSW-PM#F4CFA2E3AFE9#1.Relay0.Switch</field>
                   <field name="WITH_DELAY">FALSE</field>
                   <value name="VALUE">
                     <block type="logic_boolean" id="RE1@AmhUaFG[n*)cet0a">
                       <field name="BOOL">FALSE</field>
                     </block>
                   </value>
                 </block>
               </next>
             </block>
           </statement>
           <next>
             <block type="schedule" id="z2qzIkP+:svgre1LpmgV">
               <field name="SCHEDULE">0 8 * * 1-5</field>
               <statement name="STATEMENT">
                 <block type="comment" id="f]n$;QYr/jNhRcEPpgu?">
                   <field name="COMMENT">KWL Mo-Fr um 08:00 Uhr ausschalten</field>
                   <next>
                     <block type="controls_if" id="fz~8+0OXP|he`(QHwUlm">
                       <value name="IF0">
                         <block type="logic_negate" id="kJwW.]9geP2GXVl*6TYn">
                           <value name="BOOL">
                             <block type="get_value" id="seT2gFjpDvK-1./Jr*Rh">
                               <field name="ATTR">val</field>
                               <field name="OID">feiertage.0.heute.boolean</field>
                             </block>
                           </value>
                         </block>
                       </value>
                       <statement name="DO0">
                         <block type="control" id="HrG;mbWf1%?aGHz^rvky">
                           <mutation xmlns="http://www.w3.org/1999/xhtml" delay_input="false"></mutation>
                           <field name="OID">shelly.0.SHSW-PM#F4CFA2E3AFE9#1.Relay0.Switch</field>
                           <field name="WITH_DELAY">FALSE</field>
                           <value name="VALUE">
                             <block type="logic_boolean" id="IwvvODz5GPLi@_6l1*)^">
                               <field name="BOOL">FALSE</field>
                             </block>
                           </value>
                         </block>
                       </statement>
                     </block>
                   </next>
                 </block>
               </statement>
               <next>
                 <block type="schedule" id="f$N7U~B=x_*cS=GP]NC,">
                   <field name="SCHEDULE">0 10 * * *</field>
                   <statement name="STATEMENT">
                     <block type="comment" id="wt41P?T{J0uFtC@53|m!">
                       <field name="COMMENT">KWL Sa+So+Ft um 10:00 Uhr ausschalten</field>
                       <next>
                         <block type="controls_if" id="m];8kP1FzGe`-GQ^Il*J">
                           <value name="IF0">
                             <block type="logic_operation" id="[5pOYdA;:CFSlp:71ZiF" inline="false">
                               <field name="OP">OR</field>
                               <value name="A">
                                 <block type="get_value" id="~fIz-Op=JX;eY04AkJqO">
                                   <field name="ATTR">val</field>
                                   <field name="OID">feiertage.0.heute.boolean</field>
                                 </block>
                               </value>
                               <value name="B">
                                 <block type="logic_compare" id="pp9am)Z/Z.4tHc/C.7nG">
                                   <field name="OP">GTE</field>
                                   <value name="A">
                                     <block type="time_get" id="k9C[DIn~k}_]tzL~Q%ai">
                                       <mutation xmlns="http://www.w3.org/1999/xhtml" format="false" language="false"></mutation>
                                       <field name="OPTION">wd</field>
                                     </block>
                                   </value>
                                   <value name="B">
                                     <block type="math_number" id="vZ;|d#0=Pg:5YQyIod!Y">
                                       <field name="NUM">6</field>
                                     </block>
                                   </value>
                                 </block>
                               </value>
                             </block>
                           </value>
                           <statement name="DO0">
                             <block type="control" id="nIJz?psap/YYt*%4.n/q">
                               <mutation xmlns="http://www.w3.org/1999/xhtml" delay_input="false"></mutation>
                               <field name="OID">shelly.0.SHSW-PM#F4CFA2E3AFE9#1.Relay0.Switch</field>
                               <field name="WITH_DELAY">FALSE</field>
                               <value name="VALUE">
                                 <block type="logic_boolean" id="~U-t0DK(_T*RHN#C(-Lf">
                                   <field name="BOOL">FALSE</field>
                                 </block>
                               </value>
                             </block>
                           </statement>
                         </block>
                       </next>
                     </block>
                   </statement>
                 </block>
               </next>
             </block>
           </next>
         </block>
        </xml>
        

        Laut Doku ist Wochentag als Zahl = 1 (Mo) bis 7 (So).

        SLang77 1 Reply Last reply Reply Quote 1
        • SLang77
          SLang77 @paul53 last edited by

          @paul53 Hi und vielen herzlichen Dank für deine Unterstützung!

          Das werde ich sehr gerne Testen.

          Noch eine Frage:
          Gibt es zwischen "Nicht Wert vom Objekt ID Feiertag heute?" und dem von mir dargestellten einen Unterschied? (siehe blockly)

          Testscript.jpg

          paul53 1 Reply Last reply Reply Quote 0
          • paul53
            paul53 @SLang77 last edited by

            @slang-0 sagte: Gibt es zwischen "Nicht Wert vom Objekt ID Feiertag heute?" und dem von mir dargestellten einen Unterschied?

            Bei booleschen Werten liefern beide Varianten das gleiche Ergebnis.

            SLang77 1 Reply Last reply Reply Quote 1
            • SLang77
              SLang77 @paul53 last edited by

              @paul53 sagte in KWL Zeitsteuerung WT / Sa+So+Ft:

              @slang-0 sagte: Gibt es zwischen "Nicht Wert vom Objekt ID Feiertag heute?" und dem von mir dargestellten einen Unterschied?

              Bei booleschen Werten liefern beide Varianten das gleiche Ergebnis.

              Vielen Dank!

              Soweit ich sehe funktioniert die Steuerung jetzt auch wie gewünscht. Also auch dafür nochmal herzlichen Dank. Manchmal denkt man glaube einfach zu kompliziert.

              SLang77 1 Reply Last reply Reply Quote 0
              • SLang77
                SLang77 @SLang77 last edited by

                Leider funktioniert es doch nicht und ich blicke auch nicht drann her warum es nicht funktioiniert.
                Es sollen die Datenpunkte zusätzlich neben "Feiertag heute?", "Krank" und "Urlaub" abgefragt werden. Die Daten kommen aus einem google Kalender.
                Der Datenpunkt ical.1.events.0.today.Krank steht auf true Von daher dürfte heute doch die Anlage um 14 Uhr nicht eingeschaltet werden. Sie wird aber eingeschaltet. Ich verstehe nicht wo der Fehler liegt.

                Ich hänge nochmal den aktuellen Stand an:

                Blockly.jpg
                objekte.jpg

                paul53 1 Reply Last reply Reply Quote 0
                • paul53
                  paul53 @SLang77 last edited by paul53

                  @slang-0 sagte: Es sollen die Datenpunkte zusätzlich neben "Feiertag heute?", "Krank" und "Urlaub" abgefragt werden.

                  Das passiert bisher nicht im Skript. Es wird nur "Feiertag heute?" abgefragt.

                  EDIT: Was bedeutet "Urlaub"? Auf Reise oder zu Hause?

                  SLang77 1 Reply Last reply Reply Quote 0
                  • SLang77
                    SLang77 @paul53 last edited by SLang77

                    @paul53 sagte in KWL Zeitsteuerung WT / Sa+So+Ft:

                    @slang-0 sagte: Es sollen die Datenpunkte zusätzlich neben "Feiertag heute?", "Krank" und "Urlaub" abgefragt werden.

                    Das passiert bisher nicht im Skript. Es wird nur "Feiertag heute?" abgefragt.

                    EDIT: Was bedeutet "Urlaub"? Auf Reise oder zu Hause?

                    Urlaub bedeutet zuhause. Oder anders gesagt Krank und Urlaub bedeutet nicht auf der Arbeit und die Anlage soll zu anderen Zeiten betriben werden.
                    urlaub kommt genauso wie Krank aus einem Google Kalender und wird soweit ich sehe auch sauber eingetragen.

                    Warum passiert das nicht im Script? Es steht doch drin... Bin echt verwirrt. Ich verwende das im Prinzip genau so in einem Anderen Script. Da funktioniert das ohne Probleme. Es scheint ein Problem in dem Zeitbereich zu sein. Irgendwie schein nicht klar zu sein, das zwar Wochentag (1-5) aber die Abfrage aus dem Kalender scheint trotz dem Falls Baustein nicht zu greifen.

                    paul53 1 Reply Last reply Reply Quote 0
                    • paul53
                      paul53 @SLang77 last edited by

                      @slang-0 sagte: Warum passiert das nicht im Script? Es steht doch drin...

                      Jetzt sehe ich es: Es ist falsch unter der Woche. Richtig:

                      Bild_2021-12-03_175102.png

                      SLang77 1 Reply Last reply Reply Quote 1
                      • SLang77
                        SLang77 @paul53 last edited by

                        @paul53 sagte in KWL Zeitsteuerung WT / Sa+So+Ft:

                        @slang-0 sagte: Warum passiert das nicht im Script? Es steht doch drin...

                        Jetzt sehe ich es: Es ist falsch unter der Woche. Richtig:

                        Bild_2021-12-03_175102.png

                        okay...

                        Also ich verstehe das so, dass die Reihenfolge der Elemente nicht stimmt? Das "nicht" darf nicht nach dem "oder" folgen?
                        Ansonsten ist das doch gleich oder (siehe Bild 1 und 2)?

                        Bild1.jpg
                        Bild2.jpg

                        paul53 1 Reply Last reply Reply Quote 0
                        • paul53
                          paul53 @SLang77 last edited by paul53

                          @slang-0 sagte: Ansonsten ist das doch gleich oder (siehe Bild 1 und 2)?

                          Nein. Wenn jeder einzelne Wert negiert wird, müssen alle 3 negierten Werte mit und verknüpft werden. In Worten:
                          Es ist kein Feiertag und auch kein Urlaub und ich bin gesund, dann ...

                          SLang77 1 Reply Last reply Reply Quote 0
                          • SLang77
                            SLang77 @paul53 last edited by

                            @paul53 sagte in KWL Zeitsteuerung WT / Sa+So+Ft:

                            @slang-0 sagte: Ansonsten ist das doch gleich oder (siehe Bild 1 und 2)?

                            Nein. Wenn jeder einzelne Wert negiert wird, müssen alle 3 negierten Werte mit und verknüpft werden.

                            Wirklich absolut mega großen Dank für deine Hilfe... Ich will mich auch nicht dumm stellen, oder so... würde das dann bedeuten, dass das hier auch falsch ist:

                            Bild1.jpg

                            und eigentlich so sein müsste?

                            Bild2.jpg

                            paul53 1 Reply Last reply Reply Quote 0
                            • paul53
                              paul53 @SLang77 last edited by

                              @slang-0 sagte: eigentlich so sein müsste?

                              Ja.

                              1 Reply Last reply Reply Quote 1
                              • SLang77
                                SLang77 last edited by

                                @paul53

                                Vielen Dank!

                                1 Reply Last reply Reply Quote 0
                                • First post
                                  Last post

                                Support us

                                ioBroker
                                Community Adapters
                                Donate

                                887
                                Online

                                32.0k
                                Users

                                80.5k
                                Topics

                                1.3m
                                Posts

                                2
                                14
                                503
                                Loading More Posts
                                • Oldest to Newest
                                • Newest to Oldest
                                • Most Votes
                                Reply
                                • Reply as topic
                                Log in to reply
                                Community
                                Impressum | Datenschutz-Bestimmungen | Nutzungsbedingungen
                                The ioBroker Community 2014-2023
                                logo