Skip to main content
Skip table of contents

SIMATIC S7 Connector

This adapter allows to connect to Siemens SIMATIC S7 systems as PLCs from within Technical Processes. Data can be read from the controller as well as transmitted to it. An XML input structure allows to determine which data should be read or written. SIMATIC systems of the series S7-200, 300, 400 can be connected.

Properties

Operation

Defines the operation executed by the adapter

Possible values:

  • Read: Read data from PLC
  • Write: Write data to PLC

Parameters

Adapter

Adapter main class (do not change!)

Possible values: de.softproject.integration.adapter.s7.S7Connector: Main class (default)

host

Address to reach the PLC in the network

Possible values: IP address or Host name

rack

Rack to be addressed on the PLC

Possible values: Rack number (ask the PLC developer)

slot

Slot to be addressed on the PLC

Possible values: Slot number (ask the PLC developer)

Status values

1 (ok)

Successful communication (reading or writing) with the PLC

-1 (error)

Error during communication (reading or writing) with the PLC;
An error message is returned

Input

This adapter expects an XML document with the following input structure: 

Operation Read

XML
<?xml version="1.0" encoding="UTF-8"?>
<Read dbnum="[DBNUM]" bytes="[LENGTH]" offset="[OFFSET]">
	<FELDNAME s7type="[TYPE]" s7size="[LENGTH]" />
	...
</Read>

Parameters:

  • dbnum: DB number to be read from (ask the PLC developer)
  • bytes: Number of the bytes to be read
  • offset: Offset in bytes from which is to be read
  • The elements FELDNAME are freely selectable
  • s7type: Type of the fielt to be read; 
    Possible values:
    • Array

    • Bit (Note: only reads 1 bit, therefore 8 fields must be always specified!)

    • Byte

    • DateAndTime

    • Date (in format yyyy-MM-dd'T'HH:mm:ss)

    • Integer
    • Long
    • Real
    • String
    • Time (as Long)
  • s7size: Length in bytes to be read for the field. Only necessary for the types array and string

Operation Write

XML
<?xml version="1.0" encoding="UTF-8"?>
<Write dbnum="DBNUM" bytes="LENGTH" offset="OFFSET">
	<FELDNAME s7type="String" s7size="12">[VALUE]</AUFNR>
	...
</Write>

Parameters:

  • see operation Read 
  • The element's VALUE must syntactically match the type

Output

This connector outputs an XML document with the following structure:

  • Operation Read: The output corresponds to the input; If successful, the elements are filled with the appropriate values
  • Operation Write: The output corresponds to the input
JavaScript errors detected

Please note, these errors can depend on your browser setup.

If this problem persists, please contact our support.