Documentation

This is machine translation

Translated by Microsoft
Mouse over text to see original. Click the button below to return to the English verison of the page.

Active

Group or item activation state

Description

Active can be 'on' or 'off'. If Active is 'on', the OPC server will return data for the group or item when requested by the read function or when the corresponding data items change (subscriptions). If Active is 'off', the OPC server will not return information about the group or item.

By default, Active is set to 'on' when you create a dagroup or daitem object. Set Active to 'off' when you are temporarily not interested in that daitem or dagroup object's values. You configure Active for both dagroup and daitem objects. Changing the state of the group does not change the state of the items.

The activation state of a dagroup or daitem object affects reads and subscriptions, and depends on whether the data is obtained from the cache or from the device. The active state of a group or item affects operations as follows.

Operation

Source

Active State

read

Cache

Both group and items must be active. Inactive items in active groups, and all items in inactive groups, return bad quality.

read

Device

Active is ignored.

write

N/A

Active is ignored.

Subscription

N/A

Both group and items must be active. Inactive items in active groups, and all items in inactive groups, return bad quality.

readasync

N/A

Active is ignored.

A transition from 'off' to 'on' results in a change in quality, and causes a subscription callback for the item or items affected. Changing the Active state from 'on' to 'off' will cause a change in quality but will not cause a callback since by definition callbacks do not occur for inactive items.

You enable subscription callbacks with the Subscription property. Use the DataChangeFcn property to specify a callback function file to execute when a data change event occurs.

Characteristics

Access

Read/write

Applies to

dagroup, daitem

Data type

character vector

Values

[ 'off' | {'on'} ]

See Also

Functions

read, readasync, refresh

Properties

DataChangeFcn, Subscription

Was this topic helpful?