The PublishingInterval, the SamplingOffsetthe PublishingOffsetand the timestamp in the NetworkMessageheader shall use the same time base.

If an underlying network provides a synchronized global clock, this clock shall be used as the time base for the Publisherand Subscriber.

The beginning of a PublishingIntervalshall be a multiple of the PublishingIntervalrelative to the start of the time base. The reference start time of the PublishingIntervalcan be calculated by using the following formula:

Start of periodic execution =

current time + PublishingInterval – (current time / PublishingInterval)

Current time is the number of nanoseconds since the start of epoch used by the reference clock.

PublishingIntervalis the duration in nanoseconds.

Start of periodic executionis the number of nanoseconds since the start of epoch which is the next possible start of a PublishingInterval.

Figure 25shows an example how to select the possible start of a PublishingInterval.

image028.png

Figure 25– Start of the periodic publisher execution

The different timing offsets inside a PublishingIntervalcycle on Publisherand Subscriberside are shown in Figure 26. The SamplingOffsetand PublishingOffsetare defined as parameters of the UADP WriterGroup. The ReceiveOffsetand the ProcessingOffsetare defined as parameters of the UADP DataSetReaderin 6.3.1.4.

image029.png

Figure 26– Timing offsets in a PublishingInterval

The GroupVersionwith DataType VersionTimereflects the time of the last layout change of the content of the NetworkMessagespublished by the WriterGroup. The VersionTime DataTypeis defined in OPC 10000-4. The GroupVersionchanges when one of the following parameters is modified:

The GroupVersionis valid for all NetworkMessagesresulting from this WriterGroup.

The DataSetOrderingdefines the ordering of the DataSetMessagesin the NetworkMessages. Possible values for DataSetOrderingare described in Table 80. The default value is Undefined.

The DataSetOrderingTypeis an enumeration that specifies the possible options for the ordering of DataSetMessagesinside and across NetworkMessages. The possible enumeration values are described in Table 80.

Table 80– DataSetOrderingType values

Name

Value

Description

Undefined

0

The ordering of DataSetMessagesis not specified.

AscendingWriterId

1

DataSetMessagesare ordered ascending by the value of their corresponding DataSetWriterIds.

AscendingWriterIdSingle

2

DataSetMessagesare ordered ascending by the value of their corresponding DataSetWriterIdsand only one DataSetMessageis sent per NetworkMessage.

If DataSetOrderingis Undefinedany ordering between DataSets and their distribution into NetworkMessagesis allowed. Ordering and distribution even may change between each PublishingInterval. If DataSetOrderingis set to AscendingWriterId,the Publishershall fill up each NetworkMessagewith DataSetswith an ascending order of the related DataSetWriterIdsas long as the accumulated DataSetsizes will not exceed the MaxNetworkMessageSize. The different options are shown in Figure 27.

image030.png

Figure 27– DataSetOrdering and MaxNetworkMessageSize

The DataSetOrderingTyperepresentation in the AddressSpaceis defined in Table 81.

Table 81– DataSetOrderingType definition

Attribute

Value

BrowseName

DataSetOrderingType

IsAbstract

False

References

Node Class

BrowseName

DataType

TypeDefinition

Others

Subtype of Enumeration defined in OPC 10000-5

HasProperty

Variable

EnumStrings

LocalizedText []

PropertyType

Conformance Units

PubSub Parameters UADP

The parameter NetworkMessageContentMaskdefines the optional header fields to be included in the NetworkMessagesproduced by the WriterGroup. The DataTypefor the UADP NetworkMessagemapping is UadpNetworkMessageContentMask.

The DataType UadpNetworkMessageContentMaskis formally defined in Table 82.

Table 82– UadpNetworkMessageContentMask values

Value

Bit No.

Description

PublisherId

0

The PublisherIdis included in the NetworkMessages.

GroupHeader

1

The GroupHeader is included in the NetworkMessages.

WriterGroupId

2

The WriterGroupIdfield is included in the GroupHeader.

The flag is only valid if Bit 1 is set.

GroupVersion

3

The GroupVersionfield is included in the GroupHeader.

The flag is only valid if Bit 1 is set.

NetworkMessageNumber

4

The NetworkMessageNumberfield is included in the GroupHeader.

The field is required if more than one NetworkMessage is needed to transfer all DataSets of the group.

The flag is only valid if Bit 1 is set.

SequenceNumber

5

The SequenceNumberfield is included in the GroupHeader.

The flag is only valid if Bit 1 is set.

PayloadHeader

6

The PayloadHeaderis included in the NetworkMessages.

Timestamp

7

The sender timestamp is included in the NetworkMessages.

