Navigation

    Logo
    • Register
    • Login
    • Search
    • Recent
    • Tags
    • Unread
    • Categories
    • Unreplied
    • Popular
    • GitHub
    • Docu
    • Hilfe
    1. Home
    2. Deutsch
    3. Skripten / Logik
    4. Blockly
    5. [solved] Skriptprobleme

    NEWS

    • Wir empfehlen: Node.js 22.x

    • Neuer Blog: Fotos und Eindrücke aus Solingen

    • ioBroker goes Matter ... Matter Adapter in Stable

    [solved] Skriptprobleme

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

      Ich habe folgendes Skript bei mir laufen.

      <block xmlns="https://developers.google.com/blockly/xml" type="on" id="WDi:](4ssESe^3dhZ!v+" x="-362" y="-1093">
        <field name="OID">ecovacs-deebot.0.status.device</field>
        <field name="CONDITION">any</field>
        <field name="ACK_CONDITION"></field>
        <statement name="STATEMENT">
          <block type="controls_if" id="b8cu1SYU=7P59x=1X3wr">
            <mutation else="1"></mutation>
            <value name="IF0">
              <block type="logic_operation" id="diTiOl0L,0mYVTYX`tYs" inline="false">
                <field name="OP">OR</field>
                <value name="A">
                  <block type="logic_compare" id="t3dvYjb$qy{/[#{`^Yt]">
                    <field name="OP">EQ</field>
                    <value name="A">
                      <block type="on_source" id="K5{Bw|+~JI@dZVshKcJM">
                        <field name="ATTR">state.val</field>
                      </block>
                    </value>
                    <value name="B">
                      <block type="text" id=":Fhy{kn*Tb5A%jxa{?RP">
                        <field name="TEXT">charging</field>
                      </block>
                    </value>
                  </block>
                </value>
                <value name="B">
                  <block type="logic_operation" id="+Kp@CxZ?v,-@*;%]2gAn" inline="false">
                    <field name="OP">OR</field>
                    <value name="A">
                      <block type="logic_compare" id="-3?vUug`x)uL51pY;N)d">
                        <field name="OP">EQ</field>
                        <value name="A">
                          <block type="on_source" id="#;AY`6%ymMRV10RmP8/e">
                            <field name="ATTR">state.val</field>
                          </block>
                        </value>
                        <value name="B">
                          <block type="text" id="|452hZs/obp6T,RT)}5G">
                            <field name="TEXT">paused</field>
                          </block>
                        </value>
                      </block>
                    </value>
                    <value name="B">
                      <block type="logic_compare" id="CUwEh~AF;a*bCJCKqj^8">
                        <field name="OP">EQ</field>
                        <value name="A">
                          <block type="on_source" id="qo[Ir%qHojI4~Ebc/$v@">
                            <field name="ATTR">state.val</field>
                          </block>
                        </value>
                        <value name="B">
                          <block type="text" id=".6PxdSYl3[_kM(+.sUN,">
                            <field name="TEXT">stopped</field>
                          </block>
                        </value>
                      </block>
                    </value>
                  </block>
                </value>
              </block>
            </value>
            <statement name="DO0">
              <block type="control" id="#sT[H;rx5RLs!#6GYZT6">
                <mutation xmlns="http://www.w3.org/1999/xhtml" delay_input="false"></mutation>
                <field name="OID">javascript.0.EigeneDatenpunkte.ohne_Kamera</field>
                <field name="WITH_DELAY">FALSE</field>
                <value name="VALUE">
                  <block type="logic_boolean" id="Zbdw-]:5fA]tBi]9St|(">
                    <field name="BOOL">FALSE</field>
                  </block>
                </value>
              </block>
            </statement>
            <statement name="ELSE">
              <block type="control" id="wsaM2?W`N.~[L#1Du(%(">
                <mutation xmlns="http://www.w3.org/1999/xhtml" delay_input="false"></mutation>
                <field name="OID">javascript.0.EigeneDatenpunkte.ohne_Kamera</field>
                <field name="WITH_DELAY">FALSE</field>
                <value name="VALUE">
                  <block type="logic_boolean" id="0S8OUWW%jX9w]}aq|Ps9">
                    <field name="BOOL">TRUE</field>
                  </block>
                </value>
              </block>
            </statement>
          </block>
        </statement>
      </block>
      

      Als Trigger verwendet er den Device Status des Ecovacs Adapters. Was ich nicht verstehe ist: Er erkennt wenn sich der Datenpunkt ändert, er erkennt wenn es keiner der drei vorgegbenen Werte ist und setzt den Datenpunkt auf true. False soll er setzen wenn der device status entweder charging, stopped oder paused ist. Dieses tut er aber nicht. Ich bin wirklich verzweifelt weil ich nicht weiß warum...

      D 1 Reply Last reply Reply Quote 0
      • D
        Dragon @Dragon last edited by

        Wie es immer so ist.... Ich habe jetzt drei Tage lang verzweifelt das Problem gesucht. Habe jetzt den anderen Trigger Baustein genommen und es funktioniert... Verrückt, aber hauptsache es läuft jetzt....

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

        Support us

        ioBroker
        Community Adapters
        Donate

        668
        Online

        32.0k
        Users

        80.5k
        Topics

        1.3m
        Posts

        1
        2
        56
        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