Hallo Community
Habe mir ein Flow zusammengebastelt der Bei 99% SOC und einer Pufferspeicher Temp ( Über LM335 ) unter 71 Grad Relais 2 vom Cerbo GX den Heizstab ansteuert ( der am AUX1 am Multiplus hängt und Über VeConfig Programierten Assistenten AcOut2 ansteuert ) , die Regelung wird aber ausser kraft gesetzt wenn Differenz der Zellen über 0,01V sind .
Somit kann ich verhindern das bei Zellendifferenz der Heizstab angesteuert wird bis Zellen Ungleichgewicht unter 0,01v ist.
Viel Spaß beim Testen
Manuel
[
{
"id": "a787ea25.6e2f08",
"type": "subflow",
"name": "Difference",
"info": "",
"in": [
{
"x": 60,
"y": 120,
"wires": [
{
"id": "c6c1a8f6.29f9a"
},
{
"id": "1fb5778c.9ddfd"
}
]
}
],
"out": [
{
"x": 1020,
"y": 280,
"wires": [
{
"id": "2796226d.63c97e",
"port": 0
}
]
}
],
"outputLabels": [
"reading",
"difference"
]
},
{
"id": "1fb5778c.9ddfd",
"type": "function",
"z": "a787ea25.6e2f08",
"name": "Current Reading",
"func": "//set a topic to join later\nmsg.topic = 'curr'; \n\nreturn msg;",
"outputs": 1,
"timeout": "",
"noerr": 0,
"initialize": "",
"finalize": "",
"libs": [],
"x": 220,
"y": 180,
"wires": [
[
"b09d555.863fda8"
]
]
},
{
"id": "c6c1a8f6.29f9a",
"type": "delay",
"z": "a787ea25.6e2f08",
"name": "",
"pauseType": "delay",
"timeout": "1",
"timeoutUnits": "seconds",
"rate": "1",
"nbRateUnits": "1",
"rateUnits": "second",
"randomFirst": "1",
"randomLast": "5",
"randomUnits": "seconds",
"drop": true,
"outputs": 1,
"x": 205.75,
"y": 327.0000305175781,
"wires": [
[
"4e42e8d7.cd4be"
]
]
},
{
"id": "4e42e8d7.cd4be",
"type": "function",
"z": "a787ea25.6e2f08",
"name": "Previous Reading",
"func": "//set a topic to join later\nmsg.topic = 'prev'; \n\nreturn msg;",
"outputs": 1,
"noerr": 0,
"x": 527,
"y": 326.00006103515625,
"wires": [
[
"b09d555.863fda8"
]
]
},
{
"id": "b09d555.863fda8",
"type": "join",
"z": "a787ea25.6e2f08",
"name": "Join each topic",
"mode": "custom",
"build": "object",
"property": "payload",
"propertyType": "msg",
"key": "topic",
"joiner": "\\n",
"joinerType": "str",
"accumulate": true,
"timeout": "",
"count": "2",
"reduceRight": false,
"reduceExp": "",
"reduceInit": "",
"reduceInitType": "",
"reduceFixup": "",
"x": 580,
"y": 179.25003051757812,
"wires": [
[
"2796226d.63c97e"
]
]
},
{
"id": "2796226d.63c97e",
"type": "function",
"z": "a787ea25.6e2f08",
"name": "Difference",
"func": "var c = msg.payload.curr - msg.payload.prev;\n\n// Calculate\nif (msg.topic == 'curr'){\n msg.payload = c;\n return msg;\n}\n\n",
"outputs": 1,
"timeout": "",
"noerr": 0,
"initialize": "",
"finalize": "",
"libs": [],
"x": 1000,
"y": 180,
"wires": [
[]
]
},
{
"id": "da79a4c0.ef6ae",
"type": "comment",
"z": "a787ea25.6e2f08",
"name": "input",
"info": "Connect your Reading as msg.payload",
"x": 70,
"y": 80,
"wires": []
},
{
"id": "24a6c50a.bd7c62",
"type": "comment",
"z": "a787ea25.6e2f08",
"name": "Delay 1msg / sec",
"info": "to be able to get previous value \none message later",
"x": 207.5,
"y": 367.7500305175781,
"wires": []
},
{
"id": "3d3075e7.af4442",
"type": "comment",
"z": "a787ea25.6e2f08",
"name": "Add Topic",
"info": "",
"x": 556.25,
"y": 364.00006103515625,
"wires": []
},
{
"id": "21ff46d1.635dba",
"type": "comment",
"z": "a787ea25.6e2f08",
"name": "Add Topic",
"info": "",
"x": 240,
"y": 137.75003051757812,
"wires": []
},
{
"id": "c9aeb317.ef8668",
"type": "comment",
"z": "a787ea25.6e2f08",
"name": "Calculate the Diff",
"info": "",
"x": 840,
"y": 137.75003051757812,
"wires": []
},
{
"id": "64216738.bfae5",
"type": "comment",
"z": "a787ea25.6e2f08",
"name": "Join / Combine msgs",
"info": "",
"x": 580,
"y": 137.75003051757812,
"wires": []
},
{
"id": "2fb21af.6acaae6",
"type": "comment",
"z": "a787ea25.6e2f08",
"name": "1st Out is Difference",
"info": "",
"x": 1230,
"y": 280,
"wires": []
},
{
"id": "67dda7ad37b31550",
"type": "tab",
"label": "Solar Begranzung Pufferspeicher",
"disabled": false,
"info": "",
"env": []
},
{
"id": "04cbb6c2c70b06ed",
"type": "group",
"z": "67dda7ad37b31550",
"name": "Differences Cell Start Flow",
"style": {
"label": true
},
"nodes": [
"d05cca8e.eaf878",
"b7f4362d.727388",
"a75ef7e0.831e6",
"9d38a0f2c6f1e39b",
"7b498d69b0a180a2",
"deceb529e9c17240",
"e2d876d9eb159621",
"54d1e1c8627ef0f7",
"0dcc9ee1f1bc1b00",
"5a250d4ee669450b",
"6cfebeecd142bc40"
],
"x": 154,
"y": 879,
"w": 1732,
"h": 242
},
{
"id": "dc63c2fa37562d38",
"type": "group",
"z": "67dda7ad37b31550",
"name": "Solar limit owerflow into Ballon",
"style": {
"label": true
},
"nodes": [
"8d3e6c8e.8cbc9",
"d08663fb.931a3",
"f249379b.160858",
"5e9c463a.27fc68",
"37566273.473d5e",
"a54e7199.6374",
"2e209753.9b4fb8",
"a535b1aa.3022a",
"566cc94a.99f208",
"243e481a.080958",
"1370c306.727e1d",
"af929e90e97d568b",
"92414375d47ed037",
"9d4ea051c90522ee",
"5cbb7607b7529a84",
"ae05d5ae777de073",
"44d175d069852852",
"4b4dd70141dc58d9",
"93a19e1ef0b5e34c",
"eb658cd1d02a864c",
"5555ee0a6cdd2ab3",
"1cfa28c1870aff17",
"b2db954a1ea97ed9",
"2a5f0a576b0a424b",
"5e9acba5d747a390",
"a7a921db4a4ddc7c"
],
"x": 154,
"y": 79,
"w": 1352,
"h": 762
},
{
"id": "b2db954a1ea97ed9",
"type": "junction",
"z": "67dda7ad37b31550",
"g": "dc63c2fa37562d38",
"x": 580,
"y": 240,
"wires": [
[
"2e209753.9b4fb8"
]
]
},
{
"id": "2a5f0a576b0a424b",
"type": "junction",
"z": "67dda7ad37b31550",
"g": "dc63c2fa37562d38",
"x": 520,
"y": 380,
"wires": [
[
"a54e7199.6374"
]
]
},
{
"id": "8d3e6c8e.8cbc9",
"type": "inject",
"z": "67dda7ad37b31550",
"g": "dc63c2fa37562d38",
"name": "99%",
"props": [
{
"p": "payload"
},
{
"p": "topic",
"vt": "str"
}
],
"repeat": "",
"crontab": "",
"once": false,
"onceDelay": 0.1,
"topic": "Battery_SOC",
"payload": "99",
"payloadType": "num",
"x": 410,
"y": 120,
"wires": [
[
"b2db954a1ea97ed9"
]
]
},
{
"id": "d08663fb.931a3",
"type": "inject",
"z": "67dda7ad37b31550",
"g": "dc63c2fa37562d38",
"name": "97%",
"props": [
{
"p": "payload"
},
{
"p": "topic",
"vt": "str"
}
],
"repeat": "",
"crontab": "",
"once": false,
"onceDelay": 0.1,
"topic": "Battery SOC",
"payload": "97",
"payloadType": "num",
"x": 410,
"y": 160,
"wires": [
[
"b2db954a1ea97ed9"
]
]
},
{
"id": "f249379b.160858",
"type": "debug",
"z": "67dda7ad37b31550",
"g": "dc63c2fa37562d38",
"name": "Trigger the thing?",
"active": true,
"tosidebar": true,
"console": false,
"tostatus": true,
"complete": "payload",
"targetType": "msg",
"statusVal": "payload",
"statusType": "auto",
"x": 1170,
"y": 600,
"wires": []
},
{
"id": "5e9c463a.27fc68",
"type": "inject",
"z": "67dda7ad37b31550",
"g": "dc63c2fa37562d38",
"name": "72 C°",
"props": [
{
"p": "payload"
},
{
"p": "topic",
"vt": "str"
}
],
"repeat": "",
"crontab": "",
"once": false,
"onceDelay": 0.1,
"topic": "Pufferspeicher_Temp",
"payload": "72",
"payloadType": "num",
"x": 410,
"y": 360,
"wires": [
[
"2a5f0a576b0a424b"
]
]
},
{
"id": "37566273.473d5e",
"type": "inject",
"z": "67dda7ad37b31550",
"g": "dc63c2fa37562d38",
"name": "70 C°",
"props": [
{
"p": "payload"
},
{
"p": "topic",
"vt": "str"
}
],
"repeat": "",
"crontab": "",
"once": false,
"onceDelay": 0.1,
"topic": "Pufferspeicher_Temp",
"payload": "70",
"payloadType": "num",
"x": 410,
"y": 400,
"wires": [
[
"2a5f0a576b0a424b"
]
]
},
{
"id": "a54e7199.6374",
"type": "change",
"z": "67dda7ad37b31550",
"g": "dc63c2fa37562d38",
"name": "Pufferspeicher_Temp",
"rules": [
{
"t": "set",
"p": "Pufferspeicher_Temp",
"pt": "flow",
"to": "payload",
"tot": "msg"
}
],
"action": "",
"property": "",
"from": "",
"to": "",
"reg": false,
"x": 1000,
"y": 460,
"wires": [
[
"a7a921db4a4ddc7c"
]
]
},
{
"id": "2e209753.9b4fb8",
"type": "change",
"z": "67dda7ad37b31550",
"g": "dc63c2fa37562d38",
"name": "set Battery SOC",
"rules": [
{
"t": "set",
"p": "Battery_SOC",
"pt": "flow",
"to": "payload",
"tot": "msg"
}
],
"action": "",
"property": "",
"from": "",
"to": "",
"reg": false,
"x": 1140,
"y": 240,
"wires": [
[
"566cc94a.99f208"
]
]
},
{
"id": "a535b1aa.3022a",
"type": "link in",
"z": "67dda7ad37b31550",
"g": "dc63c2fa37562d38",
"name": "Humidity Workflow",
"links": [
"566cc94a.99f208",
"a7a921db4a4ddc7c"
],
"x": 345,
"y": 740,
"wires": [
[
"5e9acba5d747a390"
]
]
},
{
"id": "566cc94a.99f208",
"type": "link out",
"z": "67dda7ad37b31550",
"g": "dc63c2fa37562d38",
"name": "Batery SOC",
"mode": "link",
"links": [
"a535b1aa.3022a"
],
"x": 1255,
"y": 240,
"wires": []
},
{
"id": "243e481a.080958",
"type": "comment",
"z": "67dda7ad37b31550",
"g": "dc63c2fa37562d38",
"name": "Workflow",
"info": "",
"x": 240,
"y": 600,
"wires": []
},
{
"id": "1370c306.727e1d",
"type": "comment",
"z": "67dda7ad37b31550",
"g": "dc63c2fa37562d38",
"name": "on Pufferspeicher Temp",
"info": "",
"x": 280,
"y": 660,
"wires": []
},
{
"id": "af929e90e97d568b",
"type": "comment",
"z": "67dda7ad37b31550",
"g": "dc63c2fa37562d38",
"name": "Battery_SOC",
"info": "",
"x": 250,
"y": 120,
"wires": []
},
{
"id": "92414375d47ed037",
"type": "comment",
"z": "67dda7ad37b31550",
"g": "dc63c2fa37562d38",
"name": "Pufferspeicher_Temp",
"info": "",
"x": 280,
"y": 320,
"wires": []
},
{
"id": "9d4ea051c90522ee",
"type": "victron-input-temperature",
"z": "67dda7ad37b31550",
"g": "dc63c2fa37562d38",
"service": "com.victronenergy.temperature/20",
"path": "/Temperature",
"serviceObj": {
"service": "com.victronenergy.temperature/20",
"name": "Pufferspeicher"
},
"pathObj": {
"path": "/Temperature",
"type": "float",
"name": "Temperature (°C)"
},
"name": "Pufferspeicher",
"onlyChanges": true,
"roundValues": "0",
"x": 420,
"y": 460,
"wires": [
[]
]
},
{
"id": "5cbb7607b7529a84",
"type": "victron-input-system",
"z": "67dda7ad37b31550",
"g": "dc63c2fa37562d38",
"service": "com.victronenergy.system/0",
"path": "/Dc/Battery/Soc",
"serviceObj": {
"service": "com.victronenergy.system/0",
"name": "Venus system"
},
"pathObj": {
"path": "/Dc/Battery/Soc",
"type": "float",
"name": "Battery State of Charge (%)"
},
"name": "Battery SOC",
"onlyChanges": false,
"x": 410,
"y": 240,
"wires": [
[]
]
},
{
"id": "ae05d5ae777de073",
"type": "change",
"z": "67dda7ad37b31550",
"g": "dc63c2fa37562d38",
"name": "",
"rules": [
{
"t": "change",
"p": "payload",
"pt": "msg",
"from": "true",
"fromt": "bool",
"to": "1",
"tot": "num"
},
{
"t": "change",
"p": "payload",
"pt": "msg",
"from": "false",
"fromt": "bool",
"to": "0",
"tot": "num"
}
],
"action": "",
"property": "",
"from": "",
"to": "",
"reg": false,
"x": 1030,
"y": 740,
"wires": [
[
"44d175d069852852"
]
]
},
{
"id": "44d175d069852852",
"type": "victron-output-relay",
"z": "67dda7ad37b31550",
"g": "dc63c2fa37562d38",
"service": "com.victronenergy.system/0",
"path": "/Relay/1/State",
"serviceObj": {
"service": "com.victronenergy.system/0",
"name": "Venus device"
},
"pathObj": {
"path": "/Relay/1/State",
"type": "enum",
"name": "Venus relay 2 state",
"enum": {
"0": "Open",
"1": "Closed"
},
"writable": true
},
"initial": "",
"name": "Relay 2 Water Temp heater",
"onlyChanges": true,
"x": 1360,
"y": 740,
"wires": []
},
{
"id": "4b4dd70141dc58d9",
"type": "victron-input-relay",
"z": "67dda7ad37b31550",
"g": "dc63c2fa37562d38",
"service": "com.victronenergy.system/0",
"path": "/Relay/1/State",
"serviceObj": {
"service": "com.victronenergy.system/0",
"name": "Venus system"
},
"pathObj": {
"path": "/Relay/1/State",
"type": "enum",
"name": "Venus relay 2 state",
"enum": {
"0": "Open",
"1": "Closed"
}
},
"initial": "",
"name": "Relay 2 State",
"onlyChanges": false,
"x": 390,
"y": 800,
"wires": [
[
"eb658cd1d02a864c"
]
]
},
{
"id": "93a19e1ef0b5e34c",
"type": "mqtt out",
"z": "67dda7ad37b31550",
"g": "dc63c2fa37562d38",
"name": "Relay 2",
"topic": "Relay 2 State",
"qos": "2",
"retain": "",
"respTopic": "",
"contentType": "",
"userProps": "",
"correl": "",
"expiry": "",
"broker": "292856c50555893c",
"x": 900,
"y": 800,
"wires": []
},
{
"id": "eb658cd1d02a864c",
"type": "rbe",
"z": "67dda7ad37b31550",
"g": "dc63c2fa37562d38",
"name": "Relay Message",
"func": "rbe",
"gap": "",
"start": "",
"inout": "out",
"septopics": false,
"property": "payload",
"topi": "1",
"x": 600,
"y": 800,
"wires": [
[
"93a19e1ef0b5e34c"
]
]
},
{
"id": "5555ee0a6cdd2ab3",
"type": "rbe",
"z": "67dda7ad37b31550",
"g": "dc63c2fa37562d38",
"name": "Block unless value Change",
"func": "rbe",
"gap": "",
"start": "",
"inout": "out",
"septopics": false,
"property": "payload",
"topi": "1",
"x": 660,
"y": 460,
"wires": [
[
"a54e7199.6374"
]
]
},
{
"id": "1cfa28c1870aff17",
"type": "rbe",
"z": "67dda7ad37b31550",
"g": "dc63c2fa37562d38",
"name": "Block unless value Change",
"func": "rbe",
"gap": "",
"start": "",
"inout": "out",
"septopics": false,
"property": "payload",
"topi": "1",
"x": 860,
"y": 240,
"wires": [
[
"2e209753.9b4fb8"
]
]
},
{
"id": "d05cca8e.eaf878",
"type": "subflow:a787ea25.6e2f08",
"z": "67dda7ad37b31550",
"g": "04cbb6c2c70b06ed",
"name": "Difference",
"x": 980,
"y": 1040,
"wires": [
[
"deceb529e9c17240"
]
]
},
{
"id": "b7f4362d.727388",
"type": "comment",
"z": "67dda7ad37b31550",
"g": "04cbb6c2c70b06ed",
"name": "Difference node is a subflow",
"info": "Open and Edit Template to see details",
"x": 800,
"y": 960,
"wires": []
},
{
"id": "a75ef7e0.831e6",
"type": "counter",
"z": "67dda7ad37b31550",
"g": "04cbb6c2c70b06ed",
"name": "",
"init": 0,
"step": "1",
"lower": "",
"upper": "",
"mode": "increment",
"outputs": 1,
"x": 800,
"y": 1040,
"wires": [
[
"d05cca8e.eaf878"
]
]
},
{
"id": "9d38a0f2c6f1e39b",
"type": "victron-input-ess",
"z": "67dda7ad37b31550",
"g": "04cbb6c2c70b06ed",
"service": "com.victronenergy.battery/512",
"path": "/System/MaxCellVoltage",
"serviceObj": {
"service": "com.victronenergy.battery/512",
"name": "CAN-SMARTBMS-BAT"
},
"pathObj": {
"path": "/System/MaxCellVoltage",
"type": "integer",
"name": "Maximum battery cell voltage"
},
"name": "",
"onlyChanges": false,
"x": 380,
"y": 1020,
"wires": [
[
"a75ef7e0.831e6"
]
]
},
{
"id": "7b498d69b0a180a2",
"type": "victron-input-ess",
"z": "67dda7ad37b31550",
"g": "04cbb6c2c70b06ed",
"service": "com.victronenergy.battery/512",
"path": "/System/MinCellVoltage",
"serviceObj": {
"service": "com.victronenergy.battery/512",
"name": "CAN-SMARTBMS-BAT"
},
"pathObj": {
"path": "/System/MinCellVoltage",
"type": "integer",
"name": "Minimum battery cell voltage"
},
"name": "",
"onlyChanges": false,
"x": 380,
"y": 1080,
"wires": [
[
"a75ef7e0.831e6"
]
]
},
{
"id": "deceb529e9c17240",
"type": "switch",
"z": "67dda7ad37b31550",
"g": "04cbb6c2c70b06ed",
"name": "Cell Diff",
"property": "payload",
"propertyType": "msg",
"rules": [
{
"t": "btwn",
"v": "0.002",
"vt": "num",
"v2": "0.010",
"v2t": "num"
},
{
"t": "btwn",
"v": "0.011",
"vt": "num",
"v2": "0.04",
"v2t": "num"
}
],
"checkall": "true",
"repair": false,
"outputs": 2,
"x": 1140,
"y": 1040,
"wires": [
[
"0dcc9ee1f1bc1b00"
],
[
"54d1e1c8627ef0f7"
]
]
},
{
"id": "e2d876d9eb159621",
"type": "debug",
"z": "67dda7ad37b31550",
"g": "04cbb6c2c70b06ed",
"name": "debug 22",
"active": true,
"tosidebar": true,
"console": false,
"tostatus": false,
"complete": "false",
"statusVal": "",
"statusType": "auto",
"x": 1780,
"y": 920,
"wires": []
},
{
"id": "54d1e1c8627ef0f7",
"type": "range",
"z": "67dda7ad37b31550",
"g": "04cbb6c2c70b06ed",
"minin": "0.001",
"maxin": "0.01",
"minout": "5",
"maxout": "5",
"action": "scale",
"round": false,
"property": "payload",
"name": "Up To 10 Diff",
"x": 1350,
"y": 1060,
"wires": [
[
"5a250d4ee669450b"
]
]
},
{
"id": "0dcc9ee1f1bc1b00",
"type": "range",
"z": "67dda7ad37b31550",
"g": "04cbb6c2c70b06ed",
"minin": "0.011",
"maxin": "0.04",
"minout": "10",
"maxout": "10",
"action": "scale",
"round": false,
"property": "payload",
"name": "Over 10 Diff",
"x": 1350,
"y": 1020,
"wires": [
[
"5a250d4ee669450b"
]
]
},
{
"id": "5e9acba5d747a390",
"type": "function",
"z": "67dda7ad37b31550",
"g": "dc63c2fa37562d38",
"name": "Check Battrery SOC and Pufferspeicher Temp & Cell Diff",
"func": "var Pufferspeicher_Temp = flow.get('Pufferspeicher_Temp')\nvar Battery_SOC = flow.get('Battery_SOC')\nvar Cell_Diff = flow.get('Cell_Diff')\n\nvar minTemp = 71;\nvar minSOC = 98;\nvar minDiff = 9;\n\n// Check Levels\nif(Pufferspeicher_Temp < minTemp && Battery_SOC > minSOC && Cell_Diff > minDiff){\n msg.payload = true;\n}else{\n msg.payload = false;\n}\n\nreturn msg\n",
"outputs": 1,
"timeout": "",
"noerr": 0,
"initialize": "",
"finalize": "",
"libs": [],
"x": 670,
"y": 740,
"wires": [
[
"ae05d5ae777de073",
"f249379b.160858"
]
]
},
{
"id": "5a250d4ee669450b",
"type": "change",
"z": "67dda7ad37b31550",
"g": "04cbb6c2c70b06ed",
"name": "Cell_Diff",
"rules": [
{
"t": "set",
"p": "Cell_Diff",
"pt": "flow",
"to": "payload",
"tot": "msg"
}
],
"action": "",
"property": "",
"from": "",
"to": "",
"reg": false,
"x": 1560,
"y": 1040,
"wires": [
[
"e2d876d9eb159621"
]
]
},
{
"id": "6cfebeecd142bc40",
"type": "comment",
"z": "67dda7ad37b31550",
"g": "04cbb6c2c70b06ed",
"name": "Difference >10 Balancing On",
"info": "",
"x": 1260,
"y": 960,
"wires": []
},
{
"id": "a7a921db4a4ddc7c",
"type": "link out",
"z": "67dda7ad37b31550",
"g": "dc63c2fa37562d38",
"name": "Pufferspeicher",
"mode": "link",
"links": [
"a535b1aa.3022a"
],
"x": 1175,
"y": 460,
"wires": []
},
{
"id": "292856c50555893c",
"type": "mqtt-broker",
"name": "Homey",
"broker": "192.168.188.119",
"port": "1883",
"clientid": "",
"autoConnect": true,
"usetls": false,
"protocolVersion": "4",
"keepalive": "60",
"cleansession": true,
"autoUnsubscribe": true,
"birthTopic": "",
"birthQos": "0",
"birthRetain": "false",
"birthPayload": "",
"birthMsg": {},
"closeTopic": "",
"closeQos": "0",
"closeRetain": "false",
"closePayload": "",
"closeMsg": {},
"willTopic": "",
"willQos": "0",
"willRetain": "false",
"willPayload": "",
"willMsg": {},
"userProps": "",
"sessionExpiry": ""
}
]