st-one-io / node-red-contrib-s7

A Node-RED node to interact with Siemens S7 PLCs
GNU General Public License v3.0
111 stars 58 forks source link

Run flow_witeTest.json Error #6

Closed hhdang closed 7 years ago

hhdang commented 7 years ago

Return follow Error after deploy flow_writeTest.json

TypeError: this is not a typed array. at Function.from (native) at NodeS7.onTCPConnect (/home/hh/.node-red/node_modules/nodes7/nodeS7.js:247:19) at Socket. (/home/hh/.node-red/node_modules/nodes7/nodeS7.js:163:21) at Socket.g (events.js:260:16) at emitNone (events.js:67:13) at Socket.emit (events.js:166:7) at TCPConnectWrap.afterConnect [as oncomplete] (net.js:1050:10)

node -v ==>v4.2.6 npm -v==>3.5.2 uname==>4.4.0-43-Microsoft

gfcittolin commented 7 years ago

Hi, this has been introduced with a PR we've made to implement the ability to connect to the PLC by using TSAP instead of Rack/Slot. The Buffer.from() is only available in NodeJS versions greater than 6.x. I've created a PR to fix this on plcpeople/nodeS7#34. Meanwhile, if possible, you can update your NodeJS version, and the issue won't happen

gfcittolin commented 7 years ago

This was fixed upstream, going to close the issue