PicoSeconds

8

The sender PicoSecondsportion of the timestamp is included in the NetworkMessages. This flag is ignored if the Timestampflag is not set.

DataSetClassId

9

The DataSetClassIdis included in the NetworkMessages.

The NetworkMessagecan only contain DataSetMessageswith the same DataSetClassId. If DataSetMessageshave different DataSetClassIdsthey must be sent in individual NetworkMessages.

PromotedFields

10

The PromotedFieldsare included in the NetworkMessages.

The UadpNetworkMessageContentMaskrepresentation in the AddressSpaceis defined in Table 83.

Table 83– UadpNetworkMessageContentMask definition

Attribute

Value

BrowseName

UadpNetworkMessageContentMask

IsAbstract

False

References

Node Class

BrowseName

DataType

TypeDefinition

Others

Subtype of UInt32 defined in OPC 10000-5

HasProperty

Variable

OptionSetValues

LocalizedText []

PropertyType

Conformance Units

PubSub Parameters UADP

The SamplingOffsetwith the DataType Durationdefines the time in milliseconds for the offset of creating the NetworkMessagein the PublishingIntervalcycle.

Any negative value indicates that the optional parameter is not configured. In this case the Publishershall calculate the time before the PublishingOffsetthat is necessary to create the NetworkMessagein time for sending at the PublishingOffset.

The Duration DataTypeis a subtype of Doubleand allows configuration of intervals smaller than a millisecond.

The PublishingOffsetis an array of DataType Durationthat defines the time in milliseconds for the offset in the PublishingIntervalcycle of sending the NetworkMessageto the network.

Any negative value indicates that the PublishingOffsetis not configured and the timing inside the PublishingIntervalis application specific.

The Duration DataTypeis a subtype of Doubleand allows configuration of intervals smaller than a millisecond.

Figure 28depicts how the different variations of PublishingOffsetsettings affect sending of multiple NetworkMessages.

image031.png

Figure 28– PublishingOffset options for multiple NetworkMessages

If all DataSetsof a group are transferred with a single NetworkMessage, the scalar value or the first value in the array defines the offset for sending the NetworkMessagerelative to the start of the PublishingIntervalcycle. If the DataSetsof a group are sent in a series of NetworkMessages, the values in the array define the offsets of sending the NetworkMessagesrelative to the start of the PublishingIntervalcycle. If a scalar value is configured, the first NetworkMessageis sent at the offset and the following NetworkMessages are sent immediately after each other. If more NetworkMessages are available for sending than offset values in the array, the offset for the remaining NetworkMessages is extrapolated from the last two offset values in the array.

The PublishingInterval, the SamplingOffsetthe PublishingOffsetand the timestamp in the NetworkMessageheader shall use the same time base.

This Structure DataTypeis used to represent the UADP NetworkMessagemapping specific WriterGroup parameters. It is a subtype of WriterGroupMessageDataTypedefined in 6.2.6.7.3.

The UadpWriterGroupMessageDataTypeis formally defined in Table 84.

Table 84– UadpWriterGroupMessageDataType structure

Name

Type

Description

UadpWriterGroupMessageDataType

Structure

Subtype of WriterGroupMessageDataTypedefined in 6.2.6.7.3

GroupVersion

VersionTime

Defined in 6.3.1.1.2.

DataSetOrdering

DataSetOrderingType

Defined in 6.3.1.1.3.

NetworkMessageContentMask

UadpNetworkMessageContentMask

Defined in 6.3.1.1.4.

SamplingOffset

Duration

Defined in 6.3.1.1.5.

PublishingOffset

Duration[]

Defined in 6.3.1.1.6.

Its representation in the AddressSpace is defined in Table 85.

Table 85– UadpWriterGroupMessageDataType definition

Attributes

Value

BrowseName

UadpWriterGroupMessageDataType

IsAbstract

False

Subtype of WriterGroupMessageDataTypedefined in 6.2.6.7.3.

Conformance Units

PubSub Parameters UADP

There are no UADP specific message mapping parameters defined for the ReaderGroup.

The configuration of the DataSetWritersin a WriterGroupcan result in a fixed NetworkMessagelayout where all DataSetshave a static position between NetworkMessages.

In this case the parametersNetworkMessageNumberand DataSetOffsetprovide information about the static position of the DataSetMessagein a NetworkMessage Subscriberscan rely on. If the value of one of the two parameters is 0, the position is not guaranteed to be static.

NOTE A Publishercan only provide valid values for the parameters NetworkMessageNumberand DataSetOffsetif the message mapping allows keeping the value for these Propertiesconstant unless the configuration of the WriterGroupis changed.

