[ { "id": "f9e28c9cf87b10de", "type": "tab", "label": "Carlo Gavazzi EM24 Emulator", "disabled": false, "info": "# Emulador de Carlo Gavazzi EM24\n## [www.alferez.es](https://www.alferez.es/)", "env": [] }, { "id": "d85ca744fbfe6e5e", "type": "modbus-server", "z": "f9e28c9cf87b10de", "name": "Local", "logEnabled": true, "hostname": "0.0.0.0", "serverPort": "502", "responseDelay": 100, "delayUnit": "ms", "coilsBufferSize": "50000", "holdingBufferSize": "50000", "inputBufferSize": "50000", "discreteBufferSize": "50000", "showErrors": true, "x": 110, "y": 280, "wires": [ [], [], [], [], [] ] }, { "id": "cfce746916ccd7ac", "type": "inject", "z": "f9e28c9cf87b10de", "name": "Initialisieren", "props": [ { "p": "payload" } ], "repeat": "", "crontab": "", "once": true, "onceDelay": "10", "topic": "", "payload": "", "payloadType": "date", "x": 350, "y": 280, "wires": [ [ "380e2ede7834e1d6" ] ] }, { "id": "2b4b6dd6aa10fa59", "type": "comment", "z": "f9e28c9cf87b10de", "name": "Lokaler Modbus-Server", "info": "", "x": 120, "y": 40, "wires": [] }, { "id": "d0fa71a02b08376a", "type": "modbus-write", "z": "f9e28c9cf87b10de", "name": "Modell", "showStatusActivities": true, "showErrors": true, "unitid": "1", "dataType": "HoldingRegister", "adr": "11", "quantity": "1", "server": "866daf61d2f53247", "emptyMsgOnFail": false, "keepMsgProperties": false, "x": 730, "y": 160, "wires": [ [], [] ] }, { "id": "567d802b86d19936", "type": "modbus-write", "z": "f9e28c9cf87b10de", "name": "HW Version", "showStatusActivities": true, "showErrors": true, "unitid": "1", "dataType": "HoldingRegister", "adr": "777", "quantity": "1", "server": "866daf61d2f53247", "emptyMsgOnFail": false, "keepMsgProperties": false, "x": 750, "y": 200, "wires": [ [], [] ] }, { "id": "135694707df02a6e", "type": "modbus-write", "z": "f9e28c9cf87b10de", "name": "FW Version", "showStatusActivities": true, "showErrors": true, "unitid": "1", "dataType": "HoldingRegister", "adr": "772", "quantity": "1", "server": "866daf61d2f53247", "emptyMsgOnFail": false, "keepMsgProperties": false, "x": 750, "y": 240, "wires": [ [], [] ] }, { "id": "1a6e1ee5a3a58ff2", "type": "modbus-write", "z": "f9e28c9cf87b10de", "name": "Phase Config", "showStatusActivities": true, "showErrors": true, "unitid": "1", "dataType": "HoldingRegister", "adr": "4098", "quantity": "1", "server": "866daf61d2f53247", "emptyMsgOnFail": false, "keepMsgProperties": false, "x": 760, "y": 280, "wires": [ [], [] ] }, { "id": "9f0fc6df912b4153", "type": "modbus-write", "z": "f9e28c9cf87b10de", "name": "Serial", "showStatusActivities": true, "showErrors": true, "unitid": "1", "dataType": "MHoldingRegisters", "adr": "20480", "quantity": "7", "server": "866daf61d2f53247", "emptyMsgOnFail": false, "keepMsgProperties": false, "x": 730, "y": 320, "wires": [ [], [] ] }, { "id": "37ec24b6af21c1a4", "type": "modbus-write", "z": "f9e28c9cf87b10de", "name": "SwitchPos", "showStatusActivities": true, "showErrors": true, "unitid": "1", "dataType": "HoldingRegister", "adr": "41216", "quantity": "1", "server": "866daf61d2f53247", "emptyMsgOnFail": false, "keepMsgProperties": false, "x": 750, "y": 360, "wires": [ [], [] ] }, { "id": "bba1844b8aff9633", "type": "modbus-write", "z": "f9e28c9cf87b10de", "name": "Role", "showStatusActivities": true, "showErrors": true, "unitid": "1", "dataType": "MCoils", "adr": "40960", "quantity": "1", "server": "866daf61d2f53247", "emptyMsgOnFail": false, "keepMsgProperties": false, "x": 730, "y": 400, "wires": [ [], [] ] }, { "id": "18fadae810a5f576", "type": "link in", "z": "f9e28c9cf87b10de", "name": "grid.in", "links": [ "a655e772c50b9d2f" ], "x": 995, "y": 280, "wires": [ [ "6f73834d3707869e", "5e9144f8b68d7a33", "be4ca4c0679d2ebe", "223dfbb3c469940c", "950b9617d5fa0f9c", "8b0d90be5e3c24f2", "400a923863e3fc54", "1badd6a110fd02d2", "5a8eae02f07b4e08", "ae6fcf68b5c6a035" ] ] }, { "id": "6f73834d3707869e", "type": "change", "z": "f9e28c9cf87b10de", "name": "f", "rules": [ { "t": "set", "p": "payload", "pt": "msg", "to": "payload[0].grid.L1.frequency", "tot": "jsonata" } ], "action": "", "property": "", "from": "", "to": "", "reg": false, "x": 1290, "y": 20, "wires": [ [ "874d2fbbcf5c342e" ] ] }, { "id": "f93cc62703ebae49", "type": "modbus-write", "z": "f9e28c9cf87b10de", "name": "Hz", "showStatusActivities": true, "showErrors": false, "unitid": "1", "dataType": "HoldingRegister", "adr": "51", "quantity": "1", "server": "866daf61d2f53247", "emptyMsgOnFail": false, "keepMsgProperties": false, "x": 1690, "y": 20, "wires": [ [], [] ] }, { "id": "874d2fbbcf5c342e", "type": "function", "z": "f9e28c9cf87b10de", "name": "Set(f)", "func": "//Frequenz\nflow.set('hertz',msg.payload);\nvar hertz = (msg.payload * 10).toFixed(0);\n\nreturn {payload: hertz}", "outputs": 1, "timeout": "", "noerr": 0, "initialize": "", "finalize": "", "libs": [], "x": 1470, "y": 20, "wires": [ [ "f93cc62703ebae49" ] ] }, { "id": "5e9144f8b68d7a33", "type": "change", "z": "f9e28c9cf87b10de", "name": "U L1", "rules": [ { "t": "set", "p": "payload", "pt": "msg", "to": "payload[0].grid.L1.voltage", "tot": "jsonata" } ], "action": "", "property": "", "from": "", "to": "", "reg": false, "x": 1290, "y": 60, "wires": [ [ "74ece21a69de7464" ] ] }, { "id": "74ece21a69de7464", "type": "function", "z": "f9e28c9cf87b10de", "name": "Set(U1)", "func": "//Spannung L1\nflow.set('volts1',msg.payload);\n\nvar volts=new Int32Array(2);\nvolts[0] = (msg.payload * 10).toFixed(1);\n\nreturn {payload: volts}", "outputs": 1, "timeout": "", "noerr": 0, "initialize": "", "finalize": "", "libs": [], "x": 1480, "y": 60, "wires": [ [ "47f422c60c40ddf4" ] ] }, { "id": "47f422c60c40ddf4", "type": "modbus-write", "z": "f9e28c9cf87b10de", "name": "V L1", "showStatusActivities": true, "showErrors": false, "unitid": "1", "dataType": "MHoldingRegisters", "adr": "0", "quantity": "2", "server": "866daf61d2f53247", "emptyMsgOnFail": false, "keepMsgProperties": false, "x": 1690, "y": 60, "wires": [ [], [] ] }, { "id": "be4ca4c0679d2ebe", "type": "change", "z": "f9e28c9cf87b10de", "name": "U L2", "rules": [ { "t": "set", "p": "payload", "pt": "msg", "to": "payload[0].grid.L2.voltage", "tot": "jsonata" } ], "action": "", "property": "", "from": "", "to": "", "reg": false, "x": 1290, "y": 100, "wires": [ [ "2234415294ea12a7" ] ] }, { "id": "2234415294ea12a7", "type": "function", "z": "f9e28c9cf87b10de", "name": "Set(U2)", "func": "//Spannung L2\nflow.set('volts2',msg.payload);\n\nvar volts=new Int32Array(2);\nvolts[0] = (msg.payload * 10).toFixed(1);\n\nreturn {payload: volts}", "outputs": 1, "timeout": "", "noerr": 0, "initialize": "", "finalize": "", "libs": [], "x": 1480, "y": 100, "wires": [ [ "614f5c64b1c54ecb" ] ] }, { "id": "614f5c64b1c54ecb", "type": "modbus-write", "z": "f9e28c9cf87b10de", "name": "V L2", "showStatusActivities": true, "showErrors": false, "unitid": "1", "dataType": "MHoldingRegisters", "adr": "0x0002", "quantity": "2", "server": "866daf61d2f53247", "emptyMsgOnFail": false, "keepMsgProperties": false, "x": 1690, "y": 100, "wires": [ [], [] ] }, { "id": "223dfbb3c469940c", "type": "change", "z": "f9e28c9cf87b10de", "name": "U L3", "rules": [ { "t": "set", "p": "payload", "pt": "msg", "to": "payload[0].grid.L3.voltage", "tot": "jsonata" } ], "action": "", "property": "", "from": "", "to": "", "reg": false, "x": 1290, "y": 140, "wires": [ [ "5dcf20140162f7c2" ] ] }, { "id": "5dcf20140162f7c2", "type": "function", "z": "f9e28c9cf87b10de", "name": "Set(U3)", "func": "//Spannung L3\nflow.set('volts3',msg.payload);\n\nvar volts=new Int32Array(2);\nvolts[0] = (msg.payload * 10).toFixed(1);\n\nreturn {payload: volts}", "outputs": 1, "timeout": "", "noerr": 0, "initialize": "", "finalize": "", "libs": [], "x": 1480, "y": 140, "wires": [ [ "51fd9572ccde9530" ] ] }, { "id": "51fd9572ccde9530", "type": "modbus-write", "z": "f9e28c9cf87b10de", "name": "V L3", "showStatusActivities": true, "showErrors": false, "unitid": "1", "dataType": "MHoldingRegisters", "adr": "0x0004", "quantity": "2", "server": "866daf61d2f53247", "emptyMsgOnFail": false, "keepMsgProperties": false, "x": 1690, "y": 140, "wires": [ [], [] ] }, { "id": "950b9617d5fa0f9c", "type": "change", "z": "f9e28c9cf87b10de", "name": "P L1", "rules": [ { "t": "set", "p": "payload", "pt": "msg", "to": "payload[0].grid.L1.power", "tot": "jsonata" } ], "action": "", "property": "", "from": "", "to": "", "reg": false, "x": 1290, "y": 200, "wires": [ [ "527203f4995db8cc", "7a0be87998ad6aa6" ] ] }, { "id": "527203f4995db8cc", "type": "function", "z": "f9e28c9cf87b10de", "name": "Set(P1)", "func": "//Leistung L1\nflow.set('watts1',msg.payload);\n\nfunction int32ToBuffer(value) {\n var mbbuffer = new Uint16Array(2);\n var dataView = new DataView(mbbuffer.buffer);\n dataView.setInt32(0, value, true);\n var uint16Value1 = mbbuffer[0];\n var uint16Value2 = mbbuffer[1];\n return [uint16Value1, uint16Value2];\n}\n\nvar value = msg.payload.toFixed(0) * 10;\nvar mbbuffer = int32ToBuffer(value);\n\nvar modbusfx = {\n payload: {\n 'value': [\n mbbuffer[0],\n mbbuffer[1],\n ],\n 'fc': 16,\n 'unitid': 1,\n 'address': 18,\n 'quantity': 2\n }\n}\n\nmsg.payload = modbusfx.payload\nreturn msg", "outputs": 1, "timeout": "", "noerr": 0, "initialize": "", "finalize": "", "libs": [], "x": 1480, "y": 180, "wires": [ [ "abb6a6b435867422" ] ] }, { "id": "402ac05f7a5a042d", "type": "modbus-write", "z": "f9e28c9cf87b10de", "name": "A L1", "showStatusActivities": true, "showErrors": false, "unitid": "1", "dataType": "MHoldingRegisters", "adr": "12", "quantity": "2", "server": "866daf61d2f53247", "emptyMsgOnFail": false, "keepMsgProperties": false, "x": 1690, "y": 220, "wires": [ [], [] ] }, { "id": "7a0be87998ad6aa6", "type": "function", "z": "f9e28c9cf87b10de", "name": "Set(I1)", "func": "// Spannung L1 einlesen\nvar volts=flow.get('volts1');\n\n// Strom L1 berechnen\nvar amps=new Int32Array(2);\namps[0]=(msg.payload.toFixed(0) / volts.toFixed(2)) * 1000;\n\nif (amps[0] < 0 ) {\n amps[0] = 65535 + amps[0];\n amps[1] = 65535;\n}\n\nreturn {payload: amps}", "outputs": 1, "timeout": "", "noerr": 0, "initialize": "", "finalize": "", "libs": [], "x": 1470, "y": 220, "wires": [ [ "402ac05f7a5a042d" ] ] }, { "id": "8b0d90be5e3c24f2", "type": "change", "z": "f9e28c9cf87b10de", "name": "P L2", "rules": [ { "t": "set", "p": "payload", "pt": "msg", "to": "payload[0].grid.L2.power", "tot": "jsonata" } ], "action": "", "property": "", "from": "", "to": "", "reg": false, "x": 1290, "y": 280, "wires": [ [ "9cb8adb351418739", "cbf3fcbad3c05cf7" ] ] }, { "id": "9cb8adb351418739", "type": "function", "z": "f9e28c9cf87b10de", "name": "Set(P2)", "func": "//Leistung L2\nflow.set('watts2',msg.payload);\n\nfunction int32ToBuffer(value) {\n var mbbuffer = new Uint16Array(2);\n var dataView = new DataView(mbbuffer.buffer);\n dataView.setInt32(0, value, true);\n var uint16Value1 = mbbuffer[0];\n var uint16Value2 = mbbuffer[1];\n return [uint16Value1, uint16Value2];\n}\n\nvar value = msg.payload.toFixed(0) * 10;\nvar mbbuffer = int32ToBuffer(value);\n\nvar modbusfx = {\n payload: {\n 'value': [\n mbbuffer[0],\n mbbuffer[1],\n ],\n 'fc': 16,\n 'unitid': 1,\n 'address': 20,\n 'quantity': 2\n }\n}\n\nmsg.payload = modbusfx.payload\nreturn msg", "outputs": 1, "timeout": "", "noerr": 0, "initialize": "", "finalize": "", "libs": [], "x": 1480, "y": 260, "wires": [ [ "a3514049d64706f4" ] ] }, { "id": "cbf3fcbad3c05cf7", "type": "function", "z": "f9e28c9cf87b10de", "name": "Set(I2)", "func": "// Spannung L2 einlesen\nvar volts=flow.get('volts2');\n\n// Strom L2 berechnen\nvar amps=new Int32Array(2);\namps[0]=(msg.payload.toFixed(0) / volts.toFixed(2)) * 1000;\n\nif (amps[0] < 0 ) {\n amps[0] = 65535 + amps[0];\n amps[1] = 65535;\n}\n\nreturn {payload: amps}", "outputs": 1, "timeout": "", "noerr": 0, "initialize": "", "finalize": "", "libs": [], "x": 1470, "y": 300, "wires": [ [ "cd1e4906c0b77f44" ] ] }, { "id": "400a923863e3fc54", "type": "change", "z": "f9e28c9cf87b10de", "name": "P L3", "rules": [ { "t": "set", "p": "payload", "pt": "msg", "to": "payload[0].grid.L3.power", "tot": "jsonata" } ], "action": "", "property": "", "from": "", "to": "", "reg": false, "x": 1290, "y": 360, "wires": [ [ "b09c96ba32e7bacf", "589381fcdf55adb4" ] ] }, { "id": "b09c96ba32e7bacf", "type": "function", "z": "f9e28c9cf87b10de", "name": "Set(P3)", "func": "//Leistung L3\nflow.set('watts3',msg.payload);\n\nfunction int32ToBuffer(value) {\n var mbbuffer = new Uint16Array(2);\n var dataView = new DataView(mbbuffer.buffer);\n dataView.setInt32(0, value, true);\n var uint16Value1 = mbbuffer[0];\n var uint16Value2 = mbbuffer[1];\n return [uint16Value1, uint16Value2];\n}\n\nvar value = msg.payload.toFixed(0) * 10;\nvar mbbuffer = int32ToBuffer(value);\n\nvar modbusfx = {\n payload: {\n 'value': [\n mbbuffer[0],\n mbbuffer[1],\n ],\n 'fc': 16,\n 'unitid': 1,\n 'address': 22,\n 'quantity': 2\n }\n}\n\nmsg.payload = modbusfx.payload\nreturn msg", "outputs": 1, "timeout": "", "noerr": 0, "initialize": "", "finalize": "", "libs": [], "x": 1480, "y": 340, "wires": [ [ "ef63e1831902de0d" ] ] }, { "id": "589381fcdf55adb4", "type": "function", "z": "f9e28c9cf87b10de", "name": "Set(I3)", "func": "// Spannung L3 einlesen\nvar volts=flow.get('volts3');\n\n// Strom L3 berechnen\nvar amps=new Int32Array(2);\namps[0]=(msg.payload.toFixed(0) / volts.toFixed(2)) * 1000;\n\nif (amps[0] < 0 ) {\n amps[0] = 65535 + amps[0];\n amps[1] = 65535;\n}\n\nreturn {payload: amps}", "outputs": 1, "timeout": "", "noerr": 0, "initialize": "", "finalize": "", "libs": [], "x": 1470, "y": 380, "wires": [ [ "41a7dd71d70d01c7" ] ] }, { "id": "41a7dd71d70d01c7", "type": "modbus-write", "z": "f9e28c9cf87b10de", "name": "A L3", "showStatusActivities": true, "showErrors": false, "unitid": "1", "dataType": "MHoldingRegisters", "adr": "0x0010", "quantity": "2", "server": "866daf61d2f53247", "emptyMsgOnFail": false, "keepMsgProperties": false, "x": 1690, "y": 380, "wires": [ [], [] ] }, { "id": "1badd6a110fd02d2", "type": "change", "z": "f9e28c9cf87b10de", "name": "P", "rules": [ { "t": "set", "p": "payload", "pt": "msg", "to": "payload[0].grid.power", "tot": "jsonata" } ], "action": "", "property": "", "from": "", "to": "", "reg": false, "x": 1290, "y": 420, "wires": [ [ "dd658d5b037b0fb9", "9e338f7b73f5822b" ] ] }, { "id": "dd658d5b037b0fb9", "type": "function", "z": "f9e28c9cf87b10de", "name": "Set(P)", "func": "function int32ToBuffer(value) {\n var mbbuffer = new Uint16Array(2);\n var dataView = new DataView(mbbuffer.buffer);\n dataView.setInt32(0, value, true);\n var uint16Value1 = mbbuffer[0];\n var uint16Value2 = mbbuffer[1];\n return [uint16Value1, uint16Value2];\n}\n\nvar value = msg.payload.toFixed(0) * 10;\nvar mbbuffer = int32ToBuffer(value);\n\nvar modbusfx = {\n payload: {\n 'value': [\n mbbuffer[0],\n mbbuffer[1],\n ],\n 'fc': 16,\n 'unitid': 1,\n 'address': 40,\n 'quantity': 2\n }\n}\n\nmsg.payload = modbusfx.payload\nreturn msg", "outputs": 1, "timeout": "", "noerr": 0, "initialize": "", "finalize": "", "libs": [], "x": 1470, "y": 420, "wires": [ [ "e2f114c7e65e4090" ] ] }, { "id": "93035182e390a05e", "type": "modbus-write", "z": "f9e28c9cf87b10de", "name": "Total E L1", "showStatusActivities": true, "showErrors": false, "unitid": "1", "dataType": "MHoldingRegisters", "adr": "64", "quantity": "2", "server": "866daf61d2f53247", "emptyMsgOnFail": false, "keepMsgProperties": false, "x": 1680, "y": 480, "wires": [ [], [] ] }, { "id": "d8ededc671bcbf9f", "type": "modbus-write", "z": "f9e28c9cf87b10de", "name": "Total E L2", "showStatusActivities": true, "showErrors": false, "unitid": "1", "dataType": "MHoldingRegisters", "adr": "0x0042", "quantity": "2", "server": "866daf61d2f53247", "emptyMsgOnFail": false, "keepMsgProperties": false, "x": 1680, "y": 520, "wires": [ [], [] ] }, { "id": "358f0649d624a989", "type": "modbus-write", "z": "f9e28c9cf87b10de", "name": "Total E L3", "showStatusActivities": true, "showErrors": false, "unitid": "1", "dataType": "MHoldingRegisters", "adr": "0x0044", "quantity": "2", "server": "866daf61d2f53247", "emptyMsgOnFail": false, "keepMsgProperties": false, "x": 1680, "y": 560, "wires": [ [], [] ] }, { "id": "9e338f7b73f5822b", "type": "function", "z": "f9e28c9cf87b10de", "name": "Set(0)", "func": "var twatts=new Int32Array(2);\ntwatts[0] = 0;\ntwatts[1] = 0;\n\nreturn {payload: twatts}", "outputs": 1, "timeout": "", "noerr": 0, "initialize": "", "finalize": "", "libs": [], "x": 1470, "y": 520, "wires": [ [ "93035182e390a05e", "d8ededc671bcbf9f", "358f0649d624a989" ] ] }, { "id": "5a8eae02f07b4e08", "type": "change", "z": "f9e28c9cf87b10de", "name": "E Bezug", "rules": [ { "t": "set", "p": "payload", "pt": "msg", "to": "payload[0].grid.energy_forward", "tot": "jsonata" } ], "action": "", "property": "", "from": "", "to": "", "reg": false, "x": 1280, "y": 620, "wires": [ [ "3b9c6bde6c9894d2" ] ] }, { "id": "ae6fcf68b5c6a035", "type": "change", "z": "f9e28c9cf87b10de", "name": "E Einsp", "rules": [ { "t": "set", "p": "payload", "pt": "msg", "to": "payload[0].grid.energy_reverse", "tot": "jsonata" } ], "action": "", "property": "", "from": "", "to": "", "reg": false, "x": 1280, "y": 660, "wires": [ [ "9fb336a200ae9767" ] ] }, { "id": "d3769a85442f71b9", "type": "modbus-write", "z": "f9e28c9cf87b10de", "name": "Total Forward", "showStatusActivities": true, "showErrors": false, "unitid": "1", "dataType": "MHoldingRegisters", "adr": "0x0034", "quantity": "2", "server": "866daf61d2f53247", "emptyMsgOnFail": false, "keepMsgProperties": false, "x": 1660, "y": 620, "wires": [ [], [] ] }, { "id": "2117a1429bb50c89", "type": "modbus-write", "z": "f9e28c9cf87b10de", "name": "Total Reverse", "showStatusActivities": true, "showErrors": false, "unitid": "1", "dataType": "MHoldingRegisters", "adr": "78", "quantity": "2", "server": "866daf61d2f53247", "emptyMsgOnFail": false, "keepMsgProperties": false, "x": 1660, "y": 660, "wires": [ [], [] ] }, { "id": "3b9c6bde6c9894d2", "type": "function", "z": "f9e28c9cf87b10de", "name": "Set(Bezug)", "func": "// Netzbezug\n\nvar value = parseInt(msg.payload * 10).toString(2).padStart(32, '0');\n\nvar twatts = new Int32Array(2);\ntwatts[0] = parseInt(value.substring(16, 32), 2);\ntwatts[1] = parseInt(value.substring(0, 16), 2);\n\nreturn {payload: twatts}", "outputs": 1, "timeout": "", "noerr": 0, "initialize": "", "finalize": "", "libs": [], "x": 1470, "y": 620, "wires": [ [ "d3769a85442f71b9" ] ] }, { "id": "9fb336a200ae9767", "type": "function", "z": "f9e28c9cf87b10de", "name": "Set(Einsp)", "func": "// Netzbezug\n\nvar value = parseInt(msg.payload * 10).toString(2).padStart(32, '0');\n\nvar twatts = new Int32Array(2);\ntwatts[0] = parseInt(value.substring(16, 32), 2);\ntwatts[1] = parseInt(value.substring(0, 16), 2);\n\nreturn {payload: twatts}", "outputs": 1, "timeout": "", "noerr": 0, "initialize": "", "finalize": "", "libs": [], "x": 1470, "y": 660, "wires": [ [ "2117a1429bb50c89" ] ] }, { "id": "cd1e4906c0b77f44", "type": "modbus-write", "z": "f9e28c9cf87b10de", "name": "A L2", "showStatusActivities": true, "showErrors": false, "unitid": "1", "dataType": "MHoldingRegisters", "adr": "0x000E", "quantity": "2", "server": "866daf61d2f53247", "emptyMsgOnFail": false, "keepMsgProperties": false, "x": 1690, "y": 300, "wires": [ [], [] ] }, { "id": "380e2ede7834e1d6", "type": "function", "z": "f9e28c9cf87b10de", "name": "Definitionen", "func": "//Modell\nvar data1 = { payload: 1648 };\n//HW + Fw Version\nvar data2 = { payload: 0x101E };\n//PH Config (4 = 3P)\nvar data3 = { payload: 4 };\n//Serial\nvar data4 = { payload: [22359,22320,16716,17989,21061,23088,17747]};\n//Position\nvar data5 = { payload: 0x1 };\n//Role\nvar data6 = { paload: 7 }\nreturn [data1, data2, data3, data4, data5, data6];", "outputs": 6, "timeout": "", "noerr": 0, "initialize": "", "finalize": "", "libs": [], "x": 530, "y": 280, "wires": [ [ "d0fa71a02b08376a" ], [ "567d802b86d19936", "135694707df02a6e" ], [ "1a6e1ee5a3a58ff2" ], [ "9f0fc6df912b4153" ], [ "37ec24b6af21c1a4" ], [ "bba1844b8aff9633" ] ] }, { "id": "e2f114c7e65e4090", "type": "modbus-flex-write", "z": "f9e28c9cf87b10de", "name": "Sum Watts", "showStatusActivities": false, "showErrors": false, "server": "866daf61d2f53247", "emptyMsgOnFail": false, "keepMsgProperties": false, "x": 1710, "y": 420, "wires": [ [], [] ] }, { "id": "ef63e1831902de0d", "type": "modbus-flex-write", "z": "f9e28c9cf87b10de", "name": "W L3", "showStatusActivities": false, "showErrors": false, "server": "866daf61d2f53247", "emptyMsgOnFail": false, "keepMsgProperties": false, "x": 1690, "y": 340, "wires": [ [], [] ] }, { "id": "a3514049d64706f4", "type": "modbus-flex-write", "z": "f9e28c9cf87b10de", "name": "W L2", "showStatusActivities": false, "showErrors": false, "server": "866daf61d2f53247", "emptyMsgOnFail": false, "keepMsgProperties": false, "x": 1690, "y": 260, "wires": [ [], [] ] }, { "id": "abb6a6b435867422", "type": "modbus-flex-write", "z": "f9e28c9cf87b10de", "name": "W L1", "showStatusActivities": false, "showErrors": false, "server": "866daf61d2f53247", "emptyMsgOnFail": false, "keepMsgProperties": false, "x": 1690, "y": 180, "wires": [ [], [] ] }, { "id": "866daf61d2f53247", "type": "modbus-client", "name": "Local", "clienttype": "tcp", "bufferCommands": true, "stateLogEnabled": true, "queueLogEnabled": true, "tcpHost": "127.0.0.1", "tcpPort": "502", "tcpType": "DEFAULT", "serialPort": "/dev/ttyUSB", "serialType": "RTU-BUFFERD", "serialBaudrate": "9600", "serialDatabits": "8", "serialStopbits": "1", "serialParity": "none", "serialConnectionDelay": "100", "serialAsciiResponseStartDelimiter": "0x3A", "unit_id": 1, "commandDelay": 1, "clientTimeout": 1000, "reconnectOnTimeout": true, "reconnectTimeout": 2000, "parallelUnitIdsAllowed": true } ]