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. [Gelöst] HUE Motion Sensor Lampe an/aus -> Problem Haustier

NEWS

  • Jahresrückblick 2025 – unser neuer Blogbeitrag ist online! ✨
    BluefoxB
    Bluefox
    17
    1
    3.9k

  • Neuer Blogbeitrag: Monatsrückblick - Dezember 2025 🎄
    BluefoxB
    Bluefox
    13
    1
    1.2k

  • Weihnachtsangebot 2025! 🎄
    BluefoxB
    Bluefox
    25
    1
    2.5k

[Gelöst] HUE Motion Sensor Lampe an/aus -> Problem Haustier

Geplant Angeheftet Gesperrt Verschoben Blockly
31 Beiträge 3 Kommentatoren 5.1k Aufrufe 5 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.
  • SanwebS Sanweb

    @padrino

    Scheine irgendwie zu blöd dafür zu sein ... :astonished:

    HAbe mir mal eine manipulierbare variable des Buttons genommen, welche nicht gleich wild umherspringt beim drücken und los lassen des Buttons. Ergebnis: Wird der Button nicht gedrückt, funktioniert alles über wie gewohnt über den Bewegungsmelder. Wird er gedrückt, schaltet das Licht aus (soweit ja gut), aber wird der Türkontakt erneut ausgelöst (Verlassen des Raumes) bleibt das Licht an. Mann muss erst den reulären Lichtschalter betätigen (oder Alexa darum bitten) um das Licht zu löschen.

    Badezimmer_6.jpg

    <xml xmlns="https://developers.google.com/blockly/xml">
      <variables>
        <variable type="timeout" id="timeout">timeout</variable>
      </variables>
      <block type="comment" id="j^MxUgu8?7{mlu]rA:Tf" x="685" y="-2361">
        <field name="COMMENT">Bewegung</field>
        <next>
          <block type="on_ext" id="Vo2d_MmTq==sR.4ZWR$O">
            <mutation xmlns="http://www.w3.org/1999/xhtml" items="2"></mutation>
            <field name="CONDITION">ne</field>
            <field name="ACK_CONDITION"></field>
            <value name="OID0">
              <shadow type="field_oid" id="Czsj]a1TUk|+~h~ORP[b">
                <field name="oid">deconz.0.Sensors.2.presence</field>
              </shadow>
            </value>
            <value name="OID1">
              <shadow type="field_oid" id="D~cxI@R3d9Qx8WQ#e+*e">
                <field name="oid">deconz.0.Sensors.15.buttonevent</field>
              </shadow>
            </value>
            <statement name="STATEMENT">
              <block type="timeouts_cleartimeout" id=".AnY7,uE8z6%68I_9r!J">
                <field name="NAME">timeout</field>
                <next>
                  <block type="controls_if" id="+RZ{~*8u`F-{891w*mat">
                    <mutation elseif="1"></mutation>
                    <value name="IF0">
                      <block type="logic_compare" id="MN?aguGn@4Va*isSfJlE">
                        <field name="OP">EQ</field>
                        <value name="A">
                          <block type="get_value" id="Q7EW:c|QXZG`n]0EAC|{">
                            <field name="ATTR">val</field>
                            <field name="OID">deconz.0.Sensors.15.buttonevent</field>
                          </block>
                        </value>
                        <value name="B">
                          <block type="math_number" id="L}L-PyHNK43~ZBR#G]Yv">
                            <field name="NUM">1002</field>
                          </block>
                        </value>
                      </block>
                    </value>
                    <statement name="DO0">
                      <block type="timeouts_cleartimeout" id="rpT/q:9t@dh:zAD1RZRa">
                        <field name="NAME">timeout</field>
                      </block>
                    </statement>
                    <value name="IF1">
                      <block type="logic_negate" id="C4LtUkpka$={[9/VCOva">
                        <value name="BOOL">
                          <block type="on_source" id="+d+_sgAE*[8U#u/8-`=!">
                            <field name="ATTR">state.val</field>
                          </block>
                        </value>
                      </block>
                    </value>
                    <statement name="DO1">
                      <block type="timeouts_settimeout" id="b8c{g!jXe$]dFOh^QXP[">
                        <field name="NAME">timeout</field>
                        <field name="DELAY">30</field>
                        <field name="UNIT">sec</field>
                        <statement name="STATEMENT">
                          <block type="comment" id="vvNPR8V{Zt(;|2~TmxfO">
                            <field name="COMMENT">Licht ein?</field>
                            <next>
                              <block type="controls_if" id="ub/zHL/V?|rXYe|9Al6y">
                                <value name="IF0">
                                  <block type="logic_operation" id="sRWf3Sh^D=g_?X6r1GMv">
                                    <field name="OP">AND</field>
                                    <value name="A">
                                      <block type="get_value" id="FrcZZNPN%#R(^G6NN|LM">
                                        <field name="ATTR">val</field>
                                        <field name="OID">sonoff.0.Badezimmerlicht.POWER</field>
                                      </block>
                                    </value>
                                    <value name="B">
                                      <block type="logic_negate" id="F~[{i96epeX5jd2{rmv%">
                                        <value name="BOOL">
                                          <block type="get_value" id="ejT!#TZx@6fmiw7y+(:;">
                                            <field name="ATTR">val</field>
                                            <field name="OID">deconz.0.Sensors.15.buttonevent</field>
                                          </block>
                                        </value>
                                      </block>
                                    </value>
                                  </block>
                                </value>
                                <statement name="DO0">
                                  <block type="control" id="$86HuP~`N{LaY4I7md,3">
                                    <mutation xmlns="http://www.w3.org/1999/xhtml" delay_input="false"></mutation>
                                    <field name="OID">sonoff.0.Badezimmerlicht.POWER</field>
                                    <field name="WITH_DELAY">FALSE</field>
                                    <value name="VALUE">
                                      <block type="logic_boolean" id="1UP*Me:;gW3cC?+vbh94">
                                        <field name="BOOL">FALSE</field>
                                      </block>
                                    </value>
                                  </block>
                                </statement>
                              </block>
                            </next>
                          </block>
                        </statement>
                      </block>
                    </statement>
                  </block>
                </next>
              </block>
            </statement>
            <next>
              <block type="comment" id="#NX^q_VjK@F9iUWAWPA}">
                <field name="COMMENT">Tür öffnet</field>
                <next>
                  <block type="on_ext" id="/V]t?I@Gjkc^eMR_n#)|">
                    <mutation xmlns="http://www.w3.org/1999/xhtml" items="1"></mutation>
                    <field name="CONDITION">gt</field>
                    <field name="ACK_CONDITION"></field>
                    <value name="OID0">
                      <shadow type="field_oid" id="z.rf;Ppk-,EU=pVr7wQN">
                        <field name="oid">deconz.0.Sensors.5.open</field>
                      </shadow>
                    </value>
                    <statement name="STATEMENT">
                      <block type="comment" id="S+(!XQne8~@_%_R_(8!Q">
                        <field name="COMMENT">dunkel und Licht aus?</field>
                        <next>
                          <block type="controls_if" id="!muI`Yamueo@M|l(k(*v">
                            <value name="IF0">
                              <block type="logic_operation" id="F[YWS@t_RdTz=1pg)U=J" inline="false">
                                <field name="OP">AND</field>
                                <value name="A">
                                  <block type="logic_compare" id="xlS/H6h9B::cLn|J=^i+">
                                    <field name="OP">EQ</field>
                                    <value name="A">
                                      <block type="get_value" id="2NG.@e5:!/WW%;U$]|v`">
                                        <field name="ATTR">val</field>
                                        <field name="OID">deconz.0.Sensors.1.daylight</field>
                                      </block>
                                    </value>
                                    <value name="B">
                                      <block type="logic_boolean" id="/:tUU*Q~(.qOA?h~O9ft">
                                        <field name="BOOL">FALSE</field>
                                      </block>
                                    </value>
                                  </block>
                                </value>
                                <value name="B">
                                  <block type="logic_negate" id="QzU)|^M:2SQsEF%CPjDi">
                                    <value name="BOOL">
                                      <block type="get_value" id="+gD/U?X!ZU|7OJiYPclr">
                                        <field name="ATTR">val</field>
                                        <field name="OID">sonoff.0.Badezimmerlicht.POWER</field>
                                      </block>
                                    </value>
                                  </block>
                                </value>
                              </block>
                            </value>
                            <statement name="DO0">
                              <block type="control" id=":TjQf-tu@Q#kgie^P)@o">
                                <mutation xmlns="http://www.w3.org/1999/xhtml" delay_input="false"></mutation>
                                <field name="OID">sonoff.0.Badezimmerlicht.POWER</field>
                                <field name="WITH_DELAY">FALSE</field>
                                <value name="VALUE">
                                  <block type="logic_boolean" id="*ClGOYPry2taM^E+%*n#">
                                    <field name="BOOL">TRUE</field>
                                  </block>
                                </value>
                                <next>
                                  <block type="control" id="N[Wn)HQ)B|e`NIk_{%^$">
                                    <mutation xmlns="http://www.w3.org/1999/xhtml" delay_input="false"></mutation>
                                    <field name="OID">deconz.0.Sensors.15.buttonevent</field>
                                    <field name="WITH_DELAY">FALSE</field>
                                    <value name="VALUE">
                                      <block type="math_number" id="g24C1K?yk,s{q;E1_vE^">
                                        <field name="NUM">0</field>
                                      </block>
                                    </value>
                                  </block>
                                </next>
                              </block>
                            </statement>
                          </block>
                        </next>
                      </block>
                    </statement>
                  </block>
                </next>
              </block>
            </next>
          </block>
        </next>
      </block>
    </xml>
    
    paul53P Offline
    paul53P Offline
    paul53
    schrieb am zuletzt editiert von paul53
    #18

    @Sanweb
    Versuche es mal so:

    Blockly_temp.JPG

    <xml xmlns="https://developers.google.com/blockly/xml">
      <variables>
        <variable id="#?8llkQ_(?e?!}{7|0%B">duschen</variable>
        <variable type="timeout" id="timeout">timeout</variable>
      </variables>
      <block type="on_ext" id="JT^Sb~%?woKrqm#,_x?/" x="780" y="-2572">
        <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="g+hFwJ/p}d6]YQ~EspD*">
            <field name="oid">default</field>
          </shadow>
          <block type="text" id="K:Nj#+xP3L91=WcyB3vk">
            <field name="TEXT">deconz.0.Sensors.15.buttonevent</field>
          </block>
        </value>
        <statement name="STATEMENT">
          <block type="controls_if" id="5t#hR+Cr;XhCLt708]?;">
            <value name="IF0">
              <block type="logic_compare" id="*0/lSkBjPe!Q0-7A]`}t">
                <field name="OP">EQ</field>
                <value name="A">
                  <block type="on_source" id="p;(Kh@GTK/#PhbUs|2Fk">
                    <field name="ATTR">state.val</field>
                  </block>
                </value>
                <value name="B">
                  <block type="math_number" id="L}L-PyHNK43~ZBR#G]Yv">
                    <field name="NUM">1002</field>
                  </block>
                </value>
              </block>
            </value>
            <statement name="DO0">
              <block type="timeouts_cleartimeout" id="jv6hg}OB#s?,w0H*NI_d">
                <field name="NAME">timeout</field>
                <next>
                  <block type="variables_set" id="IQn)a22MZbX!@$BeNSbo">
                    <field name="VAR" id="#?8llkQ_(?e?!}{7|0%B">duschen</field>
                    <value name="VALUE">
                      <block type="logic_boolean" id=",=d^~(K|T,0?]S978@zB">
                        <field name="BOOL">TRUE</field>
                      </block>
                    </value>
                  </block>
                </next>
              </block>
            </statement>
          </block>
        </statement>
        <next>
          <block type="comment" id="j^MxUgu8?7{mlu]rA:Tf">
            <field name="COMMENT">Bewegung</field>
            <next>
              <block type="on_ext" id="Vo2d_MmTq==sR.4ZWR$O">
                <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="Czsj]a1TUk|+~h~ORP[b">
                    <field name="oid">deconz.0.Sensors.2.presence</field>
                  </shadow>
                </value>
                <statement name="STATEMENT">
                  <block type="timeouts_cleartimeout" id=".AnY7,uE8z6%68I_9r!J">
                    <field name="NAME">timeout</field>
                    <next>
                      <block type="controls_if" id="+RZ{~*8u`F-{891w*mat">
                        <value name="IF0">
                          <block type="logic_operation" id="WMPSk~z%).|`E/DHlrcn" inline="false">
                            <field name="OP">AND</field>
                            <value name="A">
                              <block type="logic_negate" id="C4LtUkpka$={[9/VCOva">
                                <value name="BOOL">
                                  <block type="on_source" id="+d+_sgAE*[8U#u/8-`=!">
                                    <field name="ATTR">state.val</field>
                                  </block>
                                </value>
                              </block>
                            </value>
                            <value name="B">
                              <block type="logic_negate" id="W1{FG$?i1lP8NHMpEzzu">
                                <value name="BOOL">
                                  <block type="variables_get" id="B^v6/7~q9mb|4}(2Qk$c">
                                    <field name="VAR" id="#?8llkQ_(?e?!}{7|0%B">duschen</field>
                                  </block>
                                </value>
                              </block>
                            </value>
                          </block>
                        </value>
                        <statement name="DO0">
                          <block type="timeouts_settimeout" id="b8c{g!jXe$]dFOh^QXP[">
                            <field name="NAME">timeout</field>
                            <field name="DELAY">30</field>
                            <field name="UNIT">sec</field>
                            <statement name="STATEMENT">
                              <block type="comment" id="vvNPR8V{Zt(;|2~TmxfO">
                                <field name="COMMENT">Licht ein?</field>
                                <next>
                                  <block type="controls_if" id="ub/zHL/V?|rXYe|9Al6y">
                                    <value name="IF0">
                                      <block type="get_value" id="FrcZZNPN%#R(^G6NN|LM">
                                        <field name="ATTR">val</field>
                                        <field name="OID">sonoff.0.Badezimmerlicht.POWER</field>
                                      </block>
                                    </value>
                                    <statement name="DO0">
                                      <block type="control" id="$86HuP~`N{LaY4I7md,3">
                                        <mutation xmlns="http://www.w3.org/1999/xhtml" delay_input="false"></mutation>
                                        <field name="OID">sonoff.0.Badezimmerlicht.POWER</field>
                                        <field name="WITH_DELAY">FALSE</field>
                                        <value name="VALUE">
                                          <block type="logic_boolean" id="1UP*Me:;gW3cC?+vbh94">
                                            <field name="BOOL">FALSE</field>
                                          </block>
                                        </value>
                                      </block>
                                    </statement>
                                  </block>
                                </next>
                              </block>
                            </statement>
                          </block>
                        </statement>
                      </block>
                    </next>
                  </block>
                </statement>
                <next>
                  <block type="comment" id="#NX^q_VjK@F9iUWAWPA}">
                    <field name="COMMENT">Tür öffnet</field>
                    <next>
                      <block type="on_ext" id="/V]t?I@Gjkc^eMR_n#)|">
                        <mutation xmlns="http://www.w3.org/1999/xhtml" items="1"></mutation>
                        <field name="CONDITION">gt</field>
                        <field name="ACK_CONDITION"></field>
                        <value name="OID0">
                          <shadow type="field_oid" id="z.rf;Ppk-,EU=pVr7wQN">
                            <field name="oid">deconz.0.Sensors.5.open</field>
                          </shadow>
                        </value>
                        <statement name="STATEMENT">
                          <block type="comment" id="S+(!XQne8~@_%_R_(8!Q">
                            <field name="COMMENT">dunkel und Licht aus?</field>
                            <next>
                              <block type="controls_if" id="!muI`Yamueo@M|l(k(*v">
                                <value name="IF0">
                                  <block type="logic_operation" id="F[YWS@t_RdTz=1pg)U=J" inline="false">
                                    <field name="OP">AND</field>
                                    <value name="A">
                                      <block type="logic_negate" id="iUk6};go{0_ftNa[9VUb">
                                        <value name="BOOL">
                                          <block type="get_value" id="2NG.@e5:!/WW%;U$]|v`">
                                            <field name="ATTR">val</field>
                                            <field name="OID">deconz.0.Sensors.1.daylight</field>
                                          </block>
                                        </value>
                                      </block>
                                    </value>
                                    <value name="B">
                                      <block type="logic_negate" id="QzU)|^M:2SQsEF%CPjDi">
                                        <value name="BOOL">
                                          <block type="get_value" id="+gD/U?X!ZU|7OJiYPclr">
                                            <field name="ATTR">val</field>
                                            <field name="OID">sonoff.0.Badezimmerlicht.POWER</field>
                                          </block>
                                        </value>
                                      </block>
                                    </value>
                                  </block>
                                </value>
                                <statement name="DO0">
                                  <block type="control" id=":TjQf-tu@Q#kgie^P)@o">
                                    <mutation xmlns="http://www.w3.org/1999/xhtml" delay_input="false"></mutation>
                                    <field name="OID">sonoff.0.Badezimmerlicht.POWER</field>
                                    <field name="WITH_DELAY">FALSE</field>
                                    <value name="VALUE">
                                      <block type="logic_boolean" id="*ClGOYPry2taM^E+%*n#">
                                        <field name="BOOL">TRUE</field>
                                      </block>
                                    </value>
                                  </block>
                                </statement>
                                <next>
                                  <block type="variables_set" id="Yv+SY!mIdF7[u6`DuzRn">
                                    <field name="VAR" id="#?8llkQ_(?e?!}{7|0%B">duschen</field>
                                    <value name="VALUE">
                                      <block type="logic_boolean" id="7{xAyMA5Inv$Sj56J$Xs">
                                        <field name="BOOL">FALSE</field>
                                      </block>
                                    </value>
                                  </block>
                                </next>
                              </block>
                            </next>
                          </block>
                        </statement>
                      </block>
                    </next>
                  </block>
                </next>
              </block>
            </next>
          </block>
        </next>
      </block>
    </xml>
    

    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

    padrinoP 1 Antwort Letzte Antwort
    0
    • paul53P paul53

      @Sanweb
      Versuche es mal so:

      Blockly_temp.JPG

      <xml xmlns="https://developers.google.com/blockly/xml">
        <variables>
          <variable id="#?8llkQ_(?e?!}{7|0%B">duschen</variable>
          <variable type="timeout" id="timeout">timeout</variable>
        </variables>
        <block type="on_ext" id="JT^Sb~%?woKrqm#,_x?/" x="780" y="-2572">
          <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="g+hFwJ/p}d6]YQ~EspD*">
              <field name="oid">default</field>
            </shadow>
            <block type="text" id="K:Nj#+xP3L91=WcyB3vk">
              <field name="TEXT">deconz.0.Sensors.15.buttonevent</field>
            </block>
          </value>
          <statement name="STATEMENT">
            <block type="controls_if" id="5t#hR+Cr;XhCLt708]?;">
              <value name="IF0">
                <block type="logic_compare" id="*0/lSkBjPe!Q0-7A]`}t">
                  <field name="OP">EQ</field>
                  <value name="A">
                    <block type="on_source" id="p;(Kh@GTK/#PhbUs|2Fk">
                      <field name="ATTR">state.val</field>
                    </block>
                  </value>
                  <value name="B">
                    <block type="math_number" id="L}L-PyHNK43~ZBR#G]Yv">
                      <field name="NUM">1002</field>
                    </block>
                  </value>
                </block>
              </value>
              <statement name="DO0">
                <block type="timeouts_cleartimeout" id="jv6hg}OB#s?,w0H*NI_d">
                  <field name="NAME">timeout</field>
                  <next>
                    <block type="variables_set" id="IQn)a22MZbX!@$BeNSbo">
                      <field name="VAR" id="#?8llkQ_(?e?!}{7|0%B">duschen</field>
                      <value name="VALUE">
                        <block type="logic_boolean" id=",=d^~(K|T,0?]S978@zB">
                          <field name="BOOL">TRUE</field>
                        </block>
                      </value>
                    </block>
                  </next>
                </block>
              </statement>
            </block>
          </statement>
          <next>
            <block type="comment" id="j^MxUgu8?7{mlu]rA:Tf">
              <field name="COMMENT">Bewegung</field>
              <next>
                <block type="on_ext" id="Vo2d_MmTq==sR.4ZWR$O">
                  <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="Czsj]a1TUk|+~h~ORP[b">
                      <field name="oid">deconz.0.Sensors.2.presence</field>
                    </shadow>
                  </value>
                  <statement name="STATEMENT">
                    <block type="timeouts_cleartimeout" id=".AnY7,uE8z6%68I_9r!J">
                      <field name="NAME">timeout</field>
                      <next>
                        <block type="controls_if" id="+RZ{~*8u`F-{891w*mat">
                          <value name="IF0">
                            <block type="logic_operation" id="WMPSk~z%).|`E/DHlrcn" inline="false">
                              <field name="OP">AND</field>
                              <value name="A">
                                <block type="logic_negate" id="C4LtUkpka$={[9/VCOva">
                                  <value name="BOOL">
                                    <block type="on_source" id="+d+_sgAE*[8U#u/8-`=!">
                                      <field name="ATTR">state.val</field>
                                    </block>
                                  </value>
                                </block>
                              </value>
                              <value name="B">
                                <block type="logic_negate" id="W1{FG$?i1lP8NHMpEzzu">
                                  <value name="BOOL">
                                    <block type="variables_get" id="B^v6/7~q9mb|4}(2Qk$c">
                                      <field name="VAR" id="#?8llkQ_(?e?!}{7|0%B">duschen</field>
                                    </block>
                                  </value>
                                </block>
                              </value>
                            </block>
                          </value>
                          <statement name="DO0">
                            <block type="timeouts_settimeout" id="b8c{g!jXe$]dFOh^QXP[">
                              <field name="NAME">timeout</field>
                              <field name="DELAY">30</field>
                              <field name="UNIT">sec</field>
                              <statement name="STATEMENT">
                                <block type="comment" id="vvNPR8V{Zt(;|2~TmxfO">
                                  <field name="COMMENT">Licht ein?</field>
                                  <next>
                                    <block type="controls_if" id="ub/zHL/V?|rXYe|9Al6y">
                                      <value name="IF0">
                                        <block type="get_value" id="FrcZZNPN%#R(^G6NN|LM">
                                          <field name="ATTR">val</field>
                                          <field name="OID">sonoff.0.Badezimmerlicht.POWER</field>
                                        </block>
                                      </value>
                                      <statement name="DO0">
                                        <block type="control" id="$86HuP~`N{LaY4I7md,3">
                                          <mutation xmlns="http://www.w3.org/1999/xhtml" delay_input="false"></mutation>
                                          <field name="OID">sonoff.0.Badezimmerlicht.POWER</field>
                                          <field name="WITH_DELAY">FALSE</field>
                                          <value name="VALUE">
                                            <block type="logic_boolean" id="1UP*Me:;gW3cC?+vbh94">
                                              <field name="BOOL">FALSE</field>
                                            </block>
                                          </value>
                                        </block>
                                      </statement>
                                    </block>
                                  </next>
                                </block>
                              </statement>
                            </block>
                          </statement>
                        </block>
                      </next>
                    </block>
                  </statement>
                  <next>
                    <block type="comment" id="#NX^q_VjK@F9iUWAWPA}">
                      <field name="COMMENT">Tür öffnet</field>
                      <next>
                        <block type="on_ext" id="/V]t?I@Gjkc^eMR_n#)|">
                          <mutation xmlns="http://www.w3.org/1999/xhtml" items="1"></mutation>
                          <field name="CONDITION">gt</field>
                          <field name="ACK_CONDITION"></field>
                          <value name="OID0">
                            <shadow type="field_oid" id="z.rf;Ppk-,EU=pVr7wQN">
                              <field name="oid">deconz.0.Sensors.5.open</field>
                            </shadow>
                          </value>
                          <statement name="STATEMENT">
                            <block type="comment" id="S+(!XQne8~@_%_R_(8!Q">
                              <field name="COMMENT">dunkel und Licht aus?</field>
                              <next>
                                <block type="controls_if" id="!muI`Yamueo@M|l(k(*v">
                                  <value name="IF0">
                                    <block type="logic_operation" id="F[YWS@t_RdTz=1pg)U=J" inline="false">
                                      <field name="OP">AND</field>
                                      <value name="A">
                                        <block type="logic_negate" id="iUk6};go{0_ftNa[9VUb">
                                          <value name="BOOL">
                                            <block type="get_value" id="2NG.@e5:!/WW%;U$]|v`">
                                              <field name="ATTR">val</field>
                                              <field name="OID">deconz.0.Sensors.1.daylight</field>
                                            </block>
                                          </value>
                                        </block>
                                      </value>
                                      <value name="B">
                                        <block type="logic_negate" id="QzU)|^M:2SQsEF%CPjDi">
                                          <value name="BOOL">
                                            <block type="get_value" id="+gD/U?X!ZU|7OJiYPclr">
                                              <field name="ATTR">val</field>
                                              <field name="OID">sonoff.0.Badezimmerlicht.POWER</field>
                                            </block>
                                          </value>
                                        </block>
                                      </value>
                                    </block>
                                  </value>
                                  <statement name="DO0">
                                    <block type="control" id=":TjQf-tu@Q#kgie^P)@o">
                                      <mutation xmlns="http://www.w3.org/1999/xhtml" delay_input="false"></mutation>
                                      <field name="OID">sonoff.0.Badezimmerlicht.POWER</field>
                                      <field name="WITH_DELAY">FALSE</field>
                                      <value name="VALUE">
                                        <block type="logic_boolean" id="*ClGOYPry2taM^E+%*n#">
                                          <field name="BOOL">TRUE</field>
                                        </block>
                                      </value>
                                    </block>
                                  </statement>
                                  <next>
                                    <block type="variables_set" id="Yv+SY!mIdF7[u6`DuzRn">
                                      <field name="VAR" id="#?8llkQ_(?e?!}{7|0%B">duschen</field>
                                      <value name="VALUE">
                                        <block type="logic_boolean" id="7{xAyMA5Inv$Sj56J$Xs">
                                          <field name="BOOL">FALSE</field>
                                        </block>
                                      </value>
                                    </block>
                                  </next>
                                </block>
                              </next>
                            </block>
                          </statement>
                        </block>
                      </next>
                    </block>
                  </next>
                </block>
              </next>
            </block>
          </next>
        </block>
      </xml>
      

      padrinoP Offline
      padrinoP Offline
      padrino
      Most Active
      schrieb am zuletzt editiert von
      #19

      @paul53
      Passt meins nicht? 🤔😔

      paul53P 1 Antwort Letzte Antwort
      0
      • padrinoP padrino

        @paul53
        Passt meins nicht? 🤔😔

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

        @padrino sagte:

        Passt meins nicht?

        Wenn das stimmt ?

        @padrino sagte in [Gelöst] HUE Motion Sensor Lampe an/aus -> Problem Haustier:

        Wenn Du drückst und der Wert war "1002" ist er danach immer noch "1002" - wenn auch "aktualisiert".

        , dann nicht.

        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

        padrinoP 1 Antwort Letzte Antwort
        0
        • paul53P paul53

          @padrino sagte:

          Passt meins nicht?

          Wenn das stimmt ?

          @padrino sagte in [Gelöst] HUE Motion Sensor Lampe an/aus -> Problem Haustier:

          Wenn Du drückst und der Wert war "1002" ist er danach immer noch "1002" - wenn auch "aktualisiert".

          , dann nicht.

          padrinoP Offline
          padrinoP Offline
          padrino
          Most Active
          schrieb am zuletzt editiert von padrino
          #21

          @paul53
          Ich war doch schon weiter. ;)
          Aber es interessiert mich, lerne gerne (aus Fehlern). :relieved:

          SanwebS 1 Antwort Letzte Antwort
          0
          • padrinoP padrino

            @paul53
            Ich war doch schon weiter. ;)
            Aber es interessiert mich, lerne gerne (aus Fehlern). :relieved:

            SanwebS Offline
            SanwebS Offline
            Sanweb
            schrieb am zuletzt editiert von Sanweb
            #22

            @padrino @paul53

            Beide Scripte funktionieren leider nicht. Ich habe beide Scripte erstellt und als erstes erst einmal getestet, wenn ich die Tür auf und zu mache, ob das Licht an geht und sich nach dem Timeout wieder ausschaltet. Ergebnis war: Tür ging auf und zu, Licht ging an und nicht wieder aus ... Der Datenpunkt von "Buttonevent" stand vor öffnen der Tür auf 1002, auch wenn ich ihn händisch mal auf 0 setze, ist das Ergebnis gleich, das Licht geht nicht wieder aus bei Tür auf und zu machen ohne Nutzung des Buttons.

            Badezimmer_7.jpg

            <xml xmlns="https://developers.google.com/blockly/xml">
              <variables>
                <variable id="#?8llkQ_(?e?!}{7|0%B">duschen</variable>
                <variable type="timeout" id="timeout">timeout</variable>
              </variables>
              <block type="comment" id="^H8S@6|A=FINJo802%?S" x="788" y="-2612">
                <field name="COMMENT">Button</field>
                <next>
                  <block type="on_ext" id="JT^Sb~%?woKrqm#,_x?/">
                    <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="g+hFwJ/p}d6]YQ~EspD*">
                        <field name="oid">deconz.0.Sensors.15.buttonevent</field>
                      </shadow>
                    </value>
                    <statement name="STATEMENT">
                      <block type="controls_if" id="5t#hR+Cr;XhCLt708]?;">
                        <value name="IF0">
                          <block type="logic_compare" id="*0/lSkBjPe!Q0-7A]`}t">
                            <field name="OP">EQ</field>
                            <value name="A">
                              <block type="on_source" id="p;(Kh@GTK/#PhbUs|2Fk">
                                <field name="ATTR">state.val</field>
                              </block>
                            </value>
                            <value name="B">
                              <block type="math_number" id="L}L-PyHNK43~ZBR#G]Yv">
                                <field name="NUM">1002</field>
                              </block>
                            </value>
                          </block>
                        </value>
                        <statement name="DO0">
                          <block type="timeouts_cleartimeout" id="jv6hg}OB#s?,w0H*NI_d">
                            <field name="NAME">timeout</field>
                            <next>
                              <block type="variables_set" id="IQn)a22MZbX!@$BeNSbo">
                                <field name="VAR" id="#?8llkQ_(?e?!}{7|0%B">duschen</field>
                                <value name="VALUE">
                                  <block type="logic_boolean" id=",=d^~(K|T,0?]S978@zB">
                                    <field name="BOOL">TRUE</field>
                                  </block>
                                </value>
                              </block>
                            </next>
                          </block>
                        </statement>
                      </block>
                    </statement>
                    <next>
                      <block type="comment" id="j^MxUgu8?7{mlu]rA:Tf">
                        <field name="COMMENT">Bewegung</field>
                        <next>
                          <block type="on_ext" id="Vo2d_MmTq==sR.4ZWR$O">
                            <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="Czsj]a1TUk|+~h~ORP[b">
                                <field name="oid">deconz.0.Sensors.2.presence</field>
                              </shadow>
                            </value>
                            <statement name="STATEMENT">
                              <block type="timeouts_cleartimeout" id=".AnY7,uE8z6%68I_9r!J">
                                <field name="NAME">timeout</field>
                                <next>
                                  <block type="controls_if" id="+RZ{~*8u`F-{891w*mat">
                                    <value name="IF0">
                                      <block type="logic_operation" id="WMPSk~z%).|`E/DHlrcn" inline="false">
                                        <field name="OP">AND</field>
                                        <value name="A">
                                          <block type="logic_negate" id="C4LtUkpka$={[9/VCOva">
                                            <value name="BOOL">
                                              <block type="on_source" id="+d+_sgAE*[8U#u/8-`=!">
                                                <field name="ATTR">state.val</field>
                                              </block>
                                            </value>
                                          </block>
                                        </value>
                                        <value name="B">
                                          <block type="logic_negate" id="W1{FG$?i1lP8NHMpEzzu">
                                            <value name="BOOL">
                                              <block type="variables_get" id="B^v6/7~q9mb|4}(2Qk$c">
                                                <field name="VAR" id="#?8llkQ_(?e?!}{7|0%B">duschen</field>
                                              </block>
                                            </value>
                                          </block>
                                        </value>
                                      </block>
                                    </value>
                                    <statement name="DO0">
                                      <block type="timeouts_settimeout" id="b8c{g!jXe$]dFOh^QXP[">
                                        <field name="NAME">timeout</field>
                                        <field name="DELAY">30</field>
                                        <field name="UNIT">sec</field>
                                        <statement name="STATEMENT">
                                          <block type="comment" id="vvNPR8V{Zt(;|2~TmxfO">
                                            <field name="COMMENT">Licht ein?</field>
                                            <next>
                                              <block type="controls_if" id="ub/zHL/V?|rXYe|9Al6y">
                                                <value name="IF0">
                                                  <block type="get_value" id="FrcZZNPN%#R(^G6NN|LM">
                                                    <field name="ATTR">val</field>
                                                    <field name="OID">sonoff.0.Badezimmerlicht.POWER</field>
                                                  </block>
                                                </value>
                                                <statement name="DO0">
                                                  <block type="control" id="$86HuP~`N{LaY4I7md,3">
                                                    <mutation xmlns="http://www.w3.org/1999/xhtml" delay_input="false"></mutation>
                                                    <field name="OID">sonoff.0.Badezimmerlicht.POWER</field>
                                                    <field name="WITH_DELAY">FALSE</field>
                                                    <value name="VALUE">
                                                      <block type="logic_boolean" id="1UP*Me:;gW3cC?+vbh94">
                                                        <field name="BOOL">FALSE</field>
                                                      </block>
                                                    </value>
                                                  </block>
                                                </statement>
                                              </block>
                                            </next>
                                          </block>
                                        </statement>
                                      </block>
                                    </statement>
                                  </block>
                                </next>
                              </block>
                            </statement>
                            <next>
                              <block type="comment" id="#NX^q_VjK@F9iUWAWPA}">
                                <field name="COMMENT">Tür öffnet</field>
                                <next>
                                  <block type="on_ext" id="/V]t?I@Gjkc^eMR_n#)|">
                                    <mutation xmlns="http://www.w3.org/1999/xhtml" items="1"></mutation>
                                    <field name="CONDITION">gt</field>
                                    <field name="ACK_CONDITION"></field>
                                    <value name="OID0">
                                      <shadow type="field_oid" id="z.rf;Ppk-,EU=pVr7wQN">
                                        <field name="oid">deconz.0.Sensors.5.open</field>
                                      </shadow>
                                    </value>
                                    <statement name="STATEMENT">
                                      <block type="comment" id="S+(!XQne8~@_%_R_(8!Q">
                                        <field name="COMMENT">dunkel und Licht aus?</field>
                                        <next>
                                          <block type="controls_if" id="!muI`Yamueo@M|l(k(*v">
                                            <value name="IF0">
                                              <block type="logic_operation" id="F[YWS@t_RdTz=1pg)U=J" inline="false">
                                                <field name="OP">AND</field>
                                                <value name="A">
                                                  <block type="logic_negate" id="iUk6};go{0_ftNa[9VUb">
                                                    <value name="BOOL">
                                                      <block type="get_value" id="2NG.@e5:!/WW%;U$]|v`">
                                                        <field name="ATTR">val</field>
                                                        <field name="OID">deconz.0.Sensors.1.daylight</field>
                                                      </block>
                                                    </value>
                                                  </block>
                                                </value>
                                                <value name="B">
                                                  <block type="logic_negate" id="QzU)|^M:2SQsEF%CPjDi">
                                                    <value name="BOOL">
                                                      <block type="get_value" id="+gD/U?X!ZU|7OJiYPclr">
                                                        <field name="ATTR">val</field>
                                                        <field name="OID">sonoff.0.Badezimmerlicht.POWER</field>
                                                      </block>
                                                    </value>
                                                  </block>
                                                </value>
                                              </block>
                                            </value>
                                            <statement name="DO0">
                                              <block type="control" id=":TjQf-tu@Q#kgie^P)@o">
                                                <mutation xmlns="http://www.w3.org/1999/xhtml" delay_input="false"></mutation>
                                                <field name="OID">sonoff.0.Badezimmerlicht.POWER</field>
                                                <field name="WITH_DELAY">FALSE</field>
                                                <value name="VALUE">
                                                  <block type="logic_boolean" id="*ClGOYPry2taM^E+%*n#">
                                                    <field name="BOOL">TRUE</field>
                                                  </block>
                                                </value>
                                              </block>
                                            </statement>
                                            <next>
                                              <block type="variables_set" id="Yv+SY!mIdF7[u6`DuzRn">
                                                <field name="VAR" id="#?8llkQ_(?e?!}{7|0%B">duschen</field>
                                                <value name="VALUE">
                                                  <block type="logic_boolean" id="7{xAyMA5Inv$Sj56J$Xs">
                                                    <field name="BOOL">FALSE</field>
                                                  </block>
                                                </value>
                                              </block>
                                            </next>
                                          </block>
                                        </next>
                                      </block>
                                    </statement>
                                  </block>
                                </next>
                              </block>
                            </next>
                          </block>
                        </next>
                      </block>
                    </next>
                  </block>
                </next>
              </block>
            </xml>
            

            paul53P 1 Antwort Letzte Antwort
            0
            • SanwebS Sanweb

              @padrino @paul53

              Beide Scripte funktionieren leider nicht. Ich habe beide Scripte erstellt und als erstes erst einmal getestet, wenn ich die Tür auf und zu mache, ob das Licht an geht und sich nach dem Timeout wieder ausschaltet. Ergebnis war: Tür ging auf und zu, Licht ging an und nicht wieder aus ... Der Datenpunkt von "Buttonevent" stand vor öffnen der Tür auf 1002, auch wenn ich ihn händisch mal auf 0 setze, ist das Ergebnis gleich, das Licht geht nicht wieder aus bei Tür auf und zu machen ohne Nutzung des Buttons.

              Badezimmer_7.jpg

              <xml xmlns="https://developers.google.com/blockly/xml">
                <variables>
                  <variable id="#?8llkQ_(?e?!}{7|0%B">duschen</variable>
                  <variable type="timeout" id="timeout">timeout</variable>
                </variables>
                <block type="comment" id="^H8S@6|A=FINJo802%?S" x="788" y="-2612">
                  <field name="COMMENT">Button</field>
                  <next>
                    <block type="on_ext" id="JT^Sb~%?woKrqm#,_x?/">
                      <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="g+hFwJ/p}d6]YQ~EspD*">
                          <field name="oid">deconz.0.Sensors.15.buttonevent</field>
                        </shadow>
                      </value>
                      <statement name="STATEMENT">
                        <block type="controls_if" id="5t#hR+Cr;XhCLt708]?;">
                          <value name="IF0">
                            <block type="logic_compare" id="*0/lSkBjPe!Q0-7A]`}t">
                              <field name="OP">EQ</field>
                              <value name="A">
                                <block type="on_source" id="p;(Kh@GTK/#PhbUs|2Fk">
                                  <field name="ATTR">state.val</field>
                                </block>
                              </value>
                              <value name="B">
                                <block type="math_number" id="L}L-PyHNK43~ZBR#G]Yv">
                                  <field name="NUM">1002</field>
                                </block>
                              </value>
                            </block>
                          </value>
                          <statement name="DO0">
                            <block type="timeouts_cleartimeout" id="jv6hg}OB#s?,w0H*NI_d">
                              <field name="NAME">timeout</field>
                              <next>
                                <block type="variables_set" id="IQn)a22MZbX!@$BeNSbo">
                                  <field name="VAR" id="#?8llkQ_(?e?!}{7|0%B">duschen</field>
                                  <value name="VALUE">
                                    <block type="logic_boolean" id=",=d^~(K|T,0?]S978@zB">
                                      <field name="BOOL">TRUE</field>
                                    </block>
                                  </value>
                                </block>
                              </next>
                            </block>
                          </statement>
                        </block>
                      </statement>
                      <next>
                        <block type="comment" id="j^MxUgu8?7{mlu]rA:Tf">
                          <field name="COMMENT">Bewegung</field>
                          <next>
                            <block type="on_ext" id="Vo2d_MmTq==sR.4ZWR$O">
                              <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="Czsj]a1TUk|+~h~ORP[b">
                                  <field name="oid">deconz.0.Sensors.2.presence</field>
                                </shadow>
                              </value>
                              <statement name="STATEMENT">
                                <block type="timeouts_cleartimeout" id=".AnY7,uE8z6%68I_9r!J">
                                  <field name="NAME">timeout</field>
                                  <next>
                                    <block type="controls_if" id="+RZ{~*8u`F-{891w*mat">
                                      <value name="IF0">
                                        <block type="logic_operation" id="WMPSk~z%).|`E/DHlrcn" inline="false">
                                          <field name="OP">AND</field>
                                          <value name="A">
                                            <block type="logic_negate" id="C4LtUkpka$={[9/VCOva">
                                              <value name="BOOL">
                                                <block type="on_source" id="+d+_sgAE*[8U#u/8-`=!">
                                                  <field name="ATTR">state.val</field>
                                                </block>
                                              </value>
                                            </block>
                                          </value>
                                          <value name="B">
                                            <block type="logic_negate" id="W1{FG$?i1lP8NHMpEzzu">
                                              <value name="BOOL">
                                                <block type="variables_get" id="B^v6/7~q9mb|4}(2Qk$c">
                                                  <field name="VAR" id="#?8llkQ_(?e?!}{7|0%B">duschen</field>
                                                </block>
                                              </value>
                                            </block>
                                          </value>
                                        </block>
                                      </value>
                                      <statement name="DO0">
                                        <block type="timeouts_settimeout" id="b8c{g!jXe$]dFOh^QXP[">
                                          <field name="NAME">timeout</field>
                                          <field name="DELAY">30</field>
                                          <field name="UNIT">sec</field>
                                          <statement name="STATEMENT">
                                            <block type="comment" id="vvNPR8V{Zt(;|2~TmxfO">
                                              <field name="COMMENT">Licht ein?</field>
                                              <next>
                                                <block type="controls_if" id="ub/zHL/V?|rXYe|9Al6y">
                                                  <value name="IF0">
                                                    <block type="get_value" id="FrcZZNPN%#R(^G6NN|LM">
                                                      <field name="ATTR">val</field>
                                                      <field name="OID">sonoff.0.Badezimmerlicht.POWER</field>
                                                    </block>
                                                  </value>
                                                  <statement name="DO0">
                                                    <block type="control" id="$86HuP~`N{LaY4I7md,3">
                                                      <mutation xmlns="http://www.w3.org/1999/xhtml" delay_input="false"></mutation>
                                                      <field name="OID">sonoff.0.Badezimmerlicht.POWER</field>
                                                      <field name="WITH_DELAY">FALSE</field>
                                                      <value name="VALUE">
                                                        <block type="logic_boolean" id="1UP*Me:;gW3cC?+vbh94">
                                                          <field name="BOOL">FALSE</field>
                                                        </block>
                                                      </value>
                                                    </block>
                                                  </statement>
                                                </block>
                                              </next>
                                            </block>
                                          </statement>
                                        </block>
                                      </statement>
                                    </block>
                                  </next>
                                </block>
                              </statement>
                              <next>
                                <block type="comment" id="#NX^q_VjK@F9iUWAWPA}">
                                  <field name="COMMENT">Tür öffnet</field>
                                  <next>
                                    <block type="on_ext" id="/V]t?I@Gjkc^eMR_n#)|">
                                      <mutation xmlns="http://www.w3.org/1999/xhtml" items="1"></mutation>
                                      <field name="CONDITION">gt</field>
                                      <field name="ACK_CONDITION"></field>
                                      <value name="OID0">
                                        <shadow type="field_oid" id="z.rf;Ppk-,EU=pVr7wQN">
                                          <field name="oid">deconz.0.Sensors.5.open</field>
                                        </shadow>
                                      </value>
                                      <statement name="STATEMENT">
                                        <block type="comment" id="S+(!XQne8~@_%_R_(8!Q">
                                          <field name="COMMENT">dunkel und Licht aus?</field>
                                          <next>
                                            <block type="controls_if" id="!muI`Yamueo@M|l(k(*v">
                                              <value name="IF0">
                                                <block type="logic_operation" id="F[YWS@t_RdTz=1pg)U=J" inline="false">
                                                  <field name="OP">AND</field>
                                                  <value name="A">
                                                    <block type="logic_negate" id="iUk6};go{0_ftNa[9VUb">
                                                      <value name="BOOL">
                                                        <block type="get_value" id="2NG.@e5:!/WW%;U$]|v`">
                                                          <field name="ATTR">val</field>
                                                          <field name="OID">deconz.0.Sensors.1.daylight</field>
                                                        </block>
                                                      </value>
                                                    </block>
                                                  </value>
                                                  <value name="B">
                                                    <block type="logic_negate" id="QzU)|^M:2SQsEF%CPjDi">
                                                      <value name="BOOL">
                                                        <block type="get_value" id="+gD/U?X!ZU|7OJiYPclr">
                                                          <field name="ATTR">val</field>
                                                          <field name="OID">sonoff.0.Badezimmerlicht.POWER</field>
                                                        </block>
                                                      </value>
                                                    </block>
                                                  </value>
                                                </block>
                                              </value>
                                              <statement name="DO0">
                                                <block type="control" id=":TjQf-tu@Q#kgie^P)@o">
                                                  <mutation xmlns="http://www.w3.org/1999/xhtml" delay_input="false"></mutation>
                                                  <field name="OID">sonoff.0.Badezimmerlicht.POWER</field>
                                                  <field name="WITH_DELAY">FALSE</field>
                                                  <value name="VALUE">
                                                    <block type="logic_boolean" id="*ClGOYPry2taM^E+%*n#">
                                                      <field name="BOOL">TRUE</field>
                                                    </block>
                                                  </value>
                                                </block>
                                              </statement>
                                              <next>
                                                <block type="variables_set" id="Yv+SY!mIdF7[u6`DuzRn">
                                                  <field name="VAR" id="#?8llkQ_(?e?!}{7|0%B">duschen</field>
                                                  <value name="VALUE">
                                                    <block type="logic_boolean" id="7{xAyMA5Inv$Sj56J$Xs">
                                                      <field name="BOOL">FALSE</field>
                                                    </block>
                                                  </value>
                                                </block>
                                              </next>
                                            </block>
                                          </next>
                                        </block>
                                      </statement>
                                    </block>
                                  </next>
                                </block>
                              </next>
                            </block>
                          </next>
                        </block>
                      </next>
                    </block>
                  </next>
                </block>
              </xml>
              

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

              @Sanweb sagte:

              das Licht geht nicht wieder aus bei Tür auf und zu machen ohne Nutzung des Buttons.

              Dann logge mal das Verhalten von "buttonevent" mit einem Debug output Wert vor der Abfrage auf Wert == 1002.

              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
              0
              • SanwebS Sanweb

                @padrino
                Hab es eben einmal ausprobiert und das Script soweit geändert, das ich die Variable nun weg gelassen habe und nun direkt mit dem Wert vergleiche.

                Der Datenpunkt "buttonpressed" steht stets IMMER auf 0, sofern KEINE Aktion mit dem Button erfolgt. Erst wenn der Button z.B. kurz gedrückt wird, springt er von "0" auf "1002" und dann wieder automatisch zurück auf "0". Also "1002" wird von Beginn bis Ende des "Drückvorganges" gesetzt, wird zu lange gedrückt, erscheint der Wert "1003".

                Bei diesem Verhalten musste ich davon ausgehen, das sich der Wert "wird ändert" von Objekt ID "Sensor 15 buttonpressed" so korrekt erst einmal ist.

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

                @Sanweb sagte:

                Der Datenpunkt "buttonpressed" steht stets IMMER auf 0, sofern KEINE Aktion mit dem Button erfolgt. Erst wenn der Button z.B. kurz gedrückt wird, springt er von "0" auf "1002" und dann wieder automatisch zurück auf "0". Also "1002" wird von Beginn bis Ende des "Drückvorganges" gesetzt, wird zu lange gedrückt, erscheint der Wert "1003".

                Das widerspricht der Aussage:
                @Sanweb sagte in [Gelöst] HUE Motion Sensor Lampe an/aus -> Problem Haustier:

                Der Datenpunkt von "Buttonevent" stand vor öffnen der Tür auf 1002,

                Ich habe irgendwo gelesen, dass 1002 "loslassen" und 1000 "drücken" entspricht. Dann müsste mit 1000 verglichen werden.

                EDIT: Kann man nicht Release after press verwenden ?

                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

                SanwebS 1 Antwort Letzte Antwort
                0
                • paul53P paul53

                  @Sanweb sagte:

                  Der Datenpunkt "buttonpressed" steht stets IMMER auf 0, sofern KEINE Aktion mit dem Button erfolgt. Erst wenn der Button z.B. kurz gedrückt wird, springt er von "0" auf "1002" und dann wieder automatisch zurück auf "0". Also "1002" wird von Beginn bis Ende des "Drückvorganges" gesetzt, wird zu lange gedrückt, erscheint der Wert "1003".

                  Das widerspricht der Aussage:
                  @Sanweb sagte in [Gelöst] HUE Motion Sensor Lampe an/aus -> Problem Haustier:

                  Der Datenpunkt von "Buttonevent" stand vor öffnen der Tür auf 1002,

                  Ich habe irgendwo gelesen, dass 1002 "loslassen" und 1000 "drücken" entspricht. Dann müsste mit 1000 verglichen werden.

                  EDIT: Kann man nicht Release after press verwenden ?

                  Blockly_temp.JPG

                  SanwebS Offline
                  SanwebS Offline
                  Sanweb
                  schrieb am zuletzt editiert von Sanweb
                  #25

                  @paul53
                  es Widerspricht nicht meiner Aussage, da ich in meinem Beitrag z.B. vom 18.08. z.B. den Datenpunkt "sensor 15 buttonpressed" zuerst benutzt hatte, welcher nicht stehen blieb und beim drücken den Wert "1002" gab und beim los lassen den Wert "0" widergab. Da ich mit diesem "gespringe" nicht zurecht kam, schrieb ich am 20.08., das ich auf den manipulierbaren Datenpunkt "Sensor 15 buttonevent" gewechselt bin. Diesen Datenpunkt hast Du auch in Deinem Scriptvorschlag ja auch benutzt.

                  Habe eben einmal das Script auf den alten Datenpunkt "Sensor 15 buttonpressed" abgeändert und neu gestestet. Den Datenpunkt " ... release_press" wäre sicherlich auch verwendbar, der wird aber so schnell von iobroker aktuallisiert, das ich auf Anhie nicht sagen könnte, ob er überhaupt auf "true" gestanden hat .... :grinning:

                  Müsste ich dennoch jetzt vergleichen, ob "1002" oder "0" steht, da nun "Objekt wurde aktuallisiert" benutzt wird? DA es funktioniert, wohl offenbar nicht ...

                  Funktioniert jetzt tadellos wie es soll. Vielen Dank für deine/eure Hilfe.

                  Lieber Paul, bei Dir bin ich mittlerweile sehr erstaunt, wie Du Dir "mal eben so" die ganzen Scripte anscheinend regelrecht aus dem "Ärmel schüttelst" ... :laughing: :clap:

                  "

                  paul53P 1 Antwort Letzte Antwort
                  0
                  • SanwebS Sanweb

                    @paul53
                    es Widerspricht nicht meiner Aussage, da ich in meinem Beitrag z.B. vom 18.08. z.B. den Datenpunkt "sensor 15 buttonpressed" zuerst benutzt hatte, welcher nicht stehen blieb und beim drücken den Wert "1002" gab und beim los lassen den Wert "0" widergab. Da ich mit diesem "gespringe" nicht zurecht kam, schrieb ich am 20.08., das ich auf den manipulierbaren Datenpunkt "Sensor 15 buttonevent" gewechselt bin. Diesen Datenpunkt hast Du auch in Deinem Scriptvorschlag ja auch benutzt.

                    Habe eben einmal das Script auf den alten Datenpunkt "Sensor 15 buttonpressed" abgeändert und neu gestestet. Den Datenpunkt " ... release_press" wäre sicherlich auch verwendbar, der wird aber so schnell von iobroker aktuallisiert, das ich auf Anhie nicht sagen könnte, ob er überhaupt auf "true" gestanden hat .... :grinning:

                    Müsste ich dennoch jetzt vergleichen, ob "1002" oder "0" steht, da nun "Objekt wurde aktuallisiert" benutzt wird? DA es funktioniert, wohl offenbar nicht ...

                    Funktioniert jetzt tadellos wie es soll. Vielen Dank für deine/eure Hilfe.

                    Lieber Paul, bei Dir bin ich mittlerweile sehr erstaunt, wie Du Dir "mal eben so" die ganzen Scripte anscheinend regelrecht aus dem "Ärmel schüttelst" ... :laughing: :clap:

                    "

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

                    @Sanweb sagte:

                    Funktioniert jetzt tadellos wie es soll.

                    Mit welchem Button-Datenpunkt ?

                    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

                    SanwebS 1 Antwort Letzte Antwort
                    0
                    • paul53P paul53

                      @Sanweb sagte:

                      Funktioniert jetzt tadellos wie es soll.

                      Mit welchem Button-Datenpunkt ?

                      SanwebS Offline
                      SanwebS Offline
                      Sanweb
                      schrieb am zuletzt editiert von Sanweb
                      #27

                      @paul53

                      Badezimmer_8.jpg

                      <xml xmlns="https://developers.google.com/blockly/xml">
                       <variables>
                         <variable id="#?8llkQ_(?e?!}{7|0%B">duschen</variable>
                         <variable type="timeout" id="timeout">timeout</variable>
                       </variables>
                       <block type="comment" id="^H8S@6|A=FINJo802%?S" x="788" y="-2612">
                         <field name="COMMENT">Button</field>
                         <next>
                           <block type="on_ext" id="JT^Sb~%?woKrqm#,_x?/">
                             <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="g+hFwJ/p}d6]YQ~EspD*">
                                 <field name="oid">deconz.0.Sensors.15.buttonpressed</field>
                               </shadow>
                             </value>
                             <statement name="STATEMENT">
                               <block type="controls_if" id="5t#hR+Cr;XhCLt708]?;">
                                 <value name="IF0">
                                   <block type="logic_compare" id="*0/lSkBjPe!Q0-7A]`}t">
                                     <field name="OP">EQ</field>
                                     <value name="A">
                                       <block type="on_source" id="p;(Kh@GTK/#PhbUs|2Fk">
                                         <field name="ATTR">state.val</field>
                                       </block>
                                     </value>
                                     <value name="B">
                                       <block type="math_number" id="L}L-PyHNK43~ZBR#G]Yv">
                                         <field name="NUM">1002</field>
                                       </block>
                                     </value>
                                   </block>
                                 </value>
                                 <statement name="DO0">
                                   <block type="timeouts_cleartimeout" id="jv6hg}OB#s?,w0H*NI_d">
                                     <field name="NAME">timeout</field>
                                     <next>
                                       <block type="variables_set" id="IQn)a22MZbX!@$BeNSbo">
                                         <field name="VAR" id="#?8llkQ_(?e?!}{7|0%B">duschen</field>
                                         <value name="VALUE">
                                           <block type="logic_boolean" id=",=d^~(K|T,0?]S978@zB">
                                             <field name="BOOL">TRUE</field>
                                           </block>
                                         </value>
                                       </block>
                                     </next>
                                   </block>
                                 </statement>
                               </block>
                             </statement>
                             <next>
                               <block type="comment" id="j^MxUgu8?7{mlu]rA:Tf">
                                 <field name="COMMENT">Bewegung</field>
                                 <next>
                                   <block type="on_ext" id="Vo2d_MmTq==sR.4ZWR$O">
                                     <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="Czsj]a1TUk|+~h~ORP[b">
                                         <field name="oid">deconz.0.Sensors.2.presence</field>
                                       </shadow>
                                     </value>
                                     <statement name="STATEMENT">
                                       <block type="timeouts_cleartimeout" id=".AnY7,uE8z6%68I_9r!J">
                                         <field name="NAME">timeout</field>
                                         <next>
                                           <block type="controls_if" id="+RZ{~*8u`F-{891w*mat">
                                             <value name="IF0">
                                               <block type="logic_operation" id="WMPSk~z%).|`E/DHlrcn" inline="false">
                                                 <field name="OP">AND</field>
                                                 <value name="A">
                                                   <block type="logic_negate" id="C4LtUkpka$={[9/VCOva">
                                                     <value name="BOOL">
                                                       <block type="on_source" id="+d+_sgAE*[8U#u/8-`=!">
                                                         <field name="ATTR">state.val</field>
                                                       </block>
                                                     </value>
                                                   </block>
                                                 </value>
                                                 <value name="B">
                                                   <block type="logic_negate" id="W1{FG$?i1lP8NHMpEzzu">
                                                     <value name="BOOL">
                                                       <block type="variables_get" id="B^v6/7~q9mb|4}(2Qk$c">
                                                         <field name="VAR" id="#?8llkQ_(?e?!}{7|0%B">duschen</field>
                                                       </block>
                                                     </value>
                                                   </block>
                                                 </value>
                                               </block>
                                             </value>
                                             <statement name="DO0">
                                               <block type="timeouts_settimeout" id="b8c{g!jXe$]dFOh^QXP[">
                                                 <field name="NAME">timeout</field>
                                                 <field name="DELAY">30</field>
                                                 <field name="UNIT">sec</field>
                                                 <statement name="STATEMENT">
                                                   <block type="comment" id="vvNPR8V{Zt(;|2~TmxfO">
                                                     <field name="COMMENT">Licht ein?</field>
                                                     <next>
                                                       <block type="controls_if" id="ub/zHL/V?|rXYe|9Al6y">
                                                         <value name="IF0">
                                                           <block type="get_value" id="FrcZZNPN%#R(^G6NN|LM">
                                                             <field name="ATTR">val</field>
                                                             <field name="OID">sonoff.0.Badezimmerlicht.POWER</field>
                                                           </block>
                                                         </value>
                                                         <statement name="DO0">
                                                           <block type="control" id="$86HuP~`N{LaY4I7md,3">
                                                             <mutation xmlns="http://www.w3.org/1999/xhtml" delay_input="false"></mutation>
                                                             <field name="OID">sonoff.0.Badezimmerlicht.POWER</field>
                                                             <field name="WITH_DELAY">FALSE</field>
                                                             <value name="VALUE">
                                                               <block type="logic_boolean" id="1UP*Me:;gW3cC?+vbh94">
                                                                 <field name="BOOL">FALSE</field>
                                                               </block>
                                                             </value>
                                                           </block>
                                                         </statement>
                                                       </block>
                                                     </next>
                                                   </block>
                                                 </statement>
                                               </block>
                                             </statement>
                                           </block>
                                         </next>
                                       </block>
                                     </statement>
                                     <next>
                                       <block type="comment" id="#NX^q_VjK@F9iUWAWPA}">
                                         <field name="COMMENT">Tür öffnet</field>
                                         <next>
                                           <block type="on_ext" id="/V]t?I@Gjkc^eMR_n#)|">
                                             <mutation xmlns="http://www.w3.org/1999/xhtml" items="1"></mutation>
                                             <field name="CONDITION">gt</field>
                                             <field name="ACK_CONDITION"></field>
                                             <value name="OID0">
                                               <shadow type="field_oid" id="z.rf;Ppk-,EU=pVr7wQN">
                                                 <field name="oid">deconz.0.Sensors.5.open</field>
                                               </shadow>
                                             </value>
                                             <statement name="STATEMENT">
                                               <block type="comment" id="S+(!XQne8~@_%_R_(8!Q">
                                                 <field name="COMMENT">dunkel und Licht aus?</field>
                                                 <next>
                                                   <block type="controls_if" id="!muI`Yamueo@M|l(k(*v">
                                                     <value name="IF0">
                                                       <block type="logic_operation" id="F[YWS@t_RdTz=1pg)U=J" inline="false">
                                                         <field name="OP">AND</field>
                                                         <value name="A">
                                                           <block type="logic_negate" id="iUk6};go{0_ftNa[9VUb">
                                                             <value name="BOOL">
                                                               <block type="get_value" id="2NG.@e5:!/WW%;U$]|v`">
                                                                 <field name="ATTR">val</field>
                                                                 <field name="OID">deconz.0.Sensors.1.dark</field>
                                                               </block>
                                                             </value>
                                                           </block>
                                                         </value>
                                                         <value name="B">
                                                           <block type="logic_negate" id="QzU)|^M:2SQsEF%CPjDi">
                                                             <value name="BOOL">
                                                               <block type="get_value" id="+gD/U?X!ZU|7OJiYPclr">
                                                                 <field name="ATTR">val</field>
                                                                 <field name="OID">sonoff.0.Badezimmerlicht.POWER</field>
                                                               </block>
                                                             </value>
                                                           </block>
                                                         </value>
                                                       </block>
                                                     </value>
                                                     <statement name="DO0">
                                                       <block type="control" id=":TjQf-tu@Q#kgie^P)@o">
                                                         <mutation xmlns="http://www.w3.org/1999/xhtml" delay_input="false"></mutation>
                                                         <field name="OID">sonoff.0.Badezimmerlicht.POWER</field>
                                                         <field name="WITH_DELAY">FALSE</field>
                                                         <value name="VALUE">
                                                           <block type="logic_boolean" id="*ClGOYPry2taM^E+%*n#">
                                                             <field name="BOOL">TRUE</field>
                                                           </block>
                                                         </value>
                                                       </block>
                                                     </statement>
                                                     <next>
                                                       <block type="variables_set" id="Yv+SY!mIdF7[u6`DuzRn">
                                                         <field name="VAR" id="#?8llkQ_(?e?!}{7|0%B">duschen</field>
                                                         <value name="VALUE">
                                                           <block type="logic_boolean" id="7{xAyMA5Inv$Sj56J$Xs">
                                                             <field name="BOOL">FALSE</field>
                                                           </block>
                                                         </value>
                                                       </block>
                                                     </next>
                                                   </block>
                                                 </next>
                                               </block>
                                             </statement>
                                           </block>
                                         </next>
                                       </block>
                                     </next>
                                   </block>
                                 </next>
                               </block>
                             </next>
                           </block>
                         </next>
                       </block>
                      </xml>
                      

                      Muss da dennoch der vergleich auf "0" mit rein? Also mit "sonst setzte duschen auf falsch"?

                      paul53P padrinoP 2 Antworten Letzte Antwort
                      0
                      • SanwebS Sanweb

                        @paul53

                        Badezimmer_8.jpg

                        <xml xmlns="https://developers.google.com/blockly/xml">
                         <variables>
                           <variable id="#?8llkQ_(?e?!}{7|0%B">duschen</variable>
                           <variable type="timeout" id="timeout">timeout</variable>
                         </variables>
                         <block type="comment" id="^H8S@6|A=FINJo802%?S" x="788" y="-2612">
                           <field name="COMMENT">Button</field>
                           <next>
                             <block type="on_ext" id="JT^Sb~%?woKrqm#,_x?/">
                               <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="g+hFwJ/p}d6]YQ~EspD*">
                                   <field name="oid">deconz.0.Sensors.15.buttonpressed</field>
                                 </shadow>
                               </value>
                               <statement name="STATEMENT">
                                 <block type="controls_if" id="5t#hR+Cr;XhCLt708]?;">
                                   <value name="IF0">
                                     <block type="logic_compare" id="*0/lSkBjPe!Q0-7A]`}t">
                                       <field name="OP">EQ</field>
                                       <value name="A">
                                         <block type="on_source" id="p;(Kh@GTK/#PhbUs|2Fk">
                                           <field name="ATTR">state.val</field>
                                         </block>
                                       </value>
                                       <value name="B">
                                         <block type="math_number" id="L}L-PyHNK43~ZBR#G]Yv">
                                           <field name="NUM">1002</field>
                                         </block>
                                       </value>
                                     </block>
                                   </value>
                                   <statement name="DO0">
                                     <block type="timeouts_cleartimeout" id="jv6hg}OB#s?,w0H*NI_d">
                                       <field name="NAME">timeout</field>
                                       <next>
                                         <block type="variables_set" id="IQn)a22MZbX!@$BeNSbo">
                                           <field name="VAR" id="#?8llkQ_(?e?!}{7|0%B">duschen</field>
                                           <value name="VALUE">
                                             <block type="logic_boolean" id=",=d^~(K|T,0?]S978@zB">
                                               <field name="BOOL">TRUE</field>
                                             </block>
                                           </value>
                                         </block>
                                       </next>
                                     </block>
                                   </statement>
                                 </block>
                               </statement>
                               <next>
                                 <block type="comment" id="j^MxUgu8?7{mlu]rA:Tf">
                                   <field name="COMMENT">Bewegung</field>
                                   <next>
                                     <block type="on_ext" id="Vo2d_MmTq==sR.4ZWR$O">
                                       <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="Czsj]a1TUk|+~h~ORP[b">
                                           <field name="oid">deconz.0.Sensors.2.presence</field>
                                         </shadow>
                                       </value>
                                       <statement name="STATEMENT">
                                         <block type="timeouts_cleartimeout" id=".AnY7,uE8z6%68I_9r!J">
                                           <field name="NAME">timeout</field>
                                           <next>
                                             <block type="controls_if" id="+RZ{~*8u`F-{891w*mat">
                                               <value name="IF0">
                                                 <block type="logic_operation" id="WMPSk~z%).|`E/DHlrcn" inline="false">
                                                   <field name="OP">AND</field>
                                                   <value name="A">
                                                     <block type="logic_negate" id="C4LtUkpka$={[9/VCOva">
                                                       <value name="BOOL">
                                                         <block type="on_source" id="+d+_sgAE*[8U#u/8-`=!">
                                                           <field name="ATTR">state.val</field>
                                                         </block>
                                                       </value>
                                                     </block>
                                                   </value>
                                                   <value name="B">
                                                     <block type="logic_negate" id="W1{FG$?i1lP8NHMpEzzu">
                                                       <value name="BOOL">
                                                         <block type="variables_get" id="B^v6/7~q9mb|4}(2Qk$c">
                                                           <field name="VAR" id="#?8llkQ_(?e?!}{7|0%B">duschen</field>
                                                         </block>
                                                       </value>
                                                     </block>
                                                   </value>
                                                 </block>
                                               </value>
                                               <statement name="DO0">
                                                 <block type="timeouts_settimeout" id="b8c{g!jXe$]dFOh^QXP[">
                                                   <field name="NAME">timeout</field>
                                                   <field name="DELAY">30</field>
                                                   <field name="UNIT">sec</field>
                                                   <statement name="STATEMENT">
                                                     <block type="comment" id="vvNPR8V{Zt(;|2~TmxfO">
                                                       <field name="COMMENT">Licht ein?</field>
                                                       <next>
                                                         <block type="controls_if" id="ub/zHL/V?|rXYe|9Al6y">
                                                           <value name="IF0">
                                                             <block type="get_value" id="FrcZZNPN%#R(^G6NN|LM">
                                                               <field name="ATTR">val</field>
                                                               <field name="OID">sonoff.0.Badezimmerlicht.POWER</field>
                                                             </block>
                                                           </value>
                                                           <statement name="DO0">
                                                             <block type="control" id="$86HuP~`N{LaY4I7md,3">
                                                               <mutation xmlns="http://www.w3.org/1999/xhtml" delay_input="false"></mutation>
                                                               <field name="OID">sonoff.0.Badezimmerlicht.POWER</field>
                                                               <field name="WITH_DELAY">FALSE</field>
                                                               <value name="VALUE">
                                                                 <block type="logic_boolean" id="1UP*Me:;gW3cC?+vbh94">
                                                                   <field name="BOOL">FALSE</field>
                                                                 </block>
                                                               </value>
                                                             </block>
                                                           </statement>
                                                         </block>
                                                       </next>
                                                     </block>
                                                   </statement>
                                                 </block>
                                               </statement>
                                             </block>
                                           </next>
                                         </block>
                                       </statement>
                                       <next>
                                         <block type="comment" id="#NX^q_VjK@F9iUWAWPA}">
                                           <field name="COMMENT">Tür öffnet</field>
                                           <next>
                                             <block type="on_ext" id="/V]t?I@Gjkc^eMR_n#)|">
                                               <mutation xmlns="http://www.w3.org/1999/xhtml" items="1"></mutation>
                                               <field name="CONDITION">gt</field>
                                               <field name="ACK_CONDITION"></field>
                                               <value name="OID0">
                                                 <shadow type="field_oid" id="z.rf;Ppk-,EU=pVr7wQN">
                                                   <field name="oid">deconz.0.Sensors.5.open</field>
                                                 </shadow>
                                               </value>
                                               <statement name="STATEMENT">
                                                 <block type="comment" id="S+(!XQne8~@_%_R_(8!Q">
                                                   <field name="COMMENT">dunkel und Licht aus?</field>
                                                   <next>
                                                     <block type="controls_if" id="!muI`Yamueo@M|l(k(*v">
                                                       <value name="IF0">
                                                         <block type="logic_operation" id="F[YWS@t_RdTz=1pg)U=J" inline="false">
                                                           <field name="OP">AND</field>
                                                           <value name="A">
                                                             <block type="logic_negate" id="iUk6};go{0_ftNa[9VUb">
                                                               <value name="BOOL">
                                                                 <block type="get_value" id="2NG.@e5:!/WW%;U$]|v`">
                                                                   <field name="ATTR">val</field>
                                                                   <field name="OID">deconz.0.Sensors.1.dark</field>
                                                                 </block>
                                                               </value>
                                                             </block>
                                                           </value>
                                                           <value name="B">
                                                             <block type="logic_negate" id="QzU)|^M:2SQsEF%CPjDi">
                                                               <value name="BOOL">
                                                                 <block type="get_value" id="+gD/U?X!ZU|7OJiYPclr">
                                                                   <field name="ATTR">val</field>
                                                                   <field name="OID">sonoff.0.Badezimmerlicht.POWER</field>
                                                                 </block>
                                                               </value>
                                                             </block>
                                                           </value>
                                                         </block>
                                                       </value>
                                                       <statement name="DO0">
                                                         <block type="control" id=":TjQf-tu@Q#kgie^P)@o">
                                                           <mutation xmlns="http://www.w3.org/1999/xhtml" delay_input="false"></mutation>
                                                           <field name="OID">sonoff.0.Badezimmerlicht.POWER</field>
                                                           <field name="WITH_DELAY">FALSE</field>
                                                           <value name="VALUE">
                                                             <block type="logic_boolean" id="*ClGOYPry2taM^E+%*n#">
                                                               <field name="BOOL">TRUE</field>
                                                             </block>
                                                           </value>
                                                         </block>
                                                       </statement>
                                                       <next>
                                                         <block type="variables_set" id="Yv+SY!mIdF7[u6`DuzRn">
                                                           <field name="VAR" id="#?8llkQ_(?e?!}{7|0%B">duschen</field>
                                                           <value name="VALUE">
                                                             <block type="logic_boolean" id="7{xAyMA5Inv$Sj56J$Xs">
                                                               <field name="BOOL">FALSE</field>
                                                             </block>
                                                           </value>
                                                         </block>
                                                       </next>
                                                     </block>
                                                   </next>
                                                 </block>
                                               </statement>
                                             </block>
                                           </next>
                                         </block>
                                       </next>
                                     </block>
                                   </next>
                                 </block>
                               </next>
                             </block>
                           </next>
                         </block>
                        </xml>
                        

                        Muss da dennoch der vergleich auf "0" mit rein? Also mit "sonst setzte duschen auf falsch"?

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

                        @Sanweb sagte:

                        Muss da dennoch der vergleich auf "0" mit rein? Also mit "sonst setzte duschen auf falsch"?

                        Nein, "setze duschen auf falsch" darf nur beim Tür öffnen erfolgen.

                        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
                        0
                        • SanwebS Sanweb

                          @paul53

                          Badezimmer_8.jpg

                          <xml xmlns="https://developers.google.com/blockly/xml">
                           <variables>
                             <variable id="#?8llkQ_(?e?!}{7|0%B">duschen</variable>
                             <variable type="timeout" id="timeout">timeout</variable>
                           </variables>
                           <block type="comment" id="^H8S@6|A=FINJo802%?S" x="788" y="-2612">
                             <field name="COMMENT">Button</field>
                             <next>
                               <block type="on_ext" id="JT^Sb~%?woKrqm#,_x?/">
                                 <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="g+hFwJ/p}d6]YQ~EspD*">
                                     <field name="oid">deconz.0.Sensors.15.buttonpressed</field>
                                   </shadow>
                                 </value>
                                 <statement name="STATEMENT">
                                   <block type="controls_if" id="5t#hR+Cr;XhCLt708]?;">
                                     <value name="IF0">
                                       <block type="logic_compare" id="*0/lSkBjPe!Q0-7A]`}t">
                                         <field name="OP">EQ</field>
                                         <value name="A">
                                           <block type="on_source" id="p;(Kh@GTK/#PhbUs|2Fk">
                                             <field name="ATTR">state.val</field>
                                           </block>
                                         </value>
                                         <value name="B">
                                           <block type="math_number" id="L}L-PyHNK43~ZBR#G]Yv">
                                             <field name="NUM">1002</field>
                                           </block>
                                         </value>
                                       </block>
                                     </value>
                                     <statement name="DO0">
                                       <block type="timeouts_cleartimeout" id="jv6hg}OB#s?,w0H*NI_d">
                                         <field name="NAME">timeout</field>
                                         <next>
                                           <block type="variables_set" id="IQn)a22MZbX!@$BeNSbo">
                                             <field name="VAR" id="#?8llkQ_(?e?!}{7|0%B">duschen</field>
                                             <value name="VALUE">
                                               <block type="logic_boolean" id=",=d^~(K|T,0?]S978@zB">
                                                 <field name="BOOL">TRUE</field>
                                               </block>
                                             </value>
                                           </block>
                                         </next>
                                       </block>
                                     </statement>
                                   </block>
                                 </statement>
                                 <next>
                                   <block type="comment" id="j^MxUgu8?7{mlu]rA:Tf">
                                     <field name="COMMENT">Bewegung</field>
                                     <next>
                                       <block type="on_ext" id="Vo2d_MmTq==sR.4ZWR$O">
                                         <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="Czsj]a1TUk|+~h~ORP[b">
                                             <field name="oid">deconz.0.Sensors.2.presence</field>
                                           </shadow>
                                         </value>
                                         <statement name="STATEMENT">
                                           <block type="timeouts_cleartimeout" id=".AnY7,uE8z6%68I_9r!J">
                                             <field name="NAME">timeout</field>
                                             <next>
                                               <block type="controls_if" id="+RZ{~*8u`F-{891w*mat">
                                                 <value name="IF0">
                                                   <block type="logic_operation" id="WMPSk~z%).|`E/DHlrcn" inline="false">
                                                     <field name="OP">AND</field>
                                                     <value name="A">
                                                       <block type="logic_negate" id="C4LtUkpka$={[9/VCOva">
                                                         <value name="BOOL">
                                                           <block type="on_source" id="+d+_sgAE*[8U#u/8-`=!">
                                                             <field name="ATTR">state.val</field>
                                                           </block>
                                                         </value>
                                                       </block>
                                                     </value>
                                                     <value name="B">
                                                       <block type="logic_negate" id="W1{FG$?i1lP8NHMpEzzu">
                                                         <value name="BOOL">
                                                           <block type="variables_get" id="B^v6/7~q9mb|4}(2Qk$c">
                                                             <field name="VAR" id="#?8llkQ_(?e?!}{7|0%B">duschen</field>
                                                           </block>
                                                         </value>
                                                       </block>
                                                     </value>
                                                   </block>
                                                 </value>
                                                 <statement name="DO0">
                                                   <block type="timeouts_settimeout" id="b8c{g!jXe$]dFOh^QXP[">
                                                     <field name="NAME">timeout</field>
                                                     <field name="DELAY">30</field>
                                                     <field name="UNIT">sec</field>
                                                     <statement name="STATEMENT">
                                                       <block type="comment" id="vvNPR8V{Zt(;|2~TmxfO">
                                                         <field name="COMMENT">Licht ein?</field>
                                                         <next>
                                                           <block type="controls_if" id="ub/zHL/V?|rXYe|9Al6y">
                                                             <value name="IF0">
                                                               <block type="get_value" id="FrcZZNPN%#R(^G6NN|LM">
                                                                 <field name="ATTR">val</field>
                                                                 <field name="OID">sonoff.0.Badezimmerlicht.POWER</field>
                                                               </block>
                                                             </value>
                                                             <statement name="DO0">
                                                               <block type="control" id="$86HuP~`N{LaY4I7md,3">
                                                                 <mutation xmlns="http://www.w3.org/1999/xhtml" delay_input="false"></mutation>
                                                                 <field name="OID">sonoff.0.Badezimmerlicht.POWER</field>
                                                                 <field name="WITH_DELAY">FALSE</field>
                                                                 <value name="VALUE">
                                                                   <block type="logic_boolean" id="1UP*Me:;gW3cC?+vbh94">
                                                                     <field name="BOOL">FALSE</field>
                                                                   </block>
                                                                 </value>
                                                               </block>
                                                             </statement>
                                                           </block>
                                                         </next>
                                                       </block>
                                                     </statement>
                                                   </block>
                                                 </statement>
                                               </block>
                                             </next>
                                           </block>
                                         </statement>
                                         <next>
                                           <block type="comment" id="#NX^q_VjK@F9iUWAWPA}">
                                             <field name="COMMENT">Tür öffnet</field>
                                             <next>
                                               <block type="on_ext" id="/V]t?I@Gjkc^eMR_n#)|">
                                                 <mutation xmlns="http://www.w3.org/1999/xhtml" items="1"></mutation>
                                                 <field name="CONDITION">gt</field>
                                                 <field name="ACK_CONDITION"></field>
                                                 <value name="OID0">
                                                   <shadow type="field_oid" id="z.rf;Ppk-,EU=pVr7wQN">
                                                     <field name="oid">deconz.0.Sensors.5.open</field>
                                                   </shadow>
                                                 </value>
                                                 <statement name="STATEMENT">
                                                   <block type="comment" id="S+(!XQne8~@_%_R_(8!Q">
                                                     <field name="COMMENT">dunkel und Licht aus?</field>
                                                     <next>
                                                       <block type="controls_if" id="!muI`Yamueo@M|l(k(*v">
                                                         <value name="IF0">
                                                           <block type="logic_operation" id="F[YWS@t_RdTz=1pg)U=J" inline="false">
                                                             <field name="OP">AND</field>
                                                             <value name="A">
                                                               <block type="logic_negate" id="iUk6};go{0_ftNa[9VUb">
                                                                 <value name="BOOL">
                                                                   <block type="get_value" id="2NG.@e5:!/WW%;U$]|v`">
                                                                     <field name="ATTR">val</field>
                                                                     <field name="OID">deconz.0.Sensors.1.dark</field>
                                                                   </block>
                                                                 </value>
                                                               </block>
                                                             </value>
                                                             <value name="B">
                                                               <block type="logic_negate" id="QzU)|^M:2SQsEF%CPjDi">
                                                                 <value name="BOOL">
                                                                   <block type="get_value" id="+gD/U?X!ZU|7OJiYPclr">
                                                                     <field name="ATTR">val</field>
                                                                     <field name="OID">sonoff.0.Badezimmerlicht.POWER</field>
                                                                   </block>
                                                                 </value>
                                                               </block>
                                                             </value>
                                                           </block>
                                                         </value>
                                                         <statement name="DO0">
                                                           <block type="control" id=":TjQf-tu@Q#kgie^P)@o">
                                                             <mutation xmlns="http://www.w3.org/1999/xhtml" delay_input="false"></mutation>
                                                             <field name="OID">sonoff.0.Badezimmerlicht.POWER</field>
                                                             <field name="WITH_DELAY">FALSE</field>
                                                             <value name="VALUE">
                                                               <block type="logic_boolean" id="*ClGOYPry2taM^E+%*n#">
                                                                 <field name="BOOL">TRUE</field>
                                                               </block>
                                                             </value>
                                                           </block>
                                                         </statement>
                                                         <next>
                                                           <block type="variables_set" id="Yv+SY!mIdF7[u6`DuzRn">
                                                             <field name="VAR" id="#?8llkQ_(?e?!}{7|0%B">duschen</field>
                                                             <value name="VALUE">
                                                               <block type="logic_boolean" id="7{xAyMA5Inv$Sj56J$Xs">
                                                                 <field name="BOOL">FALSE</field>
                                                               </block>
                                                             </value>
                                                           </block>
                                                         </next>
                                                       </block>
                                                     </next>
                                                   </block>
                                                 </statement>
                                               </block>
                                             </next>
                                           </block>
                                         </next>
                                       </block>
                                     </next>
                                   </block>
                                 </next>
                               </block>
                             </next>
                           </block>
                          </xml>
                          

                          Muss da dennoch der vergleich auf "0" mit rein? Also mit "sonst setzte duschen auf falsch"?

                          padrinoP Offline
                          padrinoP Offline
                          padrino
                          Most Active
                          schrieb am zuletzt editiert von
                          #29

                          @Sanweb
                          Könntest Du mein Skript mal mit dem richtigen Datenpunkt testen, da mich interessiert, ob es läuft. =)
                          Finde auch das von Paul sind nicht soviel anders aus. ;)

                          paul53P 1 Antwort Letzte Antwort
                          0
                          • padrinoP padrino

                            @Sanweb
                            Könntest Du mein Skript mal mit dem richtigen Datenpunkt testen, da mich interessiert, ob es läuft. =)
                            Finde auch das von Paul sind nicht soviel anders aus. ;)

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

                            @padrino sagte:

                            @Sanweb Könntest Du mein Skript mal mit dem richtigen Datenpunkt testen, da mich interessiert, ob es läuft.

                            Mit dem richtigen Datenpunkt "buttonpressed" wird es funktionieren. "stop timeout" im mache-Zweig ist unnötig, da es bei jedem Trigger erfolgt.

                            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

                            SanwebS 1 Antwort Letzte Antwort
                            0
                            • paul53P paul53

                              @padrino sagte:

                              @Sanweb Könntest Du mein Skript mal mit dem richtigen Datenpunkt testen, da mich interessiert, ob es läuft.

                              Mit dem richtigen Datenpunkt "buttonpressed" wird es funktionieren. "stop timeout" im mache-Zweig ist unnötig, da es bei jedem Trigger erfolgt.

                              SanwebS Offline
                              SanwebS Offline
                              Sanweb
                              schrieb am zuletzt editiert von
                              #31

                              @padrino
                              Habe Deines auch noch einmal ausprobiert, wie Paul schon schrieb, funktioniert Deines ebenfalls mit dem nun richtigen Datenpunkt. :clap: :grin:

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


                              Support us

                              ioBroker
                              Community Adapters
                              Donate

                              450

                              Online

                              32.7k

                              Benutzer

                              82.4k

                              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