The DataSetMessageContentMaskdefines the flags for the content of the DataSetMessageheader. The UADP message mapping specific flags are defined by the UadpDataSetMessageContentMask DataType.

The UadpDataSetMessageContentMask DataTypeis formally defined in Table 86.

Table 86– UadpDataSetMessageContentMask Values

Value

Bit No.

Description

Timestamp

0

If this flag is set, a timestamp shall be included in the DataSetMessageheader.

PicoSeconds

1

If this flag is set, a PicoSecondstimestamp field shall be included in the DataSetMessageheader. This flag is ignored if the Timestampflag is not set.

Status

2

If this flag is set, the DataSetMessagestatus is included in the DataSetMessageheader. The rules for creating the DataSetMessagestatus are defined in Table 26.

MajorVersion

3

If this flag is set, the ConfigurationVersion.MajorVersionis included in the DataSetMessageheader.

MinorVersion

4

If this flag is set, the ConfigurationVersion.MinorVersionis included in the DataSetMessageheader.

SequenceNumber

5

If this flag is set, the DataSetMessageSequenceNumber is included in the DataSetMessage header.

The UadpDataSetMessageContentMaskrepresentation in the AddressSpaceis defined in Table 87.

Table 87– UadpDataSetMessageContentMask definition

Attribute

Value

BrowseName

UadpDataSetMessageContentMask

IsAbstract

False

References

Node Class

BrowseName

DataType

TypeDefinition

Others

Subtype of UInt32 defined in OPC 10000-5

HasProperty

Variable

OptionSetValues

LocalizedText []

PropertyType

Conformance Units

PubSub Parameters UADP

The parameter ConfiguredSizewith the DataType UInt16defines the fixed size in bytes a DataSetMessageuses inside a NetworkMessage. The default value is 0 and it indicates a dynamic length. If a DataSetMessagewould be smaller in size (e.g. because of the current values that are encoded) the DataSetMessageis padded with bytes with value zero. In case it would be larger, the Publishershall set bit 0 of the DataSetFlags1to false to indicate that the DataSetMessageis not valid.

NOTE The parameter ConfiguredSizecan be used for different reasons. One reason is the reservation of space inside a NetworkMessageby setting ConfiguredSizeto a higher value than the assigned DataSetactually requires. Modifications (e.g. extensions) of the DataSetwould then not change the required bandwidth on the network which reduces the risk of side effects. Another reason would be to maintain predictable network behaviour even when using a volatile field DataTypeslike Stringor ByteString.

The parameter NetworkMessageNumberwith the DataType UInt16is the number of the NetworkMessageinside a PublishingIntervalin which this DataSetMessageis published. The default value is 0 and indicates that the number of the NetworkMessageis not fixed.

The NetworkMessageshall have a fixed layout if the PayloadHeaderflag in the NetworkMessageContentMaskis false.

If the NetworkMessagelayout is fixed and all DataSetMessagesof a WriterGroupfit into one single NetworkMessage, the value of NetworkMessageNumbershall be 1. If the DataSetMessagesof a WriterGroupare distributed or chunked over more than one NetworkMessage, the first NetworkMessagein a PublishingIntervalshall be generated with the value 1, the following NetworkMessagesshall be generated with incrementing NetworkMessageNumbers. To avoid a roll-over the number of NetworkMessagesgenerated from one WriterGroupwithin one PublishingIntervalis limited to 65535.

The parameter DataSetOffsetwith the DataType UInt16is the offset in bytes inside a NetworkMessageat which the DataSetMessageis located, relative to the beginning of the NetworkMessage.

The default value 0 indicates that the position of the DataSetMessagein a NetworkMessageis not fixed. If the DataSetWriteris disabled and the DataSetOffsetis not 0, the valid flag of the DataSetFlags1in the DataSetMessageheader at the offset shall be false.

This parameter should be set if the PayloadHeaderflag in the NetworkMessageContentMaskis false and therefore the NetworkMessagehas a fixed layout.

This Structure DataTypeis used to represent UADP DataSetMessage mapping specific DataSetWriterparameters. It is a subtype of the DataSetWriterMessageDataTypedefined in 6.2.4.5.3.

The UadpDataSetWriterMessageDataTypeis formally defined in Table 88.

Table 88– UadpDataSetWriterMessageDataType structure

Name

Type

Description

UadpDataSetWriterMessageDataType

Structure

Subtype of DataSetWriterMessageDataTypedefined in 6.2.4.5.3

DataSetMessageContentMask

UadpDataSetMessageContentMask

Defined in 6.3.1.3.2.

