Zum Inhalt springen

Weidmüller u-OS Data Hub

Dieser Inhalt ist noch nicht in deiner Sprache verfügbar.

The Weidmüller connector enables bidirectional data exchange between your logiccloud runtime and the Weidmüller u-OS Data Hub. You can publish PLC variables to the hub (provider) and subscribe to hub variables (consumer).

Before creating a Weidmüller connection, you need:

  1. A Weidmüller u-OS device with the Data Hub enabled
  2. OAuth2 client credentials configured in the u-OS Control Center (Identity & access → Clients)
  3. The exact client name as shown in Control Center

Clients live in the device’s u-OS Control Center → Identity & access → Clients. Each has a Name and a Client ID; the Name column is the value the connector’s Client name field must match.

The Clients page in the u-OS Control Center

Press Add client and give it a Client name. The device states the rule beside the field: lower case a-z, 0-9 and _ are allowed, it must start with a letter, and it must not end with _.

Then tick the permissions the connector needs, under Variable HTTP API permissions:

PermissionNeeded for
Read Hub variablesA consumer, which subscribes to hub variables
Provide Hub variablesA provider, which publishes to the hub
Read-and-write Hub variablesMappings that write back to the hub (Mode To hub)

The Administration of API permissions below them — system information, logs, network, security and update settings — are not used by the connector. Leave them unticked.

Adding a client in the u-OS Control Center, with the Variable HTTP API permissions ticked

u-OS shows the client secret once, when the client is created. Copy it then — you need it for the connection, and it cannot be read back afterwards.

  1. In your project, navigate to the Runtimes section
  2. Select your runtime and expand Connections
  3. Click Add connection and select Weidmüller
  4. Fill in the connection details:
FieldDescription
Connection nameA descriptive name for the connection
Connection descriptionOptional free text
OAuth2 client IDThe client ID from u-OS Control Center
Client nameThe exact client name from u-OS Control Center
OAuth2 client secretThe client secret

There is no token-endpoint field: the edge derives it itself.

The Create Weidmüller connection dialog

  1. Click Save to create the connection

Providers publish PLC runtime variables to the u-OS Data Hub, making them available to other systems.

  1. Right-click the connection and select Add Provider
  2. Configure the provider:
FieldDescription
NameA descriptive name for the provider
DescriptionOptional free text
Label (optional)Optional label for the provider
FolderOptional prefix for variable addresses (dot-separated)
  1. Click Save

The Create Weidmüller provider dialog

The name the hub sees comes from the connection’s Client name, so that value must follow the u-OS naming grammar:

  • Lower case letters (a-z), digits (0-9) and underscores (_) only
  • Must start with a letter
  • Must not end with an underscore
  • No dots, dashes, spaces or upper case letters

Valid: plc, weather_station, line1_sensors Invalid: PLC, plc-1, plc.line1, 1plc, plc_

u-OS enforces this as you type: the rule appears beside the Client name field when the value does not satisfy it.

Consumers subscribe to u-OS Data Hub variables and write them to PLC runtime variables.

  1. Right-click the connection and select Add Consumer
  2. Give the consumer a Name and, optionally, a Description
  3. Click Save

A consumer has no Label or Folder: those belong to providers, which publish.

The Create Weidmüller consumer dialog

Instead of typing addresses by hand, you can browse the address space the device actually reports and pick the variables you want.

  1. Select the provider or consumer
  2. Click Browse
  3. Expand the folders and select one or more variables
  4. Confirm — the IDE adds one mapping row per selected variable

The tree mirrors the folder model the hub reports. A dotted variable key such as digital_nameplate.address_information.city_town becomes one tree level per segment, so related variables stay grouped instead of appearing as one long flat list.

Folders and values are distinguished by what the device reports, not guessed:

  • Folders can be expanded and contain other nodes.
  • Values are the variables you can map.

A folder has no address of its own, so selecting one adds no mapping row. Select the values inside it instead.

ColumnFilled with
Variable NameThe full dotted key of the variable
AddressThe bare dotted key — the only form the hub accepts
TypeThe data type the device reports, defaulting to Bool if it reports none
ModeFrom hub
ProviderThe hub provider that owns the variable, when the device reports one

Variable Name is the full dotted key rather than only the last segment. Two variables named city_town in different folders therefore stay distinct instead of collapsing onto a single row.

The Provider is kept as its own field and is never joined onto the address. Leave it empty to inherit the endpoint’s Provider ID — see Per-Mapping Provider Override.

The hub reports whether each variable is read-only or read/write, and the Mode dropdown follows:

The device reportsMode offers
Read-onlyFrom hub only
Read/writeFrom hub and To hub

Writing to a read-only hub variable cannot succeed, so To hub is not offered for one — this prevents a mapping that fails silently at runtime.

Two details worth knowing:

  • A browsed row always defaults to From hub, even when the variable is writable. Write access only unlocks the To hub option; it does not preselect it.
  • A row you author by hand keeps both options, because nothing has told the IDE what that address supports.

The browse tree does not offer $quality or $timestamp entries. They are not variables you can map. Use the Quality Variable and Timestamp Variable fields on the mapping instead — see Quality and Timestamp Metadata.

Mappings connect PLC variables to u-OS Data Hub variables.

  1. Select the provider or consumer
  2. Click Add Mapping
  3. Configure each mapping:
