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. Autom. TV-Licht um Timeout erweitern

NEWS

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

  • Monatsrückblick – September 2025
    BluefoxB
    Bluefox
    13
    1
    2.0k

  • Neues Video "KI im Smart Home" - ioBroker plus n8n
    BluefoxB
    Bluefox
    16
    1
    2.7k

Autom. TV-Licht um Timeout erweitern

Geplant Angeheftet Gesperrt Verschoben Blockly
5 Beiträge 2 Kommentatoren 58 Aufrufe 1 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.
  • T Offline
    T Offline
    topsurfer
    schrieb am zuletzt editiert von
    #1

    Hallo,
    habe ein kleines Blockly erstellt,
    das TV Licht soll autom. abgehen, wenn die TV-Ecke "Strom" verbraucht (TV ist an) und es draussen dunkel ist (über aktuelle PV-Erzeugung).
    Damit nicht jede Wolke das Licht zum ein/aussschalten bringt würde ich gerne einen 5 minütigen Timeout einbauen,
    so das der Status des TV Lichts max. alle 5 Minuten sich ändert.

    Aber wie und wo einbauen?

    2025-11-24_163058.png

    <xml xmlns="https://developers.google.com/blockly/xml">
      <variables>
        <variable id="hE~ajD3aP|ifgbLDr[vv">vStatus</variable>
      </variables>
      <block type="controls_if" id="RGGS|jhJOqFa~*%h^#ly" x="-363" y="-738">
        <mutation else="1"></mutation>
        <value name="IF0">
          <block type="logic_compare" id="Kk/M^*[FK3ow%nn;s1}=">
            <field name="OP">EQ</field>
            <value name="A">
              <block type="get_value" id=");WD|pX42ZY-t.xLP@zJ">
                <field name="ATTR">val</field>
                <field name="OID">alias.0.EG.Licht.Wohnzimmer.TV_Licht.Status</field>
              </block>
            </value>
            <value name="B">
              <block type="logic_boolean" id="s!{e(GJ?|xnj4okJk)$0">
                <field name="BOOL">TRUE</field>
              </block>
            </value>
          </block>
        </value>
        <statement name="DO0">
          <block type="variables_set" id="X+/oyz:/!Y^jg^v4LZ8J">
            <field name="VAR" id="hE~ajD3aP|ifgbLDr[vv">vStatus</field>
            <value name="VALUE">
              <block type="math_number" id="i[t.t(}$(x=@;:gMu?=i">
                <field name="NUM">1</field>
              </block>
            </value>
          </block>
        </statement>
        <statement name="ELSE">
          <block type="variables_set" id="QuT|6NpF{3yR0Fq#;_)N">
            <field name="VAR" id="hE~ajD3aP|ifgbLDr[vv">vStatus</field>
            <value name="VALUE">
              <block type="math_number" id="c-OjQma7|m~6xf)b23.1">
                <field name="NUM">0</field>
              </block>
            </value>
          </block>
        </statement>
        <next>
          <block type="debug" id="NdE}mmmy`Y~Lq-WuOV*.">
            <field name="Severity">info</field>
            <value name="TEXT">
              <shadow type="text" id="3tPkkNmHx(?]C^6qE;N0">
                <field name="TEXT">Startwert: </field>
              </shadow>
            </value>
            <next>
              <block type="debug" id="5^)9`0$tW1{2[6r55:Vd">
                <field name="Severity">info</field>
                <value name="TEXT">
                  <shadow type="text" id="/*r%lpcq+QVcP3[#1d4R">
                    <field name="TEXT">test</field>
                  </shadow>
                  <block type="variables_get" id="{sBuMB(J.pi,?-:rudpW">
                    <field name="VAR" id="hE~ajD3aP|ifgbLDr[vv">vStatus</field>
                  </block>
                </value>
                <next>
                  <block type="on" id="[cigSU}85##.a7agk3yA">
                    <field name="OID">sonoff.0.Fernseheecke #s04.ENERGY_Power</field>
                    <field name="CONDITION">ne</field>
                    <field name="ACK_CONDITION"></field>
                    <statement name="STATEMENT">
                      <block type="debug" id="iMDa,@p%C[%yyCA7Z{up">
                        <field name="Severity">info</field>
                        <value name="TEXT">
                          <shadow type="text" id="b/,7kvGBakrpS7pnwCcq">
                            <field name="TEXT">test</field>
                          </shadow>
                          <block type="on_source" id="i^8UT.Cn!._X2sTHtMKq">
                            <field name="ATTR">state.val</field>
                          </block>
                        </value>
                        <next>
                          <block type="controls_if" id="-_6ht3$/`O2E^]5+m8|`">
                            <mutation else="1"></mutation>
                            <value name="IF0">
                              <block type="logic_multi_and" id="6|l$6-kYgpd3snAMH/mw">
                                <mutation xmlns="http://www.w3.org/1999/xhtml" items="3"></mutation>
                                <value name="AND0">
                                  <block type="logic_compare" id="1Ve]/%VQCd;$xthy7RaF">
                                    <field name="OP">GT</field>
                                    <value name="A">
                                      <block type="on_source" id="e5m-C$KV@PI;fPi4THEr">
                                        <field name="ATTR">state.val</field>
                                      </block>
                                    </value>
                                    <value name="B">
                                      <block type="math_number" id="w$.ZzSjd0Tl@WyTpprVn">
                                        <field name="NUM">65</field>
                                      </block>
                                    </value>
                                  </block>
                                </value>
                                <value name="AND1">
                                  <block type="logic_compare" id="k;D^*?Y6|I{+{Q-$VbF5">
                                    <field name="OP">LT</field>
                                    <value name="A">
                                      <block type="get_value" id="+n%eVR`9RkC:V7pv!60S">
                                        <field name="ATTR">val</field>
                                        <field name="OID">alias.0.Solar.PV.Erzeugung_Aktuell</field>
                                      </block>
                                    </value>
                                    <value name="B">
                                      <block type="math_number" id=":w$c9(A-eZmK6c5w2O}4">
                                        <field name="NUM">150</field>
                                      </block>
                                    </value>
                                  </block>
                                </value>
                                <value name="AND2">
                                  <block type="logic_compare" id="R#1V9q76SrK-Wb{2`4Lx">
                                    <field name="OP">EQ</field>
                                    <value name="A">
                                      <block type="get_value" id="{^Jyuf1nU}:CX-mZE3e2">
                                        <field name="ATTR">val</field>
                                        <field name="OID">0_userdata.0.Hilfs-DP.Licht.dp_TV_Licht_Automatik</field>
                                      </block>
                                    </value>
                                    <value name="B">
                                      <block type="logic_boolean" id="F-aWwx]Ic[z9ZL@Z8gx-">
                                        <field name="BOOL">TRUE</field>
                                      </block>
                                    </value>
                                  </block>
                                </value>
                              </block>
                            </value>
                            <statement name="DO0">
                              <block type="controls_if" id="0?;=88Wz~f]fWt?`f7Da">
                                <value name="IF0">
                                  <block type="logic_compare" id="4.4Noc/_-G3rxWRqD}ms">
                                    <field name="OP">EQ</field>
                                    <value name="A">
                                      <block type="variables_get" id="*WZ^F!!cZ@wLs1?v$aIS">
                                        <field name="VAR" id="hE~ajD3aP|ifgbLDr[vv">vStatus</field>
                                      </block>
                                    </value>
                                    <value name="B">
                                      <block type="math_number" id="U*vQ)~s@m8^{O2$fUoo;">
                                        <field name="NUM">0</field>
                                      </block>
                                    </value>
                                  </block>
                                </value>
                                <statement name="DO0">
                                  <block type="debug" id="HpNIM4NH)$@ym)#pq}H$">
                                    <field name="Severity">info</field>
                                    <value name="TEXT">
                                      <shadow type="text" id="N)?g=g4]+)/E2Z5!`spN">
                                        <field name="TEXT">Lampe an</field>
                                      </shadow>
                                    </value>
                                    <next>
                                      <block type="variables_set" id="`SadT#fALL}dp`z!Tp|k">
                                        <field name="VAR" id="hE~ajD3aP|ifgbLDr[vv">vStatus</field>
                                        <value name="VALUE">
                                          <block type="math_number" id="tji0GPh@0WP-+%_dT_E5">
                                            <field name="NUM">1</field>
                                          </block>
                                        </value>
                                        <next>
                                          <block type="control" id="s:{.H=Z[[ck8gl2#j]@B">
                                            <mutation xmlns="http://www.w3.org/1999/xhtml" delay_input="false"></mutation>
                                            <field name="OID">alias.0.EG.Licht.Wohnzimmer.TV_Licht.Status</field>
                                            <field name="WITH_DELAY">FALSE</field>
                                            <value name="VALUE">
                                              <block type="logic_boolean" id="I-wF99qegW[N[7_UVs=l">
                                                <field name="BOOL">TRUE</field>
                                              </block>
                                            </value>
                                          </block>
                                        </next>
                                      </block>
                                    </next>
                                  </block>
                                </statement>
                              </block>
                            </statement>
                            <statement name="ELSE">
                              <block type="controls_if" id="jLuq7b+%:S)?xliJbmh#">
                                <value name="IF0">
                                  <block type="logic_compare" id="3_m!,{dQiPBc5kKJy9,0">
                                    <field name="OP">EQ</field>
                                    <value name="A">
                                      <block type="variables_get" id="*L~$.@Y!~Vv93EqRbJma">
                                        <field name="VAR" id="hE~ajD3aP|ifgbLDr[vv">vStatus</field>
                                      </block>
                                    </value>
                                    <value name="B">
                                      <block type="math_number" id="mf~}yM6BB~;e/=6?OV`t">
                                        <field name="NUM">1</field>
                                      </block>
                                    </value>
                                  </block>
                                </value>
                                <statement name="DO0">
                                  <block type="debug" id="lmI=,HQ,k;W!76WRyU1w">
                                    <field name="Severity">info</field>
                                    <value name="TEXT">
                                      <shadow type="text" id="p@J$m?nT?DU2t$kht_l?">
                                        <field name="TEXT">Lampe aus</field>
                                      </shadow>
                                    </value>
                                    <next>
                                      <block type="variables_set" id="aT:7CA7z+Y3K6?WRGGq4">
                                        <field name="VAR" id="hE~ajD3aP|ifgbLDr[vv">vStatus</field>
                                        <value name="VALUE">
                                          <block type="math_number" id="ge}wCv)Oi$YcP%1))Fke">
                                            <field name="NUM">0</field>
                                          </block>
                                        </value>
                                        <next>
                                          <block type="control" id="Ghj6%smer~;FbH}%x^}}">
                                            <mutation xmlns="http://www.w3.org/1999/xhtml" delay_input="false"></mutation>
                                            <field name="OID">alias.0.EG.Licht.Wohnzimmer.TV_Licht.Status</field>
                                            <field name="WITH_DELAY">FALSE</field>
                                            <value name="VALUE">
                                              <block type="logic_boolean" id="-%lI;BR8BboN6pVAazk$">
                                                <field name="BOOL">FALSE</field>
                                              </block>
                                            </value>
                                          </block>
                                        </next>
                                      </block>
                                    </next>
                                  </block>
                                </statement>
                              </block>
                            </statement>
                          </block>
                        </next>
                      </block>
                    </statement>
                  </block>
                </next>
              </block>
            </next>
          </block>
        </next>
      </block>
    </xml>
    
    paul53P 1 Antwort Letzte Antwort
    0
    • T topsurfer

      Hallo,
      habe ein kleines Blockly erstellt,
      das TV Licht soll autom. abgehen, wenn die TV-Ecke "Strom" verbraucht (TV ist an) und es draussen dunkel ist (über aktuelle PV-Erzeugung).
      Damit nicht jede Wolke das Licht zum ein/aussschalten bringt würde ich gerne einen 5 minütigen Timeout einbauen,
      so das der Status des TV Lichts max. alle 5 Minuten sich ändert.

      Aber wie und wo einbauen?

      2025-11-24_163058.png

      <xml xmlns="https://developers.google.com/blockly/xml">
        <variables>
          <variable id="hE~ajD3aP|ifgbLDr[vv">vStatus</variable>
        </variables>
        <block type="controls_if" id="RGGS|jhJOqFa~*%h^#ly" x="-363" y="-738">
          <mutation else="1"></mutation>
          <value name="IF0">
            <block type="logic_compare" id="Kk/M^*[FK3ow%nn;s1}=">
              <field name="OP">EQ</field>
              <value name="A">
                <block type="get_value" id=");WD|pX42ZY-t.xLP@zJ">
                  <field name="ATTR">val</field>
                  <field name="OID">alias.0.EG.Licht.Wohnzimmer.TV_Licht.Status</field>
                </block>
              </value>
              <value name="B">
                <block type="logic_boolean" id="s!{e(GJ?|xnj4okJk)$0">
                  <field name="BOOL">TRUE</field>
                </block>
              </value>
            </block>
          </value>
          <statement name="DO0">
            <block type="variables_set" id="X+/oyz:/!Y^jg^v4LZ8J">
              <field name="VAR" id="hE~ajD3aP|ifgbLDr[vv">vStatus</field>
              <value name="VALUE">
                <block type="math_number" id="i[t.t(}$(x=@;:gMu?=i">
                  <field name="NUM">1</field>
                </block>
              </value>
            </block>
          </statement>
          <statement name="ELSE">
            <block type="variables_set" id="QuT|6NpF{3yR0Fq#;_)N">
              <field name="VAR" id="hE~ajD3aP|ifgbLDr[vv">vStatus</field>
              <value name="VALUE">
                <block type="math_number" id="c-OjQma7|m~6xf)b23.1">
                  <field name="NUM">0</field>
                </block>
              </value>
            </block>
          </statement>
          <next>
            <block type="debug" id="NdE}mmmy`Y~Lq-WuOV*.">
              <field name="Severity">info</field>
              <value name="TEXT">
                <shadow type="text" id="3tPkkNmHx(?]C^6qE;N0">
                  <field name="TEXT">Startwert: </field>
                </shadow>
              </value>
              <next>
                <block type="debug" id="5^)9`0$tW1{2[6r55:Vd">
                  <field name="Severity">info</field>
                  <value name="TEXT">
                    <shadow type="text" id="/*r%lpcq+QVcP3[#1d4R">
                      <field name="TEXT">test</field>
                    </shadow>
                    <block type="variables_get" id="{sBuMB(J.pi,?-:rudpW">
                      <field name="VAR" id="hE~ajD3aP|ifgbLDr[vv">vStatus</field>
                    </block>
                  </value>
                  <next>
                    <block type="on" id="[cigSU}85##.a7agk3yA">
                      <field name="OID">sonoff.0.Fernseheecke #s04.ENERGY_Power</field>
                      <field name="CONDITION">ne</field>
                      <field name="ACK_CONDITION"></field>
                      <statement name="STATEMENT">
                        <block type="debug" id="iMDa,@p%C[%yyCA7Z{up">
                          <field name="Severity">info</field>
                          <value name="TEXT">
                            <shadow type="text" id="b/,7kvGBakrpS7pnwCcq">
                              <field name="TEXT">test</field>
                            </shadow>
                            <block type="on_source" id="i^8UT.Cn!._X2sTHtMKq">
                              <field name="ATTR">state.val</field>
                            </block>
                          </value>
                          <next>
                            <block type="controls_if" id="-_6ht3$/`O2E^]5+m8|`">
                              <mutation else="1"></mutation>
                              <value name="IF0">
                                <block type="logic_multi_and" id="6|l$6-kYgpd3snAMH/mw">
                                  <mutation xmlns="http://www.w3.org/1999/xhtml" items="3"></mutation>
                                  <value name="AND0">
                                    <block type="logic_compare" id="1Ve]/%VQCd;$xthy7RaF">
                                      <field name="OP">GT</field>
                                      <value name="A">
                                        <block type="on_source" id="e5m-C$KV@PI;fPi4THEr">
                                          <field name="ATTR">state.val</field>
                                        </block>
                                      </value>
                                      <value name="B">
                                        <block type="math_number" id="w$.ZzSjd0Tl@WyTpprVn">
                                          <field name="NUM">65</field>
                                        </block>
                                      </value>
                                    </block>
                                  </value>
                                  <value name="AND1">
                                    <block type="logic_compare" id="k;D^*?Y6|I{+{Q-$VbF5">
                                      <field name="OP">LT</field>
                                      <value name="A">
                                        <block type="get_value" id="+n%eVR`9RkC:V7pv!60S">
                                          <field name="ATTR">val</field>
                                          <field name="OID">alias.0.Solar.PV.Erzeugung_Aktuell</field>
                                        </block>
                                      </value>
                                      <value name="B">
                                        <block type="math_number" id=":w$c9(A-eZmK6c5w2O}4">
                                          <field name="NUM">150</field>
                                        </block>
                                      </value>
                                    </block>
                                  </value>
                                  <value name="AND2">
                                    <block type="logic_compare" id="R#1V9q76SrK-Wb{2`4Lx">
                                      <field name="OP">EQ</field>
                                      <value name="A">
                                        <block type="get_value" id="{^Jyuf1nU}:CX-mZE3e2">
                                          <field name="ATTR">val</field>
                                          <field name="OID">0_userdata.0.Hilfs-DP.Licht.dp_TV_Licht_Automatik</field>
                                        </block>
                                      </value>
                                      <value name="B">
                                        <block type="logic_boolean" id="F-aWwx]Ic[z9ZL@Z8gx-">
                                          <field name="BOOL">TRUE</field>
                                        </block>
                                      </value>
                                    </block>
                                  </value>
                                </block>
                              </value>
                              <statement name="DO0">
                                <block type="controls_if" id="0?;=88Wz~f]fWt?`f7Da">
                                  <value name="IF0">
                                    <block type="logic_compare" id="4.4Noc/_-G3rxWRqD}ms">
                                      <field name="OP">EQ</field>
                                      <value name="A">
                                        <block type="variables_get" id="*WZ^F!!cZ@wLs1?v$aIS">
                                          <field name="VAR" id="hE~ajD3aP|ifgbLDr[vv">vStatus</field>
                                        </block>
                                      </value>
                                      <value name="B">
                                        <block type="math_number" id="U*vQ)~s@m8^{O2$fUoo;">
                                          <field name="NUM">0</field>
                                        </block>
                                      </value>
                                    </block>
                                  </value>
                                  <statement name="DO0">
                                    <block type="debug" id="HpNIM4NH)$@ym)#pq}H$">
                                      <field name="Severity">info</field>
                                      <value name="TEXT">
                                        <shadow type="text" id="N)?g=g4]+)/E2Z5!`spN">
                                          <field name="TEXT">Lampe an</field>
                                        </shadow>
                                      </value>
                                      <next>
                                        <block type="variables_set" id="`SadT#fALL}dp`z!Tp|k">
                                          <field name="VAR" id="hE~ajD3aP|ifgbLDr[vv">vStatus</field>
                                          <value name="VALUE">
                                            <block type="math_number" id="tji0GPh@0WP-+%_dT_E5">
                                              <field name="NUM">1</field>
                                            </block>
                                          </value>
                                          <next>
                                            <block type="control" id="s:{.H=Z[[ck8gl2#j]@B">
                                              <mutation xmlns="http://www.w3.org/1999/xhtml" delay_input="false"></mutation>
                                              <field name="OID">alias.0.EG.Licht.Wohnzimmer.TV_Licht.Status</field>
                                              <field name="WITH_DELAY">FALSE</field>
                                              <value name="VALUE">
                                                <block type="logic_boolean" id="I-wF99qegW[N[7_UVs=l">
                                                  <field name="BOOL">TRUE</field>
                                                </block>
                                              </value>
                                            </block>
                                          </next>
                                        </block>
                                      </next>
                                    </block>
                                  </statement>
                                </block>
                              </statement>
                              <statement name="ELSE">
                                <block type="controls_if" id="jLuq7b+%:S)?xliJbmh#">
                                  <value name="IF0">
                                    <block type="logic_compare" id="3_m!,{dQiPBc5kKJy9,0">
                                      <field name="OP">EQ</field>
                                      <value name="A">
                                        <block type="variables_get" id="*L~$.@Y!~Vv93EqRbJma">
                                          <field name="VAR" id="hE~ajD3aP|ifgbLDr[vv">vStatus</field>
                                        </block>
                                      </value>
                                      <value name="B">
                                        <block type="math_number" id="mf~}yM6BB~;e/=6?OV`t">
                                          <field name="NUM">1</field>
                                        </block>
                                      </value>
                                    </block>
                                  </value>
                                  <statement name="DO0">
                                    <block type="debug" id="lmI=,HQ,k;W!76WRyU1w">
                                      <field name="Severity">info</field>
                                      <value name="TEXT">
                                        <shadow type="text" id="p@J$m?nT?DU2t$kht_l?">
                                          <field name="TEXT">Lampe aus</field>
                                        </shadow>
                                      </value>
                                      <next>
                                        <block type="variables_set" id="aT:7CA7z+Y3K6?WRGGq4">
                                          <field name="VAR" id="hE~ajD3aP|ifgbLDr[vv">vStatus</field>
                                          <value name="VALUE">
                                            <block type="math_number" id="ge}wCv)Oi$YcP%1))Fke">
                                              <field name="NUM">0</field>
                                            </block>
                                          </value>
                                          <next>
                                            <block type="control" id="Ghj6%smer~;FbH}%x^}}">
                                              <mutation xmlns="http://www.w3.org/1999/xhtml" delay_input="false"></mutation>
                                              <field name="OID">alias.0.EG.Licht.Wohnzimmer.TV_Licht.Status</field>
                                              <field name="WITH_DELAY">FALSE</field>
                                              <value name="VALUE">
                                                <block type="logic_boolean" id="-%lI;BR8BboN6pVAazk$">
                                                  <field name="BOOL">FALSE</field>
                                                </block>
                                              </value>
                                            </block>
                                          </next>
                                        </block>
                                      </next>
                                    </block>
                                  </statement>
                                </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
      #2

      @topsurfer sagte: Status des TV Lichts max. alle 5 Minuten sich ändert

      Versuche es mal so:

      Blockly_temp.JPG

      Anmerkung: Ich hätte den Licht-Alias mit Typ "Logikwert" erstellt.

      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

      T 1 Antwort Letzte Antwort
      0
      • paul53P paul53

        @topsurfer sagte: Status des TV Lichts max. alle 5 Minuten sich ändert

        Versuche es mal so:

        Blockly_temp.JPG

        Anmerkung: Ich hätte den Licht-Alias mit Typ "Logikwert" erstellt.

        T Offline
        T Offline
        topsurfer
        schrieb zuletzt editiert von topsurfer
        #3

        Danke dir, Paul.

        @paul53 sagte in Autom. TV-Licht um Timeout erweitern:

        Anmerkung: Ich hätte den Licht-Alias mit Typ "Logikwert" erstellt.

        Der Alias / DP ist vom Typ Bollean (muss er auch sein),
        die (Hilfs) Variable vStatus (0, 1) hab ich nur eingebaut, um (für mich) das Script einfacher gestalten zu können.
        (aber im Prinzip könnte man auch hang auf vStatus verzichten und immer direkt den Wert vom DP prüfen).

        Hatte deine Version schon komplett eingetippt,
        jetzt sehe ich aber das es ja so nicht funktionieren kann, denn du setzt ja den vStatus (0 oder 1) auf den Licht-Status, der Boolean verlangt.
        2025-11-25_121027.png

        paul53P 1 Antwort Letzte Antwort
        0
        • T topsurfer

          Danke dir, Paul.

          @paul53 sagte in Autom. TV-Licht um Timeout erweitern:

          Anmerkung: Ich hätte den Licht-Alias mit Typ "Logikwert" erstellt.

          Der Alias / DP ist vom Typ Bollean (muss er auch sein),
          die (Hilfs) Variable vStatus (0, 1) hab ich nur eingebaut, um (für mich) das Script einfacher gestalten zu können.
          (aber im Prinzip könnte man auch hang auf vStatus verzichten und immer direkt den Wert vom DP prüfen).

          Hatte deine Version schon komplett eingetippt,
          jetzt sehe ich aber das es ja so nicht funktionieren kann, denn du setzt ja den vStatus (0 oder 1) auf den Licht-Status, der Boolean verlangt.
          2025-11-25_121027.png

          paul53P Offline
          paul53P Offline
          paul53
          schrieb zuletzt editiert von paul53
          #4

          @topsurfer sagte: Der Alias / DP ist vom Typ Bollean (muss er auch sein),

          Dann ändere es so:

          Blockly_temp.JPG

          @topsurfer sagte in Autom. TV-Licht um Timeout erweitern:

          auf vStatus verzichten und immer direkt den Wert vom DP prüfen

          Bei dir wie bei mir dient die Variable dazu, nur dann zu senden, wenn geschaltet werden soll. Wenn ein Wert mehr als einmal verwendet wird, ist eine Variable die effektivste Lösung.
          Meine Version ist auch Voraussetzung für die Verwendung nur eines Timeout. Die komplexe Funktion "steuere" sollte nur so oft verwendet werden, wie unbedingt nötig (Ressourcen).

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

          1 Antwort Letzte Antwort
          1
          • T Offline
            T Offline
            topsurfer
            schrieb zuletzt editiert von
            #5

            Super, der "Trick" ist, das du ob im "Falls .." als erstes wohl prüfst, ob ein Timeout läuft, wenn er läuft: "mach nix"

            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

            616

            Online

            32.4k

            Benutzer

            81.5k

            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