Timeout Connection between node-red-contrib-s7 and S7-1200

I'm having issues connecting the node red plc nodes with the S7-1200 in Siemens TIA Portal.

In the 's7 out' node, I've connected the IP address same with the “Device Configuration” of the S7-PLC in
the TIA-Portal.


image

Besides that, I also enable PUT/GET communication in the device configuration of the S7-1200 PLC

In the properties of my data block, I also unchecked the 'Optimized block access'

However, I received error from Node-Red terminal are as below:
Error: Timeout connecting to the transport

How could I connect my PLC to node-red?

Hi. IP address 169.254 is probably related to your issue.

My guess is you are using a Windows computer and you have a 169.254.x.y IP address?

This is an invalid IP automatically assgined to a windows computer when it cannot find a DCHP server. From the web:

When a Windows computer isn't able to communicate with the DHCP server, something called Automatic Private IP Addressing (APIPA) kicks in . It assigns the computer an IP address that starts with 169.254.

My 2nd guess is you have connected directly from the computer to the PLC?

Assuming all of the above, you should set the IP address statically to something like 192.168.x.y and a mask of 255.255.255.0 (or smaller) THEN set the IP of the PLC to an address in the same range.

e.g.:

  • computer 192.168.10.1, 255.255.255.0
  • PLC 192.168.10.2, 255.255.255.0

Then set the config address field to match the IP set for the PLC.

1 Like

Not seeing any references to uibuilder? If this isn't a uibuilder related issue, could I please ask you remove the tag? Thanks.

Thanks alot for your help Steve!

FYI, I'm using Windows computer. I am running the whole simulation using the PLCSIM, therefore it was connected to a local network called 'Siemens PLCSIM Virtual Ethernet Adapter'.

Based on your suggestions,
I changed the IP address from both computer and PLC to 192.168.x.y

In node-red, I'm connecting to http://192.168.10.1:1880 host. But turns out I still have the same error.
Error: Timeout connecting to the transport

Dumb question, but I understand that you are using PLCsim advanced. Are you able to ping downloaded PLC from your windows machine? Sometimes PLCsim advanced bricks, and it allows you to download software from TIA portal but doesn't allow external connections.

please try to replicate steps TIA Portal V17 simulation with Node-Red without use PLC - YouTube

There a few videos on YouTube that do this.

e.g. #118 Nodered s7 node with Siemens PLCSim Advanced operation - YouTube

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