Hello guys, I've got problem with node Modbus Flex Getter. When I put nodes like this Inject->function->Modbus Flex Getter( node-red-contrib-modbus )->Modbus Response it just give me 2 errors
"SyntaxError: Unexpected token function"
"TypeError: Cannot read property 'registerForModbus' of null"
Is here someone who knows what's wrong with that? When I use nodes node-red-contrib-serial-modbus it works fine but for my project would be better Modbus Flex Getter.
Here's my flow
[{"id":"9ad7528f.e69fc","type":"tab","label":"SDM630 Modbus Gateway","disabled":false,"info":""},{"id":"368a8c76.362e94","type":"modbus-flex-getter","z":"9ad7528f.e69fc","name":"","showStatusActivities":false,"showErrors":false,"logIOActivities":false,"server":"a88606c6.70fc78","useIOFile":false,"ioFile":"","useIOForPayload":false,"x":490,"y":100,"wires":[["5804250a.61e32c"],[]]},{"id":"4ebeb73b.a76818","type":"function","z":"9ad7528f.e69fc","name":"","func":"msg.payload = { value: msg.payload, 'fc': 3, 'unitid': 6, 'address': 0 , 'quantity': 10 };\nreturn msg;","outputs":1,"noerr":0,"x":280,"y":100,"wires":[["368a8c76.362e94"]]},{"id":"92660fd5.11ab1","type":"inject","z":"9ad7528f.e69fc","name":"","topic":"","payload":"","payloadType":"date","repeat":"","crontab":"","once":false,"onceDelay":0.1,"x":150,"y":100,"wires":[["4ebeb73b.a76818"]]},{"id":"5804250a.61e32c","type":"modbus-response","z":"9ad7528f.e69fc","name":"","registerShowMax":20,"x":690,"y":100,"wires":[]},{"id":"a88606c6.70fc78","type":"modbus-client","z":"","name":"","clienttype":"serial","bufferCommands":true,"stateLogEnabled":false,"tcpHost":"127.0.0.1","tcpPort":"502","tcpType":"DEFAULT","serialPort":"/dev/ttySer1","serialType":"RTU","serialBaudrate":"19200","serialDatabits":"8","serialStopbits":"1","serialParity":"none","serialConnectionDelay":"100","unit_id":"6","commandDelay":"1","clientTimeout":"1000","reconnectTimeout":"2000"}]
And also I'm not sure what exactly means Unit-id, I've got Energy meter as a slave, is that Energy meter's address??
Thanks for some ideas