ConfiguredSize

UInt16

Defined in 6.3.1.3.3.

NetworkMessageNumber

UInt16

Defined in 6.3.1.3.4.

DataSetOffset

UInt16

Defined in 6.3.1.3.5.

Its representation in the AddressSpace is defined in Table 89.

Table 89– UadpDataSetWriterMessageDataType definition

Attributes

Value

BrowseName

UadpDataSetWriterMessageDataType

IsAbstract

False

Subtype of DataSetWriterMessageDataTypedefined in 6.2.4.5.3.

Conformance Units

PubSub Parameters UADP

The parameterGroupVersion with DataType VersionTime defines the expected value in the field GroupVersion in the header of the NetworkMessage. The default value 0 is defined as null value, and means this parameter shall be ignored.

The parameterNetworkMessageNumber with DataType UInt16 is the number of the NetworkMessageinside a PublishingIntervalin which this DataSetMessageis published. The default value 0 is defined as null value, and means this parameter shall be ignored.

The NetworkMessageshall have a fixed layout if the PayloadHeaderflag in the NetworkMessageContentMaskis false.

The parameterDataSetOffset with DataType UInt16 defines the offset in bytes for the DataSetMessageinside the corresponding NetworkMessagerelative to the beginning of the NetworkMessage. The default value 0 is defined as null value, and means that the position of the DataSetMessagein a NetworkMessageis not fixed.

This parameter should be set if the PayloadHeaderflag in the NetworkMessageContentMaskis false and therefore the NetworkMessagehas a fixed layout.

The parameterDataSetClassIdwith DataType Guid defines a DataSetclass related filter. If the value is null, the DataSetClassIdfilter is not applied.

The NetworkMessageContentMaskwith DataType UadpNetworkMessageContentMaskindicates the optional header fields included in the received NetworkMessages.

The UadpNetworkMessageContentMask DataTypeis defined in 6.3.1.1.4.

The DataSetMessageContentMaskwith the DataType UadpDataSetMessageContentMaskindicates the optional header fields included in the DataSetMessages.

The UadpDataSetMessageContentMaskDataType is defined in 6.3.1.3.2.

The PublishingIntervalwith DataType Duration indicates the rate the Publishersends NetworkMessagesrelated to the DataSet. The start time for the periodic execution of the Subscribershall be calculated according to 6.3.1.1.1.

The ReceiveOffset with DataType Duration defines the time in milliseconds for the offset in the PublishingIntervalcycle for the expected receive time of the NetworkMessagefor the DataSetfrom the network.

Any negative value indicates that the ReceiveOffset is not configured and the timing inside the PublishingIntervalis not defined.

The ProcessingOffsetwith DataType Duration defines the time in milliseconds for the offset in the PublishingIntervalcycle when the received DataSet need to be processed by the application in the Subscriber.

The different timing offsets inside a PublishingIntervalcycle on the Publisherand Subscribersides are shown in Figure 26.

Any negative value indicates that the ProcessingOffsetis not configured and the timing inside the PublishingIntervalis application specific.

This Structure DataTypeis used to represent UADP message mapping specific DataSetReaderparameters. It is a subtype of the DataSetReaderMessageDataTypedefined in 6.2.9.13.3.

The UadpDataSetReaderMessageDataTypeis formally defined in Table 90.

Table 90– UadpDataSetReaderMessageDataType structure

Name

Type

Description

UadpDataSetReaderMessageDataType

Structure

Subtype of DataSetReaderMessageDataTypedefined in 6.2.9.13.3.

GroupVersion

VersionTime

Defined in 6.3.1.4.1.

NetworkMessageNumber

UInt16

Defined in 6.3.1.4.2.

DataSetOffset

UInt16

Defined in 6.3.1.4.3.

DataSetClassId

Guid

Defined in 6.3.1.4.4.

Network‌Message‌ContentMask

UadpNetworkMessageContentMask

Defined in 6.3.1.4.5.

DataSetMessage‌ContentMask

UadpDataSetMessageContentMask

Defined in 6.3.1.4.6.

PublishingInterval

Duration

Defined in 6.3.1.4.7.

ReceiveOffset

Duration

Defined in 6.3.1.4.8.

ProcessingOffset

Duration

Defined in 6.3.1.4.9.

Its representation in the AddressSpace is defined in Table 91.

Table 91– UadpDataSetReaderMessageDataType definition

Attributes

Value

BrowseName

UadpDataSetReaderMessageDataType

IsAbstract

False

Subtype of DataSetReaderMessageDataTypedefined in 6.2.9.13.3.

Conformance Units

PubSub Parameters UADP