I would like to map below mentioned MODBUS registers but getting some errors.
5,4,0,PAT-WAM-01.Clbs/day,FLT32
5,4,2,PAT-WAM-01.COST,$,FLT32
5,4,4,PAT-WAM-01.STATE,,UINT16
5,1,0,PAT-WAM-01.OOS,,boolean
[
{
"id": "7f4fc478148cb980",
"type": "tab",
"label": "Lanxess",
"disabled": false,
"info": "",
"env": []
},
{
"id": "e93c3ca6e03cd113",
"type": "comment",
"z": "7f4fc478148cb980",
"name": "Enter username/password",
"info": "",
"x": 1330,
"y": 320,
"wires": [],
"icon": "node-red/alert.svg"
},
{
"id": "819ec7545c540f03",
"type": "modbus-read",
"z": "7f4fc478148cb980",
"name": "",
"topic": "PWI",
"showStatusActivities": true,
"logIOActivities": false,
"showErrors": true,
"showWarnings": true,
"unitid": "",
"dataType": "InputRegister",
"adr": "30000",
"quantity": "1",
"rate": "30",
"rateUnit": "s",
"delayOnStart": false,
"startDelayTime": "",
"server": "b85ab8ebb65ece21",
"useIOFile": false,
"ioFile": "",
"useIOForPayload": false,
"emptyMsgOnFail": true,
"x": 430,
"y": 400,
"wires": [
[
"402206c6209b1ddd",
"057999bda20a1b2b"
],
[]
]
},
{
"id": "402206c6209b1ddd",
"type": "debug",
"z": "7f4fc478148cb980",
"name": "",
"active": true,
"tosidebar": true,
"console": false,
"tostatus": true,
"complete": "true",
"targetType": "full",
"statusVal": "payload[0]",
"statusType": "auto",
"x": 670,
"y": 220,
"wires": []
},
{
"id": "568dac3c3e1d0bfe",
"type": "buffer-parser",
"z": "7f4fc478148cb980",
"name": "",
"data": "payload",
"dataType": "msg",
"specification": "spec",
"specificationType": "ui",
"items": [
{
"type": "floatbe",
"name": "EMISSIONS",
"offset": 0,
"length": 1,
"offsetbit": 0,
"scale": "1",
"mask": ""
}
],
"swap1": "",
"swap2": "",
"swap3": "",
"swap1Type": "swap",
"swap2Type": "swap",
"swap3Type": "swap",
"msgProperty": "payload",
"msgPropertyType": "str",
"resultType": "keyvalue",
"resultTypeType": "return",
"multipleResult": false,
"fanOutMultipleResult": false,
"setTopic": true,
"outputs": 1,
"x": 130,
"y": 280,
"wires": [
[
"53910b6ec851c498",
"3f7fb59097d14abc"
]
]
},
{
"id": "53910b6ec851c498",
"type": "debug",
"z": "7f4fc478148cb980",
"name": "debug 31",
"active": true,
"tosidebar": true,
"console": false,
"tostatus": false,
"complete": "payload",
"targetType": "msg",
"statusVal": "",
"statusType": "auto",
"x": 320,
"y": 180,
"wires": []
},
{
"id": "3f7fb59097d14abc",
"type": "function",
"z": "7f4fc478148cb980",
"name": "function 9",
"func": "let msg2 = {};\nmsg2.payload = {};\nmsg2.payload.channel_1_setpoint_d={};\nmsg2.payload.channel_1_state_d= {};\nmsg2.payload.channel_2_setpoint_d = {};\nmsg2.payload.channel_2_state_d = {};\nmsg2.payload.channel_1_setpoint_d.units = \"True\";\nmsg2.payload.channel_1_setpoint_d.value = msg.payload.channel_1_setpoint_d;\nmsg2.payload.channel_1_state_d.units = \"True\";\nmsg2.payload.channel_1_state_d.value = msg.payload.channel_1_state_d;\nmsg2.payload.channel_2_setpoint_d.units = \"True\";\nmsg2.payload.channel_2_setpoint_d.value = msg.payload.channel_2_setpoint_d;\nmsg2.payload.channel_2_state_d.units = \"True\";\nmsg2.payload.channel_2_state_d.value = msg.payload.channel_2_state_d;\nmsg2.payload.measurement = \"702 DI Transmitters\";\nreturn msg2;",
"outputs": 1,
"noerr": 0,
"initialize": "",
"finalize": "",
"libs": [],
"x": 860,
"y": 280,
"wires": [
[
"c325f1aeb1af35b2",
"2a62806cf12686e1"
]
]
},
{
"id": "c325f1aeb1af35b2",
"type": "debug",
"z": "7f4fc478148cb980",
"name": "debug 32",
"active": true,
"tosidebar": true,
"console": false,
"tostatus": false,
"complete": "payload",
"targetType": "msg",
"statusVal": "",
"statusType": "auto",
"x": 1060,
"y": 420,
"wires": []
},
{
"id": "057999bda20a1b2b",
"type": "function",
"z": "7f4fc478148cb980",
"name": "function 10",
"func": "msg.payload.reverse();\nreturn msg;",
"outputs": 1,
"noerr": 0,
"initialize": "",
"finalize": "",
"libs": [],
"x": 240,
"y": 340,
"wires": [
[
"568dac3c3e1d0bfe"
]
]
},
{
"id": "2a62806cf12686e1",
"type": "influxdb out",
"z": "7f4fc478148cb980",
"influxdb": "f32f037fb43bf103",
"name": "InfluxDB",
"measurement": "Emerson_1410S_Gateway",
"precision": "",
"retentionPolicy": "",
"database": "database",
"precisionV18FluxV20": "ms",
"retentionPolicyV18Flux": "",
"org": "organisation",
"bucket": "bucket",
"x": 1320,
"y": 280,
"wires": []
},
{
"id": "b85ab8ebb65ece21",
"type": "modbus-client",
"name": "PWI",
"clienttype": "tcp",
"bufferCommands": true,
"stateLogEnabled": true,
"queueLogEnabled": false,
"failureLogEnabled": true,
"tcpHost": "10.129.251.134",
"tcpPort": "502",
"tcpType": "DEFAULT",
"serialPort": "/dev/ttyUSB",
"serialType": "RTU-BUFFERD",
"serialBaudrate": "9600",
"serialDatabits": "8",
"serialStopbits": "1",
"serialParity": "none",
"serialConnectionDelay": "100",
"serialAsciiResponseStartDelimiter": "0x3A",
"unit_id": "",
"commandDelay": "1",
"clientTimeout": "1000",
"reconnectOnTimeout": true,
"reconnectTimeout": "2000",
"parallelUnitIdsAllowed": true,
"showWarnings": true,
"showLogs": true
},
{
"id": "f32f037fb43bf103",
"type": "influxdb",
"hostname": "influxdb",
"port": "8086",
"protocol": "http",
"database": "data",
"name": "emerson_influxdb",
"usetls": false,
"tls": "",
"influxdbVersion": "1.x",
"url": "http://localhost:8086",
"rejectUnauthorized": true
}
]