Modbus Flex Write Error

Hi there,

I'm working on a project that involves the Modbus Node.

Since I need to write several coil and register into a modbus server, I used the Modbus-Flex-Write node to collect every "write" message.

Unfortunately, I get this error:

TypeError: Cannot read property 'getMachineState' of undefined

Anybody can help me to understand this error?

I see the modbus queue that grow up because something goes wrong.

Thanks for the help!

Best regards,
Federico

Are you sure it is coming from the modbus node?

Yes it comes from Modbus Write Node

image

I don't know what does it means, it seems something related to the server status.

From the catch node, I get this output

TypeError: Cannot read property 'getMachineState' of undefined at Object._inputCallback (/opt/node-red/node_modules/node-red-contrib-modbus/modbus/maps/modbus-flex-write.js:52:5) at Object.Node._emitInput (/opt/node-red/node_modules/@node-red/runtime/lib/nodes/Node.js:199:18) at Immediate._onImmediate (/opt/node-red/node_modules/@node-red/runtime/lib/nodes/Node.js:179:33) at processImmediate (internal/timers.js:439:21)

Any ideas?

Thank you

What version of node-red and nodejs are you using. For the latter, use
node -v
If that is V12, 14, or 16 then that should be ok. If you are using a recent version of node red then probably best to post an issue on the node's GitHub page.

My node-red version in "1.0.3: Maintenance Release"

This is an industrial device an I cannot access to command line to get the nodej version.

This kind of error could be related to the modbus server that does not offer the missing properties?

Thanks

Put an issue on the node's GitHub page, I think only the author can answer this.

This topic was automatically closed 60 days after the last reply. New replies are no longer allowed.