Reading SINAMICS S120 Parameters in STEP 7 via PROFIdrive Acyclic

David Krause12 min read
SiemensTIA PortalTutorial / How-to
Licensed PE Working through this on a live machine? A Maine-licensed engineer can take it from here — included with IMD hardware, by the hour for everything else. Book an engineer

Reading individual SINAMICS S120 parameters (such as r89, the actual DC link voltage) into a SIMATIC controller without burdening the cyclic process data is a common requirement on PROFINET/PROFIBUS networks. This reference describes how to perform PROFIdrive acyclic parameter access from STEP 7 (TIA Portal and classic) using the LAcycCom block library, with FB 30512 LAcycCom_ReadDriveParams as the core block.

Scope: SINAMICS S120 with CU310-2 / CU320-2 Control Units, SIMATIC S7-1500 / S7-1200 / S7-300, PROFINET or PROFIBUS, TIA Portal V15.1+ or STEP 7 V5.5/V5.6. Vector and Servo drive objects are both supported.

1. Overview and Use Case

SINAMICS S120 exposes roughly 30,000 parameters through its Drive Object (DO) model. Drive-internal observers, diagnostics, and Service functions frequently need only a handful of values — e.g., r89 DC link voltage, r21 smoothed speed, r35 motor temperature — sampled every 500–1000 ms. Mapping these values into the cyclic PZD area wastes telegram bandwidth and requires BICO re-routing every time a new parameter is added.

The PROFIdrive acyclic parameter channel is designed for this case: the controller sends a parameter request, the drive responds, and the application cycle time is decoupled from the bus cycle time. Siemens ships the LAcycCom block library specifically for this purpose. The library is supplied free of charge and contains the read block (FB 30512), the write block (FB 30513), a connection management block (FB 30511), and the matching PLC data types.

When the requirement is a single value such as r89 read every 500–1000 ms, the acyclic approach is clearly the correct choice. It keeps the cyclic telegram slim, isolates network errors to the parameter request path, and allows new parameters to be added at any time by extending the parameter array at the FB call.

2. Prerequisites

Item Specification Notes
Drive SINAMICS S120 (CU310-2 PN/DP, CU320-2 PN/DP) FW ≥ V4.5 recommended; V5.x supported
Controller SIMATIC S7-1500 (preferred), S7-1200, S7-300, ET 200SP CPU S7-1500/ET 200SP = TIA Portal; S7-300 = classic or TIA
Engineering TIA Portal V15.1 or higher (V16/V17/V18/V19) Older projects may remain on V14 SP1
Library LAcycCom_Blocks V1.0 / V1.1 (TIA Portal) Download from Siemens Support entry 109479553
GSD GSDML-Vx.x-Siemens-Sinamics-Sxxxx-xxxxxxxx.xml Matches installed FW version
Topology PROFINET IRT/RT or PROFIBUS DP PROFINET recommended for CU3x0-2 PN
Commissioning tool STARTER V5.x or Startdrive V15.1+ for offline configuration Not required at runtime; required for commissioning
GSD file discipline: Always install the GSD matching the SINAMICS FW version running on the drive. A mismatch results in start-up faults (F01346 / F08501) and rejected parameter access.

3. SINAMICS S120 Parameter Model: p-, r-, and Indexing

SINAMICS parameters are split into two groups:

  • p parameters — settable (Set) parameters. Writing changes drive behavior.
  • r parameters — read-only display parameters. Writing is rejected with fault F0100.

Each parameter number may have multiple indices (sub-parameters). Index 0 is the “main” value; indices ≥ 1 typically denote array elements (e.g., BICO inputs, fault buffer entries). r89 has only a single index (0). Examples of common parameters:

Parameter Meaning Unit Data type Access
r89 Actual smoothed DC link voltage (UDC link) V FLOAT (32-bit, N4 normalized) RO
r21 Actual speed smoothed RPM FLOAT (N4) RO
r35 Motor temperature °C FLOAT (N4) RO
p15 Macro drive object — INTEGER RW
p1215 OFF1 ramp time s FLOAT RW

The normalized floating-point format is the PROFIdrive standard: 4000hex (16384) represents 100% with sign and 16-bit mantissa per the N2/N4 spec. For r89 the scaling uses reference parameter r2001. The LAcycCom blocks return the value already scaled in floating-point LREAL form, so no manual conversion is needed in the application.

