How-to
Binding PLC tags from different DBs to a WinCC HMI UDT
Short answer
No configuration makes an HMI UDT span multiple data blocks: a structured HMI tag resolves to one addressable PLC instance. With the PLC program frozen, keep every existing address, create one external HMI tag per variable, and assign them to the faceplate interface properties at each instance; the screen-window tag prefix cannot supply per-equipment data and only reaches shared values with the documented marker.
On this page
No configuration makes an HMI user-defined type bind PLC tags that live in different data blocks. A structured HMI tag is one tag, with one controller connection and one start address, so it needs one addressable PLC instance — a DB built on a matching PLC-side type. With the PLC program frozen you cannot create that instance, which is exactly where the screen-window prefix attempt stopped. The working route: keep every existing address, create one external HMI tag per needed PLC variable, and assign those tags to the faceplate's interface properties at each instance. The faceplate is not the second-best option here; for frozen, scattered data it is the correct one.
Why an HMI UDT cannot reach across data blocks #
A UDT is a type, not storage: a named layout of members. Storage appears only where the controller creates it — a global DB built on the type, or the instance DB behind a function block call. An HMI tag of an HMI UDT type mirrors that arrangement: its members are offsets inside a single addressable structure on one connection. Member one in DB10 and member two in DB15 is not a structure; it is two tags, and no naming scheme turns two tags into one structured tag.
The function block case lands on the same rule. An FB is executable logic with instance storage; a faceplate is visualization. The HMI neither imports nor executes FB code, and each FB call keeps its own instance DB, so three calls are three data blocks — the scattered situation again, one level down. What reaches the HMI is whatever external tags you point at those instance DB members.
Where the tag prefix helps, and where it stops #
The screen window, its tag prefix, and the escape marker below are documented for WinCC RT Professional. The prefix resolves names, never addresses: it can only swap a consistent name segment while a window is reused. The documented mechanism is defined around tags assigned to a UDT — structured tags whose matching instance must exist in the controller — which is why the route closed the moment the PLC was declared untouchable.\n One documented use remains inside a prefixed window: to access a tag that is not assigned to any UDT, you add the prefix @NOTP:: to the tag name. Such a tag resolves unchanged, with the window prefix ignored. That suits shared values a reused window should always show — a line mode, a common speed reference — and nothing per-equipment. In the Unified runtime the same boundary takes the form of the faceplate interface: per-instance data comes only from tags assigned to the instance.
What the faceplate interface gives you #
In the Unified runtime, the faceplate type's tag interface is documented as a standardized communications interface between the faceplate and the automation system: you configure interface tags once in the faceplate type, the objects inside connect to those interface tags instead of fixed controller tags, and each instance is handed its own tags in configuration. That indirection is exactly what scattered data needs. The faceplate never asks whether the values behind one instance share a data block; it asks only that each interface property receive a tag of a compatible type. The instinct that a faceplate is a fragile substitute for a UDT is backwards — it is the one mechanism here whose binding is explicit per instance.
Binding the faceplate without touching the PLC #
- Write the interface contract first: one row per displayed value and per operator command, each with its PLC data type, read or write direction, and the existing DB member it lives in.
- Create one external HMI tag per contract row, each connected to its existing PLC variable — no address changes, no new DBs. For a long list, importing a PLC tag CSV into an existing HMI tag database beats typing tags one by one.
- In the faceplate type, configure one interface tag per contract row, types matching the PLC side: BOOL for states and commands, INT or REAL for analog values.
- Connect every object inside the faceplate to the interface tags. A reusable object with a fixed controller tag buried in it displays the same motor on every instance.
- At each instance, assign that equipment's HMI tags to the interface properties, working row by row from the contract. Inspect the command rows closest: a swapped command binding writes a start to the wrong equipment.
- Compile the HMI project and clear every missing reference and type mismatch before download.
Worked example: three motors in DB10, DB15 and DB30 #
Inputs: three agitator motors, each needing five values — run feedback (BOOL), fault (BOOL), speed actual (INT), speed setpoint (INT), start command (BOOL). The legacy program left the addresses where they are: Agitator 1 in DB10, Agitator 2 in DB15, Agitator 3 in DB30. The DB numbers are illustrative — substitute yours — but the shape is the blocking one: same logical set, different storage. One faceplate type exposes five interface tags.
Rule in words: external HMI tags needed equal values per equipment times equipment count, and property assignments equal the same product; the structured route would instead cost one prefix assignment per equipment.
The arithmetic:
- External HMI tags: 5 values × 3 motors = 15
- Property assignments: 5 per instance × 3 instances = 15
- Blocked alternative: 1 PLC UDT + 1 aggregation DB + 3 structured HMI tags + 3 prefix assignments, plus a PLC download that is not allowed
Result: 15 tags, 15 assignments, zero PLC changes.
Decision: 15 hand-checked assignments is an afternoon, and every binding stays visible and auditable — bind them. The number that changes the decision is growth: each future motor costs 5 tags and 5 assignments, so past roughly 20 assignments (four motors at five values), renegotiate the freeze and build the aggregation DB, because the structured route then costs one prefix per motor against five bindings per motor.
Checks before download #
Compile before anything else: a missing interface assignment or a type mismatch surfaces at compile time, not on the floor. Then run the project against the connected controller and compare each displayed value with online monitoring of its intended DB member — the same discipline as testing HMI simulation against a live PLC. A swapped read binding shows a plausible wrong number, so verify by equipment: the Agitator 2 speed display must follow DB15 while DB10 holds still. Check analog scaling once per row so an INT means the same engineering units on both sides. Exercise the command rows last, with the machine in a safe state — a misbound start command is a real start command on the wrong motor.
Questions asked
Can the faceplate read my FB automatically if the FB is called in the PLC?
No. A faceplate is visualization only; it neither imports nor executes function block logic. The FB's stored values live in its instance DB, and each call gets its own instance DB, so three calls are three data blocks — the same scattered situation one level down. Point external HMI tags at the instance DB members you want to display, then assign those tags to the interface properties at each faceplate instance.
Is there any way to keep the screen window with plain tags?
Only for shared values. In WinCC RT Professional, the documented access for a tag that is not assigned to any UDT inside a prefixed screen window is to add @NOTP:: before the tag name, and the tag then resolves unchanged with the window prefix ignored. That suits values every instance should show identically, such as a line mode or a common speed reference. It cannot supply per-equipment data, because per-instance resolution is tied to the UDT-assigned structured tags.
How many tags and bindings will this cost?
Multiply values per equipment by equipment count. Five values on three motors means 15 external HMI tags and 15 property assignments, and every route needs the 15 tags — only a PLC-side aggregation would cut the assignments to one prefix per instance. Budget checking time per assignment: a swapped read binding shows a believable wrong value until someone compares it against online monitoring.
Can a faceplate instance receive its tags dynamically at runtime?
Yes, in the Unified runtime. The documented method dynamizes the Interface object property of a faceplate instance with a tag parameter, so a button or script can change which configured tag name feeds the instance. It swaps one configured tag for another at runtime; it does not create addresses, so the scattered data blocks are unaffected.
What if the PLC freeze is only temporary?
Plan the structured route into that revision: one PLC UDT, one aggregation DB or instance array, a matching HMI UDT, structured tags, and one prefix assignment per screen window instance. Per-equipment work then drops from five assignments to one. Until the revision ships, explicit faceplate bindings are the correct interim state — keep them documented in the interface contract so the later migration maps straight across.