Navigation

    Logo
    • Register
    • Login
    • Search
    • Recent
    • Tags
    • Unread
    • Categories
    • Unreplied
    • Popular
    • GitHub
    • Docu
    • Hilfe
    1. Home
    2. Deutsch
    3. Skripten / Logik
    4. Blockly
    5. Astrofunktion mit Temperaturüberwachung

    NEWS

    • Wir empfehlen: Node.js 22.x

    • Neuer Blog: Fotos und Eindrücke aus Solingen

    • ioBroker goes Matter ... Matter Adapter in Stable

    Astrofunktion mit Temperaturüberwachung

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

      Hallo zusammen, ich brächte Hilfe um ein Script zu erstellen.
      Ich habe im Garten eine Vogelvoliere, dort ist ein Brunnen installiert, welcher über ein Shelly Plug S gesteuert wird. J
      Momentan läuft er über die Shelly Cloud, wodurch er über eine Aktion mit der Astrofunktion gesteuert wird.
      Jedoch würde ich gerne mit dem Iobroker (Blockly) ein Script erstellen, so das wenn Sonnenaufgang ist, der Brunnen an geht und wieder aus bei Sonnenuntergang, aber zusätzlich möchte ich das wenn mein Xiaomi Temperatursensor draußen eine Temperatur von weniger als 5° feststellt, der Brunnen aus bleibt, b.z.w aus geht oder bei mehr als 5° wieder an geht.
      Ist mein vorhaben, irgendwie zu realisieren?
      Über Vorschläge würde ich mich freuen.

      VG

      paul53 L 3 Replies Last reply Reply Quote 0
      • paul53
        paul53 @Blueskorpion last edited by

        @blueskorpion sagt: Über Vorschläge würde ich mich freuen.

        Bild_2021-10-22_151428.png

        B 2 Replies Last reply Reply Quote 0
        • L
          lessthanmore @Blueskorpion last edited by

          @blueskorpion Mist, war zu langsam.
          Hier mein Vorschlag:
          2021-10-22_15-16-35.png


          <xml xmlns="https://developers.google.com/blockly/xml">
          <variables>
          <variable type="timeout" id="timeout">timeout</variable>
          <variable type="timeout" id="timeout2">timeout2</variable>
          </variables>
          <block type="astro" id="k@MtEi#%?fpln!-?d7:W" x="113" y="312">
          <field name="TYPE">sunrise</field>
          <field name="OFFSET">0</field>
          <statement name="STATEMENT">
          <block type="comment" id="5ckb9V5^tVi#K+4+@Rlr">
          <field name="COMMENT">Zum Sonnenaufgang, falls Temp über 5, Brunnen an</field>
          <next>
          <block type="controls_if" id="]}Wty_Er!_Wt$ta:xl.f">
          <value name="IF0">
          <block type="logic_compare" id="WrSAd5I?5ziPHcK,Ub">
          <field name="OP">GT</field>
          <value name="A">
          <block type="get_value" id="6KDpcZkO=[j#x]sv:1|E">
          <field name="ATTR">val</field>
          <field name="OID">ID auswählen</field>
          </block>
          </value>
          <value name="B">
          <block type="math_number" id="M3GY;$#:#2;MQAzn!mYC">
          <field name="NUM">5</field>
          </block>
          </value>
          </block>
          </value>
          <statement name="DO0">
          <block type="control" id="q(H@{ODJF3gX0?c%O@w*">
          <mutation xmlns="http://www.w3.org/1999/xhtml" delay_input="false"></mutation>
          <field name="OID">Object ID</field>
          <field name="WITH_DELAY">FALSE</field>
          <value name="VALUE">
          <block type="logic_boolean" id="Vg8B$oj.].h_YpSUYDMw">
          <field name="BOOL">TRUE</field>
          </block>
          </value>
          </block>
          </statement>
          </block>
          </next>
          </block>
          </statement>
          <next>
          <block type="astro" id="kKuC|xq}!UucCVdhD|iA">
          <field name="TYPE">sunrise</field>
          <field name="OFFSET">0</field>
          <statement name="STATEMENT">
          <block type="comment" id="7ek6~!O}0W,M%R+D)zLV">
          <field name="COMMENT">Zum Sonnenuntergang, falls Brunnen an, mach aus</field>
          <next>
          <block type="controls_if" id="ILfvAOR4UG9nWhh{Yvhe">
          <value name="IF0">
          <block type="get_value" id="XHf-zr{#{aIn^|Q82{)2">
          <field name="ATTR">val</field>
          <field name="OID">ID auswählen</field>
          </block>
          </value>
          <statement name="DO0">
          <block type="control" id="kA.,@q]6WqUGUMsd!C%1">
          <mutation xmlns="http://www.w3.org/1999/xhtml" delay_input="false"></mutation>
          <field name="OID">Object ID</field>
          <field name="WITH_DELAY">FALSE</field>
          <value name="VALUE">
          <block type="logic_boolean" id="jQ/[H!KW_rT]NAg02o/=">
          <field name="BOOL">FALSE</field>
          </block>
          </value>
          </block>
          </statement>
          </block>
          </next>
          </block>
          </statement>
          <next>
          <block type="on" id="Iq9]dQmA{Blsgm|@;/cj">
          <field name="OID">Object ID</field>
          <field name="CONDITION">ne</field>
          <field name="ACK_CONDITION"></field>
          <statement name="STATEMENT">
          <block type="comment" id="v~ND{-#-/4[wA41$z~-a">
          <field name="COMMENT">Temperaturänderung zwischen Sonnenauf und untergang</field>
          <next>
          <block type="controls_if" id="%+kh9Fl!LBm|zO-|o5u+">
          <value name="IF0">
          <block type="logic_operation" id="4tBrC;Ccj}hbTu2AWyyl" inline="false">
          <field name="OP">AND</field>
          <value name="A">
          <block type="time_compare_ex" id="E${B/x3GmWUmEWN=7]h1">
          <mutation xmlns="http://www.w3.org/1999/xhtml" end_time="false" actual_time="true"></mutation>
          <field name="USE_ACTUAL_TIME">TRUE</field>
          <field name="OPTION">>=</field>
          <value name="START_TIME">
          <shadow type="text" id="O4kps[{OcN}5kMptq=]">
          <field name="TEXT">12:00</field>
          </shadow>
          <block type="time_astro" id="4pN(@N=I
          HA[^!(X]/}"> <field name="TYPE">sunrise</field> <field name="OFFSET">0</field> </block> </value> </block> </value> <value name="B"> <block type="time_compare_ex" id="=A4HCiilcr%R/tea:eZ">
          <mutation xmlns="http://www.w3.org/1999/xhtml" end_time="false" actual_time="true"></mutation>
          <field name="USE_ACTUAL_TIME">TRUE</field>
          <field name="OPTION"><=</field>
          <value name="START_TIME">
          <shadow type="text">
          <field name="TEXT">12:00</field>
          </shadow>
          <block type="time_astro" id="h^aYZZ|jE[N7Jh@f}p1"> <field name="TYPE">sunset</field> <field name="OFFSET">0</field> </block> </value> </block> </value> </block> </value> <statement name="DO0"> <block type="comment" id=";8sXZ{z9{DHxS-tBAbhC"> <field name="COMMENT">Falls Temperatur über 5 und Brunnen aus warte 30 Minuten</field> <next> <block type="controls_if" id="RS~AT?3*MXi?GWb$%qN">
          <mutation elseif="1"></mutation>
          <value name="IF0">
          <block type="logic_operation" id="VwaqqWb).OqXn7_7ML0" inline="false"> <field name="OP">AND</field> <value name="A"> <block type="logic_compare" id="bLhc=ZF4z;gyCRyrD4"> <field name="OP">GT</field> <value name="A"> <block type="get_value" id=",ub0de-?lL}5Q(#,kt*-"> <field name="ATTR">val</field> <field name="OID">ID auswählen</field> </block> </value> <value name="B"> <block type="math_number" id="_F*.+zegUrTf(,~(E+$!"> <field name="NUM">5</field> </block> </value> </block> </value> <value name="B"> <block type="logic_negate" id="+C#wo$Ju[w+HK8$8t}W">
          <value name="BOOL">
          <block type="get_value" id="E7_VY8S]^ZxkN^6I}mQ8">
          <field name="ATTR">val</field>
          <field name="OID">ID auswählen</field>
          </block>
          </value>
          </block>
          </value>
          </block>
          </value>
          <statement name="DO0">
          <block type="timeouts_cleartimeout" id="QPMI-,zqPo7Mi{zR5wTY">
          <field name="NAME">timeout2</field>
          <next>
          <block type="timeouts_settimeout" id="Oj+7@jt5;@w8cMU*ypgL">
          <field name="NAME">timeout</field>
          <field name="DELAY">30</field>
          <field name="UNIT">min</field>
          <statement name="STATEMENT">
          <block type="comment" id=")CH)T3)sWY^3s+lNn)ZK">
          <field name="COMMENT">Brunnen an nach 30 Minuten Temp über 5</field>
          <next>
          <block type="control" id="NMyY3lybI;-}BY(hjPG"> <mutation xmlns="http://www.w3.org/1999/xhtml" delay_input="false"></mutation> <field name="OID">Object ID</field> <field name="WITH_DELAY">FALSE</field> <value name="VALUE"> <block type="logic_boolean" id="UB*(^+A1-V++B7HAcTAM"> <field name="BOOL">TRUE</field> </block> </value> </block> </next> </block> </statement> </block> </next> </block> </statement> <value name="IF1"> <block type="get_value" id="C4MxYat+|)4+vl1[)-6q"> <field name="ATTR">val</field> <field name="OID">ID auswählen</field> </block> </value> <statement name="DO1"> <block type="comment" id="!tL@i.fjbVAv|0Bhf*uA"> <field name="COMMENT">Falls Brunnen an und Temp unter 5, mach aus</field> <next> <block type="timeouts_cleartimeout" id="-VwVl]s[?@JI|]@V0dY">
          <field name="NAME">timeout</field>
          <next>
          <block type="timeouts_settimeout" id="B,Q3];yX2i^3`CdMu_sT">
          <field name="NAME">timeout2</field>
          <field name="DELAY">1000</field>
          <field name="UNIT">ms</field>
          <statement name="STATEMENT">
          <block type="control" id="|#7wDV$7A0!x!{mg]P2M">
          <mutation xmlns="http://www.w3.org/1999/xhtml" delay_input="false"></mutation>
          <field name="OID">Object ID</field>
          <field name="WITH_DELAY">FALSE</field>
          <value name="VALUE">
          <block type="logic_boolean" id="ofN]0gY|FFCB7mp3PjdJ">
          <field name="BOOL">FALSE</field>
          </block>
          </value>
          </block>
          </statement>
          </block>
          </next>
          </block>
          </next>
          </block>
          </statement>
          </block>
          </next>
          </block>
          </statement>
          </block>
          </next>
          </block>
          </statement>
          </block>
          </next>
          </block>
          </next>
          </block>
          </xml>

          @paul53 hat die Schwankungen um 5° über 5,5° ausgeschlossen. Ich habe ein Timeout, so dass die Temperatur 30 Minuten über oder unter 5° sein muss, bevor geschaltet wird.
          Denke dass das mit den 5,5 sinnvoller ist.

          Aber da ich es nunmal schon gebaut hatte, wollte ich es nicht wieder löschen 😉

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

            @paul53 wird bei diesen Scrips die Temperatur mehrfach überprüft, so das wenn es beim Sonnenaufgang noch unter 5° ist, der runnen aus bleibt und wenn es dann Tagsüber wärmer wird, Trotzdem der Brunnen anspringt?

            paul53 Homoran 2 Replies Last reply Reply Quote 0
            • paul53
              paul53 @Blueskorpion last edited by

              @blueskorpion sagte: Temperatur mehrfach überprüft

              Die Temperatur triggert bei jeder Wertänderung.

              @blueskorpion sagte in Astrofunktion mit Temperaturüberwachung:

              wenn es dann Tagsüber wärmer wird, Trotzdem der Brunnen anspringt?

              Ja.

              1 Reply Last reply Reply Quote 0
              • Homoran
                Homoran Global Moderator Administrators @Blueskorpion last edited by

                @blueskorpion sagte in Astrofunktion mit Temperaturüberwachung:

                wird bei diesen Scrips die Temperatur mehrfach überprüft, so das wenn es beim Sonnenaufgang noch unter 5° ist, der runnen aus bleibt und wenn es dann Tagsüber wärmer wird, Trotzdem der Brunnen anspringt?

                ja! Es wird bei jeder Änderung der Temperatur geprüft und ggf. geschaltet

                1 Reply Last reply Reply Quote 0
                • B
                  Blueskorpion @lessthanmore last edited by

                  @lessthanmore die gelben zeilen, muss ich die dort auch einfügen?

                  L Homoran 2 Replies Last reply Reply Quote 0
                  • L
                    lessthanmore @Blueskorpion last edited by

                    @blueskorpion Nein, das sind Kommentare, damit du weißt, was wo sein sollte.
                    Im Spoiler kannst du den Code kopieren und einfach in Blockly importieren.

                    B 1 Reply Last reply Reply Quote 0
                    • Homoran
                      Homoran Global Moderator Administrators @Blueskorpion last edited by

                      @blueskorpion sagte in Astrofunktion mit Temperaturüberwachung:

                      @lessthanmore die gelben zeilen, muss ich die dort auch einfügen?

                      das sind (optionale) Kommentare, damit du nach Monaten auch noch weisst warum das jetzt so ist

                      1 Reply Last reply Reply Quote 0
                      • B
                        Blueskorpion @lessthanmore last edited by

                        @lessthanmore wie kann ich den Code Kopieren? Also brauche ich im Blockly nicht alles suchen?

                        Homoran 1 Reply Last reply Reply Quote 0
                        • Homoran
                          Homoran Global Moderator Administrators @Blueskorpion last edited by

                          @blueskorpion sagte in Astrofunktion mit Temperaturüberwachung:

                          wie kann ich den Code Kopieren

                          Spoiler öffnen, inhalt mit STRG-C in die Zwischenablage
                          js-Editor mit neuem Blockly öffnen und Importieren (Icon oben rechts "irgendwo")

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

                            @paul53 said in Astrofunktion mit Temperaturüberwachung:

                            @blueskorpion sagt: Über Vorschläge würde ich mich freuen.

                            Bild_2021-10-22_151428.png

                            Nochmal ne frage, was hat es mit der Pumpe in dem Script Aufsich?

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

                              @blueskorpion sagte: was hat es mit der Pumpe in dem Script Aufsich?

                              Das ist der Datenpunkt, der den Brunnen aktiviert (hatte gerade keinen anderen zur Hand).

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

                                @paul53 said in Astrofunktion mit Temperaturüberwachung:

                                @blueskorpion sagte: was hat es mit der Pumpe in dem Script Aufsich?

                                Das ist der Datenpunkt, der den Brunnen aktiviert (hatte gerade keinen anderen zur Hand).

                                Sorry, aber was muss ich den da eintragen? Stehe bisschen auf dem Schlauch. Ich habe doch nur einmal die Temperatur und den Trigger fürs Ein und ausschalten

                                L 1 Reply Last reply Reply Quote 0
                                • L
                                  lessthanmore @Blueskorpion last edited by

                                  @blueskorpion Den Datenpunkt mit dem du den Brunnen einschaltest.

                                  B 1 Reply Last reply Reply Quote 0
                                  • B
                                    Blueskorpion @lessthanmore last edited by

                                    @lessthanmore also entweder die Temperatur oder die Astro Funktion

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

                                      @blueskorpion sagte: Brunnen installiert, welcher über ein Shelly Plug S gesteuert wird.

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

                                        @paul53 richtig, also ist brunnen der plug s?

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

                                          @blueskorpion sagte: ist brunnen der plug s?

                                          Was sonst?

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

                                            @paul53 das verstehe ich ja, nur die Pumpe war für mich nicht verständlich.

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

                                            Support us

                                            ioBroker
                                            Community Adapters
                                            Donate

                                            842
                                            Online

                                            32.0k
                                            Users

                                            80.5k
                                            Topics

                                            1.3m
                                            Posts

                                            4
                                            20
                                            267
                                            Loading More Posts
                                            • Oldest to Newest
                                            • Newest to Oldest
                                            • Most Votes
                                            Reply
                                            • Reply as topic
                                            Log in to reply
                                            Community
                                            Impressum | Datenschutz-Bestimmungen | Nutzungsbedingungen
                                            The ioBroker Community 2014-2023
                                            logo