Overview: Direct HMI-to-Sinamics PROFIBUS Communication
Connecting a Siemens HMI panel directly to a Sinamics S120 Control Unit 320 (CU320) over PROFIBUS DP without an intermediate SIMATIC PLC is an established integration path for machines that require drive visualization, jog/MDI operator control, and fault display from a single panel. The CU320 exposes its parameter space as PROFIBUS slots that the HMI treats like a SIMATIC S7-300/400 data block image, allowing WinCC flexible tags to read and write drive parameters through a deterministic addressing scheme.
This architecture removes the PLC from the control loop for HMI-only applications, reduces hardware cost, and shortens commissioning. The trade-off is that all logic normally written in ladder or SCL must either be embedded in the drive itself (via DCC, BICO, or free function blocks on the CU320) or replicated as HMI scripts in WinCC flexible.
Prerequisites and Compatible Hardware
Validate the hardware stack and software versions before wiring. The mapping rule depends on the panel correctly identifying the drive as a SIMATIC S7-300/400 station type.
| Component | Approved Selection | Notes |
|---|---|---|
| HMI panel | SIMATIC TP177B (6" mono/color) or MP277 (7"/10") | WinCC flexible 2008 SP2/SP3 or TIA Portal WinCC Comfort/Advanced V11+ |
| Drive controller | Sinamics S120 with CU320 (6SL3040-0MA00-1AA0 / -1BA0 / -1CA0) | PROFIBUS option card CBE20 is for PROFINET; CU320 has on-board PROFIBUS DP |
| PROFIBUS interface | CU320 PROFIBUS X126 (9-pin Sub-D) | Termination ON for last node on segment |
| PROFIBUS cable | Siemens PROFIBUS FC standard cable (6XV1830-0AH10) or FC trailing (6XV1830-0BH10) | Maximum segment 100 m at 12 Mbps; use repeaters for longer distances |
| Engineering tool | WinCC flexible 2008 SP3 (or WinCC Comfort V11 SP2+ for TIA Portal) | STARTER or Scout is required separately to commission the drive parameters |
| Drive engineering | STARTER V4.x or Scout V5.x with SINAMICS Support Package | Required to set p0922, p2051, p2050, p2044, p2045 |
Confirm the following firmware baseline:
- CU320 firmware V2.4 or higher (V4.4/V4.5/V4.6 SP3 recommended for current projects).
- WinCC flexible 2008 SP3 HF6 or later for the TP177B/M277 image.
- STARTER V4.4 SP1 or higher (matches drive firmware V4.x GSD/V5.1+).
PROFIBUS Network Architecture
The CU320 is a PROFIBUS DP-V1 slave by default. When the HMI is configured to address the drive as if it were a SIMATIC S7-300/400, the PROFIBUS master logic inside WinCC flexible exchanges data using the SINAMICS PPO (Parameter Process data Object) types 1, 2, 5, or the newer telegram types. The HMI does not need PPO awareness; it just addresses data block words through the S7 API.
PROFIBUS baud rate settings: the CU320 automatically detects and adapts to the master's baud rate (9.6 kbps to 12 Mbps). For new installations set the panel and the drive to 1.5 Mbps, which is the slowest rate commonly used with WinCC flexible panels to ensure reliable handshaking during startup.
WinCC Flexible Project Configuration
- Open WinCC flexible, create a new project targeted at the TP177B or MP277, and select PROFIBUS as the HMI connection.
- In Project → Communication → Connections, add a new connection of type SIMATIC S7 300/400. Do not select SIMATIC S7 200; the drive does not speak S7-200 I/O mapping.
- Set the HMI PROFIBUS address (default 1) and the CPU/DP slave address of the CU320 (default 2).
- Insert the Sinamics S120 GSD file (
SIEM808F.GSDfor firmware V4.x orSI8281F.GSDfor legacy V2.x) into WinCC flexible's device catalog. The GSD provides the slot-based parameter channel. - Slot mapping: assign one PPO type per drive object. WinCC flexible interprets the parameter channel as DB offsets; choose PPO1 (4 PKW + 2 PZD words) for parameter-heavy screens, or PPO5 (no PKW + 10 PZD) when only process data is needed and parameter access will go through standard tags.
C:\Program Files\Siemens\Automation\WinCC flexible\GSD. Restart the project after copying the new GSD so the catalog refreshes.Parameter Addressing Formula
The Sinamics parameter channel maps each parameter onto a virtual SIMATIC data block word. The mapping rule is identical for every drive object on the CU320:
| Quantity | Mapping Rule | Bit Range |
|---|---|---|
| Parameter number | Data block number (DB) | DB offset bits 11..0 (low 11 bits) |
| Parameter sub-index | Bit 0 of DBW offset | Offset bit 0 |
| Drive object number | Bits 5..0 of DBW offset (when index bit = 0) | Offset bits 15..10 |
The base offset for drive object #1 (the CU320 control unit itself) is 1024. Each subsequent object shifts by an additional 1024 words:
- Drive Object #1 (CU320 control unit):
DBW = 1024 + (parameter index) - Drive Object #2 (first Motor Module / Drive):
DBW = 2048 + (parameter index) - Drive Object #3:
DBW = 3072 + (parameter index) - Drive Object #4:
DBW = 4096 + (parameter index) - ...
- Drive Object #N:
DBW = N * 1024 + (parameter index)
The parameter index is simply the parameter number when the parameter has no sub-index. If the parameter has sub-indices, each sub-index toggles bit 0 of the DBW offset (i.e., adds 1 to the DBW). The pattern is:
DB number = parameter number (pXXXX or rXXXX)
DBW offset = (drive_object_number << 10) + (parameter_index_word_offset)
where parameter_index_word_offset is the internal 16-bit word index inside the object. The simplest encoding is the one used in WinCC flexible:
DBW = drive_object_number * 1024 + p_or_r_number_remainder
Drive Object to DBW Address Mapping Reference
| Drive Object # | Typical Identification | Base DBW Offset |
|---|---|---|
| 1 | CU320 Control Unit | 1024 |
| 2 | Motor Module / Drive 1 (Line Module on AC/AC chassis) | 2048 |
| 3 | Drive 2 | 3072 |
| 4 | Drive 3 / TB30 Terminal Board | 4096 |
| 5..16 | Additional drives, TM31, TM15, SMC, TB30, etc. | 5120 .. 16384 |
The Control Unit itself can be confirmed as object #1 via parameter p0097 (drive object numbers in the actual topology). Always verify by reading r0002 on each object before binding an HMI tag — drive topology re-numbering after commissioning is a common cause of tags reading back zeros.
Worked Examples: Reading and Writing Tags
Each example below uses the canonical Sinamics parameter format pXXX[i] / rXXX[i] and translates it directly into a WinCC flexible Tag with address format DB<n> DBW<m>.
Example 1 — Control Unit parameter
Drive object = Control Unit (#1). Parameter p2098[1] (inverting connector for the CU's inverter output to the next higher-level controller):
DB number = 2098
DBW offset = 1024 + 1 (sub-index [1] toggles the low bit)
= 1025
Full tag: DB 2098 DBW 1025
Example 2 — Drive power module parameter without sub-index
Parameter p898 on the AC-AC power module (object #2):
DB number = 898
DBW offset = 2048 + 0 (no sub-index, no toggling)
= 2048
Full tag: DB 898 DBW 2048
Example 3 — Power module parameter with sub-index zero
Parameter p2098[0] on the power module (object #2):
DB number = 2098
DBW offset = 2048 + 0 (sub-index [0] does not toggle the low bit on this object numbering)
= 2048
Full tag: DB 2098 DBW 2048
Sub-index [0] retains the base offset; sub-indexes [1], [2], ... add 1, 2, ... to the DBW offset respectively.
Example 4 — Drive 2 actual alarm code
Parameter r2132 on Drive 2 (object #3) without index = the currently active alarm code word:
DB number = 2132
DBW offset = 3072 + 0
= 3072
Full tag: DB 2132 DBW 3072
Example 5 — Safe Limited Speed, positive direction
Parameter p9733[1] on Drive 2 (object #3):
DB number = 9733
DBW offset = 3072 + 1
= 3073
Full tag: DB 9733 DBW 3073
Example 6 — TB30 digital output word
Parameter r4047 on the TB30 Terminal Board (object #4):
DB number = 4047
DBW offset = 4096 + 0
= 4096
Full tag: DB 4047 DBW 4096
Bit extraction for sub-word parameters
For parameters that are stored as packed bit-fields such as control words (r0054) or status words (r0052, ZSW1, STW1), expose the entire DBW as a 16-bit Word tag and apply WinCC flexible Bit extraction on the I/O field or screen object:
r0052[0] of Drive 2 (status word 1, smooth):
DB number = 52
DBW offset = 3072 + 0 = 3072
Full tag: DB 52 DBW 3072
-> Extract bit 3 (operation enabled) via Bit selection 'Bit 3'
Implementing Jog and MDI Control from the HMI
For jog (JOG) and MDI (setpoint entry) operation without a PLC, the drive's control word 1 (STW1) and the matching setpoint (NSOLL) channels are written by HMI tags. Use drive object #2 (or whichever drive object carries the closed-loop control for the axis).
| Function | Drive Parameter | WinCC flexible Tag (Drive object #2 example) |
|---|---|---|
| Drive control word 1 (write) | p0840 / STW1 at PZD1 output | DB 3001 DBW 2048 (when using free PZD mapping) |
| Main setpoint, NSOLL_B (rpm) | PZD2 (set via p2051/p2050) | DB 3002 DBW 2048 |
| Jog 1 bit | p1051[0] bit mapped to STW1 bit 8 (JOG1) | DB 1051 DBW 2049 |
| Jog 2 bit | p1052[0] bit mapped to STW1 bit 9 (JOG2) | DB 1052 DBW 2049 |
| MDI setpoint (speed) | p2647 (MDI setpoint) or NSOLL | DB 2647 DBW 2048 |
| MDI mode selection | p2640 (MDI mode, 0=positioning, 1=speed) | DB 2640 DBW 2048 |
| ON/OFF1 command | p0840[0] (ON/OFF1) | DB 840 DBW 2048 |
Wiring the control word bits in STARTER/SCOUT
- Open the drive in STARTER and navigate to Commissioning → Control structure → Drive I/O.
- Confirm the PROFIBUS telegram in use — standard telegram 2 (PZD 4/4) is the smallest telegram that carries STW1/ZSW1 + NSOLL/NIST.
- For internal jog buttons driven by the HMI, route
p1051/p1052into the BICO source for STW1 bit 8/9 usingp2050[8..9], so that toggling the HMI bit directly issues a jog command. - Set control word source:
p0855 = 0(drive-controlled) andp0922 = 999(free telegram structure) if needed.
p0840 ON/OFF1 driven via a hardware enable (terminal strip, safety relay, or STO channel) before the HMI is permitted to issue jog commands. The HMI is not part of the safety chain.Reading Faults and Alarms on the Panel
Two parameter arrays are commonly placed on a fault screen:
-
r2131 (oldest active fault code) — read at object #2 as
DB 2131 DBW 2048. -
r945[i] (fault history, indexed) — full fault buffer; index
iincrements the DBW low bit per entry. For object #2:DB 945 DBW 2048 + i. - r2132 (most recent alarm number) — see Example 4 above; configure as a Word tag and let the HMI display the numeric value alongside a lookup text list in WinCC flexible.
- r2120 (alarm history bits 0..15) and r2121 (bits 16..31) — for color-coded alarm banners.
The official enumeration of fault/alarm codes is published in the Sinamics S120 List Manual (function manual FH1).
Commissioning and Verification
- Power up the CU320, wait until
r0002shows the expected drive-object count. - Compile and download the WinCC flexible project to the panel.
- On the panel, enter the PROFIBUS diagnostics screen (Start → Settings → PROFIBUS) and confirm the configured partner is Online.
- Open a temporary screen with one input field bound to
DB 21 DBW 1024(Control Unit, command parameter set selection). Write a value of0and confirm the tag echoes back0within 200 ms (one PROFIBUS poll cycle at 1.5 Mbps). - For every drive object used by the HMI, perform a single read of
r0021(actual speed smoothed) at the appropriate offset and confirm a non-zero, plausible rpm when the drive is enabled. - Trigger a known, non-damaging fault (e.g., open the encoder cable briefly) and verify the fault code displays on the panel via
DB 2131 DBW 2048within one cycle. - If a parameter reports
32767 (0x7FFF)on a status read, the panel is reading an unsupported slot — recheck p0922 and the telegram mapping.
Troubleshooting Matrix
| Symptom | Likely Cause | Corrective Action |
|---|---|---|
| Tag returns 0 for every drive object | Telegram type mismatch (no PZD/PKW selected) | Re-import GSD and select PPO1 or telegram 1+ for parameter channel |
| Address works for object #1 but not #2, #3 | Drive topology re-numbered after commissioning | Read r0002 and r0097; remap tags to actual DO numbers |
| HMI shows PROFIBUS fault | Termination missing on segment | Switch terminator ON at the last physical node on the bus |
| Status word always 0x7FFF | PZD source not configured | Verify p2051 (PZD output from drive) and p2050 (PZD input to drive) |
| Jog command from HMI has no effect | ON/OFF1 (p0840) not set | Wire ON/OFF1 to a hardware enable terminal or set via panel tag |
| Alarm codes scrambled (high/low byte swapped) | Byte order mismatch on WinCC flexible | Enable "Big-Endian" / Motorola byte order in the connection settings |
| Slow HMI update (> 2 s) | Too many tags polling at full speed | Group parameters into arrays and increase tag acquisition cycles to 500 ms |
| Connection establishes but tag values freeze | Watchdog p2044 tripped |
Raise p2044 / p2045 from defaults (0.2 s) to 3 s for HMI traffic only |
Notes on PORT Swapping and TIA Portal Equivalents
The same addressing scheme carries directly into TIA Portal projects targeting Comfort Panels and WinCC Comfort/Advanced. In TIA Portal, the equivalent mapping is configured under Devices & Networks → HMI connection → Connection resources, where the CU320 is added as a SIMATIC S7-300/400 station with a PROFIBUS subnet. Reference documentation: Configuring an HMI Connection via PROFIBUS (Basic Panels / Comfort Panels) on the TIA Portal Help (V20).
In TIA Portal the tag address syntax becomes %DB<n>.DBW<m> with identical numeric values to those shown above. The drive-object-to-offset multiplier of 1024 per object is unchanged between WinCC flexible and TIA Portal.
Which Siemens HMI panels support direct CU320 PROFIBUS connection without a PLC?
TP177B (DP version), MP277, and all Comfort Panels from KTP400 to PC-RT with WinCC flexible 2008 SP3 or WinCC Comfort V11 SP2+ support this connection. Configure the panel's PROFIBUS node as a SIMATIC S7-300/400 station so that the drive object parameters map onto DB/DBW addresses.
What is the formula to compute a Sinamics parameter DB address for a WinCC flexible tag?
DB number = parameter number (without the p/r prefix). DBW offset = (drive object number × 1024) + parameter index where the parameter index equals the sub-index low-bit value (0 or 1 for the typical [0]/[1] cases).
Can I drive a Sinamics S120 axis in JOG from the HMI with no PLC in the loop?
Yes. Connect p1051/p1052 (JOG1/JOG2 sources) into STW1 bits 8/9 via p2050, ensure a hardware enable is present on p0840, and write to DB 1051 DBW 2049 / DB 1052 DBW 2049 from the HMI for drive object #2. MDI uses p2640 (mode) and p2647 (setpoint).
How do I display Sinamics fault codes on the panel?
Read r2131 (oldest active fault) at the appropriate DBW for each drive object, or read r945[i] for the fault history array. Each index increments the DBW low bit by 1. Combine the code with a text list in WinCC flexible for human-readable descriptions.
What baud rate should I use for a panel-to-CU320 PROFIBUS link?
1.5 Mbps is the conventional default for WinCC flexible panels; it provides robust handshaking during startup. The CU320 auto-bauds from 9.6 kbps up to 12 Mbps, so a higher rate (3, 6, or 12 Mbps) can be used if both the panel and the cable plant support it and the segment is well terminated.