FieldDescription
Variable NameThe PLC runtime variable
AddressThe hub variable address (dot-separated path)
TypeData type: Bool, Int, Float64, String, etc.
ModeDirection: From hub (subscribe) or To hub (publish)
ProviderOptional: override the endpoint’s provider ID for this mapping
Quality VariableOptional: PLC variable for quality metadata
Timestamp VariableOptional: PLC variable for timestamp metadata

The hub variable address uses dot-separated segments:

Valid: temperature, line1.temp1, sensors.out.temp1 Invalid: 1temp, temp-1, temp/out

When you set a Folder on the provider/consumer, it is automatically prepended to each mapping’s address:

FolderMapping AddressEffective Address
sensors.outtemp1sensors.out.temp1
plc.valuestemperatureplc.values.temperature
(empty)line1.sp1line1.sp1

This allows organizing variables hierarchically without repeating the prefix in every mapping.

TypeDescription
BoolBoolean (true/false)
Int32-bit signed integer
Int6464-bit signed integer
Float32Single-precision floating point
Float64Double-precision floating point
StringUTF-8 text
DurationTime duration value
TimestampDate/time timestamp

By default, all mappings in a provider/consumer use the endpoint’s Provider ID. You can override this per-mapping to publish/subscribe to a different hub provider:

  1. In the mapping row, set the Provider field to a different provider ID
  2. Leave it empty to inherit from the endpoint

This allows a single consumer to subscribe to variables from multiple hub providers.

Each mapping can optionally capture metadata reported by the u-OS Data Hub:

FieldDescription
Quality VariableA PLC variable that receives the hub-reported signal quality indicator. Useful for detecting stale or invalid data.
Timestamp VariableA PLC variable that receives the hub-reported timestamp of the last value update. Useful for diagnostics and data synchronization.

These fields are optional. When configured, the edge runtime automatically populates them with metadata from the hub alongside the actual variable value.

The sections above describe each field on its own. This is the whole task, end to end.

Data always travels between a PLC variable in your program and a hub variable on the device. A mapping is the link between the two, and its Mode says which way the value moves.

A mapping can only use a variable your program exposes. Declare it in the PLC code with the {IN} or {OUT} attribute, according to the direction you want:

Declared asBecomesUse it to
{IN}an Inputreceive a value from the hub
{OUT}an Outputsend a value to the hub

Open the runtime’s Inputs/Outputs and press Refresh. Newly declared variables appear only after this — the list does not update by itself.

  • To send data, add a provider. It publishes your PLC variables to the hub.
  • To receive data, add a consumer. It subscribes to hub variables and writes them into your PLC variables.

In the provider or consumer, add a mapping for each variable. Two shortcuts save typing:

  • Browse picks the hub side — it fills Address, Type and Provider from what the device reports. See Browse the Data Hub.
  • Advanced fill picks the PLC side — it opens Fill - Inputs/Outputs and creates a row per selected variable.

Advanced fill sets Mode from the variable’s direction: an Output becomes To hub, an Input becomes From hub. That is almost always what you want, and you can change it in the Mode column.

Save the mappings, then build and deploy the runtime. Data starts moving once the runtime is running.

To confirm it, use the device’s own Data Hub Browser, below.

The device has its own u-OS Data Hub Browser, reached from the u-OS home page or directly at https://<DEVICE IP>/u-os-hub/. It lists every variable on the hub and shows each one’s current value, so it is the quickest way to confirm that a provider is publishing or that a consumer has something to read.

Select a variable in the tree and the right-hand pane shows it in full.

The street variable in the u-OS Data Hub Browser, showing its provider, key, access, value and quality

Every field there corresponds to something in this page:

In the Data Hub BrowserIn logiccloud
ProviderThe hub provider — named after your connection’s Client name
KeyThe mapping Address — the bare dotted key
Access (Read-Only / Read-Write)What the device reports, and therefore whether To hub is offered in Mode
Data typeThe mapping Type
Current valueWhat your provider published, or what a consumer reads
QualityWhat a Quality Variable receives
Latest changeWhat a Timestamp Variable receives

So if a mapping is not behaving as expected, this view answers three questions at once: whether the variable exists at all, whether the device considers it writable, and whether its value is actually changing.

Cause: The Client Name doesn’t match exactly what’s in u-OS Control Center.

Solution:

  1. Open u-OS Control Center → Identity & access → Clients
  2. Copy the exact client name (case-sensitive)
  3. Update the connection in logiccloud

”providerId is not a valid hub provider name”

Section titled “”providerId is not a valid hub provider name””

Cause: The Provider ID contains invalid characters.

Solution: Use only lowercase letters, digits, and underscores. Must start with a letter.

Possible causes:

  • Provider not registered (check edge device logs)
  • Address doesn’t match the VariableName grammar
  • OAuth2 token expired or invalid

Solution:

  1. Check the edge device logs for registration errors
  2. Verify the address uses only valid characters (letters, digits, underscores, dots)
  3. Verify OAuth2 credentials are correct

Cause: Mappings weren’t saved correctly.

Solution: Re-open the provider/consumer, verify mappings are listed, and save again.

Cause: The selected node has no mapping address. Folders are the usual case — they group variables but are not variables themselves.

Solution: Expand the folder and select the values inside it. If a value is skipped as well, the device reported no address for it; check the edge device logs.

Cause: The hub reported that variable as read-only, so only From hub is offered. Writing to it could not succeed.

Solution: If the variable should be writable, correct its access type in u-OS, then browse again so the IDE picks up the new access level.