Please ensure Javascript is enabled for purposes of website accessibility
Powered by Zoomin Software. For more details please contactZoomin

PI Interface for OPC DA

Scan class settings and update rates

  • Last UpdatedMay 21, 2025
  • 3 minute read

Scan classes specify how often a data source is checked for new data. The f parameter in the .bat file defines one or more scan classes.

Syntax: /f=scan-interval

Specify scan interval and optional offset using the following format: time value,time offset,L

Scan class time and offset time values use the following format: HH:MM:SS.##, where:

  • HH is hours

  • MM is minutes

  • SS is seconds

  • ## is hundredths of seconds (01 to 99)

If you omit HH and MM, the scan period is assumed to be in seconds. For example, /f=00:01:00,00:00:05 is equivalent to /f=60,5.

The L value associates the time unit value with the local computer time-of-day settings. Time-of-day scans use a 24-hour clock and are automatically adjusted for daylight saving time. This is also known as wall clock scheduling. The following example uses a scan frequency of 24 hours (once a day), an offset of eight hours from midnight (8 AM), and enables time-of-day scanning by specifying the L value: /f=24:00:00,08:00:00,L

The scan class frequency determines how often to scan for data. The offset specifies how long after the frequency's time value to scan for data. To balance the scanning workload, specify an offset for scan classes that have the same interval so that they are not scanned simultaneously.

For each scan class that you want to define, specify the f parameter. Scan classes are numbered by the order in which you define them. Scan class 1 is the first defined f parameter, and scan class 2 is the second f parameter you define.

Examples:

  • Scan class 1 has a scanning frequency of one minute with an offset of five seconds, and scan class 2 has a scanning frequency of seven seconds with no offset:

    /f=00:01:00,00:00:05 /f=00:00:07

  • Two scan classes, defined using only seconds:

    /f=60,5 /f=7

  • Sub-second scan classes defined as decimal values:

    /f=0.5 /f=00:00:00.1

Note: Deleting scan classes or changing their order can adversely affect the operation of existing PI points, which are closely related to scan rates. Scan classes should be adjusted only by PI System administrators who are fully aware of the PI System configuration and the effects of any such changes.

For more information about scan classes, see the PI Interface Configuration Utility (PI ICU) User Guide.

Scanning offsets

To mitigate the interface and OPC server workload, you can use the offset to stagger scanning. If an offset is specified, scan time is calculated from midnight on the day that the interface was started, applying any offset specified. In the first scan class in the above example, if the interface was started at 05:06:06, the first scan occurs at 05:07:05, the second scan at 05:08:05, and so on. If offset is omitted, scanning is performed at the specified interval, regardless of clock time.

Offsets determine when the interface asks the OPC server for the current values for polled classes. They do not control the behavior of the OPC server, and have no effect on advise classes unless the ga parameter is specified to stagger the activation of groups. In this case, the offsets are used to time the activation of all groups except for scan class 1, which is reserved for advise tags.

Update rates

The OPC server reads data from the device according to the update rate for the group in which the item resides. By default, the update rate is the same as the scan rate.

To override the default using PI ICU, browse to the OPCInt > OPC Server > Advanced Options page and enter your update rate value for the ur parameter in the Update Rates area.

For polled groups, configuring an update rate that is shorter than the scan period ensures that the interface is receiving current data. For example, if the scan period is five seconds but the update rate is two seconds, the data is no more than two seconds old when it is read. However, note that a faster update rate increases the OPC server workload.

For advise groups, assign identical update and scan rates, except in cases where phase 1 UniInt failover is configured for the interface. In this case, to ensure that the interface sees new values for failover heartbeat tags as soon as possible, set the update rate to half the scan period. This configuration reduces the risk of control needlessly switching back and forth. Dedicate a scan class with faster update rate to the failover heartbeat points.

Note: AVEVA recommends using phase 2 UniInt failover. For more information about converting from phase 1 to phase 2 UniInt failover, see the PI Universal Interface (UniInt) User Guide.

In This Topic
TitleResults for “How to create a CRG?”Also Available in