[ { "id": "530db9f01f93674d", "type": "tab", "label": "Flow 1", "disabled": false, "info": "", "env": [] }, { "id": "88201f33ddc1ade5", "type": "victron-output-relay", "z": "530db9f01f93674d", "service": "com.victronenergy.system", "path": "/Relay/1/State", "serviceObj": { "service": "com.victronenergy.system", "name": "Venus device", "paths": [ { "path": "/Relay/0/State", "type": "enum", "name": "Venus relay 1 state", "enum": { "0": "Open", "1": "Closed" }, "writable": true }, { "path": "/Relay/1/State", "type": "enum", "name": "Venus relay 2 state", "enum": { "0": "Open", "1": "Closed" }, "writable": true } ] }, "pathObj": { "path": "/Relay/1/State", "type": "enum", "name": "Venus relay 2 state", "enum": { "0": "Open", "1": "Closed" }, "writable": true }, "initial": "", "name": "Relay 2 State", "x": 620, "y": 500, "wires": [] }, { "id": "eb15c8433eded05b", "type": "victron-input-battery", "z": "530db9f01f93674d", "service": "com.victronenergy.battery.socketcan_can1", "path": "/Soc", "serviceObj": { "service": "com.victronenergy.battery.socketcan_can1", "name": "Pylontech battery", "paths": [ { "path": "/Alarms/CellImbalance", "type": "enum", "name": "Cell Imbalance alarm", "enum": { "0": "No alarm", "1": "Warning", "2": "Alarm" } }, { "path": "/Alarms/HighChargeCurrent", "type": "enum", "name": "High charge current alarm", "enum": { "0": "No alarm", "1": "Warning", "2": "Alarm" } }, { "path": "/Alarms/HighChargeTemperature", "type": "enum", "name": "High charge temperature alarm", "enum": { "0": "No alarm", "1": "Warning", "2": "Alarm" } }, { "path": "/Alarms/HighDischargeCurrent", "type": "enum", "name": "High discharge current alarm", "enum": { "0": "No alarm", "1": "Warning", "2": "Alarm" } }, { "path": "/Alarms/HighTemperature", "type": "enum", "name": "High battery temperature alarm", "enum": { "0": "No alarm", "2": "Alarm" } }, { "path": "/Alarms/HighVoltage", "type": "enum", "name": "High voltage alarm", "enum": { "0": "No alarm", "2": "Alarm" } }, { "path": "/Alarms/InternalFailure", "type": "enum", "name": "Internal error alarm", "enum": { "0": "No alarm", "1": "Warning", "2": "Alarm" } }, { "path": "/Alarms/LowChargeTemperature", "type": "enum", "name": "Low charge temperature alarm", "enum": { "0": "No alarm", "1": "Warning", "2": "Alarm" } }, { "path": "/Alarms/LowTemperature", "type": "enum", "name": "Low battery temperature alarm", "enum": { "0": "No alarm", "2": "Alarm" } }, { "path": "/Alarms/LowVoltage", "type": "enum", "name": "Low voltage alarm", "enum": { "0": "No alarm", "2": "Alarm" } }, { "path": "/Capacity", "type": "float", "name": "Capacity (Ah)" }, { "path": "/Dc/0/Current", "type": "float", "name": "Current (A)" }, { "path": "/Dc/0/Temperature", "type": "float", "name": "Battery temperature (C)" }, { "path": "/Dc/0/Voltage", "type": "float", "name": "Voltage (V)" }, { "path": "/History/ChargedEnergy", "type": "float", "name": "Charged Energy (kWh)" }, { "path": "/History/DischargedEnergy", "type": "float", "name": "Discharged Energy (kWh)" }, { "path": "/Info/BatteryLowVoltage", "type": "float", "name": "Min discharge voltage (V DC)" }, { "path": "/Info/MaxChargeCurrent", "type": "float", "name": "CCL - Charge Current Limit (A)" }, { "path": "/Info/MaxChargeVoltage", "type": "float", "name": "CVL - Charge Voltage Limit (V)" }, { "path": "/Info/MaxDischargeCurrent", "type": "float", "name": "DCL - Discharge Current Limit (A)" }, { "path": "/Soc", "type": "float", "name": "State of charge (%)" }, { "path": "/Soh", "type": "float", "name": "State of health (%)" }, { "path": "/System/MaxVoltageCellId", "type": "string", "name": "System; ID of module with highest cell voltage" }, { "path": "/System/MaxCellTemperature", "type": "float", "name": "Maximum cell temperature (Degrees celsius)" }, { "path": "/System/MaxCellVoltage", "type": "float", "name": "System; maximum cell voltage (V DC)" }, { "path": "/System/MaxTemperatureCellId", "type": "string", "name": "System; ID of module with highest cell temperature" }, { "path": "/System/MinVoltageCellId", "type": "string", "name": "System; ID of module with lowest cell voltage" }, { "path": "/System/MinCellTemperature", "type": "float", "name": "Minimum cell temperature (Degrees celsius)" }, { "path": "/System/MinCellVoltage", "type": "float", "name": "System; minimum cell voltage (V DC)" }, { "path": "/System/MinTemperatureCellId", "type": "string", "name": "System; ID of module with lowest cell temperature" }, { "path": "/System/NrOfModulesBlockingCharge", "type": "integer", "name": "Number of modules blocking charge" }, { "path": "/System/NrOfModulesBlockingDischarge", "type": "integer", "name": "Number of modules blocking discharge" }, { "path": "/System/NrOfModulesOffline", "type": "integer", "name": "Number of offline modules" }, { "path": "/System/NrOfModulesOnline", "type": "integer", "name": "Number of online modules" } ] }, "pathObj": { "path": "/Soc", "type": "float", "name": "State of charge (%)" }, "initial": "", "name": "", "x": 350, "y": 400, "wires": [ [ "de9ad1beba0a0686" ] ] }, { "id": "ba3e85e29cd8cca4", "type": "debug", "z": "530db9f01f93674d", "name": "State Of Charge", "active": true, "tosidebar": true, "console": false, "tostatus": false, "complete": "payload", "targetType": "msg", "statusVal": "", "statusType": "auto", "x": 840, "y": 400, "wires": [] }, { "id": "de9ad1beba0a0686", "type": "change", "z": "530db9f01f93674d", "name": "", "rules": [ { "t": "set", "p": "#:(file)::StateOfCharge", "pt": "global", "to": "payload", "tot": "msg" } ], "action": "", "property": "", "from": "", "to": "", "reg": false, "x": 630, "y": 400, "wires": [ [ "ba3e85e29cd8cca4" ] ] }, { "id": "c0c22c460a1bf509", "type": "function", "z": "530db9f01f93674d", "name": "SetRelay", "func": "var soc = global.get(\"StateOfCharge\");\nif (msg.payload == true) {\n // Timer On\n if (soc >= 62) {\n // Set Relay On\n msg.payload = 1;\n } else {\n // Set Relay Off\n msg.payload = 0;\n }\n} else {\n // Timer Off\n if (soc <= 61) {\n // Set Relay Off\n msg.payload = 0;\n } else {\n // Stop further processing\n msg.payload = null;\n } \n}\nreturn msg;", "outputs": 1, "noerr": 0, "initialize": "", "finalize": "", "libs": [], "x": 420, "y": 500, "wires": [ [ "88201f33ddc1ade5" ] ] }, { "id": "e46a33db5737b655", "type": "inject", "z": "530db9f01f93674d", "name": "true", "props": [ { "p": "payload" }, { "p": "topic", "vt": "str" } ], "repeat": "", "crontab": "39 23 * * *", "once": false, "onceDelay": 0.1, "topic": "", "payload": "true", "payloadType": "bool", "x": 270, "y": 520, "wires": [ [ "c0c22c460a1bf509" ] ] }, { "id": "4a8bfb498776f172", "type": "inject", "z": "530db9f01f93674d", "name": "false", "props": [ { "p": "payload" }, { "p": "topic", "vt": "str" } ], "repeat": "", "crontab": "00 07 * * *", "once": false, "onceDelay": 0.1, "topic": "", "payload": "false", "payloadType": "bool", "x": 270, "y": 480, "wires": [ [ "c0c22c460a1bf509" ] ] } ]