Navigation

    Logo
    • Register
    • Login
    • Search
    • Recent
    • Tags
    • Unread
    • Categories
    • Unreplied
    • Popular
    • GitHub
    • Docu
    • Hilfe
    1. Home
    2. Deutsch
    3. Skripten / Logik
    4. Blockly
    5. Nachricht wenn es an der Haustür klingelt

    NEWS

    • Neuer Blog: Fotos und Eindrücke aus Solingen

    • ioBroker@Smart Living Forum Solingen, 14.06. - Agenda added

    • ioBroker goes Matter ... Matter Adapter in Stable

    Nachricht wenn es an der Haustür klingelt

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

      @Ja-rod sagte:

      ich bekomme jetzt überhaupt keine Benachrichtigung mehr

      Anstelle von

      und KlingelStop == falsch
      

      verwende

      und nicht KlingelStop
      

      oder initialisiere die Variable KlingelStop bei Skriptstart auf falsch.

      1 Reply Last reply Reply Quote 0
      • Asgothian
        Asgothian Developer @Ja.rod last edited by

        @Ja-rod

        Das ist ein klassisches "entprell" Problem.
        So wie es aussieht fehlt nur ein "Klingelstop = falsch" vor dem Trigger.

        A.

        1 Reply Last reply Reply Quote 0
        • J
          Ja.rod last edited by

          Entschuldigt, aber wahrscheinlich sehe ich den Wald vor lauter Bäumen nicht...
          Sobald es einmal geklingelt hat wird die Variable "Klingelstop" auf wahr gesetzt, damit bei einem weiteren Klingeln innerhalb von 2 Minuten das Script nicht erneut ausgeführt wird. Mit dem Timeout wird die Variable "Klingelstop" zeitverzögert um 2 Minuten wieder auf "falsch" gesetzt, somit kann das Script wieder ganz normal" durchlaufen und es wird eine Nachricht rausgeschickt wenn es klingelt.
          Wenn ich jetzt die Variable "Klingelstop" bei Scriptstart auf "Falsche" setzt oder dies auch vor dem Trigger mache , wird dann nicht der Timeout von 2 min nutzlos?

          paul53 1 Reply Last reply Reply Quote 0
          • paul53
            paul53 @Ja.rod last edited by paul53

            @Ja-rod sagte:

            Sobald es einmal geklingelt hat wird die Variable "Klingelstop" auf wahr gesetzt

            Soweit kommt es nicht, weil die Variable KlingelStop nach Skriptstart auf undefined steht.

            @Ja-rod sagte in Nachricht wenn es an der Haustür klingelt:

            wird dann nicht der Timeout von 2 min nutzlos?

            Nein, die Initialisierung auf falsch erfolgt außerhalb des Triggers (nur einmal bei Skriptstart). Innerhalb des Triggers wird die Variable mit Verzögerung auf falsch gesetzt.

            1 Reply Last reply Reply Quote 0
            • crunchip
              crunchip Forum Testing Most Active last edited by

              hab das so wie hier
              https://www.youtube.com/watch?v=-NjcFdLBGgo
              1ed035db-1936-4194-a8da-95a368458f33-image.png

              E 1 Reply Last reply Reply Quote 0
              • E
                eMd @crunchip last edited by

                @crunchip
                Was lässt du dort dimmen und farbig leuchten? Erzähl mal, ich suche imemr Ideen die einer umsetzung verlangen 🙂

                MfG
                eMd

                crunchip 1 Reply Last reply Reply Quote 0
                • Wal
                  Wal Developer @Ja.rod last edited by

                  @Ja-rod

                  Hier sogar mit Bild von einer Webcam.

                  var request = require('request');
                  var fs      = require('fs');
                  var bell = true;
                  
                  function sendImage() {
                      request.get({url: 'http://192.168.12.85:9900/?action=snapshot', encoding: 'binary'}, function (err, response, body) {
                          fs.writeFile("/tmp/snap.jpg", body, 'binary', function(err) {
                  
                          if (err) {
                              console.error(err);
                          } else {
                              console.log('Snapshot sent');
                              sendTo('telegram.0', {text: '/tmp/snap.jpg', caption: 'Jemand klingelt an der Haustür !!!'});   
                          }
                        });
                      });
                  }
                  
                  on({id: "mqtt.0.piface.input.DoorBell_1", val: true}, function (obj) {
                      if (bell) sendImage();
                      bell = false;
                      timer = setTimeout(function() {
                          bell = true;
                        }, 120000);
                  });
                  
                  1 Reply Last reply Reply Quote 0
                  • crunchip
                    crunchip Forum Testing Most Active @eMd last edited by crunchip

                    @eMd ne Xiaomi Gateway
                    mit diesem Teil im Blockly lass ich mir das Kamera Bild am Tablet anzeigen
                    f43b8ccf-06e4-460b-bf4b-f745d5c00cf1-image.png

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

                      Könnt ihr mir sagen welche Sensoren etc ihr verbaut habt damit getriggert wird? Würde auch gerne meine Haustüre smart machen.

                      crunchip 1 Reply Last reply Reply Quote 0
                      • crunchip
                        crunchip Forum Testing Most Active @SeiteBallon74 last edited by

                        @SeiteBallon74 xiaomi tür/fenster kontakt

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

                        Support us

                        ioBroker
                        Community Adapters
                        Donate

                        869
                        Online

                        31.9k
                        Users

                        80.1k
                        Topics

                        1.3m
                        Posts

                        7
                        11
                        1025
                        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