Siemens S7
This input is tailored for the S7 communication protocol, facilitating a direct connection with S7-300, S7-400, S7-1200, and S7-1500 series PLCs.
Configuration
Configuration Parameters
tcpDevice: IP address of the Siemens S7 PLC.
rack: Identifies the physical location of the CPU within the PLC rack.
slot: Identifies the specific CPU slot within the rack.
batchMaxSize: Maximum count of addresses bundled in a single batch request. This affects the PDU size.
timeout: Timeout duration in milliseconds for connection attempts and read requests.
disableCPUInfo: Set this to true to not fetch CPU information from the PLC. Should be used when you get the error 'Failed to get CPU information'
addresses: Specifies the list of addresses to read. The format for addresses is
<area>.<type><address>[.extra]
, where:area
: Specifies the direct area access, e.g., "DB1" for data block one. Supported areas include inputs (PE
), outputs (PA
), Merkers (MK
), DB (DB
), counters (C
), and timers (T
).type
: Indicates the data type, such as bit (X
), byte (B
), word (W
), double word (DW
), integer (I
), double integer (DI
), real (R
), date-time (DT
), and string (S
). Some types require an 'extra' parameter, e.g., the bit number forX
or the maximum length forS
.
Output
Similar to the OPC UA input, this outputs for each address a single message with the payload being the value that was read. To distinguish messages, you can use meta("s7_address") in a following benthos bloblang processor.
Last updated