Navigation

    Logo
    • Register
    • Login
    • Search
    • Recent
    • Tags
    • Unread
    • Categories
    • Unreplied
    • Popular
    • GitHub
    • Docu
    • Hilfe
    1. Home
    2. Deutsch
    3. Skripten / Logik
    4. Node-Red
    5. Garagentor überwachen

    NEWS

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

    • ioBroker goes Matter ... Matter Adapter in Stable

    • Monatsrückblick - April 2025

    Garagentor überwachen

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

      Hallo,

      ich habe einen Adapter an meinem Garagentor. Die momentane Position des Tores wird mir per MQTT in einem Wert übermittelt (0=zu ... 100=komplett offen).

      Ich würde nun gerne wenn das Tor vom Wert (5 bis ca. 10) ansteigt ab 20 das Licht in der Garage anschalten (Shelly). 5 deswegen will bis vier die Garage noch leicht zum lüften geöffnet werden kann.

      Ich habe gerade keine Idee wie ich das mit Node Red auswerten kann. MQTT in für den Wert habe ich schon, aber wie geht es dann weiter? Danke für etwas Hilfe hierbei.

      mickym 1 Reply Last reply Reply Quote 0
      • mickym
        mickym Most Active @hotspot_2 last edited by

        @hotspot_2 Nun triggern muss mqtt. Dann musst Du überprüfen, ob der Wert ansteigt (was das 5-10 bedeutet) verstehe ich nicht - weiß aber nicht, ob das notwendig ist und dann halt ab 20 einschalten. Also erst prüfen, ob ansteigend und ab 20 Licht einschalten, wenn noch nicht eingeschaltet.

        H 1 Reply Last reply Reply Quote 0
        • H
          hotspot_2 @mickym last edited by

          @mickym Genau, das passt. Prüfen ob ansteigend und dann ab 10 oder 20 Licht an.

          Wie mach ich das?

          mickym 1 Reply Last reply Reply Quote 0
          • mickym
            mickym Most Active @hotspot_2 last edited by

            @hotspot_2

            [
               {
                   "id": "7168f4fee6b218e3",
                   "type": "mqtt in",
                   "z": "7e6af0015415146d",
                   "d": true,
                   "name": "",
                   "topic": "tor",
                   "qos": "2",
                   "datatype": "auto-detect",
                   "broker": "be6c1eaab0dff4fe",
                   "nl": false,
                   "rap": true,
                   "rh": 0,
                   "inputs": 0,
                   "x": 130,
                   "y": 6900,
                   "wires": [
                       [
                           "e4fa43d23db23eed"
                       ]
                   ]
               },
               {
                   "id": "e4fa43d23db23eed",
                   "type": "switch",
                   "z": "7e6af0015415146d",
                   "name": "Tor geht auf/zu",
                   "property": "payload",
                   "propertyType": "msg",
                   "rules": [
                       {
                           "t": "gt",
                           "v": "",
                           "vt": "prev"
                       },
                       {
                           "t": "lt",
                           "v": "",
                           "vt": "prev"
                       }
                   ],
                   "checkall": "true",
                   "repair": false,
                   "outputs": 2,
                   "x": 300,
                   "y": 6900,
                   "wires": [
                       [
                           "e1f420dd6fa1957c"
                       ],
                       []
                   ],
                   "outputLabels": [
                       "Tor auf",
                       "Tor zu"
                   ]
               },
               {
                   "id": "e1f420dd6fa1957c",
                   "type": "switch",
                   "z": "7e6af0015415146d",
                   "name": "Tor über 20%",
                   "property": "payload",
                   "propertyType": "msg",
                   "rules": [
                       {
                           "t": "gte",
                           "v": "20",
                           "vt": "num"
                       }
                   ],
                   "checkall": "true",
                   "repair": false,
                   "outputs": 1,
                   "x": 510,
                   "y": 6860,
                   "wires": [
                       [
                           "c449567fbe887ce5"
                       ]
                   ]
               },
               {
                   "id": "c449567fbe887ce5",
                   "type": "ioBroker get",
                   "z": "7e6af0015415146d",
                   "name": "Licht status?",
                   "topic": "",
                   "attrname": "payload",
                   "payloadType": "value",
                   "errOnInvalidState": "nothing",
                   "x": 690,
                   "y": 6860,
                   "wires": [
                       [
                           "6303e8da33fc9b23"
                       ]
                   ]
               },
               {
                   "id": "6303e8da33fc9b23",
                   "type": "switch",
                   "z": "7e6af0015415146d",
                   "name": "Licht aus?",
                   "property": "payload",
                   "propertyType": "msg",
                   "rules": [
                       {
                           "t": "false"
                       }
                   ],
                   "checkall": "true",
                   "repair": false,
                   "outputs": 1,
                   "x": 870,
                   "y": 6860,
                   "wires": [
                       [
                           "6f9d4a16951d6222"
                       ]
                   ]
               },
               {
                   "id": "9e43424f8a404313",
                   "type": "debug",
                   "z": "7e6af0015415146d",
                   "name": "Licht ein",
                   "active": true,
                   "tosidebar": true,
                   "console": false,
                   "tostatus": false,
                   "complete": "payload",
                   "targetType": "msg",
                   "statusVal": "",
                   "statusType": "auto",
                   "x": 1220,
                   "y": 6900,
                   "wires": []
               },
               {
                   "id": "6f9d4a16951d6222",
                   "type": "change",
                   "z": "7e6af0015415146d",
                   "name": "Licht ein",
                   "rules": [
                       {
                           "t": "set",
                           "p": "payload",
                           "pt": "msg",
                           "to": "true",
                           "tot": "bool"
                       }
                   ],
                   "action": "",
                   "property": "",
                   "from": "",
                   "to": "",
                   "reg": false,
                   "x": 1040,
                   "y": 6860,
                   "wires": [
                       [
                           "9e43424f8a404313"
                       ]
                   ]
               },
               {
                   "id": "be6c1eaab0dff4fe",
                   "type": "mqtt-broker",
                   "name": "",
                   "broker": "192.168.178.104",
                   "port": "1883",
                   "clientid": "mqttClientNodeRedTest",
                   "autoConnect": true,
                   "usetls": false,
                   "protocolVersion": "4",
                   "keepalive": "60",
                   "cleansession": true,
                   "autoUnsubscribe": true,
                   "birthTopic": "",
                   "birthQos": "0",
                   "birthPayload": "",
                   "birthMsg": {},
                   "closeTopic": "",
                   "closeQos": "0",
                   "closePayload": "",
                   "closeMsg": {},
                   "willTopic": "",
                   "willQos": "0",
                   "willPayload": "",
                   "willMsg": {},
                   "userProps": "",
                   "sessionExpiry": ""
               }
            ]
            

            e081c63c-5978-458c-ac97-b83f31958844-image.png

            H 1 Reply Last reply Reply Quote 1
            • H
              hotspot_2 @mickym last edited by

              @mickym Vielen Dank! Läuft perfekt.

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

              Support us

              ioBroker
              Community Adapters
              Donate

              719
              Online

              31.7k
              Users

              79.7k
              Topics

              1.3m
              Posts

              2
              5
              174
              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