4. Cyclic vs Acyclic Data Exchange: When to Use Each

Criterion Cyclic (PZD) Acyclic (PKW / LAcycCom)
Cycle time Bus cycle (1–4 ms typical) Application cycle (≥ 50 ms recommended)
Number of parameters Limited by telegram (8–32 PZD) Up to 16 per FB call (multiple calls allowed)
Configuration BICO interconnection + telegram assignment Block call only
Reconfiguration Drive restart + controller download Online; no restart
Recommended for Closed-loop control words, setpoints, fast feedbacks Diagnostics, slow process values, parameter changes

For a single parameter sampled every 500–1000 ms, acyclic is the better choice. It keeps the cyclic telegram slim, isolates network errors to the parameter request path, and allows new parameters to be added at any time by extending the parameter array at the FB call.

5. Required Siemens Library: LAcycCom_Blocks

The library is published as a global library (.zip) for TIA Portal and as a set of FBs/ST sources for classic STEP 7. Reference: Siemens Support Entry 109479553 – LAcycCom_Blocks (FB 30512 / 30513). The entry contains the library archive, the function manuals, and sample projects for S7-1500 / ET 200SP, S7-1200, and S7-300/400. A working S7-1500 / SINAMICS S120 example is published separately at Siemens Support Entry 109749224 – SINAMICS S120 with SIMATIC S7-1500.

Block Number Function
LAcycCom_Connect FB 30511 Establishes / monitors the acyclic connection; called once per drive
LAcycCom_ReadDriveParams FB 30512 Reads 1–16 parameters acyclically (used in this article)
LAcycCom_WriteDriveParams FB 30513 Writes 1–16 parameters acyclically
LAcycCom_typeParams UDT Parameter request / response structure
LAcycCom_typeDriveObjectId UDT Drive object addressing
Installation path (TIA Portal): Options → Global libraries → Open library → select the supplied .zip. The library is non-master, meaning updates can be merged in later. Always keep the library version aligned with your TIA Portal version; V18+ libraries will not open in V15.1.

6. TIA Portal Hardware Configuration for SINAMICS S120

Follow the official configuration procedure described in the TIA Portal help: Configuring SINAMICS S120 (SIMATIC S7-1500 / ET 200MP Manual Collection).

  1. Install the GSD file (Options → Manage general station description files).
  2. Add the S120 to the PROFINET network and assign a device name and IP address.
  3. Drag the S120 from the catalog to the device configuration.
  4. Open the S120 device view. The slot index 0 represents the CU; further slots depend on the Line Module and Motor Modules present.
  5. Assign a standard telegram (e.g., Telegram 1 for vector with control word 1 and speed setpoint) or a SIEMENS-specific telegram (e.g., Telegram 370, 371) on the appropriate subslot. The telegram is configured per drive object, not for the whole CU.
  6. Compile and download the configuration. The S120 should report no F01346 / F08501 start-up faults.

For acyclic access the telegram is irrelevant — the parameter channel uses a separate PROFINET acyclic RPC. Telegram 999 (free PZD assignment) can be combined with LAcycCom to keep the cyclic area minimal, and Telegram 0 (no PZD at all) is acceptable for pure-diagnostic configurations.

7. Drive Object Addressing and Telegram Selection

A single S120 chassis can host several drive objects (DOs). The DO ID is required by every LAcycCom call. With STARTER or Startdrive, the DO ID is visible under Properties → Drive Object → DO Number.

Drive object Typical DO ID Comments
CU (Control Unit) 1 r89 read here returns the common DC link voltage
Infeed (Active / Smart / Basic Line Module) 2 DO 2 has its own r89 (UDC link of the infeed)
Vector axis / Servo axis 3, 4, 5… Up to 6 Motor Modules per CU320-2

r89 is identical at the CU (DO 1) and at the infeed (DO 2); either can be used. Reading r89 from a Servo or Vector axis DO (3+) does not return a meaningful DC link voltage and will return a per-parameter error ≠ 0.

8. Reading r89 Using FB 30512 (LAcycCom_ReadDriveParams)

The block signature (TIA Portal V18, library V1.1) is shown below. The same signature is valid for V15.1, V16, and V17 with the corresponding library version.

