Navigation

    Logo
    • Register
    • Login
    • Search
    • Recent
    • Tags
    • Unread
    • Categories
    • Unreplied
    • Popular
    • GitHub
    • Docu
    • Hilfe
    1. Home
    2. Deutsch
    3. Skripten / Logik
    4. Blockly
    5. [gelöst]Hilfe bei Erstellung von Blockly - Anwesenheit

    NEWS

    • Neues Video über Aliase, virtuelle Geräte und Kategorien

    • Wir empfehlen: Node.js 22.x

    • Neuer Blog: Fotos und Eindrücke aus Solingen

    [gelöst]Hilfe bei Erstellung von Blockly - Anwesenheit

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

      @paul53 sagte in Hilfe bei Erstellung von Blockly - Anwesenheit:

      @wszene sagte: Er soll auf true geschalten werden wenn nur ein Gerät in der Auflistung "Anwesenheit" "true" ist

      Bei dem Selektor auf die Schreibweise in der ID "enum.functions.Anwesend" achten:

      Bild_2022-02-09_155643.png

      Vielen Dank
      Leider bin ich noch sehr unerfahren um aus deinem Bild schlau zu werden

      z.B. Was ist "ids"?
      Kannst du mir evtl. den Code zur Verfügung stellen vielleicht ist es da für mich einfacher zu verstehen

      Danke dir

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

        @wszene sagte: Kannst du mir evtl. den Code zur Verfügung stellen

        <xml xmlns="https://developers.google.com/blockly/xml">
         <variables>
           <variable id="B~6E2M9LNR0A68YO_!?h">ids</variable>
           <variable id="8xwpI[Ec2NLCoKl2G^HN">anwesend</variable>
           <variable id="b~edSQ%u?[=zCg?@@NVd">id</variable>
         </variables>
         <block type="variables_set" id="@r0H7Pd#IuCWPzYVs]@B" x="38" y="-38">
           <field name="VAR" id="B~6E2M9LNR0A68YO_!?h">ids</field>
           <value name="VALUE">
             <block type="selector" id="9dmgHnb{Mu,KR]4`=we+">
               <field name="TEXT">*(functions=Anwesend)</field>
             </block>
           </value>
           <next>
             <block type="on_ext" id="|J))({--a@{f:i%:B6=!">
               <mutation xmlns="http://www.w3.org/1999/xhtml" items="1"></mutation>
               <field name="CONDITION">ne</field>
               <field name="ACK_CONDITION"></field>
               <value name="OID0">
                 <shadow type="field_oid" id="[?h1n*ipJA5z3%Z(Fe7A">
                   <field name="oid">default</field>
                 </shadow>
                 <block type="variables_get" id="NM6FjaeM/e|vN6))Wjl8">
                   <field name="VAR" id="B~6E2M9LNR0A68YO_!?h">ids</field>
                 </block>
               </value>
               <statement name="STATEMENT">
                 <block type="variables_set" id="W9cD^h2NB/Oh6uCM~,ch">
                   <field name="VAR" id="8xwpI[Ec2NLCoKl2G^HN">anwesend</field>
                   <value name="VALUE">
                     <block type="logic_boolean" id="EK#H|i-qNzR8{6L@qCs:">
                       <field name="BOOL">FALSE</field>
                     </block>
                   </value>
                   <next>
                     <block type="controls_forEach" id="fcL+iAOQ?2UQ{l%R@Ben">
                       <field name="VAR" id="b~edSQ%u?[=zCg?@@NVd">id</field>
                       <value name="LIST">
                         <block type="variables_get" id="|LRMU1|FENYMFt?tKXql">
                           <field name="VAR" id="B~6E2M9LNR0A68YO_!?h">ids</field>
                         </block>
                       </value>
                       <statement name="DO">
                         <block type="controls_if" id="q*MoV25XBw2yjtA/#U;e">
                           <value name="IF0">
                             <block type="get_value_var" id="C*qbN~*s|0Y[,|yE0w:;">
                               <field name="ATTR">val</field>
                               <value name="OID">
                                 <shadow type="text" id="{9}$5RK-gBSnkI[~/qun">
                                   <field name="TEXT"></field>
                                 </shadow>
                                 <block type="variables_get" id="tHy8m#37cp1AiM#mF$J5">
                                   <field name="VAR" id="b~edSQ%u?[=zCg?@@NVd">id</field>
                                 </block>
                               </value>
                             </block>
                           </value>
                           <statement name="DO0">
                             <block type="variables_set" id="fy7ZPy/LDb$jnsJ~-]/~">
                               <field name="VAR" id="8xwpI[Ec2NLCoKl2G^HN">anwesend</field>
                               <value name="VALUE">
                                 <block type="logic_boolean" id="Jy1;ir02zJi$n;+0,^mD">
                                   <field name="BOOL">TRUE</field>
                                 </block>
                               </value>
                               <next>
                                 <block type="controls_flow_statements" id="`CM-oF[[Z,xAFsleL`H4">
                                   <field name="FLOW">BREAK</field>
                                 </block>
                               </next>
                             </block>
                           </statement>
                         </block>
                       </statement>
                       <next>
                         <block type="update" id="A9rcbHAGvYr()@Dq}FS|">
                           <mutation xmlns="http://www.w3.org/1999/xhtml" delay_input="false"></mutation>
                           <field name="OID">Object ID</field>
                           <field name="WITH_DELAY">FALSE</field>
                           <value name="VALUE">
                             <block type="variables_get" id="(?Ieb;C^RtOKl[Q~7TV/">
                               <field name="VAR" id="8xwpI[Ec2NLCoKl2G^HN">anwesend</field>
                             </block>
                           </value>
                         </block>
                       </next>
                     </block>
                   </next>
                 </block>
               </statement>
             </block>
           </next>
         </block>
        </xml>
        

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

          @paul53
          Danke für den Code

          Leider passiert bei mir garnichts
          Ich habe mir auch mal die Variable "ids" als debug ausgeben lassen aber Diese ist leider auch leer

          Wo könnte denn der Fehler liegen
          Bildschirmfoto 2022-02-09 um 21.54.16.png

          <xml xmlns="https://developers.google.com/blockly/xml">
            <variables>
              <variable id="B~6E2M9LNR0A68YO_!?h">ids</variable>
              <variable type="timeout" id="start">start</variable>
              <variable id="8xwpI[Ec2NLCoKl2G^HN">anwesend</variable>
              <variable id="b~edSQ%u?[=zCg?@@NVd">id</variable>
            </variables>
            <block type="procedures_defcustomnoreturn" id="D:0E=~0D8*EFnn8f|sd." x="-1138" y="-463">
              <mutation statements="false"></mutation>
              <field name="NAME">Datenpunkte_erstellen</field>
              <field name="SCRIPT">Ly8gRFAgb2huZSBBbGV4YQpjcmVhdGVTdGF0ZSgnMF91c2VyZGF0YS4wLjAyMF9Tb25zdGlnZXMuQW53ZXNlbmhlaXQuTWFyY2VsJywgeyduYW1lJzonTWFyY2VsIEFud2Vlc2VuZCcsICd0eXBlJzonYm9vbGVhbicsICdyZWFkJzp0cnVlLCAnd3JpdGUnOnRydWUsICdyb2xlJzonc3RhdGUnLCAnZGVmJzpmYWxzZSwgInNtYXJ0TmFtZSI6IGZhbHNlIH0pOwovLyBEUCBtaXQgQWxleGEKLy9jcmVhdGVTdGF0ZSgnMF91c2VyZGF0YS4wLjAwMDFfVGVzdC50ZXN0LWRwLWFsZXhhJywgeyduYW1lJzonVGVzdCBEUCBBbGV4YScsICd0eXBlJzonYm9vbGVhbicsICdyZWFkJzp0cnVlLCAnd3JpdGUnOnRydWUsICdyb2xlJzonc3dpdGNoJywgJ2RlZic6ZmFsc2UsICJzbWFydE5hbWUiOiB7ImRlIjogIlRlc3QtR2Vyw6R0Iiwic21hcnRUeXBlIjogIkxJR0hUIn0gfSk7</field>
              <comment pinned="false" h="80" w="160">Datenpunkte erstellen</comment>
            </block>
            <block type="comment" id="/_6pGOv!o3)I1~^MR*yi" x="-1137" y="-437">
              <field name="COMMENT">Funktion ausführen</field>
              <next>
                <block type="timeouts_settimeout" id="8FQd(trxfKDt`(FG0(?=">
                  <field name="NAME">start</field>
                  <field name="DELAY">1000</field>
                  <field name="UNIT">ms</field>
                  <statement name="STATEMENT">
                    <block type="procedures_callcustomnoreturn" id="}{A#y;jy-Pl_)n6[of`b">
                      <mutation name="Datenpunkte_erstellen"></mutation>
                    </block>
                  </statement>
                </block>
              </next>
            </block>
            <block type="variables_set" id="@r0H7Pd#IuCWPzYVs]@B" x="-1138" y="-287">
              <field name="VAR" id="B~6E2M9LNR0A68YO_!?h">ids</field>
              <value name="VALUE">
                <block type="selector" id="9dmgHnb{Mu,KR]4`=we+">
                  <field name="TEXT">*(functions=anwesend)</field>
                </block>
              </value>
              <next>
                <block type="debug" id=".n!pnU7r[Q)}xF!+~Z._">
                  <field name="Severity">log</field>
                  <value name="TEXT">
                    <shadow type="text" id="qei2KI8)Z+HTi.iDty+C">
                      <field name="TEXT">test</field>
                    </shadow>
                    <block type="text_join" id=":r@S7)0ebZCw6_Bv$_i]">
                      <mutation items="3"></mutation>
                      <value name="ADD0">
                        <block type="text" id=",Fl|y?EhO}LV?w0;lR;i">
                          <field name="TEXT">Debug Anfang </field>
                        </block>
                      </value>
                      <value name="ADD1">
                        <block type="variables_get" id="tv@RG,_o3z_]2|QoI;)3">
                          <field name="VAR" id="B~6E2M9LNR0A68YO_!?h">ids</field>
                        </block>
                      </value>
                      <value name="ADD2">
                        <block type="text" id="ny@TZyd0Z/8ziFSu`0!,">
                          <field name="TEXT"> Debug Ende</field>
                        </block>
                      </value>
                    </block>
                  </value>
                  <next>
                    <block type="on_ext" id="|J))({--a@{f:i%:B6=!">
                      <mutation xmlns="http://www.w3.org/1999/xhtml" items="1"></mutation>
                      <field name="CONDITION">ne</field>
                      <field name="ACK_CONDITION"></field>
                      <value name="OID0">
                        <shadow type="field_oid" id="[?h1n*ipJA5z3%Z(Fe7A">
                          <field name="oid">default</field>
                        </shadow>
                        <block type="variables_get" id="NM6FjaeM/e|vN6))Wjl8">
                          <field name="VAR" id="B~6E2M9LNR0A68YO_!?h">ids</field>
                        </block>
                      </value>
                      <statement name="STATEMENT">
                        <block type="variables_set" id="W9cD^h2NB/Oh6uCM~,ch">
                          <field name="VAR" id="8xwpI[Ec2NLCoKl2G^HN">anwesend</field>
                          <value name="VALUE">
                            <block type="logic_boolean" id="EK#H|i-qNzR8{6L@qCs:">
                              <field name="BOOL">FALSE</field>
                            </block>
                          </value>
                          <next>
                            <block type="controls_forEach" id="fcL+iAOQ?2UQ{l%R@Ben">
                              <field name="VAR" id="b~edSQ%u?[=zCg?@@NVd">id</field>
                              <value name="LIST">
                                <block type="variables_get" id="|LRMU1|FENYMFt?tKXql">
                                  <field name="VAR" id="B~6E2M9LNR0A68YO_!?h">ids</field>
                                </block>
                              </value>
                              <statement name="DO">
                                <block type="controls_if" id="q*MoV25XBw2yjtA/#U;e">
                                  <value name="IF0">
                                    <block type="get_value_var" id="C*qbN~*s|0Y[,|yE0w:;">
                                      <field name="ATTR">val</field>
                                      <value name="OID">
                                        <shadow type="text" id="{9}$5RK-gBSnkI[~/qun">
                                          <field name="TEXT"></field>
                                        </shadow>
                                        <block type="variables_get" id="tHy8m#37cp1AiM#mF$J5">
                                          <field name="VAR" id="b~edSQ%u?[=zCg?@@NVd">id</field>
                                        </block>
                                      </value>
                                    </block>
                                  </value>
                                  <statement name="DO0">
                                    <block type="variables_set" id="fy7ZPy/LDb$jnsJ~-]/~">
                                      <field name="VAR" id="8xwpI[Ec2NLCoKl2G^HN">anwesend</field>
                                      <value name="VALUE">
                                        <block type="logic_boolean" id="Jy1;ir02zJi$n;+0,^mD">
                                          <field name="BOOL">TRUE</field>
                                        </block>
                                      </value>
                                      <next>
                                        <block type="controls_flow_statements" id="`CM-oF[[Z,xAFsleL`H4">
                                          <field name="FLOW">BREAK</field>
                                        </block>
                                      </next>
                                    </block>
                                  </statement>
                                </block>
                              </statement>
                              <next>
                                <block type="update" id="A9rcbHAGvYr()@Dq}FS|">
                                  <mutation xmlns="http://www.w3.org/1999/xhtml" delay_input="false"></mutation>
                                  <field name="OID">0_userdata.0.020_Sonstiges.Anwesenheit.Marcel</field>
                                  <field name="WITH_DELAY">FALSE</field>
                                  <value name="VALUE">
                                    <block type="variables_get" id="(?Ieb;C^RtOKl[Q~7TV/">
                                      <field name="VAR" id="8xwpI[Ec2NLCoKl2G^HN">anwesend</field>
                                    </block>
                                  </value>
                                </block>
                              </next>
                            </block>
                          </next>
                        </block>
                      </statement>
                    </block>
                  </next>
                </block>
              </next>
            </block>
          </xml>
          
          paul53 1 Reply Last reply Reply Quote 0
          • paul53
            paul53 @Wszene last edited by paul53

            @wszene
            Zeige mal die Aufzählung "enum.functions.anwesend".

            ids ist ein Array. Das kann man nicht zusammen mit weiterem Text als Log ausgeben, sondern nur so:

            Bild_2022-02-09_223016.png

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

              @paul53

              Hier die Ausgabe

              
              javascript.0
              2022-02-09 22:38:06.523	info	script.js.20-Sonstiges.Marcel_-_Anwesend: registered 0 subscriptions and 0 schedules
              
              javascript.0
              2022-02-09 22:38:06.523	info	script.js.20-Sonstiges.Marcel_-_Anwesend: []
              
              javascript.0
              2022-02-09 22:38:06.500	info	Start javascript script.js.20-Sonstiges.Marcel_-_Anwesend
              
              javascript.0
              2022-02-09 22:38:06.494	info	Stop script script.js.20-Sonstiges.Marcel_-_Anwesend
              

              Es ist aber ein Gerät auf True

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

                @wszene sagte: Es ist aber ein Gerät auf True

                Das Log zeigt ein leeres Array, was bedeutet, dass kein zum Selektor passender Datenpunkt gefunden wurde. Falls die Datenpunkte erst kürzlich zur Aufzählung zugewiesen wurden, starte die Javascript-Instanz neu, um den Puffer zu aktualisieren.

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

                  @paul53
                  Danke das hat geholfen

                  
                  javascript.0
                  2022-02-10 07:16:25.036	info	script.js.20-Sonstiges.Marcel_-_Anwesend: registered 5 subscriptions and 0 schedules
                  
                  javascript.0
                  2022-02-10 07:16:25.036	info	script.js.20-Sonstiges.Marcel_-_Anwesend: ['0_userdata.0.001_Alexa.01_Stube.Lampen.Stehlampe','0_userdata.0.001_Alexa.01_Stube.Lampen.Esstisch','0_userdata.0.001_Alexa.01_Stube.Lampen.Sofatisch','0_userdata.0.001_Alexa.01_Stube.Harmony.TV.Allgemein.Kino','0_userdata.0.001_Alexa.02_Schlafzimmer.Dosen.TV_Bett']
                  
                  javascript.0
                  2022-02-10 07:16:25.025	info	Start javascript script.js.20-Sonstiges.Marcel_-_Anwesend
                  

                  Der DP wurde auf "true" gesetzt was ja richtig ist da die Stehlampe an ist
                  Mache ich jetzt aber die Stehlampe aus sollte ja der DP auf "false" gestellt werden
                  Da passiert aber leider nicht

                  1 Reply Last reply Reply Quote 0
                  • Wszene
                    Wszene last edited by

                    Kann mir hier keiner helfen?
                    hat denn noch niemand so etwas umgesetzt?
                    das kann ich mir eigentlich garnicht vorstellen

                    Die Liste wird ja in die Variable geschrieben
                    Aber wie kann ich jetzt herausfinden ob ein Gerät in der Variable den Wert true hat?

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

                      @wszene sagte: wie kann ich jetzt herausfinden ob ein Gerät in der Variable den Wert true hat?

                      Bild_2022-02-12_123837.png

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

                        @paul53
                        OK danke nun haben wir eine Liste mit Werten

                        
                        javascript.0
                        2022-02-12 13:41:51.032	info	script.js.20-Sonstiges.Marcel_-_Anwesend: 0_userdata.0.001_Alexa.01_Stube.Lampen.Stehlampe : true
                        
                        javascript.0
                        2022-02-12 13:41:51.032	info	script.js.20-Sonstiges.Marcel_-_Anwesend: 0_userdata.0.001_Alexa.01_Stube.Lampen.Sofatisch : false
                        
                        javascript.0
                        2022-02-12 13:41:51.032	info	script.js.20-Sonstiges.Marcel_-_Anwesend: 0_userdata.0.001_Alexa.01_Stube.Lampen.Esstisch : false
                        
                        javascript.0
                        2022-02-12 13:41:51.032	info	script.js.20-Sonstiges.Marcel_-_Anwesend: 0_userdata.0.001_Alexa.01_Stube.Harmony.TV.Allgemein.Kino : false
                        
                        javascript.0
                        2022-02-12 13:41:51.030	info	script.js.20-Sonstiges.Marcel_-_Anwesend: 0_userdata.0.001_Alexa.01_Stube.Lampen.Stehlampe : true
                        
                        javascript.0
                        2022-02-12 13:41:51.030	info	script.js.20-Sonstiges.Marcel_-_Anwesend: 0_userdata.0.001_Alexa.01_Stube.Lampen.Sofatisch : false
                        
                        javascript.0
                        2022-02-12 13:41:51.030	info	script.js.20-Sonstiges.Marcel_-_Anwesend: 0_userdata.0.001_Alexa.01_Stube.Lampen.Esstisch : false
                        
                        javascript.0
                        2022-02-12 13:41:51.030	info	script.js.20-Sonstiges.Marcel_-_Anwesend: 0_userdata.0.001_Alexa.01_Stube.Harmony.TV.Allgemein.Kino : false
                        
                        javascript.0
                        2022-02-12 13:41:51.027	info	script.js.20-Sonstiges.Marcel_-_Anwesend: 0_userdata.0.001_Alexa.01_Stube.Lampen.Stehlampe : true
                        
                        javascript.0
                        2022-02-12 13:41:51.027	info	script.js.20-Sonstiges.Marcel_-_Anwesend: 0_userdata.0.001_Alexa.01_Stube.Lampen.Sofatisch : false
                        
                        javascript.0
                        2022-02-12 13:41:51.027	info	script.js.20-Sonstiges.Marcel_-_Anwesend: 0_userdata.0.001_Alexa.01_Stube.Lampen.Esstisch : false
                        
                        javascript.0
                        2022-02-12 13:41:51.026	info	script.js.20-Sonstiges.Marcel_-_Anwesend: 0_userdata.0.001_Alexa.01_Stube.Harmony.TV.Allgemein.Kino : false
                        

                        Und wie kann ich jetzt sagen das wenn ein Wert "true" ist der DP auch als True gesetzt wird
                        Oder vieleicht ist es ja auch einfacher es so zu machen wenn alle Werte "false" sind den DP auf "false" zusetzten

                        
                        javascript.0
                        2022-02-12 13:45:14.456	info	script.js.20-Sonstiges.Marcel_-_Anwesend: 0_userdata.0.001_Alexa.02_Schlafzimmer.Dosen.TV_Bett : false
                        
                        javascript.0
                        2022-02-12 13:45:14.456	info	script.js.20-Sonstiges.Marcel_-_Anwesend: 0_userdata.0.001_Alexa.01_Stube.Lampen.Stehlampe : false
                        
                        javascript.0
                        2022-02-12 13:45:14.456	info	script.js.20-Sonstiges.Marcel_-_Anwesend: 0_userdata.0.001_Alexa.01_Stube.Lampen.Sofatisch : false
                        
                        javascript.0
                        2022-02-12 13:45:14.456	info	script.js.20-Sonstiges.Marcel_-_Anwesend: 0_userdata.0.001_Alexa.01_Stube.Lampen.Esstisch : false
                        
                        javascript.0
                        2022-02-12 13:45:14.456	info	script.js.20-Sonstiges.Marcel_-_Anwesend: 0_userdata.0.001_Alexa.01_Stube.Harmony.TV.Allgemein.Kino : false
                        

                        Danke

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

                          @wszene sagte: Und wie kann ich jetzt sagen das wenn ein Wert "true" ist der DP auch als True gesetzt wird

                          Das macht das Skript:
                          Zuerst wird die Variable anwesend auf false gesetzt. Wenn in der Schleife ein Datenpunkt mit Wert true gefunden wird, wird die Variable auf true gesetzt, andernfalls bleibt sie auf false. Zum Schluss wird die Variable in den Datenpunkt geschrieben.

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

                            Traumhaft so soll es sein
                            1001 Dank an @paul53

                            Wenn es jemand interessiert hier das Blockly

                            <xml xmlns="https://developers.google.com/blockly/xml">
                              <variables>
                                <variable id="B~6E2M9LNR0A68YO_!?h">ids</variable>
                                <variable type="timeout" id="start">start</variable>
                                <variable id="8xwpI[Ec2NLCoKl2G^HN">anwesend</variable>
                                <variable id="b~edSQ%u?[=zCg?@@NVd">id</variable>
                              </variables>
                              <block type="procedures_defcustomnoreturn" id="D:0E=~0D8*EFnn8f|sd." x="-1138" y="-463">
                                <mutation statements="false"></mutation>
                                <field name="NAME">Datenpunkte_erstellen</field>
                                <field name="SCRIPT">Ly8gRFAgb2huZSBBbGV4YQpjcmVhdGVTdGF0ZSgnMF91c2VyZGF0YS4wLjAyMF9Tb25zdGlnZXMuQW53ZXNlbmhlaXQuTWFyY2VsJywgeyduYW1lJzonTWFyY2VsIEFud2Vlc2VuZCcsICd0eXBlJzonYm9vbGVhbicsICdyZWFkJzp0cnVlLCAnd3JpdGUnOnRydWUsICdyb2xlJzonc3RhdGUnLCAnZGVmJzpmYWxzZSwgInNtYXJ0TmFtZSI6IGZhbHNlIH0pOwovLyBEUCBtaXQgQWxleGEKLy9jcmVhdGVTdGF0ZSgnMF91c2VyZGF0YS4wLjAwMDFfVGVzdC50ZXN0LWRwLWFsZXhhJywgeyduYW1lJzonVGVzdCBEUCBBbGV4YScsICd0eXBlJzonYm9vbGVhbicsICdyZWFkJzp0cnVlLCAnd3JpdGUnOnRydWUsICdyb2xlJzonc3dpdGNoJywgJ2RlZic6ZmFsc2UsICJzbWFydE5hbWUiOiB7ImRlIjogIlRlc3QtR2Vyw6R0Iiwic21hcnRUeXBlIjogIkxJR0hUIn0gfSk7</field>
                                <comment pinned="false" h="80" w="160">Datenpunkte erstellen</comment>
                              </block>
                              <block type="comment" id="/_6pGOv!o3)I1~^MR*yi" x="-1137" y="-437">
                                <field name="COMMENT">Funktion ausführen</field>
                                <next>
                                  <block type="timeouts_settimeout" id="8FQd(trxfKDt`(FG0(?=">
                                    <field name="NAME">start</field>
                                    <field name="DELAY">1000</field>
                                    <field name="UNIT">ms</field>
                                    <statement name="STATEMENT">
                                      <block type="procedures_callcustomnoreturn" id="}{A#y;jy-Pl_)n6[of`b">
                                        <mutation name="Datenpunkte_erstellen"></mutation>
                                      </block>
                                    </statement>
                                  </block>
                                </next>
                              </block>
                              <block type="variables_set" id="@r0H7Pd#IuCWPzYVs]@B" x="-1138" y="-287">
                                <field name="VAR" id="B~6E2M9LNR0A68YO_!?h">ids</field>
                                <value name="VALUE">
                                  <block type="selector" id="9dmgHnb{Mu,KR]4`=we+">
                                    <field name="TEXT">state[id=*](functions=anwesend)</field>
                                  </block>
                                </value>
                                <next>
                                  <block type="on_ext" id="|J))({--a@{f:i%:B6=!">
                                    <mutation xmlns="http://www.w3.org/1999/xhtml" items="1"></mutation>
                                    <field name="CONDITION">any</field>
                                    <field name="ACK_CONDITION"></field>
                                    <value name="OID0">
                                      <shadow type="field_oid" id="[?h1n*ipJA5z3%Z(Fe7A">
                                        <field name="oid">default</field>
                                      </shadow>
                                      <block type="variables_get" id="NM6FjaeM/e|vN6))Wjl8">
                                        <field name="VAR" id="B~6E2M9LNR0A68YO_!?h">ids</field>
                                      </block>
                                    </value>
                                    <statement name="STATEMENT">
                                      <block type="variables_set" id="W9cD^h2NB/Oh6uCM~,ch">
                                        <field name="VAR" id="8xwpI[Ec2NLCoKl2G^HN">anwesend</field>
                                        <value name="VALUE">
                                          <block type="logic_boolean" id="EK#H|i-qNzR8{6L@qCs:">
                                            <field name="BOOL">FALSE</field>
                                          </block>
                                        </value>
                                        <next>
                                          <block type="controls_forEach" id="fcL+iAOQ?2UQ{l%R@Ben">
                                            <field name="VAR" id="b~edSQ%u?[=zCg?@@NVd">id</field>
                                            <value name="LIST">
                                              <block type="variables_get" id="|LRMU1|FENYMFt?tKXql">
                                                <field name="VAR" id="B~6E2M9LNR0A68YO_!?h">ids</field>
                                              </block>
                                            </value>
                                            <statement name="DO">
                                              <block type="debug" id=".n!pnU7r[Q)}xF!+~Z._" disabled="true">
                                                <field name="Severity">log</field>
                                                <value name="TEXT">
                                                  <shadow type="text" id="qei2KI8)Z+HTi.iDty+C">
                                                    <field name="TEXT">test</field>
                                                  </shadow>
                                                  <block type="text_join" id="`[kmxP4e#x}%#pKLw;ei">
                                                    <mutation items="3"></mutation>
                                                    <value name="ADD0">
                                                      <block type="variables_get" id="tv@RG,_o3z_]2|QoI;)3">
                                                        <field name="VAR" id="b~edSQ%u?[=zCg?@@NVd">id</field>
                                                      </block>
                                                    </value>
                                                    <value name="ADD1">
                                                      <block type="text" id="c-F%qmhaJ@{J!SsfF7f$">
                                                        <field name="TEXT"> : </field>
                                                      </block>
                                                    </value>
                                                    <value name="ADD2">
                                                      <block type="get_value_var" id="O=D6Yw4J/%U90ae?kn*b">
                                                        <field name="ATTR">val</field>
                                                        <value name="OID">
                                                          <shadow type="text">
                                                            <field name="TEXT"></field>
                                                          </shadow>
                                                          <block type="variables_get" id="5H(j1*]9Flo81ly#4itt">
                                                            <field name="VAR" id="b~edSQ%u?[=zCg?@@NVd">id</field>
                                                          </block>
                                                        </value>
                                                      </block>
                                                    </value>
                                                  </block>
                                                </value>
                                                <next>
                                                  <block type="controls_if" id="q*MoV25XBw2yjtA/#U;e">
                                                    <mutation else="1"></mutation>
                                                    <value name="IF0">
                                                      <block type="logic_compare" id="GA*ckh?Pp/%@%+5)8C?s">
                                                        <field name="OP">EQ</field>
                                                        <value name="A">
                                                          <block type="get_value_var" id="C*qbN~*s|0Y[,|yE0w:;">
                                                            <field name="ATTR">val</field>
                                                            <value name="OID">
                                                              <shadow type="text" id="{9}$5RK-gBSnkI[~/qun">
                                                                <field name="TEXT"></field>
                                                              </shadow>
                                                              <block type="variables_get" id="tHy8m#37cp1AiM#mF$J5">
                                                                <field name="VAR" id="b~edSQ%u?[=zCg?@@NVd">id</field>
                                                              </block>
                                                            </value>
                                                          </block>
                                                        </value>
                                                        <value name="B">
                                                          <block type="logic_boolean" id="/!dprzsB*lsRbR6$v6m4">
                                                            <field name="BOOL">TRUE</field>
                                                          </block>
                                                        </value>
                                                      </block>
                                                    </value>
                                                    <statement name="DO0">
                                                      <block type="variables_set" id="fy7ZPy/LDb$jnsJ~-]/~">
                                                        <field name="VAR" id="8xwpI[Ec2NLCoKl2G^HN">anwesend</field>
                                                        <value name="VALUE">
                                                          <block type="logic_boolean" id="Jy1;ir02zJi$n;+0,^mD">
                                                            <field name="BOOL">TRUE</field>
                                                          </block>
                                                        </value>
                                                        <next>
                                                          <block type="controls_flow_statements" id="`CM-oF[[Z,xAFsleL`H4">
                                                            <field name="FLOW">BREAK</field>
                                                          </block>
                                                        </next>
                                                      </block>
                                                    </statement>
                                                    <statement name="ELSE">
                                                      <block type="variables_set" id="~mtzbd`zn~MO?Wj)`p~2">
                                                        <field name="VAR" id="8xwpI[Ec2NLCoKl2G^HN">anwesend</field>
                                                        <value name="VALUE">
                                                          <block type="logic_boolean" id="5=!Majg[*^Z*GbHZRsBj">
                                                            <field name="BOOL">FALSE</field>
                                                          </block>
                                                        </value>
                                                      </block>
                                                    </statement>
                                                  </block>
                                                </next>
                                              </block>
                                            </statement>
                                            <next>
                                              <block type="update" id="A9rcbHAGvYr()@Dq}FS|">
                                                <mutation xmlns="http://www.w3.org/1999/xhtml" delay_input="false"></mutation>
                                                <field name="OID">0_userdata.0.020_Sonstiges.Anwesenheit.Marcel</field>
                                                <field name="WITH_DELAY">FALSE</field>
                                                <value name="VALUE">
                                                  <block type="variables_get" id="(?Ieb;C^RtOKl[Q~7TV/">
                                                    <field name="VAR" id="8xwpI[Ec2NLCoKl2G^HN">anwesend</field>
                                                  </block>
                                                </value>
                                              </block>
                                            </next>
                                          </block>
                                        </next>
                                      </block>
                                    </statement>
                                  </block>
                                </next>
                              </block>
                            </xml>
                            
                            1 Reply Last reply Reply Quote 0
                            • First post
                              Last post

                            Support us

                            ioBroker
                            Community Adapters
                            Donate

                            774
                            Online

                            32.1k
                            Users

                            80.6k
                            Topics

                            1.3m
                            Posts

                            blockly
                            3
                            15
                            392
                            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