@asgothian said in Zeitschaltuhr mit Blockly:
@vit-hei
Ich würde das ganze prinzipiell anders aufbauen:
- Je einen "benannten" Zeitplan für jeden Tag der Woche
 
- Je einen Trigger auf die Datenpunkte die zu den Zeitplänen für diesen Wochentag gehen
 
- Im Trigger den entsprechenden "benannten" Zeitplan löschen und einen neuen anlegen.
 
- Bei Skriptstart alle Zeitpläne anlegen
 
Dankeschön.
Habe ich nun hinbekommen:
<xml xmlns="https://developers.google.com/blockly/xml">
  <variables>
    <variable type="cron" id="Rollos auf/zu">Rollos auf/zu</variable>
  </variables>
  <block type="procedures_defnoreturn" id="KjD@@8v2b3[l!Iz4,QCH" x="-838" y="-562">
    <field name="NAME">Rollos_Auf</field>
    <comment pinned="false" h="80" w="160">Beschreibe diese Funktion …</comment>
    <statement name="STACK">
      <block type="comment" id="|FhckLJj_i~O-Q-8we4c">
        <field name="COMMENT">Skript funktioniert für Mittwoch---VH</field>
        <next>
          <block type="controls_if" id="N@[Q7y~uhX%vi=W_Subm">
            <value name="IF0">
              <block type="logic_compare" id="{lp2NwS{(F9hF0_)(Y1~">
                <field name="OP">EQ</field>
                <value name="A">
                  <block type="get_value" id=")y|Xx]1=:Mo(qJ/P]bgB">
                    <field name="ATTR">val</field>
                    <field name="OID">0_userdata.0.Rollos.Timerzustand.Mittwoch.Mittwoch_ein/aus</field>
                  </block>
                </value>
                <value name="B">
                  <block type="logic_boolean" id=".My;62PsS:.S(l4NDudp">
                    <field name="BOOL">TRUE</field>
                  </block>
                </value>
              </block>
            </value>
            <statement name="DO0">
              <block type="schedule_create" id="f2ex;D{,jkR5P[F/e{(u">
                <field name="NAME">Rollos auf/zu</field>
                <value name="SCHEDULE">
                  <shadow type="field_cron" id="}Z$O${@0RX,AU4!kK)Q/">
                    <field name="CRON">* * * * *</field>
                  </shadow>
                  <block type="cron_builder" id="HZ-xpXQoB/fIeB8NLT)8">
                    <mutation xmlns="http://www.w3.org/1999/xhtml" seconds="false" as_line="false"></mutation>
                    <field name="LINE">FALSE</field>
                    <field name="WITH_SECONDS">FALSE</field>
                    <value name="DOW">
                      <shadow type="text" id="U@Ml#/x`x2uvVW@h;+19">
                        <field name="TEXT">3</field>
                      </shadow>
                    </value>
                    <value name="MONTHS">
                      <shadow type="text" id=".OORsyiYSe0p$kV:4*^S">
                        <field name="TEXT">*</field>
                      </shadow>
                    </value>
                    <value name="DAYS">
                      <shadow type="text" id="$TKDnjAdVXCWFeG3=~o5">
                        <field name="TEXT">*</field>
                      </shadow>
                    </value>
                    <value name="HOURS">
                      <shadow type="text" id="HW5[hw2v$O=bR2:,ArE+">
                        <field name="TEXT">*</field>
                      </shadow>
                    </value>
                    <value name="MINUTES">
                      <shadow type="text" id="7$5pc@`1z$YXuUN;vM`.">
                        <field name="TEXT">*</field>
                      </shadow>
                    </value>
                  </block>
                </value>
                <statement name="STATEMENT">
                  <block type="controls_if" id="-q=`JfRqQ2@FdS!,(MxQ">
                    <value name="IF0">
                      <block type="logic_compare" id="Ul]/CpM8TE}/_lFG:nv]">
                        <field name="OP">EQ</field>
                        <value name="A">
                          <block type="time_get" id="tzZnp_cu`*Vn0aY:2}]Y">
                            <mutation xmlns="http://www.w3.org/1999/xhtml" format="false" language="false"></mutation>
                            <field name="OPTION">hh:mm</field>
                          </block>
                        </value>
                        <value name="B">
                          <block type="convert_from_date" id="okj(VDeTV}BjJe+I:/)|">
                            <mutation xmlns="http://www.w3.org/1999/xhtml" format="false" language="false"></mutation>
                            <field name="OPTION">hh:mm</field>
                            <value name="VALUE">
                              <block type="get_value" id="6/2Bwm6}]dU3mZ+VlP(3">
                                <field name="ATTR">val</field>
                                <field name="OID">0_userdata.0.Rollos.Timerzustand.Mittwoch.H_An</field>
                              </block>
                            </value>
                          </block>
                        </value>
                      </block>
                    </value>
                    <statement name="DO0">
                      <block type="control" id="6MkWfqRbg+fx(1o9t[}t">
                        <mutation xmlns="http://www.w3.org/1999/xhtml" delay_input="false"></mutation>
                        <field name="OID">javascript.0.Rollladensteuerung.VIS.ALL_shutter_OnOff</field>
                        <field name="WITH_DELAY">FALSE</field>
                        <value name="VALUE">
                          <block type="logic_boolean" id="7b_l!`z4nELM[|A%kyXd">
                            <field name="BOOL">TRUE</field>
                          </block>
                        </value>
                      </block>
                    </statement>
                    <next>
                      <block type="controls_if" id="ax2q^4c,/j9,QYx-FNV~">
                        <value name="IF0">
                          <block type="logic_compare" id="P2x2*-a29/Jfn,GxQ}O/">
                            <field name="OP">EQ</field>
                            <value name="A">
                              <block type="time_get" id="#|N,9~`*6Q-,W]2i7A6x">
                                <mutation xmlns="http://www.w3.org/1999/xhtml" format="false" language="false"></mutation>
                                <field name="OPTION">hh:mm</field>
                              </block>
                            </value>
                            <value name="B">
                              <block type="convert_from_date" id="xZ{XB7dkHQ3M)q6a-8qb">
                                <mutation xmlns="http://www.w3.org/1999/xhtml" format="false" language="false"></mutation>
                                <field name="OPTION">hh:mm</field>
                                <value name="VALUE">
                                  <block type="get_value" id="/ED;v.u7y-?(dC8#I,.t">
                                    <field name="ATTR">val</field>
                                    <field name="OID">0_userdata.0.Rollos.Timerzustand.Mittwoch.H_Aus</field>
                                  </block>
                                </value>
                              </block>
                            </value>
                          </block>
                        </value>
                        <statement name="DO0">
                          <block type="control" id="vq)26KfG@u]7L9:[hjML">
                            <mutation xmlns="http://www.w3.org/1999/xhtml" delay_input="false"></mutation>
                            <field name="OID">javascript.0.Rollladensteuerung.VIS.ALL_shutter_OnOff</field>
                            <field name="WITH_DELAY">FALSE</field>
                            <value name="VALUE">
                              <block type="logic_boolean" id="h/|0,Z)74mA1R*xu1;h!">
                                <field name="BOOL">FALSE</field>
                              </block>
                            </value>
                          </block>
                        </statement>
                      </block>
                    </next>
                  </block>
                </statement>
              </block>
            </statement>
          </block>
        </next>
      </block>
    </statement>
  </block>
  <block type="procedures_callnoreturn" id="2#?5/,^RbDXuW]Mh2Acu" x="-187" y="-512">
    <mutation name="Rollos_Auf"></mutation>
    <next>
      <block type="on" id="$1t,..3bo,l8YGlFzHaP">
        <field name="OID">0_userdata.0.Rollos.Timerzustand.Dienstag.H_An</field>
        <field name="CONDITION">ne</field>
        <field name="ACK_CONDITION"></field>
        <statement name="STATEMENT">
          <block type="schedule_clear" id="P0|ssO|C0@|W2N8+cS/i">
            <field name="NAME">Rollos auf/zu</field>
            <next>
              <block type="procedures_callnoreturn" id="$O2wOf{`^NuX9:aq%VXg">
                <mutation name="Rollos_Auf"></mutation>
              </block>
            </next>
          </block>
        </statement>
      </block>
    </next>
  </block>
</xml>

Für meine Zwecke reicht es erstmal.