Skip to content
  • Home
  • Aktuell
  • Tags
  • 0 Ungelesen 0
  • Kategorien
  • Unreplied
  • Beliebt
  • GitHub
  • Docu
  • Hilfe
Skins
  • Light
  • Brite
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Standard: (Kein Skin)
  • Kein Skin
Einklappen
ioBroker Logo

Community Forum

donate donate
  1. ioBroker Community Home
  2. Deutsch
  3. Skripten / Logik
  4. Blockly
  5. Blockly unnötige Steuerung wie lösen?

NEWS

  • Neuer Blogbeitrag: Monatsrückblick - Dezember 2025 🎄
    BluefoxB
    Bluefox
    10
    1
    140

  • Weihnachtsangebot 2025! 🎄
    BluefoxB
    Bluefox
    24
    1
    1.4k

  • UPDATE 31.10.: Amazon Alexa - ioBroker Skill läuft aus ?
    apollon77A
    apollon77
    48
    3
    9.4k

Blockly unnötige Steuerung wie lösen?

Geplant Angeheftet Gesperrt Verschoben Blockly
6 Beiträge 5 Kommentatoren 529 Aufrufe 3 Watching
  • Älteste zuerst
  • Neuste zuerst
  • Meiste Stimmen
Antworten
  • In einem neuen Thema antworten
