Hi Guys,
I'm having problems with a simple flow reading data from my non-optimized DB1,WORD0 using an S7 1200 with V14 SP1. I am using the S7 In node connected to a debug node (Msg.Payload).
When my string is deployed the indicator on the "S7 In" node turns yellow(connecting) then a message appears "Lost connection to server". I have deleted the flow numerous times from the IOT2040 and set it up again but I kept having the same problem.
On a previous test program I had no connection problems and communication was fine, I was able to send and receive data to the PLC. I have also tried to change the IP address, to no avail.
I have tried a factory reset on the PLC, created new program and reuploaded the image for the IOT and installed the S7 library, but I still have the same issue as seen in the log report below. I have also changed cables and switch ports.
In order to access node red again i have to delete the flows.
See script and Node red log below.
I'm very new to this so any help is much appreciated.
Regards.
[{"id":"10146917.7654c7","type":"s7 in","z":"b469084f.726ab8","endpoint":"4d278213.c75a8c","mode":"single","variable":"OUT","diff":true,"name":"","x":110,"y":80,"wires":[["2f3e1868.683a68"]]},{"id":"4d278213.c75a8c","type":"s7 endpoint","z":"","transport":"iso-on-tcp","address":"192.168.0.3","port":"102","rack":"0","slot":"1","localtsaphi":"01","localtsaplo":"00","remotetsaphi":"01","remotetsaplo":"00","connmode":"rack-slot","adapter":"","busaddr":"2","cycletime":"5000","timeout":"2
Node Red Log:
9 Nov 22:11:02 - [info] Starting flows
9 Nov 22:11:02 - [info] Started flows
9 Nov 22:18:05 - [info] Stopping flows
9 Nov 22:18:05 - [info] Stopped flows
9 Nov 22:18:05 - [info] Starting flows
9 Nov 22:18:06 - [info] Started flows
9 Nov 22:18:06 - [error] [s7 out:bde46f5e.59633] Error: Not connected
9 Nov 22:18:06 - [red] Uncaught Exception:
9 Nov 22:18:06 - TypeError: stream.off is not a function
at ISOOnTCPClient.isoOnTcp.createConnection (/usr/lib/node_modules/node-red- contrib-s7/node_modules/@st-one-io/nodes7/src/s7endpoint.js:207:24)
at Object.onceWrapper (events.js:313:30)
at emitNone (events.js:106:13)
at ISOOnTCPClient.emit (events.js:208:7)
at process.nextTick (/usr/lib/node_modules/node-red-contrib-s7/node_modules/ iso-on-tcp/src/client.js:193:45)
at _combinedTickCallback (internal/process/next_tick.js:132:7)
at process._tickCallback (internal/process/next_tick.js:181:9)