Skip to content
< All Topics

S7 Functions

The S7 Functions is a protocol to communicate with a Siemens PLC.

Important: The S7-3xx PLCs have a limitation (that cannot be changed) of PDU (Protocol Data Unit) data size 220 bytes. This is the number of bytes that can be read/written in single operation. The most obvious way to overcome this is to add multiple connections if you expect to exceed 220 bytes in length.

In Experior it is possible to allocate more than 220 bytes per connection but data will then be transmitted in fractions of maximum 220 bytes. Allocating 440 bytes on one connection should have same impact on the PLC performance-wise as setting up two connections with 220 bytes allocated on each.

In both cases Experior will make two read/write operations.

But it is very important not to have too many unused bytes allocated: If there are some addresses in Experior that are positioned in the address area between 0 and 100 and the next address area of interest to the emulation is in the address area from 300 to 500 then it is important to split into two connections: one connection operating in the area between 0 and 100 and another connection operating in the area from 300 to 500. Unless there will in the current example be three read/write operations instead of only two.

If the length exceeds 220 bytes there will be a notification on the connection icon:

It is also important to consider the update internal (see the description of the different properties below): If there are signals that has to be transmitted to the PLC as fast as possible, it is advised that these signals are isolated in a separate connection where only inputs are associated with this connection (like encoder and pulse generator signals). In the same way, if there are signals that does not have to be updated that frequently (like buttons and lamps) it is advised to isolate those signals on a separate connection and then set a higher update interval. Then the PLC have more “time” to answer the request from the connections with a smaller update interval.

Properties

Identification

  • Name – Customizable name
  • Id – Customizable Id

 

Address

  • Rack – Number of rack that is being connected to
  • Slot – Number of slot where CPU is located

 

Communication

  • IP Address – Type in IP address
  • Update Interval – Measured in milliseconds. Less than 10ms activates fast mode updating
  • Auto Connect – Activate or Deactivate whether EcoStruxure Machine Expert Twin should try to automatically connect to the “Device”

 

Memory Allocation (PLC Input)

  • Automatic – Activate or Deactivate automatic memory allocation
  • Source Name – Input – static value, can’t be changed (only available if Automatic = False)
  • Length – Set data length (only available if Automatic = False)
  • Offset – Minimum offset (only available if Automatic = False)

 

Memory Allocation (PLC Output)

  • Automatic – Activate or Deactivate automatic memory allocation
  • Source Name – Output – static value, can’t be changed (only available if Automatic = False)
  • Length – Set data length (only available if Automatic = False)
  • Offset – Minimum offset (only available if Automatic = False)

 

If you are using a Siemens 1200 or 1500 series PLC, you will need to grant Experior full access through TIA.