Anmelden zum Antworten
Dieses Thema wurde gelöscht. Nur Nutzer mit entsprechenden Rechten können es sehen.
  • M Offline
    M Offline
    mrfloppy
    schrieb am zuletzt editiert von mrfloppy
    #1

    In meinem Blockly steuere ich mit 3 BWM mein Kellerlicht.
    Das Blockly funktioniert soweit , nur wird bei jedem mal wahr
    der Block "steuere Brightness mit 100" immer wieder ausgeführt obwohl eh schon auf 100.
    Wie kann man das schön lösen und Steuer Befehle einsparen?

    Danke LG Thomas
    blokly.png

    <xml xmlns="https://developers.google.com/blockly/xml">
      <variables>
        <variable type="timeout" id="timeout2">timeout2</variable>
        <variable type="timeout" id="timeout3">timeout3</variable>
      </variables>
      <block type="comment" id="a;4E{*dk:]raf}1GK:oC" x="38" y="-562">
        <field name="COMMENT">BWM 1 und 2 und 3 am Kellerabgang schaltet Gruppe in Zigbee2mqtttt</field>
        <next>
          <block type="on_ext" id="6NTf}*4Hs@H?k/54~dHi">
            <mutation xmlns="http://www.w3.org/1999/xhtml" items="3"></mutation>
            <field name="CONDITION">ne</field>
            <field name="ACK_CONDITION"></field>
            <value name="OID0">
              <shadow type="field_oid" id="eIwD5nRX(N$RuC,J1uKe">
                <field name="oid">zigbee2mqtt.0.0x00158d0008f11336.occupancy</field>
              </shadow>
            </value>
            <value name="OID1">
              <shadow type="field_oid" id=".,b50y=^Z^X,#iPP9XI1">
                <field name="oid">zigbee2mqtt.0.0x00158d0008d9195e.occupancy</field>
              </shadow>
            </value>
            <value name="OID2">
              <shadow type="field_oid" id="RvLxvwPtZFz~hQ[$wUgM">
                <field name="oid">zigbee2mqtt.0.0xa4c1382e5d2ff601.occupancy</field>
              </shadow>
            </value>
            <statement name="STATEMENT">
              <block type="controls_if" id="i6lv|%TLZaltMR@P/Q!Z">
                <mutation elseif="1"></mutation>
                <value name="IF0">
                  <block type="logic_operation" id="M:xQdbhe*,yzGM,Gm,z." inline="false">
                    <field name="OP">OR</field>
                    <value name="A">
                      <block type="logic_compare" id="U[*%P+/)BvVg.{-cRyGH">
                        <field name="OP">EQ</field>
                        <value name="A">
                          <block type="get_value" id="BJ(j7?;/kA~6rEy=|dkJ">
                            <field name="ATTR">val</field>
                            <field name="OID">zigbee2mqtt.0.0x00158d0008f11336.occupancy</field>
                          </block>
                        </value>
                        <value name="B">
                          <block type="logic_boolean" id="9%geI{n+~Xd7T6%HAW[L">
                            <field name="BOOL">TRUE</field>
                          </block>
                        </value>
                      </block>
                    </value>
                    <value name="B">
                      <block type="logic_operation" id="UAhbdHGUCbKKn?G=I0ab" inline="false">
                        <field name="OP">OR</field>
                        <value name="A">
                          <block type="logic_compare" id="}mo^tTy+|@Tl%T5-1;d5">
                            <field name="OP">EQ</field>
                            <value name="A">
                              <block type="get_value" id="=o[6`YJt2VX``#mw(~VB">
                                <field name="ATTR">val</field>
                                <field name="OID">zigbee2mqtt.0.0x00158d0008d9195e.occupancy</field>
                              </block>
                            </value>
                            <value name="B">
                              <block type="logic_boolean" id="mDe~ellX*:$%Q^NBF)bN">
                                <field name="BOOL">TRUE</field>
                              </block>
                            </value>
                          </block>
                        </value>
                        <value name="B">
                          <block type="logic_compare" id="~h$}jSLIP6}.NFPm_d`,">
                            <field name="OP">EQ</field>
                            <value name="A">
                              <block type="get_value" id="_Y%Q0o*SCHOr4Z9__a_R">
                                <field name="ATTR">val</field>
                                <field name="OID">zigbee2mqtt.0.0xa4c1382e5d2ff601.occupancy</field>
                              </block>
                            </value>
                            <value name="B">
                              <block type="logic_boolean" id="sSym*aP338bTY/#@[jyn">
                                <field name="BOOL">TRUE</field>
                              </block>
                            </value>
                          </block>
                        </value>
                      </block>
                    </value>
                  </block>
                </value>
                <statement name="DO0">
                  <block type="timeouts_cleartimeout" id="4rKh8(mY;Q_88{m_F(qP">
                    <field name="NAME">timeout2</field>
                    <next>
                      <block type="timeouts_cleartimeout" id="2^|Pgwbdl1)GVYu%TGDX">
                        <field name="NAME">timeout3</field>
                        <next>
                          <block type="control" id="v%$[jBEi/`P(;I~rsc^)">
                            <mutation xmlns="http://www.w3.org/1999/xhtml" delay_input="false"></mutation>
                            <field name="OID">zigbee2mqtt.0.group_2.brightness</field>
                            <field name="WITH_DELAY">FALSE</field>
                            <value name="VALUE">
                              <block type="math_number" id="V|E,e~rCGj2E0)f8UZM1">
                                <field name="NUM">100</field>
                              </block>
                            </value>
                          </block>
                        </next>
                      </block>
                    </next>
                  </block>
                </statement>
                <value name="IF1">
                  <block type="logic_operation" id="{Ev6=boS]pkCMNh2Eo*r" inline="false">
                    <field name="OP">AND</field>
                    <value name="A">
                      <block type="logic_compare" id="-:71$@UQ!R!G$R)7+u4,">
                        <field name="OP">EQ</field>
                        <value name="A">
                          <block type="get_value" id="W}gB;F`sQD|pbZR;=c/g">
                            <field name="ATTR">val</field>
                            <field name="OID">zigbee2mqtt.0.0x00158d0008f11336.occupancy</field>
                          </block>
                        </value>
                        <value name="B">
                          <block type="logic_boolean" id="RR-tvQ|18yCnOa6px]n{">
                            <field name="BOOL">FALSE</field>
                          </block>
                        </value>
                      </block>
                    </value>
                    <value name="B">
                      <block type="logic_operation" id="gI6(6CqwKBw46y7f9:M(" inline="false">
                        <field name="OP">AND</field>
                        <value name="A">
                          <block type="logic_compare" id="!%QFhWOT0,ezYAlm?W5Y">
                            <field name="OP">EQ</field>
                            <value name="A">
                              <block type="get_value" id="v8UPSTq2iX1m7lJuVq=4">
                                <field name="ATTR">val</field>
                                <field name="OID">zigbee2mqtt.0.0x00158d0008d9195e.occupancy</field>
                              </block>
                            </value>
                            <value name="B">
                              <block type="logic_boolean" id="?baQ6C2+i`gG:L}}p{px">
                                <field name="BOOL">FALSE</field>
                              </block>
                            </value>
                          </block>
                        </value>
                        <value name="B">
                          <block type="logic_compare" id="VoT)O#[2|8E6B;ivqW:D">
                            <field name="OP">EQ</field>
                            <value name="A">
                              <block type="get_value" id="3}_#K*vf:oM@+16_L@Yh">
                                <field name="ATTR">val</field>
                                <field name="OID">zigbee2mqtt.0.0xa4c1382e5d2ff601.occupancy</field>
                              </block>
                            </value>
                            <value name="B">
                              <block type="logic_boolean" id="+C{#hnP3T/B}6`;Pkiu(">
                                <field name="BOOL">FALSE</field>
                              </block>
                            </value>
                          </block>
                        </value>
                      </block>
                    </value>
                  </block>
                </value>
                <statement name="DO1">
                  <block type="timeouts_cleartimeout" id="z0j0JlAZ`MO*8H;qm8CL">
                    <field name="NAME">timeout2</field>
                    <next>
                      <block type="timeouts_cleartimeout" id="|eqm6V;gq0/h7-M^=q/v">
                        <field name="NAME">timeout3</field>
                        <next>
                          <block type="comment" id="dB)lP2oEri|Qrf/O4jiG">
                            <field name="COMMENT">Nach 20 Sekunden 50% Brightness</field>
                            <next>
                              <block type="timeouts_settimeout" id="^rA;}G.RQGj$wah~6t$F">
                                <field name="NAME">timeout2</field>
                                <field name="DELAY">20</field>
                                <field name="UNIT">sec</field>
                                <statement name="STATEMENT">
                                  <block type="control" id="YE1m(S6HS%tUdRp|P3jc">
                                    <mutation xmlns="http://www.w3.org/1999/xhtml" delay_input="false"></mutation>
                                    <field name="OID">zigbee2mqtt.0.group_2.brightness</field>
                                    <field name="WITH_DELAY">FALSE</field>
                                    <value name="VALUE">
                                      <block type="math_number" id="NLaBY|LX*s{_]X2*)F1W">
                                        <field name="NUM">25</field>
                                      </block>
                                    </value>
                                    <next>
                                      <block type="comment" id="TyGElbkcOe?92|/!gkDA">
                                        <field name="COMMENT">Nach 50 Sekunden 0% Brightness sprich Licht aus</field>
                                        <next>
                                          <block type="timeouts_settimeout" id="0}(3}t4y=BB1U,Em;Bh)">
                                            <field name="NAME">timeout3</field>
                                            <field name="DELAY">20</field>
                                            <field name="UNIT">sec</field>
                                            <statement name="STATEMENT">
                                              <block type="control" id="{3/Nni!,/xR.L6_??ig[">
                                                <mutation xmlns="http://www.w3.org/1999/xhtml" delay_input="false"></mutation>
                                                <field name="OID">zigbee2mqtt.0.group_2.brightness</field>
                                                <field name="WITH_DELAY">FALSE</field>
                                                <value name="VALUE">
                                                  <block type="math_number" id="so:A@$lw2FwU}b)B!/#]">
                                                    <field name="NUM">0</field>
                                                  </block>
                                                </value>
                                              </block>
                                            </statement>
                                          </block>
                                        </next>
                                      </block>
                                    </next>
                                  </block>
                                </statement>
                              </block>
                            </next>
                          </block>
                        </next>
                      </block>
                    </next>
                  </block>
                </statement>
              </block>
            </statement>
          </block>
        </next>
      </block>
    </xml>
    
    DJMarc75D paul53P Zamecnik JindrichZ 3 Antworten Letzte Antwort
    0
    • M mrfloppy

      In meinem Blockly steuere ich mit 3 BWM mein Kellerlicht.
      Das Blockly funktioniert soweit , nur wird bei jedem mal wahr
      der Block "steuere Brightness mit 100" immer wieder ausgeführt obwohl eh schon auf 100.
      Wie kann man das schön lösen und Steuer Befehle einsparen?

      Danke LG Thomas
      blokly.png

      <xml xmlns="https://developers.google.com/blockly/xml">
        <variables>
          <variable type="timeout" id="timeout2">timeout2</variable>
          <variable type="timeout" id="timeout3">timeout3</variable>
        </variables>
        <block type="comment" id="a;4E{*dk:]raf}1GK:oC" x="38" y="-562">
          <field name="COMMENT">BWM 1 und 2 und 3 am Kellerabgang schaltet Gruppe in Zigbee2mqtttt</field>
          <next>
            <block type="on_ext" id="6NTf}*4Hs@H?k/54~dHi">
              <mutation xmlns="http://www.w3.org/1999/xhtml" items="3"></mutation>
              <field name="CONDITION">ne</field>
              <field name="ACK_CONDITION"></field>
              <value name="OID0">
                <shadow type="field_oid" id="eIwD5nRX(N$RuC,J1uKe">
                  <field name="oid">zigbee2mqtt.0.0x00158d0008f11336.occupancy</field>
                </shadow>
              </value>
              <value name="OID1">
                <shadow type="field_oid" id=".,b50y=^Z^X,#iPP9XI1">
                  <field name="oid">zigbee2mqtt.0.0x00158d0008d9195e.occupancy</field>
                </shadow>
              </value>
              <value name="OID2">
                <shadow type="field_oid" id="RvLxvwPtZFz~hQ[$wUgM">
                  <field name="oid">zigbee2mqtt.0.0xa4c1382e5d2ff601.occupancy</field>
                </shadow>
              </value>
              <statement name="STATEMENT">
                <block type="controls_if" id="i6lv|%TLZaltMR@P/Q!Z">
                  <mutation elseif="1"></mutation>
                  <value name="IF0">
                    <block type="logic_operation" id="M:xQdbhe*,yzGM,Gm,z." inline="false">
                      <field name="OP">OR</field>
                      <value name="A">
                        <block type="logic_compare" id="U[*%P+/)BvVg.{-cRyGH">
                          <field name="OP">EQ</field>
                          <value name="A">
                            <block type="get_value" id="BJ(j7?;/kA~6rEy=|dkJ">
                              <field name="ATTR">val</field>
                              <field name="OID">zigbee2mqtt.0.0x00158d0008f11336.occupancy</field>
                            </block>
                          </value>
                          <value name="B">
                            <block type="logic_boolean" id="9%geI{n+~Xd7T6%HAW[L">
                              <field name="BOOL">TRUE</field>
                            </block>
                          </value>
                        </block>
                      </value>
                      <value name="B">
                        <block type="logic_operation" id="UAhbdHGUCbKKn?G=I0ab" inline="false">
                          <field name="OP">OR</field>
                          <value name="A">
                            <block type="logic_compare" id="}mo^tTy+|@Tl%T5-1;d5">
                              <field name="OP">EQ</field>
                              <value name="A">
                                <block type="get_value" id="=o[6`YJt2VX``#mw(~VB">
                                  <field name="ATTR">val</field>
                                  <field name="OID">zigbee2mqtt.0.0x00158d0008d9195e.occupancy</field>
                                </block>
                              </value>
                              <value name="B">
                                <block type="logic_boolean" id="mDe~ellX*:$%Q^NBF)bN">
                                  <field name="BOOL">TRUE</field>
                                </block>
                              </value>
                            </block>
                          </value>
                          <value name="B">
                            <block type="logic_compare" id="~h$}jSLIP6}.NFPm_d`,">
                              <field name="OP">EQ</field>
                              <value name="A">
                                <block type="get_value" id="_Y%Q0o*SCHOr4Z9__a_R">
                                  <field name="ATTR">val</field>
                                  <field name="OID">zigbee2mqtt.0.0xa4c1382e5d2ff601.occupancy</field>
                                </block>
                              </value>
                              <value name="B">
                                <block type="logic_boolean" id="sSym*aP338bTY/#@[jyn">
                                  <field name="BOOL">TRUE</field>
                                </block>
                              </value>
                            </block>
                          </value>
                        </block>
                      </value>
                    </block>
                  </value>
                  <statement name="DO0">
                    <block type="timeouts_cleartimeout" id="4rKh8(mY;Q_88{m_F(qP">
                      <field name="NAME">timeout2</field>
                      <next>
                        <block type="timeouts_cleartimeout" id="2^|Pgwbdl1)GVYu%TGDX">
                          <field name="NAME">timeout3</field>
                          <next>
                            <block type="control" id="v%$[jBEi/`P(;I~rsc^)">
                              <mutation xmlns="http://www.w3.org/1999/xhtml" delay_input="false"></mutation>
                              <field name="OID">zigbee2mqtt.0.group_2.brightness</field>
                              <field name="WITH_DELAY">FALSE</field>
                              <value name="VALUE">
                                <block type="math_number" id="V|E,e~rCGj2E0)f8UZM1">
                                  <field name="NUM">100</field>
                                </block>
                              </value>
                            </block>
                          </next>
                        </block>
                      </next>
                    </block>
                  </statement>
                  <value name="IF1">
                    <block type="logic_operation" id="{Ev6=boS]pkCMNh2Eo*r" inline="false">
                      <field name="OP">AND</field>
                      <value name="A">
                        <block type="logic_compare" id="-:71$@UQ!R!G$R)7+u4,">
                          <field name="OP">EQ</field>
                          <value name="A">
                            <block type="get_value" id="W}gB;F`sQD|pbZR;=c/g">
                              <field name="ATTR">val</field>
                              <field name="OID">zigbee2mqtt.0.0x00158d0008f11336.occupancy</field>
                            </block>
                          </value>
                          <value name="B">
                            <block type="logic_boolean" id="RR-tvQ|18yCnOa6px]n{">
                              <field name="BOOL">FALSE</field>
                            </block>
                          </value>
                        </block>
                      </value>
                      <value name="B">
                        <block type="logic_operation" id="gI6(6CqwKBw46y7f9:M(" inline="false">
                          <field name="OP">AND</field>
                          <value name="A">
                            <block type="logic_compare" id="!%QFhWOT0,ezYAlm?W5Y">
                              <field name="OP">EQ</field>
                              <value name="A">
                                <block type="get_value" id="v8UPSTq2iX1m7lJuVq=4">
                                  <field name="ATTR">val</field>
                                  <field name="OID">zigbee2mqtt.0.0x00158d0008d9195e.occupancy</field>
                                </block>
                              </value>
                              <value name="B">
                                <block type="logic_boolean" id="?baQ6C2+i`gG:L}}p{px">
                                  <field name="BOOL">FALSE</field>
                                </block>
                              </value>
                            </block>
                          </value>
                          <value name="B">
                            <block type="logic_compare" id="VoT)O#[2|8E6B;ivqW:D">
                              <field name="OP">EQ</field>
                              <value name="A">
                                <block type="get_value" id="3}_#K*vf:oM@+16_L@Yh">
                                  <field name="ATTR">val</field>
                                  <field name="OID">zigbee2mqtt.0.0xa4c1382e5d2ff601.occupancy</field>
                                </block>
                              </value>
                              <value name="B">
                                <block type="logic_boolean" id="+C{#hnP3T/B}6`;Pkiu(">
                                  <field name="BOOL">FALSE</field>
                                </block>
                              </value>
                            </block>
                          </value>
                        </block>
                      </value>
                    </block>
                  </value>
                  <statement name="DO1">
                    <block type="timeouts_cleartimeout" id="z0j0JlAZ`MO*8H;qm8CL">
                      <field name="NAME">timeout2</field>
                      <next>
                        <block type="timeouts_cleartimeout" id="|eqm6V;gq0/h7-M^=q/v">
                          <field name="NAME">timeout3</field>
                          <next>
                            <block type="comment" id="dB)lP2oEri|Qrf/O4jiG">
                              <field name="COMMENT">Nach 20 Sekunden 50% Brightness</field>
                              <next>
                                <block type="timeouts_settimeout" id="^rA;}G.RQGj$wah~6t$F">
                                  <field name="NAME">timeout2</field>
                                  <field name="DELAY">20</field>
                                  <field name="UNIT">sec</field>
                                  <statement name="STATEMENT">
                                    <block type="control" id="YE1m(S6HS%tUdRp|P3jc">
                                      <mutation xmlns="http://www.w3.org/1999/xhtml" delay_input="false"></mutation>
                                      <field name="OID">zigbee2mqtt.0.group_2.brightness</field>
                                      <field name="WITH_DELAY">FALSE</field>
                                      <value name="VALUE">
                                        <block type="math_number" id="NLaBY|LX*s{_]X2*)F1W">
                                          <field name="NUM">25</field>
                                        </block>
                                      </value>
                                      <next>
                                        <block type="comment" id="TyGElbkcOe?92|/!gkDA">
                                          <field name="COMMENT">Nach 50 Sekunden 0% Brightness sprich Licht aus</field>
                                          <next>
                                            <block type="timeouts_settimeout" id="0}(3}t4y=BB1U,Em;Bh)">
                                              <field name="NAME">timeout3</field>
                                              <field name="DELAY">20</field>
                                              <field name="UNIT">sec</field>
                                              <statement name="STATEMENT">
                                                <block type="control" id="{3/Nni!,/xR.L6_??ig[">
                                                  <mutation xmlns="http://www.w3.org/1999/xhtml" delay_input="false"></mutation>
                                                  <field name="OID">zigbee2mqtt.0.group_2.brightness</field>
                                                  <field name="WITH_DELAY">FALSE</field>
                                                  <value name="VALUE">
                                                    <block type="math_number" id="so:A@$lw2FwU}b)B!/#]">
                                                      <field name="NUM">0</field>
                                                    </block>
                                                  </value>
                                                </block>
                                              </statement>
                                            </block>
                                          </next>
                                        </block>
                                      </next>
                                    </block>
                                  </statement>
                                </block>
                              </next>
                            </block>
                          </next>
                        </block>
                      </next>
                    </block>
                  </statement>
                </block>
              </statement>
            </block>
          </next>
        </block>
      </xml>
      
      DJMarc75D Offline
      DJMarc75D Offline
      DJMarc75
      schrieb am zuletzt editiert von
      #2

      @mrfloppy bitte einen Screenshot vom Blockly zusätzlich zeigen

      Lehrling seit 1975 !!!
      Beitrag geholfen ? dann gerne ein upvote rechts unten im Beitrag klicken ;)
      https://forum.iobroker.net/topic/51555/hinweise-f%C3%BCr-gute-forenbeitr%C3%A4ge

      1 Antwort Letzte Antwort
      0
      • M mrfloppy

        In meinem Blockly steuere ich mit 3 BWM mein Kellerlicht.
        Das Blockly funktioniert soweit , nur wird bei jedem mal wahr
        der Block "steuere Brightness mit 100" immer wieder ausgeführt obwohl eh schon auf 100.
        Wie kann man das schön lösen und Steuer Befehle einsparen?

        Danke LG Thomas
        blokly.png

        <xml xmlns="https://developers.google.com/blockly/xml">
          <variables>
            <variable type="timeout" id="timeout2">timeout2</variable>
            <variable type="timeout" id="timeout3">timeout3</variable>
          </variables>
          <block type="comment" id="a;4E{*dk:]raf}1GK:oC" x="38" y="-562">
            <field name="COMMENT">BWM 1 und 2 und 3 am Kellerabgang schaltet Gruppe in Zigbee2mqtttt</field>
            <next>
              <block type="on_ext" id="6NTf}*4Hs@H?k/54~dHi">
                <mutation xmlns="http://www.w3.org/1999/xhtml" items="3"></mutation>
                <field name="CONDITION">ne</field>
                <field name="ACK_CONDITION"></field>
                <value name="OID0">
                  <shadow type="field_oid" id="eIwD5nRX(N$RuC,J1uKe">
                    <field name="oid">zigbee2mqtt.0.0x00158d0008f11336.occupancy</field>
                  </shadow>
                </value>
                <value name="OID1">
                  <shadow type="field_oid" id=".,b50y=^Z^X,#iPP9XI1">
                    <field name="oid">zigbee2mqtt.0.0x00158d0008d9195e.occupancy</field>
                  </shadow>
                </value>
                <value name="OID2">
                  <shadow type="field_oid" id="RvLxvwPtZFz~hQ[$wUgM">
                    <field name="oid">zigbee2mqtt.0.0xa4c1382e5d2ff601.occupancy</field>
                  </shadow>
                </value>
                <statement name="STATEMENT">
                  <block type="controls_if" id="i6lv|%TLZaltMR@P/Q!Z">
                    <mutation elseif="1"></mutation>
                    <value name="IF0">
                      <block type="logic_operation" id="M:xQdbhe*,yzGM,Gm,z." inline="false">
                        <field name="OP">OR</field>
                        <value name="A">
                          <block type="logic_compare" id="U[*%P+/)BvVg.{-cRyGH">
                            <field name="OP">EQ</field>
                            <value name="A">
                              <block type="get_value" id="BJ(j7?;/kA~6rEy=|dkJ">
                                <field name="ATTR">val</field>
                                <field name="OID">zigbee2mqtt.0.0x00158d0008f11336.occupancy</field>
                              </block>
                            </value>
                            <value name="B">
                              <block type="logic_boolean" id="9%geI{n+~Xd7T6%HAW[L">
                                <field name="BOOL">TRUE</field>
                              </block>
                            </value>
                          </block>
                        </value>
                        <value name="B">
                          <block type="logic_operation" id="UAhbdHGUCbKKn?G=I0ab" inline="false">
                            <field name="OP">OR</field>
                            <value name="A">
                              <block type="logic_compare" id="}mo^tTy+|@Tl%T5-1;d5">
                                <field name="OP">EQ</field>
                                <value name="A">
                                  <block type="get_value" id="=o[6`YJt2VX``#mw(~VB">
                                    <field name="ATTR">val</field>
                                    <field name="OID">zigbee2mqtt.0.0x00158d0008d9195e.occupancy</field>
                                  </block>
                                </value>
                                <value name="B">
                                  <block type="logic_boolean" id="mDe~ellX*:$%Q^NBF)bN">
                                    <field name="BOOL">TRUE</field>
                                  </block>
                                </value>
                              </block>
                            </value>
                            <value name="B">
                              <block type="logic_compare" id="~h$}jSLIP6}.NFPm_d`,">
                                <field name="OP">EQ</field>
                                <value name="A">
                                  <block type="get_value" id="_Y%Q0o*SCHOr4Z9__a_R">
                                    <field name="ATTR">val</field>
                                    <field name="OID">zigbee2mqtt.0.0xa4c1382e5d2ff601.occupancy</field>
                                  </block>
                                </value>
                                <value name="B">
                                  <block type="logic_boolean" id="sSym*aP338bTY/#@[jyn">
                                    <field name="BOOL">TRUE</field>
                                  </block>
                                </value>
                              </block>
                            </value>
                          </block>
                        </value>
                      </block>
                    </value>
                    <statement name="DO0">
                      <block type="timeouts_cleartimeout" id="4rKh8(mY;Q_88{m_F(qP">
                        <field name="NAME">timeout2</field>
                        <next>
                          <block type="timeouts_cleartimeout" id="2^|Pgwbdl1)GVYu%TGDX">
                            <field name="NAME">timeout3</field>
                            <next>
                              <block type="control" id="v%$[jBEi/`P(;I~rsc^)">
                                <mutation xmlns="http://www.w3.org/1999/xhtml" delay_input="false"></mutation>
                                <field name="OID">zigbee2mqtt.0.group_2.brightness</field>
                                <field name="WITH_DELAY">FALSE</field>
                                <value name="VALUE">
                                  <block type="math_number" id="V|E,e~rCGj2E0)f8UZM1">
                                    <field name="NUM">100</field>
                                  </block>
                                </value>
                              </block>
                            </next>
                          </block>
                        </next>
                      </block>
                    </statement>
                    <value name="IF1">
                      <block type="logic_operation" id="{Ev6=boS]pkCMNh2Eo*r" inline="false">
                        <field name="OP">AND</field>
                        <value name="A">
                          <block type="logic_compare" id="-:71$@UQ!R!G$R)7+u4,">
                            <field name="OP">EQ</field>
                            <value name="A">
                              <block type="get_value" id="W}gB;F`sQD|pbZR;=c/g">
                                <field name="ATTR">val</field>
                                <field name="OID">zigbee2mqtt.0.0x00158d0008f11336.occupancy</field>
                              </block>
                            </value>
                            <value name="B">
                              <block type="logic_boolean" id="RR-tvQ|18yCnOa6px]n{">
                                <field name="BOOL">FALSE</field>
                              </block>
                            </value>
                          </block>
                        </value>
                        <value name="B">
                          <block type="logic_operation" id="gI6(6CqwKBw46y7f9:M(" inline="false">
                            <field name="OP">AND</field>
                            <value name="A">
                              <block type="logic_compare" id="!%QFhWOT0,ezYAlm?W5Y">
                                <field name="OP">EQ</field>
                                <value name="A">
                                  <block type="get_value" id="v8UPSTq2iX1m7lJuVq=4">
                                    <field name="ATTR">val</field>
                                    <field name="OID">zigbee2mqtt.0.0x00158d0008d9195e.occupancy</field>
                                  </block>
                                </value>
                                <value name="B">
                                  <block type="logic_boolean" id="?baQ6C2+i`gG:L}}p{px">
                                    <field name="BOOL">FALSE</field>
                                  </block>
                                </value>
                              </block>
                            </value>
                            <value name="B">
                              <block type="logic_compare" id="VoT)O#[2|8E6B;ivqW:D">
                                <field name="OP">EQ</field>
                                <value name="A">
                                  <block type="get_value" id="3}_#K*vf:oM@+16_L@Yh">
                                    <field name="ATTR">val</field>
                                    <field name="OID">zigbee2mqtt.0.0xa4c1382e5d2ff601.occupancy</field>
                                  </block>
                                </value>
                                <value name="B">
                                  <block type="logic_boolean" id="+C{#hnP3T/B}6`;Pkiu(">
                                    <field name="BOOL">FALSE</field>
                                  </block>
                                </value>
                              </block>
                            </value>
                          </block>
                        </value>
                      </block>
                    </value>
                    <statement name="DO1">
                      <block type="timeouts_cleartimeout" id="z0j0JlAZ`MO*8H;qm8CL">
                        <field name="NAME">timeout2</field>
                        <next>
                          <block type="timeouts_cleartimeout" id="|eqm6V;gq0/h7-M^=q/v">
                            <field name="NAME">timeout3</field>
                            <next>
                              <block type="comment" id="dB)lP2oEri|Qrf/O4jiG">
                                <field name="COMMENT">Nach 20 Sekunden 50% Brightness</field>
                                <next>
                                  <block type="timeouts_settimeout" id="^rA;}G.RQGj$wah~6t$F">
                                    <field name="NAME">timeout2</field>
                                    <field name="DELAY">20</field>
                                    <field name="UNIT">sec</field>
                                    <statement name="STATEMENT">
                                      <block type="control" id="YE1m(S6HS%tUdRp|P3jc">
                                        <mutation xmlns="http://www.w3.org/1999/xhtml" delay_input="false"></mutation>
                                        <field name="OID">zigbee2mqtt.0.group_2.brightness</field>
                                        <field name="WITH_DELAY">FALSE</field>
                                        <value name="VALUE">
                                          <block type="math_number" id="NLaBY|LX*s{_]X2*)F1W">
                                            <field name="NUM">25</field>
                                          </block>
                                        </value>
                                        <next>
                                          <block type="comment" id="TyGElbkcOe?92|/!gkDA">
                                            <field name="COMMENT">Nach 50 Sekunden 0% Brightness sprich Licht aus</field>
                                            <next>
                                              <block type="timeouts_settimeout" id="0}(3}t4y=BB1U,Em;Bh)">
                                                <field name="NAME">timeout3</field>
                                                <field name="DELAY">20</field>
                                                <field name="UNIT">sec</field>
                                                <statement name="STATEMENT">
                                                  <block type="control" id="{3/Nni!,/xR.L6_??ig[">
                                                    <mutation xmlns="http://www.w3.org/1999/xhtml" delay_input="false"></mutation>
                                                    <field name="OID">zigbee2mqtt.0.group_2.brightness</field>
                                                    <field name="WITH_DELAY">FALSE</field>
                                                    <value name="VALUE">
                                                      <block type="math_number" id="so:A@$lw2FwU}b)B!/#]">
                                                        <field name="NUM">0</field>
                                                      </block>
                                                    </value>
                                                  </block>
                                                </statement>
                                              </block>
                                            </next>
                                          </block>
                                        </next>
                                      </block>
                                    </statement>
                                  </block>
                                </next>
                              </block>
                            </next>
                          </block>
                        </next>
                      </block>
                    </statement>
                  </block>
                </statement>
              </block>
            </next>
          </block>
        </xml>
        
        paul53P Offline
        paul53P Offline
        paul53
        schrieb am zuletzt editiert von
        #3

        @mrfloppy sagte: "steuere Brightness mit 100" immer wieder ausgeführt obwohl eh schon auf 100.

        Blockly_temp.JPG

        Bitte verzichtet auf Chat-Nachrichten, denn die Handhabung ist grauenhaft !
        Produktiv: RPi 2 mit S.USV, HM-MOD-RPI und SLC-USB-Stick mit root fs

        Dr. BakteriusD 1 Antwort Letzte Antwort
        0
        • M mrfloppy

          In meinem Blockly steuere ich mit 3 BWM mein Kellerlicht.
          Das Blockly funktioniert soweit , nur wird bei jedem mal wahr
          der Block "steuere Brightness mit 100" immer wieder ausgeführt obwohl eh schon auf 100.
          Wie kann man das schön lösen und Steuer Befehle einsparen?

          Danke LG Thomas
          blokly.png

          <xml xmlns="https://developers.google.com/blockly/xml">
            <variables>
              <variable type="timeout" id="timeout2">timeout2</variable>
              <variable type="timeout" id="timeout3">timeout3</variable>
            </variables>
            <block type="comment" id="a;4E{*dk:]raf}1GK:oC" x="38" y="-562">
              <field name="COMMENT">BWM 1 und 2 und 3 am Kellerabgang schaltet Gruppe in Zigbee2mqtttt</field>
              <next>
                <block type="on_ext" id="6NTf}*4Hs@H?k/54~dHi">
                  <mutation xmlns="http://www.w3.org/1999/xhtml" items="3"></mutation>
                  <field name="CONDITION">ne</field>
                  <field name="ACK_CONDITION"></field>
                  <value name="OID0">
                    <shadow type="field_oid" id="eIwD5nRX(N$RuC,J1uKe">
                      <field name="oid">zigbee2mqtt.0.0x00158d0008f11336.occupancy</field>
                    </shadow>
                  </value>
                  <value name="OID1">
                    <shadow type="field_oid" id=".,b50y=^Z^X,#iPP9XI1">
                      <field name="oid">zigbee2mqtt.0.0x00158d0008d9195e.occupancy</field>
                    </shadow>
                  </value>
                  <value name="OID2">
                    <shadow type="field_oid" id="RvLxvwPtZFz~hQ[$wUgM">
                      <field name="oid">zigbee2mqtt.0.0xa4c1382e5d2ff601.occupancy</field>
                    </shadow>
                  </value>
                  <statement name="STATEMENT">
                    <block type="controls_if" id="i6lv|%TLZaltMR@P/Q!Z">
                      <mutation elseif="1"></mutation>
                      <value name="IF0">
                        <block type="logic_operation" id="M:xQdbhe*,yzGM,Gm,z." inline="false">
                          <field name="OP">OR</field>
                          <value name="A">
                            <block type="logic_compare" id="U[*%P+/)BvVg.{-cRyGH">
                              <field name="OP">EQ</field>
                              <value name="A">
                                <block type="get_value" id="BJ(j7?;/kA~6rEy=|dkJ">
                                  <field name="ATTR">val</field>
                                  <field name="OID">zigbee2mqtt.0.0x00158d0008f11336.occupancy</field>
                                </block>
                              </value>
                              <value name="B">
                                <block type="logic_boolean" id="9%geI{n+~Xd7T6%HAW[L">
                                  <field name="BOOL">TRUE</field>
                                </block>
                              </value>
                            </block>
                          </value>
                          <value name="B">
                            <block type="logic_operation" id="UAhbdHGUCbKKn?G=I0ab" inline="false">
                              <field name="OP">OR</field>
                              <value name="A">
                                <block type="logic_compare" id="}mo^tTy+|@Tl%T5-1;d5">
                                  <field name="OP">EQ</field>
                                  <value name="A">
                                    <block type="get_value" id="=o[6`YJt2VX``#mw(~VB">
                                      <field name="ATTR">val</field>
                                      <field name="OID">zigbee2mqtt.0.0x00158d0008d9195e.occupancy</field>
                                    </block>
                                  </value>
                                  <value name="B">
                                    <block type="logic_boolean" id="mDe~ellX*:$%Q^NBF)bN">
                                      <field name="BOOL">TRUE</field>
                                    </block>
                                  </value>
                                </block>
                              </value>
                              <value name="B">
                                <block type="logic_compare" id="~h$}jSLIP6}.NFPm_d`,">
                                  <field name="OP">EQ</field>
                                  <value name="A">
                                    <block type="get_value" id="_Y%Q0o*SCHOr4Z9__a_R">
                                      <field name="ATTR">val</field>
                                      <field name="OID">zigbee2mqtt.0.0xa4c1382e5d2ff601.occupancy</field>
                                    </block>
                                  </value>
                                  <value name="B">
                                    <block type="logic_boolean" id="sSym*aP338bTY/#@[jyn">
                                      <field name="BOOL">TRUE</field>
                                    </block>
                                  </value>
                                </block>
                              </value>
                            </block>
                          </value>
                        </block>
                      </value>
                      <statement name="DO0">
                        <block type="timeouts_cleartimeout" id="4rKh8(mY;Q_88{m_F(qP">
                          <field name="NAME">timeout2</field>
                          <next>
                            <block type="timeouts_cleartimeout" id="2^|Pgwbdl1)GVYu%TGDX">
                              <field name="NAME">timeout3</field>
                              <next>
                                <block type="control" id="v%$[jBEi/`P(;I~rsc^)">
                                  <mutation xmlns="http://www.w3.org/1999/xhtml" delay_input="false"></mutation>
                                  <field name="OID">zigbee2mqtt.0.group_2.brightness</field>
                                  <field name="WITH_DELAY">FALSE</field>
                                  <value name="VALUE">
                                    <block type="math_number" id="V|E,e~rCGj2E0)f8UZM1">
                                      <field name="NUM">100</field>
                                    </block>
                                  </value>
                                </block>
                              </next>
                            </block>
                          </next>
                        </block>
                      </statement>
                      <value name="IF1">
                        <block type="logic_operation" id="{Ev6=boS]pkCMNh2Eo*r" inline="false">
                          <field name="OP">AND</field>
                          <value name="A">
                            <block type="logic_compare" id="-:71$@UQ!R!G$R)7+u4,">
                              <field name="OP">EQ</field>
                              <value name="A">
                                <block type="get_value" id="W}gB;F`sQD|pbZR;=c/g">
                                  <field name="ATTR">val</field>
                                  <field name="OID">zigbee2mqtt.0.0x00158d0008f11336.occupancy</field>
                                </block>
                              </value>
                              <value name="B">
                                <block type="logic_boolean" id="RR-tvQ|18yCnOa6px]n{">
                                  <field name="BOOL">FALSE</field>
                                </block>
                              </value>
                            </block>
                          </value>
                          <value name="B">
                            <block type="logic_operation" id="gI6(6CqwKBw46y7f9:M(" inline="false">
                              <field name="OP">AND</field>
                              <value name="A">
                                <block type="logic_compare" id="!%QFhWOT0,ezYAlm?W5Y">
                                  <field name="OP">EQ</field>
                                  <value name="A">
                                    <block type="get_value" id="v8UPSTq2iX1m7lJuVq=4">
                                      <field name="ATTR">val</field>
                                      <field name="OID">zigbee2mqtt.0.0x00158d0008d9195e.occupancy</field>
                                    </block>
                                  </value>
                                  <value name="B">
                                    <block type="logic_boolean" id="?baQ6C2+i`gG:L}}p{px">
                                      <field name="BOOL">FALSE</field>
                                    </block>
                                  </value>
                                </block>
                              </value>
                              <value name="B">
                                <block type="logic_compare" id="VoT)O#[2|8E6B;ivqW:D">
                                  <field name="OP">EQ</field>
                                  <value name="A">
                                    <block type="get_value" id="3}_#K*vf:oM@+16_L@Yh">
                                      <field name="ATTR">val</field>
                                      <field name="OID">zigbee2mqtt.0.0xa4c1382e5d2ff601.occupancy</field>
                                    </block>
                                  </value>
                                  <value name="B">
                                    <block type="logic_boolean" id="+C{#hnP3T/B}6`;Pkiu(">
                                      <field name="BOOL">FALSE</field>
                                    </block>
                                  </value>
                                </block>
                              </value>
                            </block>
                          </value>
                        </block>
                      </value>
                      <statement name="DO1">
                        <block type="timeouts_cleartimeout" id="z0j0JlAZ`MO*8H;qm8CL">
                          <field name="NAME">timeout2</field>
                          <next>
                            <block type="timeouts_cleartimeout" id="|eqm6V;gq0/h7-M^=q/v">
                              <field name="NAME">timeout3</field>
                              <next>
                                <block type="comment" id="dB)lP2oEri|Qrf/O4jiG">
                                  <field name="COMMENT">Nach 20 Sekunden 50% Brightness</field>
                                  <next>
                                    <block type="timeouts_settimeout" id="^rA;}G.RQGj$wah~6t$F">
                                      <field name="NAME">timeout2</field>
                                      <field name="DELAY">20</field>
                                      <field name="UNIT">sec</field>
                                      <statement name="STATEMENT">
                                        <block type="control" id="YE1m(S6HS%tUdRp|P3jc">
                                          <mutation xmlns="http://www.w3.org/1999/xhtml" delay_input="false"></mutation>
                                          <field name="OID">zigbee2mqtt.0.group_2.brightness</field>
                                          <field name="WITH_DELAY">FALSE</field>
                                          <value name="VALUE">
                                            <block type="math_number" id="NLaBY|LX*s{_]X2*)F1W">
                                              <field name="NUM">25</field>
                                            </block>
                                          </value>
                                          <next>
                                            <block type="comment" id="TyGElbkcOe?92|/!gkDA">
                                              <field name="COMMENT">Nach 50 Sekunden 0% Brightness sprich Licht aus</field>
                                              <next>
                                                <block type="timeouts_settimeout" id="0}(3}t4y=BB1U,Em;Bh)">
                                                  <field name="NAME">timeout3</field>
                                                  <field name="DELAY">20</field>
                                                  <field name="UNIT">sec</field>
                                                  <statement name="STATEMENT">
                                                    <block type="control" id="{3/Nni!,/xR.L6_??ig[">
                                                      <mutation xmlns="http://www.w3.org/1999/xhtml" delay_input="false"></mutation>
                                                      <field name="OID">zigbee2mqtt.0.group_2.brightness</field>
                                                      <field name="WITH_DELAY">FALSE</field>
                                                      <value name="VALUE">
                                                        <block type="math_number" id="so:A@$lw2FwU}b)B!/#]">
                                                          <field name="NUM">0</field>
                                                        </block>
                                                      </value>
                                                    </block>
                                                  </statement>
                                                </block>
                                              </next>
                                            </block>
                                          </next>
                                        </block>
                                      </statement>
                                    </block>
                                  </next>
                                </block>
                              </next>
                            </block>
                          </next>
                        </block>
                      </statement>
                    </block>
                  </statement>
                </block>
              </next>
            </block>
          </xml>
          
          Zamecnik JindrichZ Offline
          Zamecnik JindrichZ Offline
          Zamecnik Jindrich
          schrieb am zuletzt editiert von
          #4

          @mrfloppy Here are some ways to avoid unnecessary repeated brightness controls in Blockly when controlling a light:

          1. Use a variable to store the current brightness value. Check if the requested value differs from the variable before setting brightness. For example:
          if (brightness != requestedValue) {
            set brightness to requestedValue
            set brightnessVariable to requestedValue
          }
          
          1. Use events/callbacks so brightness is only set when an explicit change is made rather than constantly checking. For example, have a "when brightness clicked" event trigger the set brightness block.

          2. Use a timer to limit how often the brightness check runs to avoid spamming updates.

          3. Only update brightness when other state changes occur - for example when a light is turned on/off, reset the brightness afterwards.

          4. Create a brightnessChange() custom function that gets called instead of directly setting brightness. Have this function implement the checking logic to prevent unnecessary duplicates.

          The key ideas are using variables, events, or cooldowns to determine if brightness needs changing rather than directly setting it continuously. This will help optimize unnecessary commands.

          https://geometrydash-free.com

          1 Antwort Letzte Antwort
          0
          • paul53P paul53

            @mrfloppy sagte: "steuere Brightness mit 100" immer wieder ausgeführt obwohl eh schon auf 100.

            Blockly_temp.JPG

            Dr. BakteriusD Online
            Dr. BakteriusD Online
            Dr. Bakterius
            Most Active
            schrieb am zuletzt editiert von
            #5

            @paul53 Da reicht doch auch einmal auf Wert prüfen. Der wird immer wahr egal welcher Trigger ausgelöst hat. Oder übersehe ich da etwas?

            paul53P 1 Antwort Letzte Antwort
            0
            • Dr. BakteriusD Dr. Bakterius

              @paul53 Da reicht doch auch einmal auf Wert prüfen. Der wird immer wahr egal welcher Trigger ausgelöst hat. Oder übersehe ich da etwas?

              paul53P Offline
              paul53P Offline
              paul53
              schrieb am zuletzt editiert von paul53
              #6

              @dr-bakterius sagte: Da reicht doch auch einmal auf Wert prüfen.

              Nein, man benötigt eine Oder-Verknüpfung der Werte. Sonst kann es passieren, dass zwei BWM auf false gehen und dadurch mehrere Timer laufen, die sich nicht mehr stoppen lassen.
              Außerdem ist immer noch Bewegung, wenn erst zwei BWM Bewegung melden und dann nur noch ein BWM.

              Bitte verzichtet auf Chat-Nachrichten, denn die Handhabung ist grauenhaft !
              Produktiv: RPi 2 mit S.USV, HM-MOD-RPI und SLC-USB-Stick mit root fs

              1 Antwort Letzte Antwort
              1
              Antworten
              • In einem neuen Thema antworten
              Anmelden zum Antworten
              • Älteste zuerst
              • Neuste zuerst
              • Meiste Stimmen


              Support us

              ioBroker
              Community Adapters
              Donate

              843

              Online

              32.5k

              Benutzer

              81.7k

              Themen

              1.3m

              Beiträge
              Community
              Impressum | Datenschutz-Bestimmungen | Nutzungsbedingungen | Einwilligungseinstellungen
              ioBroker Community 2014-2025
              logo
              • Anmelden

              • Du hast noch kein Konto? Registrieren

              • Anmelden oder registrieren, um zu suchen
              • Erster Beitrag
                Letzter Beitrag
              0
              • Home
              • Aktuell
              • Tags
              • Ungelesen 0
              • Kategorien
              • Unreplied
              • Beliebt
              • GitHub
              • Docu
              • Hilfe