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. Function Node welche zwei Werte vergleicht

    NEWS

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

    • ioBroker goes Matter ... Matter Adapter in Stable

    • Monatsrückblick - April 2025

    Function Node welche zwei Werte vergleicht

    This topic has been deleted. Only users with topic management privileges can see it.
    • 1
      1984chris @mickym last edited by

      @mickym
      Vielen Danke, werde es später probieren.
      Muss jetzt leider weg.
      Melde mich später wieder.

      LG Christoph

      1 1 Reply Last reply Reply Quote 0
      • 1
        1984chris @1984chris last edited by

        @1984chris
        bin gerade am testen will damit einen shelly ein oder Ausschalten wenn die Filter Node am Ende ist funktioniert das nicht. Wenn ich Schgalter aus mit 1 ON und Schalter aus mit 0 Off verbinde funktioniert es. Es werden dann halt wenn sekündlich Werte geschickt werden z.b für Ein diese immer weitergeleitet an den Shelly wie kann ich das unterbinden?

        [
            {
                "id": "be0d20ba8c83cf52",
                "type": "inject",
                "z": "b7365eb2cd9f043a",
                "name": "",
                "props": [
                    {
                        "p": "payload"
                    },
                    {
                        "p": "topic",
                        "vt": "str"
                    }
                ],
                "repeat": "",
                "crontab": "",
                "once": false,
                "onceDelay": 0.1,
                "topic": "Verbraucher 1",
                "payload": "0",
                "payloadType": "num",
                "x": 140,
                "y": 540,
                "wires": [
                    [
                        "69beb01e48cbb490"
                    ]
                ]
            },
            {
                "id": "69beb01e48cbb490",
                "type": "join",
                "z": "b7365eb2cd9f043a",
                "name": "",
                "mode": "custom",
                "build": "object",
                "property": "payload",
                "propertyType": "msg",
                "key": "topic",
                "joiner": "\\n",
                "joinerType": "str",
                "accumulate": true,
                "timeout": "",
                "count": "1",
                "reduceRight": false,
                "reduceExp": "",
                "reduceInit": "",
                "reduceInitType": "",
                "reduceFixup": "",
                "x": 790,
                "y": 540,
                "wires": [
                    [
                        "423fc589613bb585"
                    ]
                ]
            },
            {
                "id": "e27beb8583aa4ba3",
                "type": "inject",
                "z": "b7365eb2cd9f043a",
                "name": "",
                "props": [
                    {
                        "p": "payload"
                    },
                    {
                        "p": "topic",
                        "vt": "str"
                    }
                ],
                "repeat": "",
                "crontab": "",
                "once": false,
                "onceDelay": 0.1,
                "topic": "Verbraucher 1",
                "payload": "60",
                "payloadType": "num",
                "x": 140,
                "y": 500,
                "wires": [
                    [
                        "69beb01e48cbb490"
                    ]
                ]
            },
            {
                "id": "a2acd308ce3c999b",
                "type": "inject",
                "z": "b7365eb2cd9f043a",
                "name": "",
                "props": [
                    {
                        "p": "payload"
                    },
                    {
                        "p": "topic",
                        "vt": "str"
                    }
                ],
                "repeat": "",
                "crontab": "",
                "once": false,
                "onceDelay": 0.1,
                "topic": "Verbraucher 3",
                "payload": "2300",
                "payloadType": "num",
                "x": 130,
                "y": 660,
                "wires": [
                    [
                        "69beb01e48cbb490"
                    ]
                ]
            },
            {
                "id": "0c034a90eacd5fc4",
                "type": "inject",
                "z": "b7365eb2cd9f043a",
                "name": "",
                "props": [
                    {
                        "p": "payload"
                    },
                    {
                        "p": "topic",
                        "vt": "str"
                    }
                ],
                "repeat": "",
                "crontab": "",
                "once": false,
                "onceDelay": 0.1,
                "topic": "Verbraucher 2",
                "payload": "100",
                "payloadType": "num",
                "x": 130,
                "y": 580,
                "wires": [
                    [
                        "69beb01e48cbb490"
                    ]
                ]
            },
            {
                "id": "89f4ac760b787b09",
                "type": "inject",
                "z": "b7365eb2cd9f043a",
                "name": "",
                "props": [
                    {
                        "p": "payload"
                    },
                    {
                        "p": "topic",
                        "vt": "str"
                    }
                ],
                "repeat": "",
                "crontab": "",
                "once": false,
                "onceDelay": 0.1,
                "topic": "Verbraucher 2",
                "payload": "0",
                "payloadType": "num",
                "x": 140,
                "y": 620,
                "wires": [
                    [
                        "69beb01e48cbb490"
                    ]
                ]
            },
            {
                "id": "eb464f1d17573074",
                "type": "inject",
                "z": "b7365eb2cd9f043a",
                "name": "",
                "props": [
                    {
                        "p": "payload"
                    },
                    {
                        "p": "topic",
                        "vt": "str"
                    }
                ],
                "repeat": "",
                "crontab": "",
                "once": false,
                "onceDelay": 0.1,
                "topic": "Verbraucher 3",
                "payload": "0",
                "payloadType": "num",
                "x": 140,
                "y": 700,
                "wires": [
                    [
                        "69beb01e48cbb490"
                    ]
                ]
            },
            {
                "id": "423fc589613bb585",
                "type": "change",
                "z": "b7365eb2cd9f043a",
                "name": "Summe Verbrauch",
                "rules": [
                    {
                        "t": "set",
                        "p": "payload",
                        "pt": "msg",
                        "to": "$sum(payload.*)",
                        "tot": "jsonata"
                    },
                    {
                        "t": "set",
                        "p": "Verbrauch",
                        "pt": "flow",
                        "to": "payload",
                        "tot": "msg"
                    }
                ],
                "action": "",
                "property": "",
                "from": "",
                "to": "",
                "reg": false,
                "x": 970,
                "y": 540,
                "wires": [
                    [
                        "a846941657aec3a0",
                        "ae6c196add3ae406"
                    ]
                ]
            },
            {
                "id": "a846941657aec3a0",
                "type": "debug",
                "z": "b7365eb2cd9f043a",
                "name": "Summe Verbrauch",
                "active": true,
                "tosidebar": true,
                "console": false,
                "tostatus": false,
                "complete": "payload",
                "targetType": "msg",
                "statusVal": "",
                "statusType": "auto",
                "x": 1210,
                "y": 540,
                "wires": []
            },
            {
                "id": "ae6c196add3ae406",
                "type": "change",
                "z": "b7365eb2cd9f043a",
                "name": "",
                "rules": [
                    {
                        "t": "set",
                        "p": "payload",
                        "pt": "msg",
                        "to": "{\t \"AutoEin\":$exists($flowContext(\"AutoEin\")),\t \"Einspeisung\":$exists($flowContext(\"Einspeisung\")),\t \"SOC\":$exists($flowContext(\"SOC\")),\t \"Verbrauch\": $exists($flowContext(\"Verbrauch\"))\t}",
                        "tot": "jsonata"
                    }
                ],
                "action": "",
                "property": "",
                "from": "",
                "to": "",
                "reg": false,
                "x": 1310,
                "y": 240,
                "wires": [
                    [
                        "c682c690f3686aba",
                        "8a0e4f6d9aadf84a"
                    ]
                ]
            },
            {
                "id": "ad44ce022520acb9",
                "type": "junction",
                "z": "b7365eb2cd9f043a",
                "x": 940,
                "y": 240,
                "wires": [
                    [
                        "ae6c196add3ae406"
                    ]
                ]
            },
            {
                "id": "c682c690f3686aba",
                "type": "switch",
                "z": "b7365eb2cd9f043a",
                "name": "AND?",
                "property": "$reduce(payload.*,function($i, $j){$i and $j})",
                "propertyType": "jsonata",
                "rules": [
                    {
                        "t": "true"
                    }
                ],
                "checkall": "true",
                "repair": false,
                "outputs": 1,
                "x": 1490,
                "y": 240,
                "wires": [
                    [
                        "296fc791b35c3cf0",
                        "611f290ee889a6c9"
                    ]
                ],
                "info": "# All properties of an object must be true.\n\nAll properties of an object must be true.\n\n`{\n \"Office\": true,\n \"Bedroom\": true,\n \"Living Room Balcony\": true,\n \"Living Room Right Window\": true,\n \"Living Room Left Window\": true\n}`\n\nis true,\n\n`{\n \"Office\": true,\n \"Bedroom\": false,\n \"Living Room Balcony\": true,\n \"Living Room Right Window\": true,\n \"Living Room Left Window\": true\n}`\n\nis false.\n\n# Alle Eigenschaften eines Objektes müssen wahr sein\n\nAlle Eigenschaften eines Objektes müssen wahr sein.\n\n`{\n \"Büro Balkon\": true,\n \"Schlafzimmer Balkon\": true,\n \"Wohnzimmer Balkon\": true,\n \"Wohnzimmer rechtes Fenster\": true,\n \"Wohnzimmer linkes Fenster\": true\n}`\n\nergibt true,\n\n`{\n \"Büro Balkon\": true,\n \"Schlafzimmer Balkon\": true,\n \"Wohnzimmer Balkon\": true,\n \"Wohnzimmer rechtes Fenster\": false,\n \"Wohnzimmer linkes Fenster\": true\n}`\n\nergibt false."
            },
            {
                "id": "8a0e4f6d9aadf84a",
                "type": "debug",
                "z": "b7365eb2cd9f043a",
                "name": "Alle Parameter",
                "active": false,
                "tosidebar": true,
                "console": false,
                "tostatus": false,
                "complete": "payload",
                "targetType": "msg",
                "statusVal": "",
                "statusType": "auto",
                "x": 1520,
                "y": 180,
                "wires": []
            },
            {
                "id": "075995c61d50b0fc",
                "type": "change",
                "z": "b7365eb2cd9f043a",
                "name": "",
                "rules": [
                    {
                        "t": "set",
                        "p": "AutoEin",
                        "pt": "flow",
                        "to": "payload",
                        "tot": "msg"
                    }
                ],
                "action": "",
                "property": "",
                "from": "",
                "to": "",
                "reg": false,
                "x": 750,
                "y": 120,
                "wires": [
                    [
                        "ad44ce022520acb9"
                    ]
                ]
            },
            {
                "id": "81cca1013046684b",
                "type": "change",
                "z": "b7365eb2cd9f043a",
                "name": "",
                "rules": [
                    {
                        "t": "set",
                        "p": "Einspeisung",
                        "pt": "flow",
                        "to": "payload",
                        "tot": "msg"
                    }
                ],
                "action": "",
                "property": "",
                "from": "",
                "to": "",
                "reg": false,
                "x": 740,
                "y": 240,
                "wires": [
                    [
                        "ad44ce022520acb9",
                        "86c5f5293c29797f"
                    ]
                ]
            },
            {
                "id": "723be488aa772937",
                "type": "change",
                "z": "b7365eb2cd9f043a",
                "name": "",
                "rules": [
                    {
                        "t": "set",
                        "p": "SOC",
                        "pt": "flow",
                        "to": "payload",
                        "tot": "msg"
                    }
                ],
                "action": "",
                "property": "",
                "from": "",
                "to": "",
                "reg": false,
                "x": 740,
                "y": 340,
                "wires": [
                    [
                        "ad44ce022520acb9"
                    ]
                ]
            },
            {
                "id": "296fc791b35c3cf0",
                "type": "debug",
                "z": "b7365eb2cd9f043a",
                "name": "Alle Parameter gesetzt?",
                "active": false,
                "tosidebar": true,
                "console": false,
                "tostatus": false,
                "complete": "payload",
                "targetType": "msg",
                "statusVal": "",
                "statusType": "auto",
                "x": 1790,
                "y": 180,
                "wires": []
            },
            {
                "id": "611f290ee889a6c9",
                "type": "switch",
                "z": "b7365eb2cd9f043a",
                "name": "Auto Ein/Aus",
                "property": "AutoEin",
                "propertyType": "flow",
                "rules": [
                    {
                        "t": "cont",
                        "v": "AutoEin",
                        "vt": "str"
                    },
                    {
                        "t": "else"
                    }
                ],
                "checkall": "true",
                "repair": false,
                "outputs": 2,
                "x": 1710,
                "y": 240,
                "wires": [
                    [
                        "e917da2b3033e0ad"
                    ],
                    [
                        "4064534edf8a91ba"
                    ]
                ]
            },
            {
                "id": "3527032527097f5a",
                "type": "inject",
                "z": "b7365eb2cd9f043a",
                "name": "",
                "props": [
                    {
                        "p": "payload"
                    },
                    {
                        "p": "topic",
                        "vt": "str"
                    }
                ],
                "repeat": "",
                "crontab": "",
                "once": false,
                "onceDelay": 0.1,
                "topic": "AutoEin",
                "payload": "AutoEin",
                "payloadType": "str",
                "x": 180,
                "y": 40,
                "wires": [
                    [
                        "075995c61d50b0fc"
                    ]
                ]
            },
            {
                "id": "aa347550f2f3195a",
                "type": "inject",
                "z": "b7365eb2cd9f043a",
                "name": "",
                "props": [
                    {
                        "p": "payload"
                    },
                    {
                        "p": "topic",
                        "vt": "str"
                    }
                ],
                "repeat": "",
                "crontab": "",
                "once": false,
                "onceDelay": 0.1,
                "topic": "AutoAus",
                "payload": "AutoAus",
                "payloadType": "str",
                "x": 220,
                "y": 80,
                "wires": [
                    [
                        "075995c61d50b0fc"
                    ]
                ]
            },
            {
                "id": "60b09aa662d21699",
                "type": "inject",
                "z": "b7365eb2cd9f043a",
                "name": "",
                "props": [
                    {
                        "p": "payload"
                    }
                ],
                "repeat": "",
                "crontab": "",
                "once": false,
                "onceDelay": 0.1,
                "topic": "",
                "payload": "2600",
                "payloadType": "num",
                "x": 170,
                "y": 240,
                "wires": [
                    [
                        "81cca1013046684b"
                    ]
                ]
            },
            {
                "id": "de72bd27154966a3",
                "type": "inject",
                "z": "b7365eb2cd9f043a",
                "name": "",
                "props": [
                    {
                        "p": "payload"
                    }
                ],
                "repeat": "",
                "crontab": "",
                "once": false,
                "onceDelay": 0.1,
                "topic": "",
                "payload": "2300",
                "payloadType": "num",
                "x": 170,
                "y": 280,
                "wires": [
                    [
                        "81cca1013046684b"
                    ]
                ]
            },
            {
                "id": "034ed6ed5c92fe19",
                "type": "inject",
                "z": "b7365eb2cd9f043a",
                "name": "",
                "props": [
                    {
                        "p": "payload"
                    }
                ],
                "repeat": "",
                "crontab": "",
                "once": false,
                "onceDelay": 0.1,
                "topic": "",
                "payload": "4500",
                "payloadType": "num",
                "x": 170,
                "y": 320,
                "wires": [
                    [
                        "81cca1013046684b"
                    ]
                ]
            },
            {
                "id": "86c5f5293c29797f",
                "type": "debug",
                "z": "b7365eb2cd9f043a",
                "name": "Einspeisung",
                "active": true,
                "tosidebar": true,
                "console": false,
                "tostatus": false,
                "complete": "payload",
                "targetType": "msg",
                "statusVal": "",
                "statusType": "auto",
                "x": 990,
                "y": 320,
                "wires": []
            },
            {
                "id": "a81140ec925e801f",
                "type": "inject",
                "z": "b7365eb2cd9f043a",
                "name": "",
                "props": [
                    {
                        "p": "payload"
                    }
                ],
                "repeat": "",
                "crontab": "",
                "once": false,
                "onceDelay": 0.1,
                "topic": "",
                "payload": "81",
                "payloadType": "num",
                "x": 110,
                "y": 380,
                "wires": [
                    [
                        "723be488aa772937"
                    ]
                ]
            },
            {
                "id": "d71c87a4f57fa8a9",
                "type": "inject",
                "z": "b7365eb2cd9f043a",
                "name": "",
                "props": [
                    {
                        "p": "payload"
                    }
                ],
                "repeat": "",
                "crontab": "",
                "once": false,
                "onceDelay": 0.1,
                "topic": "",
                "payload": "79",
                "payloadType": "num",
                "x": 110,
                "y": 420,
                "wires": [
                    [
                        "723be488aa772937"
                    ]
                ]
            },
            {
                "id": "e917da2b3033e0ad",
                "type": "switch",
                "z": "b7365eb2cd9f043a",
                "name": "Überschuss > 2500W",
                "property": "$flowContext(\"Einspeisung\") - $flowContext(\"Verbrauch\")\t\t",
                "propertyType": "jsonata",
                "rules": [
                    {
                        "t": "gt",
                        "v": "2500",
                        "vt": "num"
                    },
                    {
                        "t": "else"
                    }
                ],
                "checkall": "true",
                "repair": false,
                "outputs": 2,
                "x": 1920,
                "y": 220,
                "wires": [
                    [
                        "fa07332ccb7479f3"
                    ],
                    [
                        "62b38ef63522d9ae"
                    ]
                ]
            },
            {
                "id": "4064534edf8a91ba",
                "type": "junction",
                "z": "b7365eb2cd9f043a",
                "x": 1820,
                "y": 300,
                "wires": [
                    [
                        "62b38ef63522d9ae"
                    ]
                ]
            },
            {
                "id": "fa07332ccb7479f3",
                "type": "switch",
                "z": "b7365eb2cd9f043a",
                "name": "SOC > 80%",
                "property": "SOC",
                "propertyType": "flow",
                "rules": [
                    {
                        "t": "gt",
                        "v": "80",
                        "vt": "num"
                    },
                    {
                        "t": "else"
                    }
                ],
                "checkall": "true",
                "repair": false,
                "outputs": 2,
                "x": 2190,
                "y": 220,
                "wires": [
                    [
                        "07419de8e60d43c6",
                        "4a3b1677942b79db"
                    ],
                    [
                        "12d84d1a6640f144"
                    ]
                ]
            },
            {
                "id": "62b38ef63522d9ae",
                "type": "junction",
                "z": "b7365eb2cd9f043a",
                "x": 2100,
                "y": 300,
                "wires": [
                    [
                        "12d84d1a6640f144"
                    ]
                ]
            },
            {
                "id": "07419de8e60d43c6",
                "type": "change",
                "z": "b7365eb2cd9f043a",
                "name": "Schalter Ein",
                "rules": [
                    {
                        "t": "set",
                        "p": "payload",
                        "pt": "msg",
                        "to": "Pumpe Ein 1",
                        "tot": "str"
                    }
                ],
                "action": "",
                "property": "",
                "from": "",
                "to": "",
                "reg": false,
                "x": 2410,
                "y": 200,
                "wires": [
                    [
                        "aafdd4e5972e1401"
                    ]
                ]
            },
            {
                "id": "4a3b1677942b79db",
                "type": "change",
                "z": "b7365eb2cd9f043a",
                "name": "",
                "rules": [
                    {
                        "t": "set",
                        "p": "reset",
                        "pt": "msg",
                        "to": "true",
                        "tot": "bool"
                    },
                    {
                        "t": "set",
                        "p": "payload",
                        "pt": "msg",
                        "to": "1",
                        "tot": "str"
                    }
                ],
                "action": "",
                "property": "",
                "from": "",
                "to": "",
                "reg": false,
                "x": 2430,
                "y": 240,
                "wires": [
                    [
                        "f15fd06658be8b23",
                        "3c0a215e508cab6f"
                    ]
                ]
            },
            {
                "id": "12d84d1a6640f144",
                "type": "junction",
                "z": "b7365eb2cd9f043a",
                "x": 2420,
                "y": 320,
                "wires": [
                    [
                        "3c0a215e508cab6f"
                    ]
                ]
            },
            {
                "id": "aafdd4e5972e1401",
                "type": "rbe",
                "z": "b7365eb2cd9f043a",
                "name": "",
                "func": "rbe",
                "gap": "",
                "start": "",
                "inout": "out",
                "septopics": false,
                "property": "payload",
                "topi": "topic",
                "x": 3090,
                "y": 220,
                "wires": [
                    [
                        "0858f158df46bb51",
                        "92a59b4ca2939e92",
                        "abb927025f221499"
                    ]
                ]
            },
            {
                "id": "f15fd06658be8b23",
                "type": "delay",
                "z": "b7365eb2cd9f043a",
                "name": "",
                "pauseType": "delay",
                "timeout": "5",
                "timeoutUnits": "seconds",
                "rate": "1",
                "nbRateUnits": "1",
                "rateUnits": "second",
                "randomFirst": "1",
                "randomLast": "5",
                "randomUnits": "seconds",
                "drop": false,
                "allowrate": false,
                "outputs": 1,
                "x": 2720,
                "y": 300,
                "wires": [
                    [
                        "5c2873c0b8c42da6"
                    ]
                ]
            },
            {
                "id": "3c0a215e508cab6f",
                "type": "rbe",
                "z": "b7365eb2cd9f043a",
                "name": "",
                "func": "rbe",
                "gap": "",
                "start": "",
                "inout": "out",
                "septopics": false,
                "property": "payload",
                "topi": "topic",
                "x": 2510,
                "y": 320,
                "wires": [
                    [
                        "f15fd06658be8b23"
                    ]
                ]
            },
            {
                "id": "5c2873c0b8c42da6",
                "type": "change",
                "z": "b7365eb2cd9f043a",
                "name": "Schalter Aus",
                "rules": [
                    {
                        "t": "set",
                        "p": "payload",
                        "pt": "msg",
                        "to": "Pumpe Aus 0",
                        "tot": "str"
                    }
                ],
                "action": "",
                "property": "",
                "from": "",
                "to": "",
                "reg": false,
                "x": 2890,
                "y": 300,
                "wires": [
                    [
                        "aafdd4e5972e1401"
                    ]
                ]
            },
            {
                "id": "0858f158df46bb51",
                "type": "debug",
                "z": "b7365eb2cd9f043a",
                "name": "Ergebnis",
                "active": true,
                "tosidebar": true,
                "console": false,
                "tostatus": false,
                "complete": "payload",
                "targetType": "msg",
                "statusVal": "",
                "statusType": "auto",
                "x": 3240,
                "y": 160,
                "wires": []
            },
            {
                "id": "92a59b4ca2939e92",
                "type": "function",
                "z": "b7365eb2cd9f043a",
                "name": "1 On",
                "func": "msg.payload = {\n    method: \"Switch.Set\",\n    parameters : {\n        id : 0,\n        on: true,\n        \n    }\n};\nreturn msg;",
                "outputs": 1,
                "timeout": "",
                "noerr": 0,
                "initialize": "",
                "finalize": "",
                "libs": [],
                "x": 3290,
                "y": 240,
                "wires": [
                    [
                        "55a334f62dd97366"
                    ]
                ]
            },
            {
                "id": "abb927025f221499",
                "type": "function",
                "z": "b7365eb2cd9f043a",
                "name": "0 off",
                "func": "msg.payload = {\n    method: \"Switch.Set\",\n    parameters : {\n        id : 0,\n        on : false,\n    }\n};\nreturn msg;",
                "outputs": 1,
                "timeout": "",
                "noerr": 0,
                "initialize": "",
                "finalize": "",
                "libs": [],
                "x": 3290,
                "y": 340,
                "wires": [
                    [
                        "55a334f62dd97366"
                    ]
                ]
            },
            {
                "id": "55a334f62dd97366",
                "type": "shelly-gen2",
                "z": "b7365eb2cd9f043a",
                "hostname": "192.168.1.110",
                "description": "",
                "mode": "polling",
                "server": "",
                "outputmode": "event",
                "uploadretryinterval": 5000,
                "pollinginterval": 5000,
                "pollstatus": false,
                "getstatusoncommand": true,
                "devicetype": "Relay",
                "outputs": 1,
                "x": 3620,
                "y": 280,
                "wires": [
                    []
                ]
            }
        ]
        
        mickym 1 Reply Last reply Reply Quote 0
        • mickym
          mickym Most Active @1984chris last edited by mickym

          @1984chris

          Dann mach halt nicht das mit Pumpe ein 0 - das hast Du doch eingeführt, sondern setze die Schalter auf on, off oder true, false.
          Im Übrigen muss man auch nicht über RPC schalten und function Nodes braucht man dafür auch nicht.

          In der Regel mache ich alles über mqtt.
          Wenn Du mqtt nutzt kannst Du auch Gen2 Geräte direkt über einen command topic schalten.

          https://shelly-api-docs.shelly.cloud/gen2/ComponentsAndServices/Switch#mqtt-control

          0a9b6d9f-41e7-4dd8-a0ec-2f697e93b68e-image.png

          Und falls Du Objekte versenden willst, geht das auch mit JSONATA einfacher als mit function Nodes.

          a09ea1e8-a21d-4c9a-ae05-b440d617e8b2-image.png

          Sowas ist Käse - damit schaltest Du gleichzeitig ein und aus. Du musst das doch vorher festlegen.

          Wenn dann schaltest Du true/false vorher - also werde ich jetzt mal Schalter ein auf true setzen und Schalter aus auf false.

          0338fcdd-69e4-4f1f-95d0-840f7769d40c-image.png

          für Schalter aus entsprechend.

          Wenn Du das RPC verwenden willst und nicht das Command über mqtt, dann erstellt man mit einer Change Node das Objekt und die payload, die aus dem filter kommt ist nur true oder false.

          339fb12a-2bec-452c-8aad-223890eb105d-image.png

          Also ab Schalter ein/aus die Nodes durch diese ersetzen - die function Nodes sparst Du Dir und nutzt JSONATA mit einer Change Node.

          [{"id":"07419de8e60d43c6","type":"change","z":"517cd16e4d7e6ae4","name":"Schalter Ein","rules":[{"t":"set","p":"payload","pt":"msg","to":"true","tot":"bool"}],"action":"","property":"","from":"","to":"","reg":false,"x":2890,"y":4440,"wires":[["aafdd4e5972e1401"]]},{"id":"aafdd4e5972e1401","type":"rbe","z":"517cd16e4d7e6ae4","name":"","func":"rbe","gap":"","start":"","inout":"out","septopics":false,"property":"payload","topi":"topic","x":3090,"y":4460,"wires":[["fe12d75c77ea96a9"]]},{"id":"5c2873c0b8c42da6","type":"change","z":"517cd16e4d7e6ae4","name":"Schalter Aus","rules":[{"t":"set","p":"payload","pt":"msg","to":"false","tot":"bool"}],"action":"","property":"","from":"","to":"","reg":false,"x":2890,"y":4540,"wires":[["aafdd4e5972e1401"]]},{"id":"0858f158df46bb51","type":"debug","z":"517cd16e4d7e6ae4","name":"Ergebnis","active":true,"tosidebar":true,"console":false,"tostatus":false,"complete":"payload","targetType":"msg","statusVal":"","statusType":"auto","x":3480,"y":4420,"wires":[]},{"id":"fe12d75c77ea96a9","type":"change","z":"517cd16e4d7e6ae4","name":"","rules":[{"t":"set","p":"payload","pt":"msg","to":"{\t   \"method\": \"Switch.Set\",\t   \"parameters\" : {\t       \"id\" : 0,\t       \"on\": payload       \t   }\t}","tot":"jsonata"}],"action":"","property":"","from":"","to":"","reg":false,"x":3290,"y":4460,"wires":[["0858f158df46bb51"]]}]
          

          Was das dahinten sein soll, verstehe ich nicht

          b28463ed-5c44-49cc-abed-77a89e50c8d7-image.png

          Ich würde es wieder wegschmeissen und meinen ursprünglichen Flow nehmen.

          Hier nochmal mein ursprünglicher Flow - da musst halt die Shelly Node wieder hinten dran hängen - oder Du nutzt halt mqtt und nicht diese Nodes. 😉

          [{"id":"a86c1f1e4b75e441","type":"inject","z":"517cd16e4d7e6ae4","name":"","props":[{"p":"payload"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","payload":"81","payloadType":"num","x":150,"y":3720,"wires":[["494bb9361ae7bea3"]]},{"id":"f18c81168d9f50a0","type":"inject","z":"517cd16e4d7e6ae4","name":"","props":[{"p":"payload"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","payload":"2600","payloadType":"num","x":150,"y":3580,"wires":[["6fa8637750ac1054"]]},{"id":"a3d2d88cd6708218","type":"inject","z":"517cd16e4d7e6ae4","name":"","props":[{"p":"payload"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","payload":"79","payloadType":"num","x":150,"y":3760,"wires":[["494bb9361ae7bea3"]]},{"id":"f3d26ec9c8d67465","type":"inject","z":"517cd16e4d7e6ae4","name":"","props":[{"p":"payload"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","payload":"2300","payloadType":"num","x":150,"y":3620,"wires":[["6fa8637750ac1054"]]},{"id":"84b2fa38187ff34f","type":"inject","z":"517cd16e4d7e6ae4","name":"","props":[{"p":"payload"},{"p":"topic","vt":"str"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"AutoEin","payload":"AutoEin","payloadType":"str","x":140,"y":3480,"wires":[["5e6eefda3fb81cfd"]]},{"id":"eba9ab8e96ae87e8","type":"inject","z":"517cd16e4d7e6ae4","name":"","props":[{"p":"payload"},{"p":"topic","vt":"str"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","payload":"AutoAus","payloadType":"str","x":160,"y":3520,"wires":[["5e6eefda3fb81cfd"]]},{"id":"5e6eefda3fb81cfd","type":"change","z":"517cd16e4d7e6ae4","name":"","rules":[{"t":"set","p":"AutoEin","pt":"flow","to":"payload","tot":"msg"}],"action":"","property":"","from":"","to":"","reg":false,"x":370,"y":3500,"wires":[["043e832f297c9831"]]},{"id":"6fa8637750ac1054","type":"change","z":"517cd16e4d7e6ae4","name":"","rules":[{"t":"set","p":"Einspeisung","pt":"flow","to":"payload","tot":"msg"}],"action":"","property":"","from":"","to":"","reg":false,"x":360,"y":3600,"wires":[["043e832f297c9831","ed14cc2d24f3ff16"]]},{"id":"494bb9361ae7bea3","type":"change","z":"517cd16e4d7e6ae4","name":"","rules":[{"t":"set","p":"SOC","pt":"flow","to":"payload","tot":"msg"}],"action":"","property":"","from":"","to":"","reg":false,"x":360,"y":3700,"wires":[["043e832f297c9831"]]},{"id":"c9bdbf8b0e1b8b42","type":"change","z":"517cd16e4d7e6ae4","name":"","rules":[{"t":"set","p":"payload","pt":"msg","to":"{\t   \"AutoEin\":$exists($flowContext(\"AutoEin\")),\t   \"Einspeisung\":$exists($flowContext(\"Einspeisung\")),\t   \"SOC\":$exists($flowContext(\"SOC\")),\t   \"Verbrauch\": $exists($flowContext(\"SOC\"))\t}","tot":"jsonata"}],"action":"","property":"","from":"","to":"","reg":false,"x":930,"y":3600,"wires":[["9367f9f7.8f5708","3a39b9030c5759fa"]]},{"id":"2975f91defeba563","type":"debug","z":"517cd16e4d7e6ae4","name":"Alle Parameter gesetzt?","active":false,"tosidebar":true,"console":false,"tostatus":false,"complete":"payload","targetType":"msg","statusVal":"","statusType":"auto","x":1410,"y":3540,"wires":[]},{"id":"9367f9f7.8f5708","type":"switch","z":"517cd16e4d7e6ae4","name":"AND?","property":"$reduce(payload.*,function($i, $j){$i and $j})","propertyType":"jsonata","rules":[{"t":"true"}],"checkall":"true","repair":false,"outputs":1,"x":1110,"y":3600,"wires":[["2975f91defeba563","c6ee18440c5ede12"]],"info":"# All properties of an object must be true.\n\nAll properties of an object must be true.\n\n`{\n \"Office\": true,\n \"Bedroom\": true,\n \"Living Room Balcony\": true,\n \"Living Room Right Window\": true,\n \"Living Room Left Window\": true\n}`\n\nis true,\n\n`{\n \"Office\": true,\n \"Bedroom\": false,\n \"Living Room Balcony\": true,\n \"Living Room Right Window\": true,\n \"Living Room Left Window\": true\n}`\n\nis false.\n\n# Alle Eigenschaften eines Objektes müssen wahr sein\n\nAlle Eigenschaften eines Objektes müssen wahr sein.\n\n`{\n \"Büro Balkon\": true,\n \"Schlafzimmer Balkon\": true,\n \"Wohnzimmer Balkon\": true,\n \"Wohnzimmer rechtes Fenster\": true,\n \"Wohnzimmer linkes Fenster\": true\n}`\n\nergibt true,\n\n`{\n \"Büro Balkon\": true,\n \"Schlafzimmer Balkon\": true,\n \"Wohnzimmer Balkon\": true,\n \"Wohnzimmer rechtes Fenster\": false,\n \"Wohnzimmer linkes Fenster\": true\n}`\n\nergibt false."},{"id":"45a1bb09159cf684","type":"switch","z":"517cd16e4d7e6ae4","name":"SOC > 80%","property":"SOC","propertyType":"flow","rules":[{"t":"gt","v":"80","vt":"num"},{"t":"else"}],"checkall":"true","repair":false,"outputs":2,"x":1810,"y":3580,"wires":[["55afcaa9b715c923","e6bff6b181617360"],["a24a10d67adf7325"]]},{"id":"5192b4bc40dd7659","type":"switch","z":"517cd16e4d7e6ae4","name":"Überschuss > 2500W","property":"$flowContext(\"Einspeisung\") - $flowContext(\"Verbrauch\")\t\t","propertyType":"jsonata","rules":[{"t":"gt","v":"2500","vt":"num"},{"t":"else"}],"checkall":"true","repair":false,"outputs":2,"x":1540,"y":3580,"wires":[["45a1bb09159cf684"],["0f2c3c5c8743b77e"]]},{"id":"c6ee18440c5ede12","type":"switch","z":"517cd16e4d7e6ae4","name":"Auto Ein/Aus","property":"AutoEin","propertyType":"flow","rules":[{"t":"cont","v":"AutoEin","vt":"str"},{"t":"else"}],"checkall":"true","repair":false,"outputs":2,"x":1330,"y":3600,"wires":[["5192b4bc40dd7659"],["473eacb13a6cb11c"]]},{"id":"5d671131260cc2d4","type":"change","z":"517cd16e4d7e6ae4","name":"Schalter Aus","rules":[{"t":"set","p":"payload","pt":"msg","to":"false","tot":"bool"}],"action":"","property":"","from":"","to":"","reg":false,"x":2430,"y":3660,"wires":[["ddf39dae01705e59"]]},{"id":"856ab41216e0c0af","type":"delay","z":"517cd16e4d7e6ae4","name":"","pauseType":"delay","timeout":"5","timeoutUnits":"seconds","rate":"1","nbRateUnits":"1","rateUnits":"second","randomFirst":"1","randomLast":"5","randomUnits":"seconds","drop":false,"allowrate":false,"outputs":1,"x":2240,"y":3660,"wires":[["5d671131260cc2d4"]]},{"id":"55afcaa9b715c923","type":"change","z":"517cd16e4d7e6ae4","name":"Schalter Ein","rules":[{"t":"set","p":"payload","pt":"msg","to":"true","tot":"bool"}],"action":"","property":"","from":"","to":"","reg":false,"x":2430,"y":3560,"wires":[["ddf39dae01705e59"]]},{"id":"e6bff6b181617360","type":"change","z":"517cd16e4d7e6ae4","name":"","rules":[{"t":"set","p":"reset","pt":"msg","to":"true","tot":"bool"}],"action":"","property":"","from":"","to":"","reg":false,"x":2040,"y":3600,"wires":[["856ab41216e0c0af"]]},{"id":"19225af3a1bf8b1a","type":"rbe","z":"517cd16e4d7e6ae4","name":"","func":"rbe","gap":"","start":"","inout":"out","septopics":false,"property":"payload","topi":"topic","x":2650,"y":3620,"wires":[["fe12d75c77ea96a9"]]},{"id":"9685a44b6acadc85","type":"inject","z":"517cd16e4d7e6ae4","name":"","props":[{"p":"payload"},{"p":"topic","vt":"str"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"Verbraucher 1","payload":"60","payloadType":"num","x":180,"y":3820,"wires":[["6236f30557c7e780"]]},{"id":"3a39b9030c5759fa","type":"debug","z":"517cd16e4d7e6ae4","name":"Alle Parameter","active":false,"tosidebar":true,"console":false,"tostatus":false,"complete":"payload","targetType":"msg","statusVal":"","statusType":"auto","x":1140,"y":3540,"wires":[]},{"id":"7971d5242a5ea489","type":"inject","z":"517cd16e4d7e6ae4","name":"","props":[{"p":"payload"},{"p":"topic","vt":"str"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"Verbraucher 2","payload":"100","payloadType":"num","x":170,"y":3900,"wires":[["6236f30557c7e780"]]},{"id":"7c3015bff0b30e2e","type":"inject","z":"517cd16e4d7e6ae4","name":"","props":[{"p":"payload"},{"p":"topic","vt":"str"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"Verbraucher 3","payload":"2300","payloadType":"num","x":170,"y":3980,"wires":[["6236f30557c7e780"]]},{"id":"a3f8d990d290d69d","type":"join","z":"517cd16e4d7e6ae4","name":"","mode":"custom","build":"object","property":"payload","propertyType":"msg","key":"topic","joiner":"\\n","joinerType":"str","accumulate":true,"timeout":"","count":"1","reduceRight":false,"reduceExp":"","reduceInit":"","reduceInitType":"","reduceFixup":"","x":410,"y":3900,"wires":[["edaa035f0714e9aa"]]},{"id":"edaa035f0714e9aa","type":"change","z":"517cd16e4d7e6ae4","name":"Summe Verbrauch","rules":[{"t":"set","p":"payload","pt":"msg","to":"$sum(payload.*)","tot":"jsonata"},{"t":"set","p":"Verbrauch","pt":"flow","to":"payload","tot":"msg"}],"action":"","property":"","from":"","to":"","reg":false,"x":590,"y":3900,"wires":[["cf8c319f66d88019","c9bdbf8b0e1b8b42"]]},{"id":"b29693a62628fd9f","type":"inject","z":"517cd16e4d7e6ae4","name":"","props":[{"p":"payload"},{"p":"topic","vt":"str"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"Verbraucher 1","payload":"0","payloadType":"num","x":180,"y":3860,"wires":[["6236f30557c7e780"]]},{"id":"f548db43288fcfb0","type":"inject","z":"517cd16e4d7e6ae4","name":"","props":[{"p":"payload"},{"p":"topic","vt":"str"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"Verbraucher 2","payload":"0","payloadType":"num","x":180,"y":3940,"wires":[["6236f30557c7e780"]]},{"id":"3c6178107678bdff","type":"inject","z":"517cd16e4d7e6ae4","name":"","props":[{"p":"payload"},{"p":"topic","vt":"str"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"Verbraucher 3","payload":"0","payloadType":"num","x":180,"y":4020,"wires":[["6236f30557c7e780"]]},{"id":"cf8c319f66d88019","type":"debug","z":"517cd16e4d7e6ae4","name":"Summe Verbrauch","active":true,"tosidebar":true,"console":false,"tostatus":false,"complete":"payload","targetType":"msg","statusVal":"","statusType":"auto","x":830,"y":3900,"wires":[]},{"id":"43328f2d1b31cb20","type":"inject","z":"517cd16e4d7e6ae4","name":"","props":[{"p":"payload"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","payload":"4500","payloadType":"num","x":150,"y":3660,"wires":[["6fa8637750ac1054"]]},{"id":"ed14cc2d24f3ff16","type":"debug","z":"517cd16e4d7e6ae4","name":"Einspeisung","active":true,"tosidebar":true,"console":false,"tostatus":false,"complete":"payload","targetType":"msg","statusVal":"","statusType":"auto","x":610,"y":3660,"wires":[]},{"id":"0858f158df46bb51","type":"debug","z":"517cd16e4d7e6ae4","name":"Ergebnis","active":true,"tosidebar":true,"console":false,"tostatus":false,"complete":"payload","targetType":"msg","statusVal":"","statusType":"auto","x":3020,"y":3580,"wires":[]},{"id":"fe12d75c77ea96a9","type":"change","z":"517cd16e4d7e6ae4","name":"","rules":[{"t":"set","p":"payload","pt":"msg","to":"{\t   \"method\": \"Switch.Set\",\t   \"parameters\" : {\t       \"id\" : 0,\t       \"on\": payload       \t   }\t}","tot":"jsonata"}],"action":"","property":"","from":"","to":"","reg":false,"x":2830,"y":3620,"wires":[["0858f158df46bb51"]]},{"id":"a24a10d67adf7325","type":"junction","z":"517cd16e4d7e6ae4","x":1960,"y":3660,"wires":[["856ab41216e0c0af"]]},{"id":"0f2c3c5c8743b77e","type":"junction","z":"517cd16e4d7e6ae4","x":1720,"y":3660,"wires":[["a24a10d67adf7325"]]},{"id":"473eacb13a6cb11c","type":"junction","z":"517cd16e4d7e6ae4","x":1440,"y":3660,"wires":[["0f2c3c5c8743b77e"]]},{"id":"ddf39dae01705e59","type":"junction","z":"517cd16e4d7e6ae4","x":2560,"y":3620,"wires":[["19225af3a1bf8b1a"]]},{"id":"6236f30557c7e780","type":"junction","z":"517cd16e4d7e6ae4","x":340,"y":3900,"wires":[["a3f8d990d290d69d"]]},{"id":"043e832f297c9831","type":"junction","z":"517cd16e4d7e6ae4","x":560,"y":3600,"wires":[["c9bdbf8b0e1b8b42"]]}]
          

          1 1 Reply Last reply Reply Quote 0
          • 1
            1984chris @mickym last edited by

            @mickym
            das habe ich gemacht das die Verzögerung nicht bei jedem Wert (wenn <2500W,SOC<80% usw.)um eins raufgesetzt wird und mit einem >2500W, SOC>80% usw wird die Verzögerung wieder zurückgesetzt und der Filter bekommt auch eine Änderung, passt das nicht so? weil es funktioniert Eigentlich.

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

              @1984chris Selbst wenn die Verzögerungen um 8 raufgesetz werden, und einmal ein Pumpe ein kommt, wird nicht um 1 runtergesetzt, sondern die Delay Node wird komplett zurückgesetzt. Ein reset setzt immer sofort auf 0.

              Der Filter braucht man nur zum Schluss. Wenn Du 8 mal off/false ankommt, kommt das nur einmal durch - dafür ist der Filter ja da und den braucht man nur zum Schluss. Wie gesagt - ich habe nun Schalter ein und aus auf true und false gesetzt.

              1 2 Replies Last reply Reply Quote 0
              • 1
                1984chris @mickym last edited by

                @mickym
                ich bekomme halt sekündlich werte das spielt dann keine Rolle?

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

                  @1984chris sagte in Function Node welche zwei Werte vergleicht:

                  @mickym
                  ich bekomme halt sekündlich werte das spielt dann keine Rolle?

                  Na das wird durch den Filter blockiert - somit bekommt Dein Shelly nicht dauernd Kommandos. Du siehst doch an der debug Node Ergebnis, dass nur beim Wechsel von aus/ein ein Kommando durchkommt.

                  1 1 Reply Last reply Reply Quote 0
                  • 1
                    1984chris @mickym last edited by

                    @mickym
                    Das beim Schalter ein Setze String Pumpe ein 1 habe ich gehabt weil ich ein UDP Telegramm mit diesen Inhalt versende und das im Homserver die Pumpe aktiviert.Wie kan ich das jetzt lösen?

                    mickym 1 Reply Last reply Reply Quote 0
                    • 1
                      1984chris @mickym last edited by

                      @mickym
                      Ich meinte nur das der Zähler bei der Verzögerung (blaue Ziffer) immer höher wird.

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

                        @1984chris sagte in Function Node welche zwei Werte vergleicht:

                        @mickym
                        Das beim Schalter ein Setze String Pumpe ein 1 habe ich gehabt weil ich ein UDP Telegramm mit diesen Inhalt versende und das im Homserver die Pumpe aktiviert.Wie kan ich das jetzt lösen?

                        Also Du schaltest sowohl einen Shelly - als auch irgendwas im Homeserver.

                        1 1 Reply Last reply Reply Quote 0
                        • 1
                          1984chris @mickym last edited by

                          @mickym
                          ja.

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

                            @1984chris sagte in Function Node welche zwei Werte vergleicht:

                            @mickym
                            Ich meinte nur das der Zähler bei der Verzögerung (blaue Ziffer) immer höher wird.

                            Ja aber das stört ja nicht. In der Regel baut man halt keine zeitliche Verzögerungen ein, sondern nimmt ein Hysterese um unnötiges Schalten zu verhindern.

                            1 2 Replies Last reply Reply Quote 0
                            • 1
                              1984chris @mickym last edited by

                              @mickym
                              ok dachte nur.
                              Dann lösch ich das wieder raus.

                              mickym 1 Reply Last reply Reply Quote 0
                              • 1
                                1984chris @mickym last edited by

                                @mickym
                                Ich erkläre dir mein Vorhaben,
                                Habe einen Homserver mit einer Zeitschaltuhr wo die Poolpumpe jeden tag 3 mal je 2 Stunden eingeschaltet wird (dafür brauche ich die UDP Telegramme) das ich diese Zeitschaltuhr ausschalte und die Poolpumpe direkt einschalte bei PV Überschuss und die Wärmepumpe.Ich hoffe hab das halbwegs erklärt.

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

                                  @1984chris sagte in Function Node welche zwei Werte vergleicht:

                                  @mickym
                                  ja.

                                  f4b91562-ba4e-48e5-a96d-be2254a26f92-image.png

                                  Dann bereitest Du die payload je nachdem ob true oder false einmal für den Shelly und einmal für den Homeserver auf. Wird ja dann gleichzeitig gesendet.

                                  [{"id":"0858f158df46bb51","type":"debug","z":"517cd16e4d7e6ae4","name":"Ergebnis für Shelly","active":true,"tosidebar":true,"console":false,"tostatus":false,"complete":"payload","targetType":"msg","statusVal":"","statusType":"auto","x":3070,"y":3680,"wires":[]},{"id":"fe12d75c77ea96a9","type":"change","z":"517cd16e4d7e6ae4","name":"","rules":[{"t":"set","p":"payload","pt":"msg","to":"{\t   \"method\": \"Switch.Set\",\t   \"parameters\" : {\t       \"id\" : 0,\t       \"on\": payload       \t   }\t}","tot":"jsonata"}],"action":"","property":"","from":"","to":"","reg":false,"x":2830,"y":3660,"wires":[["0858f158df46bb51"]]},{"id":"b1dfdd79c609cc2a","type":"change","z":"517cd16e4d7e6ae4","name":"","rules":[{"t":"set","p":"payload","pt":"msg","to":"payload ? \"Pumpe ein 1\" : \"Pumpe aus 0\"","tot":"jsonata"}],"action":"","property":"","from":"","to":"","reg":false,"x":2830,"y":3580,"wires":[["f128f99f6a4ec367"]]},{"id":"f128f99f6a4ec367","type":"debug","z":"517cd16e4d7e6ae4","name":"Ergebnis für Homeserver","active":true,"tosidebar":true,"console":false,"tostatus":false,"complete":"payload","targetType":"msg","statusVal":"","statusType":"auto","x":3090,"y":3560,"wires":[]}]
                                  

                                  Nochmal zur Hysterese. In der Regel macht man sowas halt nicht zeitorientiert, sondern nimmt einen Puffer.
                                  Lassen wir mal den SOC bei 80 - aber bei dem Überschuss nehme ich keine feste Grenze von 2500,

                                  sondern ich sage ab 2500 schalte Wärmepumpe ein, schalte sie aber erst aus, wenn der Überschuss unter 2300 sinkt. In dem Puffer passiert gar nichts. Also man nimmt gewisse Pufferbereiche um kurzfristige Schwankungen auszugleichen und keinen zeitlichen Puffer.

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

                                    @1984chris sagte in Function Node welche zwei Werte vergleicht:

                                    @mickym
                                    Ich erkläre dir mein Vorhaben,
                                    Habe einen Homserver mit einer Zeitschaltuhr wo die Poolpumpe jeden tag 3 mal je 2 Stunden eingeschaltet wird (dafür brauche ich die UDP Telegramme) das ich diese Zeitschaltuhr ausschalte und die Poolpumpe direkt einschalte bei PV Überschuss und die Wärmepumpe.Ich hoffe hab das halbwegs erklärt.

                                    Ich hab dir oben true/false einmal für den Shelly und gleichzeitig für den Homeserver aufbereitet.

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

                                      @1984chris sagte in Function Node welche zwei Werte vergleicht:

                                      @mickym
                                      ok dachte nur.
                                      Dann lösch ich das wieder raus.

                                      Was Du machen kannst, wenn Du die Anzahl Nachrichten vermindern willst, dann kannst Du auch eine delay Node nehmen und die Nachrichtenrate begrenzen.

                                      1 1 Reply Last reply Reply Quote 0
                                      • 1
                                        1984chris @mickym last edited by

                                        @mickym
                                        das ist ja die Verzögerung oder?

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

                                          @1984chris Nein die Delay Node kann zum einen verzögern oder die Nachrichtenrate begrenzen.

                                          4c8062cb-17e3-453e-a2b1-231cde51dd82-image.png

                                          So könntest auch einstellen 1 Nachricht in 10s oder was auch immer.

                                          1 1 Reply Last reply Reply Quote 0
                                          • 1
                                            1984chris @mickym last edited by

                                            @mickym
                                            was wäre hier ein sinvoller wert?

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

                                            Support us

                                            ioBroker
                                            Community Adapters
                                            Donate

                                            844
                                            Online

                                            31.6k
                                            Users

                                            79.6k
                                            Topics

                                            1.3m
                                            Posts

                                            5
                                            207
                                            18117
                                            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