Navigation

    Logo
    • Register
    • Login
    • Search
    • Recent
    • Tags
    • Unread
    • Categories
    • Unreplied
    • Popular
    • GitHub
    • Docu
    • Hilfe
    1. Home
    2. Deutsch
    3. Skripten / Logik
    4. Blockly
    5. (erl.)(Torantrieb) Blockly soll den Status abbilden

    NEWS

    • Wir empfehlen: Node.js 22.x

    • Neuer Blog: Fotos und Eindrücke aus Solingen

    • ioBroker goes Matter ... Matter Adapter in Stable

    (erl.)(Torantrieb) Blockly soll den Status abbilden

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

      Hallo 👍

      ich möchte euch bitten mein Blockly zu kontrollieren.
      Klassiker - Garagenantrieb.
      Shelly 25 steuert den Antrieb (1s, selbstabfallend), Eingang ist ein mechanischer Schalter für geschlossen. Bewegungszeit ist größer 15s. Dh. die Bewegung soll zeitgesteuert kontrolliert werden zum öffnen, wenn der Vorgang abgebrochen wird, wird erst durch geschlossen wieder kalibriert.

      Danke!

      • habe es gerade getestet, das Objekt braucht max. 4, sonst hat es geklappt.
        noch Verbesserungsergänzungen ?


      <xml xmlns="https://developers.google.com/blockly/xml">
      <variables>
      <variable type="timeout" id="timeout">timeout</variable>
      </variables>
      <block type="comment" id="=x83F$~_HVya0,h19VT" x="-913" y="-613"> <field name="COMMENT">-----------Objekte-----------</field> <next> <block type="comment" id="5nmPfqGoHbAL9,AKL.9y"> <field name="COMMENT">State = 0 = geschlossen</field> <next> <block type="comment" id="}VtqU1#p^80a^z6OD7:H"> <field name="COMMENT">State = 1 = öffnet</field> <next> <block type="comment" id="S^b+qQIvS~]t10?]uY5">
      <field name="COMMENT">State = 2 = offen</field>
      <next>
      <block type="comment" id="rhu4~~r.;PXYY9aj;r%"> <field name="COMMENT">State = 3 = schließt</field> <next> <block type="comment" id="=%#|K0qU:LpE.qkCGat">
      <field name="COMMENT">State = 4 = undefiniert</field>
      <next>
      <block type="create" id="J;IaDKF*{j]J,vTY}(o"> <field name="NAME">javascript.0.Garage.Garage_Zoe_Status</field> <value name="VALUE"> <block type="text" id="KHaoj{M$^{I+:GA8TR">
      <field name="TEXT">0</field>
      </block>
      </value>
      <value name="COMMON">
      <block type="text" id="w}X}bl$nftPtXr7_O/w1">
      <field name="TEXT">{"name": "Garage_Zoe_State","role": "","type": "number","desc": "Blockly erzeugt","unit": "","min": 0,"max": 3,"def": 3,"read": true,"write": true}</field>
      </block>
      </value>
      <next>
      <block type="comment" id="+Z-^bY)!C8zt~y}4NVn%">
      <field name="COMMENT">---------Torantrieb------------</field>
      <next>
      <block type="comment" id="bQ;WcQ]5|1_HOX:GyY9I">
      <field name="COMMENT">Input = Shelly 25 Eingang (mech. Schalter zu)</field>
      <next>
      <block type="comment" id="!V{^[xy2LYo+9z]Y9UUp">
      <field name="COMMENT">es gibt nur 1 Schalter = geschlossen</field>
      <next>
      <block type="comment" id="_d:D}pB:XHfix6sssH,%">
      <field name="COMMENT">Switch = Shelly 25 Kontakt (1s)</field>
      <next>
      <block type="comment" id="/6P(=o=IrqKk{~5bF["> <field name="COMMENT">1) Torantriebe - geschlossen</field> <next> <block type="on" id="Ep_=Rd)S5hAyFR[lyt#8"> <field name="OID">shelly.0.SHSW-25#483FDA8241A8#1.Relay0.Input</field> <field name="CONDITION">true</field> <field name="ACK_CONDITION">true</field> <statement name="STATEMENT"> <block type="update" id="Qe|(SYw4P-5!+K5~7?]">
      <mutation xmlns="http://www.w3.org/1999/xhtml" delay_input="false"></mutation>
      <field name="OID">javascript.0.Garage.Garage_Zoe_Status</field>
      <field name="WITH_DELAY">FALSE</field>
      <value name="VALUE">
      <block type="math_number" id="D$/AN_9OsxX%D1W??c">
      <field name="NUM">0</field>
      </block>
      </value>
      </block>
      </statement>
      <next>
      <block type="comment" id="N1-s97~MChU,OTu=bcv%">
      <field name="COMMENT">2) Torantrieb - öffnet/schließt</field>
      <next>
      <block type="on" id="LAtmA=bL|BHqK~MFaB.P">
      <field name="OID">shelly.0.SHSW-25#483FDA8241A8#1.Relay0.Switch</field>
      <field name="CONDITION">true</field>
      <field name="ACK_CONDITION">true</field>
      <statement name="STATEMENT">
      <block type="timeouts_cleartimeout" id="Oq{yUf!.aX?OTJVA5KE5">
      <field name="NAME">timeout</field>
      <next>
      <block type="controls_if" id="!HmjljSpQw)q)j|mOa}r">
      <mutation elseif="1" else="1"></mutation>
      <value name="IF0">
      <block type="logic_compare" id="U}=tYI=jj!D.bI_ST5Kf">
      <field name="OP">EQ</field>
      <value name="A">
      <block type="get_value" id="}6Ds(_iBhtg@{K$xm_gp">
      <field name="ATTR">val</field>
      <field name="OID">javascript.0.Garage.Garage_Zoe_Status</field>
      </block>
      </value>
      <value name="B">
      <block type="math_number" id="rE@M51)d}z2]k}pJQy8?">
      <field name="NUM">0</field>
      </block>
      </value>
      </block>
      </value>
      <statement name="DO0">
      <block type="update" id="P5[L]V1n
      FTV$4m
      ]PCd">
      <mutation xmlns="http://www.w3.org/1999/xhtml" delay_input="false"></mutation>
      <field name="OID">javascript.0.Garage.Garage_Zoe_Status</field>
      <field name="WITH_DELAY">FALSE</field>
      <value name="VALUE">
      <block type="math_number" id="Uj1pmFh{S;0St%mObj,">
      <field name="NUM">1</field>
      </block>
      </value>
      <next>
      <block type="timeouts_settimeout" id="erQ~wdiJLaRqsMlj#3H~">
      <field name="NAME">timeout</field>
      <field name="DELAY">15</field>
      <field name="UNIT">sec</field>
      <statement name="STATEMENT">
      <block type="update" id="Kbs+u[le2ynksp(
      .]:G">
      <mutation xmlns="http://www.w3.org/1999/xhtml" delay_input="false"></mutation>
      <field name="OID">javascript.0.Garage.Garage_Zoe_Status</field>
      <field name="WITH_DELAY">FALSE</field>
      <value name="VALUE">
      <block type="math_number" id="UEw-%1nj1OB!fvdo}30i">
      <field name="NUM">2</field>
      </block>
      </value>
      </block>
      </statement>
      </block>
      </next>
      </block>
      </statement>
      <value name="IF1">
      <block type="logic_compare" id="*vAP[t~Q@b2}d/Sy8XxB">
      <field name="OP">EQ</field>
      <value name="A">
      <block type="get_value" id="|LK1PoFzoQ)@A/:cLv3J">
      <field name="ATTR">val</field>
      <field name="OID">javascript.0.Garage.Garage_Zoe_Status</field>
      </block>
      </value>
      <value name="B">
      <block type="math_number" id="dFQ+8m7-/W!rx|tx!VPa">
      <field name="NUM">2</field>
      </block>
      </value>
      </block>
      </value>
      <statement name="DO1">
      <block type="update" id="]Gofauh8h}k9dfH+SHhb">
      <mutation xmlns="http://www.w3.org/1999/xhtml" delay_input="false"></mutation>
      <field name="OID">javascript.0.Garage.Garage_Zoe_Status</field>
      <field name="WITH_DELAY">FALSE</field>
      <value name="VALUE">
      <block type="math_number" id="6_q9lDzT,@#O%2v9/,{8">
      <field name="NUM">3</field>
      </block>
      </value>
      </block>
      </statement>
      <statement name="ELSE">
      <block type="update" id="ROM7TdJX1a.Yukt})Yt{">
      <mutation xmlns="http://www.w3.org/1999/xhtml" delay_input="false"></mutation>
      <field name="OID">javascript.0.Garage.Garage_Zoe_Status</field>
      <field name="WITH_DELAY">FALSE</field>
      <value name="VALUE">
      <block type="math_number" id="$5i,V_w1aIUrW`5:N2}m">
      <field name="NUM">4</field>
      </block>
      </value>
      </block>
      </statement>
      </block>
      </next>
      </block>
      </statement>
      </block>
      </next>
      </block>
      </next>
      </block>
      </next>
      </block>
      </next>
      </block>
      </next>
      </block>
      </next>
      </block>
      </next>
      </block>
      </next>
      </block>
      </next>
      </block>
      </next>
      </block>
      </next>
      </block>
      </next>
      </block>
      </next>
      </block>
      </next>
      </block>
      </xml>

      Bildschirmfoto 2021-05-22 um 08.33.15.png

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

      Support us

      ioBroker
      Community Adapters
      Donate

      748
      Online

      32.0k
      Users

      80.5k
      Topics

      1.3m
      Posts

      1
      1
      82
      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