Annex C (normative) OPC Binary Type Description System ToC Previous Next

C.4 Type Description examples ToC Previous Next

  1. A 128-bit signed integer. ```
A 128-bit signed integer.

2. A 16-bit value divided into several fields.
An OPC COM-DA quality value.

When using bit fields, the least significant bits within a byte shall appear first.

1. A structured type with optional fields.
A value with an associated timestamp, and quality.

It is necessary to explicitly specify any padding bits required to ensure subsequent fields line up on byte boundaries.

1. An array of integers.
An array of integers prefixed by its length.

Nothing is encoded for the Array field if the Size field has a value ≤ 0.

1. An array of integers with a terminator instead of a length prefix.
An array of integers terminated with a known value.

The terminator is 32,767 converted to hexadecimal with LittleEndian byte order.

1. A simple union.
A union of several types.

The *ArrayLength* field is optional. If it is not present in an encoded value, then the length of all fields with *LengthField* set to "ArrayLength" have a length of 1.

It is valid for the *VariantType* field to have a value that has no matching field defined. This simply means all optional fields are not present in the encoded value.

1. An enumerated type.
The possible colours for a traffic signal. Red says stop immediately. Yellow says prepare to stop. Green says you may proceed.

The documentation element is used to provide human readable description of the type and values.

1. A nillable array.
An array where a length of -1 means null. </opc:StructuredType> ``` If the length of the array is −1 then the array does not appear in the stream. ![Previous](/assets/images/prev.png "Previous") ![Next](/assets/images/next.png "Next")