FUNCTION_BLOCK LAcycCom_ReadDriveParams
VAR_INPUT
    hwInterface      : HW_ANY;             // PROFINET/PROFIBUS interface HW ID
    iopl             : BOOL;               // IO process life-bit (heartbeat)
    reqParams        : LAcycCom_typeParams;// parameter request structure
    execute          : BOOL;               // rising edge starts the job
END_VAR
VAR_OUTPUT
    done             : BOOL;
    busy             : BOOL;
    error            : BOOL;
    status           : WORD;               // 0 = OK, see error table
    rdParams         : LAcycCom_typeParams;// response structure
END_VAR

The LAcycCom_typeParams UDT contains the following fields, where the array index runs from 1 to 16:

TYPE LAcycCom_typeParams
STRUCT
    driveObjectId    : BYTE;               // 1 = CU, 2 = Infeed, 3+ = axis
    paramCount       : INT;                // 1..16
    parameterNumber  : ARRAY[1..16] OF INT;// e.g., 89
    parameterIndex   : ARRAY[1..16] OF INT;// typically 0
    parameterValue   : ARRAY[1..16] OF LREAL;// scaled value, e.g., 540.1
    parameterError   : ARRAY[1..16] OF WORD;// per-parameter error
END_STRUCT
END_TYPE

The block is multi-instance capable. Allocate one instance DB per drive object so the call is re-entrant for other DOs without interfering with each other. The iopl input must be wired to a CPU-side life bit (e.g., a system clock at 100 ms or a 1-Hz flip-flop); an inactive iopl causes the block to abort with status 0x8002.

9. Sample SCL / Structured Text Code

// FB_R_DriveParams (Function Block wrapper) — SCL, TIA Portal V18

FUNCTION_BLOCK "FB_Read_R89"
VAR
    sReq       : LAcycCom_typeParams;
    sResp      : LAcycCom_typeParams;
    sInst      : "LAcycCom_ReadDriveParams";
    sTrig      : BOOL;
    sVal89     : LREAL;
    sErr       : WORD;
END_VAR
BEGIN
    // Build request
    sReq.driveObjectId    := 1;             // CU
    sReq.paramCount       := 1;
    sReq.parameterNumber[1] := 89;         // r89 DC link voltage
    sReq.parameterIndex[1]  := 0;

    // Trigger on a 500-ms clock pulse
    IF "Clock_500ms" THEN
        sTrig := TRUE;
    END_IF;

    sInst(
        hwInterface  := "PROFINET_IO_1",
        iopl         := "Iopl_CPU",
        reqParams    := sReq,
        execute      := sTrig,
        done         => sDone,
        busy         => sBusy,
        error        => sError,
        status       => sStatus,
        rdParams     => sResp
    );

    IF sDone AND NOT sError THEN
        sVal89 := sResp.parameterValue[1];
        sErr   := 0;
    ELSIF sError THEN
        sErr := sStatus;
    END_IF;

    // Drop trigger after the call completes
    sTrig := sTrig AND sBusy;
END_FUNCTION_BLOCK

Place the FB call in OB1 behind a 500-ms clock generator built from a TP (pulse timer) or a cyclic OB with execution-time monitoring. Avoid placing the call in OB1 with a 1-ms cycle; the drive CPU can only process a limited number of acyclic requests per second, and flooding it with requests triggers F08501 "PROFINET acyclic channel overloaded".

10. Error Handling and Status Word Interpretation

status (hex) Meaning Remedy
0000 Success —
7000 Idle / no job active Wait for execute
7001 Job in progress —
7002 Receiving response —
8001 Drive returned parameter error Check rdParams.parameterError[i]
8002 Timeout (drive did not respond) Check connection, GSD, FW, iopl
8003 Parameter format error Verify data type, index
8004 Access denied (write to r parameter) Switch to FB 30512 (read), not FB 30513
8005 Parameter number out of range Cross-check in STARTER parameter list
8006 Drive object not found Verify DO ID in STARTER

Per-parameter errors (rdParams.parameterError[i]) contain the PROFIdrive error number 0x0000–0x00FF; the most relevant are:

  • 0x0001 — Illegal parameter number (r89 only on DO 1 or 2).
  • 0x0002 — Illegal sub-index (use 0 for r89).
  • 0x001F — Parameter access temporarily unavailable (drive in startup, wait for r899.0 = 0).

11. Verification Procedure

  1. Download the project to the S7-1500 and go online.
  2. Open the instance DB inst_Read_R89 in monitor / watch mode.
  3. Force sTrig := TRUE and observe status transition 7000 → 7001 → 7002 → 0000.
  4. Confirm rdParams.parameterValue[1] is non-zero and within physical range. For a 400 V class S120 with mains 380–480 V, r89 should read 540–680 V during normal operation (UDC link ≈ 1.35 × Vrms).
  5. Disable the drive (OFF1) and check r89 drops to a value near 0 within 5 s; enable and verify recovery.
  6. Disconnect the PROFINET cable and verify the block reports status 8002 within the configured timeout.
  7. Cross-check r89 against the S120 HMI / Startdrive trace to confirm identical values.

12. Troubleshooting Matrix

Symptom Likely cause Action
status = 8002 permanent PROFINET name/IP mismatch, iopl stuck Re-assign device name; verify topology in TIA; check iopl heartbeat
rdParams.parameterValue[1] = 0 Wrong DO ID, or drive in startup Set DO ID = 1 or 2; wait for r899.0 = 0
rdParams.parameterError[1] = 0x0001 Parameter 89 not on chosen DO Use CU or Infeed DO
Block does not compile Library version mismatch Use LAcycCom matching TIA Portal version
value jumps by ±10 V Reading r89 on Servo axis (uninitialized) Switch to DO 1 or DO 2
Timeout with S7-300 FB 30512 not supported on 300 Use SINA_PARA (FB 287) or DRIVEES_PARA
status = 8004 Attempted write on r parameter Use FB 30512, not FB 30513
Error after firmware update GSD obsolete Install new GSD and re-compile
F08501 on drive Acyclic request rate too high Raise application cycle to ≥ 250 ms; reduce parameter count

13. Performance and Timing Notes

A single-parameter acyclic read on PROFINET IRT with a typical S7-1500 CPU takes 20–60 ms round-trip. Reading 16 parameters in one FB call takes 80–200 ms. The application cycle should be sized to at least 2× the round-trip to allow for retries. On PROFIBUS DP, expect 50–100 ms per parameter due to the slower acyclic DPV1 service.

For S7-300/400, the LAcycCom library is not available. Use the SINA_PARA block (FB 287) from DriveES-S7 or the older DRIVEES_PARA (FB 192) for PROFIBUS. On S7-1200 the LAcycCom library is supported with the V1.1 update; V1.0 does not include S7-1200-compatible code.

When the cycle must be faster than 50 ms, consider mapping r89 to cyclic PZD via Telegram 999 plus a BICO routing from r89 to a PZD word. This is faster but consumes telegram bandwidth and must be re-configured every time a new parameter is added.

Why is r89 returning 0 even though the drive is enabled?

You are probably reading r89 on a Servo or Vector axis DO (3, 4, 5…) where the parameter is either non-existent or reports 0. r89 (DC link voltage) is defined on the CU (DO 1) and Infeed (DO 2). Set driveObjectId := 1 in your FB 30512 request structure.

Can I use LAcycCom on a SIMATIC S7-300 with PROFIBUS?

No, FB 30512 and FB 30513 from the LAcycCom library target S7-1500, S7-1200 and ET 200SP. For S7-300/400 use the older SINA_PARA (FB 287) or DRIVEES_PARA (FB 192) from DriveES-S7. The S7-300 DP master DPV1 service is fully supported by these alternative blocks.

How many parameters can one FB 30512 call read?

Up to 16 parameters per call, driven by the paramCount field. For more, either call the block multiple times sequentially with separate instance DBs, or migrate to a rotating-window design where the request list cycles through 16-element windows over multiple cycles.

Does acyclic read work without a configured cyclic telegram?

Yes. The PROFIdrive acyclic parameter channel is a separate RPC service on PROFINET and a separate DPV1 service on PROFIBUS, independent of the cyclic PZD telegram. Telegram 0 / 999 (no or free cyclic PZD) is acceptable, provided the drive is reachable on the network and the GSD is installed.

What scaling does the block apply to r89?

The block returns the value already scaled into engineering units (LREAL, in volts for r89) using the standard PROFIdrive N2/N4 reference parameter r2001. The application does not need to multiply by 1.732 or 4000hex; the library does it. If you see raw normalized values, you are reading from a non-standard telegram, not from the LAcycCom block.

Back to blog