Sunteți pe pagina 1din 139

PI Interface for Foxboro I/A 70

Series

Version 2.4.2.x

iii
OSIsoft, LLC
1600 Alvarado Street
San Leandro, CA 94577 USA
Tel: (01) 510-297-5800
Fax: (01) 510-357-8136
Web: http://www.osisoft.com

OSIsoft Australia • Perth, Australia


OSIsoft Europe GmbH • Frankfurt, Germany
OSIsoft Asia Pte Ltd. • Singapore
OSIsoft Canada ULC • Montreal & Calgary, Canada
OSIsoft, LLC Representative Office • Shanghai, People’s Republic of China
OSIsoft Japan KK • Tokyo, Japan
OSIsoft Mexico S. De R.L. De C.V. • Mexico City, Mexico
OSIsoft do Brasil Sistemas Ltda. • Sao Paulo, Brazil
OSIsoft France EURL • Paris, France

PI Interface for Foxboro I/A 70 Series


Copyright: © 1997-2016 OSIsoft, LLC. All rights reserved.
No part of this publication may be reproduced, stored in a retrieval system, or transmitted, in any form or by any means,
mechanical, photocopying, recording, or otherwise, without the prior written permission of OSIsoft, LLC.

OSIsoft, the OSIsoft logo and logotype, Managed PI, OSIsoft Advanced Services, OSIsoft Cloud Services, OSIsoft Connected
Services, PI ACE, PI Advanced Computing Engine, PI AF SDK, PI API, PI Asset Framework, PI Audit Viewer, PI Builder, PI Cloud
Connect, PI Connectors, PI Coresight, PI Data Archive, PI DataLink, PI DataLink Server, PI Developer's Club, PI Integrator for
Business Analytics, PI Interfaces, PI JDBC driver, PI Manual Logger, PI Notifications, PI ODBC, PI OLEDB Enterprise, PI OLEDB
Provider, PI OPC HDA Server, PI ProcessBook, PI SDK, PI Server, PI Square, PI System, PI System Access, PI Visualization
Suite, PI Web API, PI WebParts, PI Web Services, RLINK and RtReports are all trademarks of OSIsoft, LLC.

All other trademarks or trade names used herein are the property of their respective owners.

U.S. GOVERNMENT RIGHTS


Use, duplication or disclosure by the U.S. Government is subject to restrictions set forth in the OSIsoft, LLC license agreement and
as provided in DFARS 227.7202, DFARS 252.227-7013, FAR 12.212, FAR 52.227, as applicable. OSIsoft, LLC.
Published: 11/2016
Table of Contents
Chapter 1. Introduction ................................................................................................ 1
Reference Manuals ............................................................................................. 2
Supported Operating Systems ............................................................................ 3
Supported Features............................................................................................. 3
Diagram of Hardware Connection ....................................................................... 8

Chapter 2. Principles of Operation .............................................................................. 9


FoxAPI and AIM*API ........................................................................................... 9
Overview ............................................................................................................. 9
Buffered Access .................................................................................................. 9
Unbuffered Access ............................................................................................10
Object Status .....................................................................................................10
Outputs ..............................................................................................................10

Chapter 3. Installation Checklist................................................................................ 13


Data Collection Steps ........................................................................................13
Interface Diagnostics .........................................................................................15
Advanced Interface Features ............................................................................15

Chapter 4. Interface Installation................................................................................. 17


Naming Conventions and Requirements ..........................................................17
Interface Directories ..........................................................................................18
PIHOME Directory Tree ..........................................................................18
Interface Installation Directory ................................................................18
FoxAPI / AIM*API Installation ............................................................................19
FoxAPI / AIM*API Configuration .......................................................................19
Interface Installation Procedure ........................................................................20
PI Trust for Interface Authentication..................................................................21
Installing Interface as a Windows Service.........................................................22
Installing Interface Service with PI Interface Configuration Utility .....................22
Service Configuration .............................................................................22
Clearing and Resetting the FoxAPI / AIM*API Lists ..........................................25
Changing from FoxAPI to AIM*API ...................................................................26
Uninstall ..................................................................................................26
Change / Modify ......................................................................................26
Installing Interface Service Manually.................................................................26
Installing the Interface on Secure I/A Systems .................................................28

Chapter 5. FoxAPI/AIM*API Test Program ................................................................ 29

Chapter 6. Digital States............................................................................................. 33

Chapter 7. PointSource .............................................................................................. 35


PI Interface for Foxboro I/A 70 Series iii
Table of Contents

Chapter 8. PI Point Configuration .............................................................................. 37


Point Attributes ..................................................................................................37
Tag ..........................................................................................................37
PointSource ............................................................................................38
PointType ................................................................................................38
Location1 ................................................................................................38
Location2 ................................................................................................38
Location3 ................................................................................................39
Location4 ................................................................................................40
Location5 ................................................................................................40
InstrumentTag .........................................................................................41
ExcDev / ExcDevPercent ........................................................................41
ExDesc ....................................................................................................41
UserInt1 ..................................................................................................45
Scan ........................................................................................................46
Shutdown ................................................................................................46
DataSecurity ...........................................................................................47
PtSecurity................................................................................................47
Output Points .....................................................................................................47
Trigger Method 1 (Recommended).........................................................48
Trigger Method 2.....................................................................................48
Output Point Whitelist .............................................................................48
Point Configuration Examples ...........................................................................49

Chapter 9. Startup Command File ............................................................................. 51


Configuring the Interface with PI ICU ................................................................51
fxbais Interface Page ..............................................................................53
Command-line Parameters ...............................................................................58
Sample fxbais.bat File .......................................................................................64
fxbais.ini Configuration File ...............................................................................65

Chapter 10. Interface Failover Configuration.......................................................... 69


Introduction ........................................................................................................69
Parameters for Operation ..................................................................................71
Design Details ...................................................................................................73
Operational Scenarios .......................................................................................77
Failover Installation Checklist ............................................................................79
Miscellaneous Information on Failover ..............................................................80

Chapter 11. Interface Node Clock ............................................................................ 83

Chapter 12. Security ................................................................................................. 85


Windows ............................................................................................................85
Authentication ....................................................................................................85
Authorization .....................................................................................................86

Chapter 13. Starting / Stopping the Interface ......................................................... 89


Starting Interface as a Service ..........................................................................89
Stopping Interface Running as a Service ..........................................................89

Chapter 14. Buffering for PI Interfaces .................................................................... 91


iv
Buffering services ..............................................................................................91
Buffering and collectives ...................................................................................91
Buffering configuration ......................................................................................91

Chapter 15. Interface Diagnostics Configuration ................................................... 93


Scan Class Performance Points .......................................................................93
Performance Counter Points .............................................................................96
Performance Counters ............................................................................98
Performance Counters for both (_Total) and (Scan Class x) .................98
Performance Counters for (_Total) only .................................................99
Performance Counters for (Scan Class x) only ....................................102
Interface Health Monitoring Points ..................................................................103
I/O Rate Point ..................................................................................................108

Appendix A. Error and Informational Messages................................................... 111


Message Logs .................................................................................................111
Extra Debugging Messages ............................................................................111
Interface-level .......................................................................................111
Point-level .............................................................................................112
List Event Counters and Location5 .......................................................113
System Errors and PI Errors ...........................................................................114

Appendix B. PI SDK Options.................................................................................. 115

Appendix C. Common Problems ........................................................................... 117


Operational Hints .............................................................................................119
FoxAPI/AIM*API Configuration Settings (foxapi.cfg/aimapi.cfg) .....................120

Appendix D. FoxAPI/AIM*API Status Definition .................................................... 123


Status Definition for I/A Series Version 4.1 and Earlier ..................................123
Status Definition for I/A Series Version 4.2 and Later .....................................124
Storing Status Values in PI .............................................................................125

Appendix E. Terminology....................................................................................... 126

Appendix F. Technical Support and Resources ................................................... 129

Appendix G. Revision History................................................................................ 131

PI Interface for Foxboro I/A 70 Series v


Chapter 1. Introduction

The “PI Interface for Foxboro I/A 51 Series” and the “PI Interface for Foxboro I/A 70 Series”
(fxbais) provide for the bi-directional transfer of data between OSIsoft’s PI Data Archive and
Foxboro’s I/A Series system. Foxboro’s I/A Series systems run on either Solaris (51 Series
I/A 6.x or later) or Windows (70 Series I/A 8.2 or later) computers.
This manual only includes instructions for the Windows based “PI Interface for Foxboro I/A
70 Series”. Details on the installation of the Solaris build of the fxbais interface can be found
in the manual that ships with the Solaris interface.
The interface uses either the FoxAPI or the AIM*API to communicate with the I/A system.
The interface must run directly on a Foxboro I/A AP or AW machine, where either the
FoxAPI or the AIM*API software installed. It is compatible with “Secure” I/A systems as
well as standard I/A. The fxbais interface does not support networked access to the FoxAPI
or AIM*API (The FoxAPI/AIM*API running on a machine that is NOT part of the I/A
system configuration).
As of I/A 8.8, the FoxAPI is no longer available and is replaced by the AIM*API. These
APIs have the same functionality and are source code compatible, but require different
executables. The interface setup kit for Windows includes executables for both FoxAPI and
AIM*API, and the required executables are selected during the installation. The configuration
of the interface and the PI points are the same for both the FoxAPI and AIM*API.
For Foxboro I/A systems prior to I/A 8.2, the older release of the fxbais interface 2.3.8.66
using the FoxAPI is required. For more details, refer to the Vendor Software Required section
below.

Note: The value of [PIHOME] variable for the 32-bit interface will depend on whether the
interface is being installed on a 32-bit operating system (C:\Program Files\PIPC) or
a 64-bit operating system (C:\Program Files (x86)\PIPC).
The value of [PIHOME64] variable for a 64-bit interface will be C:\Program Files\PIPC on
the 64-bit operating system.
In this documentation [PIHOME] will be used to represent the value for either [PIHOME]
or [PIHOME64]. The value of [PIHOME] is the directory which is the common location for
PI client applications.

Note: This interface has been built against a UniInt version (4.5.0.59 and later)
which now writes all its messages to the local PI Message log.

PI Interface for Foxboro I/A 70 Series 1


Introduction

Please see the document UniInt Interface Message Logging for UniInt 4.5.0.x and
later Interfaces in the %PIHOME%\Interfaces\UniInt directory for more details
on how to access these messages.

Note: OSIsoft is revising product documentation and other literature to reflect the
evolution of the PI Server from a single server to a multi-server architecture.
Specifically, the original historian core of the PI Server is now referred to as the
PI Data Archive.

Originally, the PI Server was a single server that contained the PI Data Archive and other
subsystems. To add features and improve scalability, the PI Server has evolved from a single
server to multiple servers. While the PI Data Archive remains a core server of the PI Server
product, the product name “PI Server” now refers to much more than the PI Data Archive.
OSIsoft documentation, including this user manual, is changing to use “PI Server” in this
broader sense and “PI Data Archive” to refer to the historian core.

Reference Manuals
OSIsoft
 PI Data Archive manuals
 PI API Installation Instructions manual
(%PIHOME%\bin\API_install.doc)
 PI Universal Interface (UniInt) User Guide
(%PIHOME%\Interfaces\UniInt\UniInt Interface User Manual.pdf)
 UniInt Interface Message Logging for UniInt 4.5.0.x and later Interfaces
(%PIHOME%\Interfaces\UniInt\UniInt Interface Message Logging.pdf)
 PI Interface Configuration Utility User Guide
(%PIHOME%\ICU\PI Interface Configuration Utility.pdf)

Foxboro
 Foxboro I/A Series documentation
 I/A Series FoxAPI Installation Guide (B0193UC)
 I/A Series FoxAPI User’s Guide (B0193UD)
 AIM*AT Installation Guide(B0193YM)
 I/A Series AIM*API User’s Guide (B0193YN)

2
Supported Operating Systems
Platforms 32-bit application 64-bit application
32-bit OS No No
Windows Vista
64-bit OS No (Emulation Mode) No
Windows 2008 32-bit OS No No
Windows 2008 R2 64-bit OS Yes (Emulation Mode) No
32-bit OS Yes No
Windows 7
64-bit OS Yes (Emulation Mode) No
Windows 8 and 8.1 32-bit OS Yes No
64-bit OS Yes (Emulation Mode) No
Windows 2012 Server 64-bit OS Yes (Emulation Mode) No

The interface is designed to run on the above-mentioned Microsoft Windows operating


systems. Because it is dependent on vendor software, newer platforms may not yet be
supported.
Please contact OSIsoft Technical Support for more information.

Security Note: We recommend installing all available updates from Windows Update
service. We recommend the newest versions of Windows for latest security features.

Supported Features
Feature Support
Interface Part Number PI-IN-FX-IA-NTI
Auto Creates PI Points No
Point Builder Utility No
ICU Control Yes
PI Point Types float16 / float 32 / float 64 / int16 / int32 / digital /
string
Sub-second Timestamps Yes
*Sub-second Scan Classes Yes (but of limited use. See note below)
Automatically Incorporates PI Point Yes
Attribute Changes
Exception Reporting Yes
Inputs to PI Data Archive Scan-based/Event Tags
Outputs to data source Yes
* Read-only interface available Yes
Supports Questionable Bit Yes
Supports Multi-character PointSource Yes
Maximum Point Count Unlimited for the FoxAPI
30,000 buffered points for the AIM*API
* Uses PI SDK No
PINet String Support No
* Source of Timestamps Synchronized to the PI Data Archive

PI Interface for Foxboro I/A 70 Series 3


Introduction

Feature Support
History Recovery No
* UniInt-based Yes
* Disconnected Startup Yes
* SetDeviceStatus Yes
* Failover Interface specific
* Vendor Software Required on Yes
Interface Node / PINet Node
Vendor Software Required on Data No
Source Device
Vendor Hardware Required No
Additional PI Software Included with No
interface
*Device Point Types See below
Serial-Based interface No

* See paragraphs below for further explanation.

Read-only Interface Available


A read-only version of this interface is available. Read-only versions cannot update the data
source (that is, control system). If outputs to the data source are not needed, use the read-only
version of the interface.

Security Note: A read-only interface provides the best defense against


accidental or malicious changes to the control system.

Sub-second Timestamps and Scan Classes


The interface supports sub-second scan classes and timestamps. However, there are
limitations within the I/A system which mean that the accuracy of the timestamps may not be
reliable.
Firstly, the fastest the I/A stations check for updates for the FoxAPI/AIM*API is 0.5 second
(this is independent of the station BPC). Therefore, defining a scan class for the interface
faster than 0.5 second will only result in duplicate values being read.
Secondly, the FoxAPI/AIM*API does not return timestamps with the values. Therefore the
interface must apply a timestamp when it reads the value and there will be a delay between
the value scanned in the I/A control station and when the timestamp is applied.
Also note that high scan frequencies impose a high CPU load on the system and should be
avoided if not absolutely required.

Uses PI SDK
The PI SDK and the PI API are bundled together and must be installed on each interface
node. This interface does not specifically make PI SDK calls.

Source of Timestamps
The time on the PI Data Archive is treated as the master clock when time-stamping values
received by the interface. The timestamp is calculated by using the current time on the

4
interface node and applying an offset calculated from the different in the interface node time
and the time on the PI Data Archive.
Because the Foxboro I/A series workstation may have its time zone set to GMT and its clock
set to wall clock time, the time as indicated internally on this machine is technically incorrect.
Therefore, PI Foxboro uses the PI API to determine the PI Data Archive’s local time. The
Interface then applies an additional time offset to obtain the correct Coordinated Universal
Time (UTC). This offset is recalculated every 10 minutes.

UniInt-based
UniInt stands for Universal Interface. UniInt is not a separate product or file; it is an
OSIsoft-developed template used by developers and is integrated into many interfaces,
including this interface. The purpose of UniInt is to keep a consistent feature set and behavior
across as many of OSIsoft’s interfaces as possible. It also allows for the very rapid
development of new interfaces. In any UniInt-based interface, the interface uses some of the
UniInt-supplied configuration parameters and some interface-specific parameters. UniInt is
constantly being upgraded with new options and features.
The PI Universal Interface (UniInt) User Guide is a supplement to this manual.

Disconnected Start-Up
The fxbais interface is built with a version of UniInt that supports disconnected start-up.
Disconnected start-up is the ability to start the interface without a connection to the
PI Data Archive. This functionality is enabled by adding /cachemode to the list of start-up
parameters or by enabling disconnected startup using the ICU. Refer to the PI Universal
Interface (UniInt) User Guide for more details on UniInt disconnected startup.

SetDeviceStatus
Functionality has been added to UniInt 4.3.0.15 and later to support health tags. The PI
Foxboro I/A interface is built against a version of UniInt that supports the health tags.
The Health tag with a string point type and the attribute Exdesc = [UI_DEVSTAT], is used to
represent the status of the interface. The possible values for this string point are:
 “1 | Starting” – The Interface remains in this state until it has loaded the PI points
and either starts scanning, or if running in failover, it initializes the failover state.
 “2 | Connected/No Data” – the interface is part of a failover pair and currently
initializing or changing failover state.
 “Good” – The interface is able to collect data. A value of “Good” does not mean
that all tags are receiving good values, but it is a good indication that there are no
hardware or network problems. When using failover, a “Good” status can
indicate that the interface is active or on standby. The failover status PI points
will show the status of the individual instances of the interface.
 “4 | Intf Shutdown” – The Interface has shut down.
The Interface updates this point whenever the interface is started or stopped.

Failover
The user may simultaneously run two copies of PI Foxboro in a failover configuration. In this
manner, if one copy of the Interface fails, the other automatically assumes responsibility for
data collection. See the Failover section of this manual for details.

PI Interface for Foxboro I/A 70 Series 5


Introduction

Note: The failover mechanism used by the interface is specific to the PI Interface for
Foxboro I/A (fxbais) interface. The interface does not support the UniInt-based
failover. –UFO_ID= is not supported.

Vendor Software Required


The PI Interface for Foxboro I/A 70 Series requires
 I/A 8.2 or later on an AW70/AP70 with either
o FoxAPI version 4.x.x, or
o AIM*API version 3.4.x or later
As of fxbais 2.4.0.x, the interface only supports I/A running on Windows XP SP2 or later.
If the I/A 70 series version is prior to I/A 8.2, then the fxbais 2.4.0.x interface is NOT
compatible. However, the earlier fxbais 2.3.8.66 interface can be used on these older systems.
Please contact OSIsoft for the following versions of the required OSIsoft packages:
 OSIprerequisites-legacy_2_0_0_10_.exe (supports Windows XP SP1)
 PIICUSetup_1.4.8.0_.exe (which installs the PISDK 1.3.8.388 & PIAPI 1.6.1.17)
 fxbais_2.3.8.66_.exe

Device Point Types


The PI Foxboro Interface supports the following Foxboro I/A point types:
 char (I/A type 1)
 short integer (I/A type 2)
 float (I/A type 3)
 string (I/A type 4)
 Boolean (I/A type 5)
 long integer (I/A type 6)
 short integer (I/A type 8)
 packed Boolean (I/A type 9)
 long packed Boolean (I/A type 10)
The Interface does not support the reading of I/A Series messages. The following message
types are NOT supported:
 Control Station Generated:
o Process Alarms
o Sequence of Events
o Sequence Block
 System Monitor
 Operator Action Journal

6
PI Interface for Foxboro I/A 70 Series 7
Introduction

Diagram of Hardware Connection


The following diagrams indicate the connectivity between the various hardware and software
components. Note that the Interface must run on a machine that is separate from the PI Data
Archive. The Interface must be installed on a machine that is part of the I/A system. In
OSIsoft’s terminology, the machine will be a “PI Interface node”.

8
Chapter 2. Principles of Operation

The following description of the PI Foxboro Interface assumes that the user is familiar with
running OSIsoft interface programs in general. First-time users of the PI System may wish to
skim this section and return at a later time.

FoxAPI and AIM*API


As of fxbais version 2.4.x.x, either the FoxAPI or the AIM*API are supported. On Windows
platforms, different executables are installed depending on which of the APIs the interface is
to use. The APIs have the same functionality and are source code compatible.
When this manual refers to the FoxAPI, it is implied that it is referring to either the FoxAPI
or the AIM*API, depending on the executable being used. To check which executable is
installed, either check the executable Properties/File Description, or run the executable with
the –v argument.
Before PI Foxboro can start up, the FoxAPI/AIM*API processes must already be running. On
Windows, FoxAPI/AIM*API control panel can be used.

Overview
Upon startup, PI Foxboro reads the PI point database and determines which PI points it
services by looking at the Point Source and Location1 point attribute fields. The
InstrumentTag field should contain the name of the Foxboro I/A object. Otherwise, the
Extended Descriptor must have the name of the Foxboro I/A object.
PI Foxboro makes calls to FoxAPI functions in order to retrieve data from the I/A system.
The Location2 value determines whether the Interface utilizes unbuffered or buffered FoxAPI
access routines. Values written from PI to the I/A are also via either buffered or unbuffered
FoxAPI function calls.

Buffered Access
Buffered access involves reading from or writing to I/A object values in the I/A shared
memory. The interface uses the FoxAPI scopen() function to open the lists. When opening
the lists of buffered objects, the interface uses the value from the ExcDev attribute of the PI
points as the “delta” value within the FoxAPI data sets. When the Foxboro system sees that
an object has changed by more that the “delta” value, then it updates the value in the I/A
shared memory. When the interface reads a buffered value using the FoxAPI mreaidx()
function, it is actually reading from the I/A shared memory.

PI Interface for Foxboro I/A 70 Series 9


Principles of Operation

Note: An ExcDev/ExcDevPercent value of zero should be avoided as the Foxboro system


will always send an update to the I/A shared memory, regardless of whether the value has
changed or not. The loading on the I/A system caused by these unnecessary updates can
cause issues.
When the interface is using buffered output points, it will open FoxAPI lists with write
access. These write lists will secure all the objects within the list and stop any other
application from updating them. The objects will be unsecured when the interface is stopped.

Unbuffered Access
Unbuffered access involves the FoxAPI broadcasting a message across the I/A system to
locate the objects requested and waiting until it receives a reply or times out. This generates a
lot of network traffic and CPU loading on the I/A system. Another problem with unbuffered
access is caused when the station hosting an unbuffered object is not available (offline,
network problem etc), then the interface must wait for the FoxAPI call to timeout. During this
timeout period, the interface is not able to do anything else, and this can cause gaps in the
scanning of the other points within the interface. For this reason, unbuffered access should be
avoided if possible. Unfortunately, some I/A objects can only be accessed with unbuffered
calls. These include all string objects. Care should be taken when using unbuffered access.

Object Status
When the interface receives a value from the I/A system, it also gets status information. The
interface examines the status to determine whether the value is valid. By default, the interface
can send either “Bad Input” or “I/O Timeout” when the object to the PI point depending on
the object status.
“I/O Timeout” is sent when the status indicated that the object is not being scanned. (i.e. no
response, disconnected, deleted etc). The connection status are bits 5 to 7 of the status.
“Bad Input” is sent when the object is bad (status bit 8) or out-of-service (status bit 11).
The system digital states sent can be changed using the –doubtful= and –no_connect=
command-line arguments.
For more information of the I/A object manager status information returned with the values,
see “Appendix F: FoxAPI/AIM*API Status Definition”. It is also possible to store the status
itself in a PI point by setting Location3=0. Note that the object status is not the same as a
block status. The block status can be read by configuring a point to read the .BLKSTA
parameter.
The interface can also be configured to ignore the object status and to always send the value
to PI. This can be configured for all points with the BadStatusIndication parameter in the
fxbais.ini file, or on a point-by-point basis with the userint1 point attribute. For more
information on the BadStatusIndication parameter, see the section on the fxbais.ini
Configuration File.

Outputs
Outputs from the PI System to the Foxboro I/A are performed via OSIsoft’s standard event-
based mechanism. That is, when the Interface determines that a PI point has received a new
10
value, it sends this value to the corresponding I/A object. Similar to the inputs, outputs can be
either buffered or unbuffered. When an object is in a write list, the object is secured and only
the interface will be able to write to that object. For speed and reliability, buffered outputs are
recommended.
However, care must be taken when configuring buffered output points. The parameter that
the interface is writing to must not be an output parameter from a block, or a parameter that
can be secured by the block. The parameters accessibility must be connectable and settable
and with no configured connections. For example, the OUT parameter from a PID cannot be
used. Similarly, the SPT parameter of a PID block cannot be used because it can be secured
when the PID controller is put into remote. However, the RI0x parameter of a CALC block
with no configured connections can be safely used.
There are limitations with writing values to I/A objects with buffered lists. It is not possible to
use buffered lists to write to any output parameters of I/A blocks. This includes the VALUE
parameter of I/A variable block types (BOOL, LONG, PACK, REAL, STRING etc.). They
can be read with buffered lists, but they cannot be written to with buffered lists. The interface
may hang when attempting to open write lists that contain output parameters (even when the
blocks are in manual and the I/A system is not securing the outputs). The unbuffered writes
do not have the same problems, but any unbuffered access have other problems. When
writing values to the I/A system, it is advisable to use buffered lists (location2>0) to write to
the input parameters of blocks.

PI Interface for Foxboro I/A 70 Series 11


Chapter 3. Installation Checklist

If you are familiar with running PI data collection interface programs, this checklist helps you
get the interface running. If you are not familiar with PI interfaces, return to this section after
reading the rest of the manual in detail.
This checklist summarizes the steps for installing this interface. You need not perform a
given task if you have already done so as part of the installation of another interface. For
example, you only have to configure one instance of Buffering for every interface node
regardless of how many interfaces run on that node.
The Data Collection Steps below are required. Interface Diagnostics and Advanced Interface
Features are optional.

Data Collection Steps


1. Confirm that you can use PI SMT to configure the PI Data Archive. You need not run
PI SMT on the same computer on which you run this interface.
2. If you are running the interface on an interface node, edit the PI Data Archive’s Trust
Table to allow the interface to read attributes and point data. If a buffering
application is not running on the interface node, the PI trust must allow the interface
to write data.
3. Run the installation kit for the PI Interface Configuration Utility (ICU) on the
interface node if the ICU will be used to configure the interface. This kit runs the PI
SDK installation kit, which installs both the PI API and the PI SDK.
4. Run the installation kit for this interface. Unless you need output points, use the read-
only version of the interface. This kit also runs the PI SDK installation kit which
installs both the PI API and the PI SDK if necessary.
5. If you are running the interface on an interface node, check the computer’s time zone
properties. An improper time zone configuration can cause the PI Data Archive to
reject the data that this interface writes.
6. Run the ICU and configure a new instance of this interface. Essential startup
parameters for this interface are:
Point Source (/PS=x)
Interface ID (/ID=#)
PI Data Archive (/Host=host:port)
Scan Class (/F=##:##:##,offset)
Enable Outputs (optional /write)
7. If you will use digital points, define the appropriate digital state sets.

PI Interface for Foxboro I/A 70 Series 13


Installation Checklist

8. Build input points and, if desired, output points for this interface. Important point
attributes and their purposes are:
Location1 specifies the interface instance ID multiplied by 100.
Location2 is the PI list number for buffered access to I/A objects. Zero for
unbuffered points
Location3 is the data type of the I/A object. A positive value indicates input
(from I/A to PI) and a negative value indicates an output (from PI to
I/A). Zero indicates that the FoxAPI/AIM*API object status will be
store instead of the object value.
Location4 specifies the scan class.
Location5 is normally zero, but when non-zero makes the interface write the
FoxAPI/AIM*API list change count to the PI point.
ExDev specifies the delta that the value must change be before the CP will
notify the FoxAPI/AIM*API of the change. Care must be taken
when using ExcDev=0 as this can overload an I/A system.
ExDesc can specify the Foxboro I/A object or various other special
operations.
InstrumentTag specifies the Foxboro I/A object
PtSecurity must permit read access for the PI identity, group, or user configured in
the PI trust that is used by the interface.
DataSecurity must permit read access (buffering enabled) or read/write access
(unbuffered) for the PI identity, group, or user configured in the PI trust that is used
by the interface.

Security Note: When buffering is configured, the DataSecurity attribute must permit write
access for the buffering application’s PI trust or mapping. DataSecurity write permission for
the interface’s PI trust is required only when buffering is not configured.

9. Start the interface interactively and confirm its successful connection to the
PI Data Archive without buffering. (The DataSecurity attribute for interface points
must permit write access for the interface’s PI trust.)
10. Confirm that the interface collects data successfully.
11. If the messages “open_action: not found” or “clsset_action: not found” are output,
then refer to the section “Warnings ‘open_action: not found’ and ‘clsset_action : not
found’”
12. If output points are required, confirm that output points update the correct values in
the data source. Create an output point whitelist file for the interface instance.
13. Stop the interface and configure a buffering application (either Bufserv or PIBufss).
14. Start the buffering application and the interface. Confirm that the interface works
together with the buffering application by physically removing the connection
between the interface node and the PI Data Archive node. (The DataSecurity attribute
for interface points must permit write access for the buffering application’s PI trust or
mapping. The interface’s PI trust does not require DataSecurity write permission.)
15. Configure the interface to run as a Windows service. Confirm that the interface runs
properly as a service.
16. Restart the interface node and confirm that the interface and the buffering application
restart.
14
Interface Diagnostics
1. Configure Scan Class Performance points.
2. Install the PI Interface for Performance Monitor (Full Version only) on the interface
node.
3. Configure performance counter points.
4. Configure UniInt Health Monitoring points
5. Configure the I/O Rate point.
6. Install and configure the Interface Status Utility on the PI Data Archive node.
7. Configure the Interface Status point.

Advanced Interface Features


1. Configure the interface for disconnected startup. Refer to the UniInt Interface User
Manual for more details on UniInt disconnected startup.
2. Configure interface failover if required. See that section in this document for details
related to configuring the interface for failover.

PI Interface for Foxboro I/A 70 Series 15


Chapter 4. Interface Installation

OSIsoft recommends that interfaces be installed on interface nodes instead of directly on the
PI Data Archive node. An interface node is any node other than the PI Data Archive node
where the PI Application Programming Interface (PI API) is installed (see the
PI API manual). With this approach, the PI Data Archive need not compete with interfaces
for the machine’s resources. The primary function of the PI Data Archive is to archive data
and to service clients that request data.
After the interface has been installed and tested, buffering should be enabled on the interface
node. Buffering refers to either PI API Buffer Server (Bufserv) or the PI Buffer Subsystem
(PIBufss). For more information about buffering see the Buffering for PI Interfaces chapter of
this manual.
In most cases, interfaces on interface nodes should be installed as automatic services.
Services keep running after the user logs off. Automatic services automatically restart when
the computer is restarted, which is useful in the event of a power failure.

Naming Conventions and Requirements


In the installation procedure below, it is assumed that the name of the interface executable is
fxbais.exe and that the startup command file is called fxbais.bat.
The read-only version of the interface is named fxbais_ReadOnly.exe and the command
file is named fxbais _ReadOnly.bat. If you are configuring an instance of the read-only
interface, use these names instead of fxbais.exe and fxbais.bat in the procedures in
the remainder of this document.

When Configuring the Interface Manually


It is customary for the user to rename the executable and the startup command file when
multiple copies of the interface are run. For example, fxbais1.exe and fxbais1.bat
would typically be used for instance 1, fxbais2.exe and fxbais2.bat for instance 2, and
so on. When an interface is run as a service, the executable and the command file must have
the same root name because the service looks for its command-line parameters in a file that
has the same root name.

PI Interface for Foxboro I/A 70 Series 17


Interface Installation

Interface Directories

PIHOME Directory Tree

32-bit Interfaces
The [PIHOME] directory tree is defined by the PIHOME entry in the pipc.ini configuration
file. This pipc.ini file is an ASCII text file, which is located in the %windir% directory.
For 32-bit operating systems, a typical pipc.ini file contains the following lines:
[PIPC]
PIHOME=C:\Program Files\PIPC
For 64-bit operating systems, a typical pipc.ini file contains the following lines:
[PIPC]
PIHOME=C:\Program Files (X86)\PIPC
The above lines define the root of the PIHOME directory on the C: drive. The PIHOME
directory does not need to be on the C: drive. OSIsoft recommends using the paths shown
above as the root PIHOME directory name.

Security Note: Restrict the Windows accounts that can create or write files in
the %PIHOME% folder and subfolders.

Interface Installation Directory

The installation kit for the read/write version will automatically install the interface to:
PIHOME\Interfaces\fxbais\
PIHOME is defined in the pipc.ini file.
The installation kit for the read-only version of the interface installs the interface to:
PIHOME\Interfaces\fxbais_ReadOnly
A read-only version of this interface is available. Read-only versions cannot update the data
source (that is, control system). If outputs to the data source are not needed, use the read-only
version of the interface.

Security Note: A read-only interface provides the best defense against accidental or
malicious changes to the control system.

FoxAPI Software Requirement


Ensure that the FoxAPI/AIM*API software is installed and running correctly before
attempting to install the fxbais interface software. The FoxAPI/AIM*API is normally
installed on the D:\opt\fox\ais\bin directory. Foxboro recommend using the current
release of the FoxAPI, so check with Foxboro to ensure that the version on the system is up to
date.
For details on installing the FoxAPI software, refer to the Foxboro manual “FoxAPI
Installation Manual” B0193UC.

18
Note: The FoxAPI Release Notes (B0193UH) refers to “Special Instructions for Existing
OSI PI Applications”. These notes only apply to fxbais 2.2.5 or earlier and are not
relevant for the current release of the fxbais interface.
The FoxAPI entry in the Windows Control Panel can be selected to allow the FoxAPI to start
on a reboot and to manually start or stop the FoxAPI process.
As of I/A 8.8, the AIM*API is installed by default in the D:\opt\aim\bin directory. The
AIM*API process (apimgr.exe) is installed as a Windows service called the Aim API
Manager Service. It can be started and stopped with the Windows Services control panel.

FoxAPI / AIM*API Installation


Ensure that the FoxAPI/AIM*API software is installed and running correctly before
attempting to install the OSIsoft software.
The FoxAPI is normally installed on the D:\opt\fox\ais\bin directory.
For details on installing the FoxAPI software, refer to the Foxboro manual “FoxAPI
Installation Manual” B0193UC.
Note: The FoxAPI Release Notes (B0193UH) refers to “Special Instructions for Existing
OSI PI Applications”. These notes only apply to fxbais 2.2.5 or earlier and are not
relevant for the current release of the fxbais interface.

The FoxAPI/AIM*API applet in the Windows Control Panel can be selected to allow the
FoxAPI/AIM*API to start on a reboot and to manually start or stop the FoxAPI process.
Foxboro recommend using the current release of the FoxAPI/AIM*API, so check with
Foxboro to ensure that the version on the system is up to date.
As of I/A 8.8, the AIM*API is installed by default in the D:\opt\aim\bin directory. The
AIM*API process (apimgr.exe) is installed as a Windows service called the Aim API
Manager Service. It can be started and stopped with the Windows Services control panel.
The AIM*API applet in the Control Panel is not required as the AIM*API services can be
controlled with the Windows Services control panel.
For details on installing the AIM*API software, refer to the Foxboro manual “AIM*AT
Installation Guide” B0193YM.

FoxAPI / AIM*API Configuration


On startup, the FoxAPI or AIM*API reads its configuration from the foxapi.cfg or
aimapi.cfg file in the FoxAPI/AIM*API directory. These are text files with a list of
parameters and values.
For the interface to read from the I/A objects, there must be sufficient resources allocated by
the FoxAPI or AIM*API.
The maxobj parameter defines the maximum number of object-connections. The interface
requires an object-connect for each buffered pointed loaded. It is recommended to have
maxobj significantly higher than the actual number of points to be loaded (1.5 – 2 times
more).
For the FoxAPI, the maxobj range is 1000 to unlimited.

PI Interface for Foxboro I/A 70 Series 19


Interface Installation

For the AIM*API, the maxobj range is 1000 to 30000.


If there are multiple interfaces configured to run, then the API must be configured to handle
all the points from all the interfaces on the AW
To change the configuration file,
1) Stop the interface and any other API applications (historians etc.) running on the AW.
2) Stop the API processes
For FoxAPI, use either aisstop or FoxAPI control panel
For AIM*API, use either the AIM*AT control panel, or
stop the AimAPI Network Service and the Aim API Manager Service.
3) Edit the foxapi.cfg file in the FoxAPI directory
For FoxAPI, D:\opt\fox\ais\bin
For AIM*API, D:\opt\aim\bin
4) Restart the API processes
5) Restart the interface and other API applications
Please refer to section “FoxAPI/AIM*API Configuration Settings (foxapi.cfg/aimapi.cfg)”
for more information.
Note: When using the AIM*API, ensure that it is configured to NOT share Object
Manager (OM) lists. In the aimapi.cfg file, set useaimapi=1 or remove the useaimapi
entry from the file.
For details on the FoxAPI or AIM*API parameters, refer to the Foxboro I/A manuals
 FoxAPI User Manual (B0193UD), Appendix H – Configuration File Parameters
 AIM*API User Manual (B0193YN), Appendix J – Configuration File Parameters

Interface Installation Procedure


The following procedure shows the steps required to install the PI fxbais interface on a
Foxboro I/A AW70 machine, along with the other OSIsoft software required.
1. Check that the FoxAPI or AIM*API software has been installed and that is it
configured to start automatically on a reboot.
2. Ping the PI Data Archive to verify the network connection and the IP name resolution
is set up correctly.
3. Ensure that the trusts on the PI Data Archive are setup to allow the interface to write
to the PI Data Archive.
4. Boot the AW70 with the I/A software turned off by selecting Control Panel >
Foxboro I/A > I/A Series Off / Autologon and then rebooting.
5. Ensure that the FoxAPI (foxapi.exe) and AIM*API processes (apimgr.exe) are NOT
running.
6. Run the OSIsoft prerequisites install kit. The prerequisite install kit used depends on
the version of Windows is running on the AW70.
The installation of the prerequisites may require the station to be rebooted. After the
reboot, the installation should continue.

20
7. Run the “Interface Configuration Utility (ICU)” install kit. The ICU install kit will
also install the PI SDK, the PI API and the pibufss components.
During the installation, it will ask for a destination folder. It is recommended that
“D:\PIPC” be used. For the PI Data Archive name, the FQDN is recommended.
8. Once the ICU and its components are installed, the connection to the PI Data Archive
should be verified. Using the “About-SDK” utility, test the connection to the PI Data
Archive.
9. Run the fxbais_#.#.#.#.exe install kit to install the interface and the fxbais ICU
control. The install kit will prompt to select the feature to install. Select either the
FoxAPI or the AIM*API, depending on the requirements.

10. Enable the I/A software by selecting the Control Panel > Foxboro I/A > I/A Series
On / Autologon and reboot the station.
Once the interface and its required packages and installed then the interface can be
configured and set up as a service using either the ICU or manually.

PI Trust for Interface Authentication


A PI Interface usually runs on an interface node as a Windows service, which is a non-
interactive environment. In order for an interface to authenticate itself to a PI Data Archive
and obtain the access permissions for proper operation, the PI Data Archive must have a
PI trust that matches the connection credentials of the interface. Determine if a suitable
PI trust for the interface exists on the PI Data Archive. If a suitable PI trust does not exist, see
the Security chapter for instructions on creating a new PI trust.

PI Interface for Foxboro I/A 70 Series 21


Interface Installation

Installing Interface as a Windows Service


The fxbais interface service can be created, preferably, with the
PI Interface Configuration Utility, or can be created manually.

Security Note: For improved security, we recommend running the interface


service under a non-administrative account, such as a Windows built-in service
virtual account, the built-in Network Service account, or a non-administrative account
that you create.

Installing Interface Service with PI Interface Configuration Utility


The PI Interface Configuration Utility provides a user interface for creating, editing, and
deleting the interface service:

Service Configuration

Service name
The Service name box shows the name of the current interface service. This service name is
obtained from the interface executable.

22
ID
This is the service ID used to distinguish multiple instances of the same interface using the
same executable.

Display name
The Display name text box shows the current Display Name of the interface service. If there
is currently no service for the selected interface, the default Display Name is the service name
with a “PI-” prefix. Users may specify a different Display Name. OSIsoft suggests that the
prefix “PI-” be appended to the beginning of the interface name to indicate that the service is
part of the OSIsoft suite of products.

Log on as
The Log on as box shows the current “Log on as” Windows account of the interface service.
If the service is configured to use the Local System account, the Log on as will have selected
“LocalSystem.” Users may specify a different Windows account for the service to use.

Security Note: For best security, we recommend running this interface service
under an account with minimum privileges, such as a Windows built-in service virtual
account, the built-in Network Service account, or a non administrative account that
you create.

PI ICU versions earlier than 1.4.14.x cannot create a service that runs as a Windows built-in
service virtual account or the built-in Network Service or Local Service accounts. After ICU
creates the interface service, you can change the account with a Windows administrative tool,
such as Services on the Control Panel or the sc command-line utility.

Password
If a Windows User account is entered in the Log on as text box, then a password must be
provided in the Password text box, unless the account requires no password.

Confirm password
If a password is entered in the Password text box, then it must be confirmed in the Confirm
password text box.

Dependencies
The Installed services list is a list of the services currently installed on this machine. Services
upon which this interface is dependent should be moved into the Dependencies list using the

button. For example, if API Buffering is enabled, then Bufserv or PIBufss should be
selected from the list at the right and added to the list on the left. To remove a service from

the list of dependencies, use the button, and the service name will be removed from
the Dependencies list.
When the interface is started (as a service), the services listed in the dependency list will be
verified as running (or an attempt will be made to start them). If the dependent service(s)
cannot be started for any reason, then the interface service will not run.

PI Interface for Foxboro I/A 70 Series 23


Interface Installation

Note: Please see the PI Log and Windows Event Logger for messages that may
indicate the cause for any service not running as expected.

fxbais service using the FoxAPI and AIM*API 3.2 or earlier


The FoxAPI process is run as a background process and is NOT a Windows service.
Therefore, it is not possible to have the fxbais interface service depend on the FoxAPI
process. To work around this issue, when the fxbais interface starts, it will check that the
FoxAPI is running before attempting accessing it.

fxbais service using the AIM*API 3.3 or later


On I/A 8.8 or later, the AIM*API process is run as a Windows service called the Aim API
Manager Service. Therefore, the AIM*API service (apimgr) should be added to the list of
dependencies of the fxbais service. This means that Windows will not allow the fxbais
service to run if the apimgr service is not running.

- Add Button
To add a dependency from the list of Installed services, select the dependency name, and
click the Add button.

- Remove Button
To remove a selected dependency, select the service name in the Dependencies list, and click
the Remove button.
The full name of the service selected in the Installed services list is displayed below the
Installed services list box.

Startup Type
The Startup Type indicates whether the interface service will start automatically or needs to
be started manually on reboot.
 If the Auto option is selected, the service will be installed to start automatically when
the machine reboots.
 If the Manual option is selected, the interface service will not start on reboot, but will
require someone to manually start the service.
 If the Disabled option is selected, the service will not start at all.
Generally, interface services are set to start automatically.

Create
The Create button adds the displayed service with the specified Dependencies and with the
specified Startup Type.

Remove
The Remove button removes the displayed service. If the service is not currently installed, or
if the service is currently running, this button will be grayed out.
24
Start or Stop Service
The toolbar contains a Start button and a Stop button . If this interface service is not
currently installed, these buttons will remain grayed out until the service is added. If this
interface service is running, the Stop button is available. If this service is not running, the
Start button is available.
The status of the interface service is indicated in the lower portion of the PI ICU dialog.

Status of the
Status of Interface Service
the ICU Service installed or
uninstalled

Clearing and Resetting the FoxAPI / AIM*API Lists


If the fxbais interface has problems with opening the FoxAPI or AIM*API data sets, it may
be due to conflicts with the cached I/A object indexes.
This step is only required when the interface is started for the first time or if there are
problems with the fxbais interface in opening the FoxAPI/AIM*API data sets, and is NOT
required for a normal start of the interface.
The restore_index.dat files are used by the FoxAPI or AIM*API to map I/A objects to
the internal indexes from previous runs of the APIs. This is so that objects will receive the
same index if the AW70 is rebooted. When the client applications that are using the indexes
are stopped, then there is no requirement for the restore_index.dat files. The files can be
removed. When the interface and other applications are started, the restore_index.dat
file will be recreated by the FoxAPI or AIM*API as required.
To safely remove the restore_index.dat file(s),
1) Stop the interface and any other FoxAPI/AIM*API applications (historians etc) running
on the AW. During installation, the reboot with I/A Series OFF will mean that they are
already stopped.
2) Stop the FoxAPI processes (aisstop or FoxAPI control panel) and the AIM*API
processes (aisstop or AIM*API control panel)
3) Delete the restore_index.dat files from the API bin directories.
FoxAPI on AW70 D:\opt\fox\ais\bin
AIM*API on AW70 D:\opt\aim\bin
4) Restart the FoxAPI processes (aisstop or FoxAPI control panel) and the AIM*API
processes (aisstop or AIM*API control panel)
5) Restart the interface and other FoxAPI applications
The restore_index.dat files will be recreated by the FoxAPI and AIM*API as required.

PI Interface for Foxboro I/A 70 Series 25


Interface Installation

Changing from FoxAPI to AIM*API


If the interface has been installed for one API and the other API is then required, there are
two ways of changing the installation. Either uninstall the existing interface and reinstall, or
Windows “Programs and Feature” window to “Change/Modify” the installed interface.

Uninstall

Use the Windows Control Panel “Add or Remove Programs” or “Programs and Features” to
uninstall the “PI Interface for Foxboro IA (fxbais)” program. Do not uninstall any of the other
OSIsoft programs. The uninstall will remove the interface files from the system, but the site
specific .bat files will remain.
Run the fxbais_x.x.x.x_.exe installation kit. The interface will be marked for installation.
Follow the install prompts and selected the required API type when requested.

Change / Modify

 Open the Windows Control Panel “Add or Remove Programs” or “Programs and
Features”.
 Right click on the “PI Interface for Foxboro I/A 70 Series” program, and select
“Change” from the context menu.

 Select Modify and Next. The setup program will then prompt for required API type.
 Select the required API type, then Next and Install.
The installation will replace the existing interface files with the ones required for the selected
API. The site specific .bat files will remain unchanged.

Installing Interface Service Manually


Help for installing the interface as a service is available at any time with the command:
26
fxbais.exe /help
Open a Windows command prompt window and change to the directory where the
fxbais.exe executable is located. Then, consult the following table to determine the
appropriate service installation command.

Note: In the following Windows service installation commands you may use either a
slash (/) or dash (-) as the delimiter.

Windows Service Installation Commands on an Interface Node or a PI Data Archive Node


with Bufserv implemented
Manual service fxbais.exe /install /depend "“cpip bufserv”

Automatic service fxbais.exe /install /auto /depend "“cpip bufserv"”

*Automatic service with fxbais.exe /s27ervicedX /install /auto /depend "“cpip bufserv"”
service ID
Windows Service Installation Commands on an Interface Node or a PI Data Archive Node
without Bufserv implemented
Manual service fxbais.exe /install /depend tcpip
Automatic service fxbais.exe /install /auto /depend tcpip
*Automatic service with fxbais.exe /s27ervicedX /install /auto /depend tcpip
service ID

*When specifying service ID, the user must include an ID number. It is suggested that this
number correspond to the interface ID (/id) parameter found in the interface .bat file.
Check the Microsoft Windows Services control panel to verify that the service was added
successfully. The services control panel can be used at any time to change the interface from
an automatic service to a manual service or vice versa.
The service installation commands in this section create an interface service that runs under a
low-privilege built-in account. On Windows 7 and Server 2012 and later, the service logs on
as the service virtual account. For earlier versions of Windows, the service logs on as
Network Service.

Security Note: For best security, we recommend running this interface service
under an account with minimum privileges, such as a Windows service virtual
account, the built-in Network Service account, or a non administrative account that
you create.

As discussed earlier, following the recommendation to run the interface service under a low-
privilege account may affect performance counters.
The services control panel can change the account that the interface service runs under.
Changing the account while the interface service is running does not take effect until the
interface service is restarted.

PI Interface for Foxboro I/A 70 Series 27


Interface Installation

Installing the Interface on Secure I/A Systems


The fxbais interface will install and run on Secure I/A systems in much the same way as on
standard I/A systems. The exception is the “Log on as” settings for the service.
If the fxbais interface service is configured with a user account without sufficient permissions
to access the FoxAPI, then when the interface attempts to open a data set, the interface will
fail with an error reterr=212.
The fxbais interface does not control the permissions that it is run with. The service will
inherit the user credentials from the “Log on as” setting for the interface service. It depends
on the FoxAPI or AIM*API having the configuration with the correct permissions to allow
the interface to run.
The local “Fox” user can still be used on Secure I/A systems. Within the FoxAPI, the “Fox”
user is granted full access.
If a real user account needs to be used, then the user must be granted access using the
foxapi.tcp configuration file.
For example, if the fxbais interface was to be run by the domain user “IAManager”, then the
/opt/fox/ais/bin/foxapi.tcp file would need to contain
[Security_Access]
IAManager=System

28
Chapter 5. FoxAPI/AIM*API Test Program

The PI Interface for Foxboro I/A (fxbais) relies on the services provided by the FoxAPI or the
AIM*API. To verify that the FoxAPI/AIM*API is currently functional, use the utilities
supplied by Foxboro.
For the FoxAPI, the utility is called foxtst. Use a command such as
D:\opt\fox\ais\bin\foxtst.exe
For the AIM*API, the utility is called apitst. Use a command such as
D:\opt\aim\bin\foxtst.exe
The actual directories vary depending on the location that the FoxAPI/AIM*API was
installed.
Because the foxtst/apitst programs and fxbais interface both use the same underlying
FoxAPI/AIM*API functions, foxtst/apitst provides an easy way to verify values that are
read by the fxbais interface and subsequently sent to PI Data Archive. Similarly, if
foxtst/apitst programs experience problems with reading a particular I/A object, then
the fxbais interface will likewise have difficulties.

For example, to use the FoxAPI uread() function to read the current value for the I/A object
CMPD:BLKA.BI0004, do the following (inputs are in bold below):
D:\opt\fox\ais\bin\foxtst.exe
Foxboro Fox API Test Program

Menu (1) Fox API Test Program Hostid = 80fe6962 System Type
= 51

Test Program Quick Tests Sub Menus


-1 Exit 10-FoxAPI Status 100 –(Menu 1) Main Menu
0-Repeat Last 11-Block Info 200 –(Menu 2) Block Info
1-Help 12-Objects 300 –(Menu 3) Objects
2-Menu On/Off 13-CDX 400 –(Menu 4) CDX
3-Echo On/Off 14-File 500 –(Menu 5) File
3-Echo On/Off 15-Historian 600 –(Menu 6) Historian
4-Save Settings 16-FoxHistory 700 –(Menu 7) FoxHistory
5-an_error 17-Counters 800 –(Menu 8) Counters
18-Trouble Shooting 900 –(Menu 9) Trouble Shooting
19-OM 1000-(Menu 10) OM Functions
1100-(Menu 11) Old Functions

function[ 0]: 300

Menu (3) Object Access Hostid = 80fe6962 System Type = 51

PI Interface for Foxboro I/A 70 Series 29


FoxAPI/AIM*API Test Program

Test Program Functions Functions Functions


-1 Main Menu 10-scopen 30-getidx 40-uread
1-Help 11-sqopen 31-getmidx 41-uwrite
2-Menu On/Off 12-bread 32-readval 42-sread
3-Echo On/Off 13-bwrite 33-mreaidx 43-swrite
4-Save Settings 14-qread 34-readnam 44-an_nam2val
5-Save Set Info 35-readsta 45-wrtval
16-clsset 36-mreawidx 46-an_write_valstat
17-get_set_name 37-all_read
18-get_set_num
19-put_set_name
20-gsinfo
21-getnam
22-gsnent

function[ 0]: 40

---- uread ----


compound [ point1 ]: CMPD
block [ . ]: BLKA
parameter [ . ]: RI04
value type [ 3 ]: 3
multiples [ 1 ]:
ok to add? [ ]: Y
end of set? [ N ]: Y

num entries [ 1 ]:
reterr = 0 – ( Success )

entry name error value status


----- ---- ----- ----- ------
1 CMPD:BLKA.RI04 0 1.24 0023x ActOffUns_OkFlt
In the above example, the value of the I/A object CMPD:BLKA.RI04 as returned by the
FoxAPI uread() function is 1.24.

The interface uses mreaidx() to read the values for buffered inputs. Therefore, using
getidx() and mreaidx() within foxtst/apitst is the recommended method of
checking points that do not appear to be updating correctly within the PI Data Archive.
Here is example that finds the indexes of 3 objects (MEAS, SPT and OUT of a PIDE block),
and then reads the buffered values for the C:B.Ps from the data sets. The fxbais interface is
running (so the objects will be in the data sets) :
D:\opt\aim\bin\apitst

Invensys AIM*API Test Program

-enu (1) AIM*API Test Program Hostid = 1725755c System Type


= 70

Test Program Quick Tests Sub Menus


-1 Exit 10-AIM*API Status 100 -–Menu 1) Main Menu
0-Repeat Last 11-Block Info 200 -–Menu 2) Block Info
1-Help 12-Objects 300 -–Menu 3) Objects
2-Menu On/Off 13-CDX 400 -–Menu 4) CDX
3-Echo On/Off 14-File 500 -–Menu 5) File

30
3-Echo On/Off 15-Historian 600 -–Menu 6) Historian
4-Save Settings 16-AIM*Historian 700 -–Menu 7) AIM*Historian
5-an_error 17-Counters 800 -–Menu 8) Counters
18-Trouble Shooting 900 -–Menu 9) Trouble Shooting
19-OM 1000-(Menu 10) OM Functions
1100-(Menu 11) Old Functions
1300-(Menu 13) t_Objects
1400-(Menu 14) t_CDX

function[ 0]: 300

-enu (3) Object Access Hostid = 1725755c System Type = 70


Test Program Functions Functions Functions
-1 Main Menu 10-scopen 30-getidx 40-uread
1-Help 11-sqopen 31-getmidx 41-uwrite
2-Menu On/Off 12-bread 32-readval 42-sread
3-Echo On/Off 13-bwrite 33-mreaidx 43-swrite
4-Save Settings 14-qread 34-readnam 44-an_nam2val
5-Save Set Info 35-readsta 45-wrtval
16-clsset 36-mreawidx 46-an_write_valstat
17-get_set_name 37-all_read
18-get_set_num
19-put_set_name
20-gsinfo
21-getnam
22-gsnent

function[ 0]: 30
---- getidx ----

compound [ UC01_LEAD:SINE.MEAS ]: PITEST88_01


block [ . ]: LC001_CTRL
parameter [ . ]: MEAS

name index
---- -----
PITEST88_01:LC001_CTRL.MEAS 1

<<snipped>>

function[ 30]: 30
---- getidx ----

compound [ PITEST88_01 ]: PITEST88_01


block [ LC001_CTRL ]: LC001_CTRL
parameter [ MEAS ]: SPT

name index
---- -----
PITEST88_01:LC001_CTRL.SPT 7

<<snipped>>

function[ 30]: 30
---- getidx ----

compound [ PITEST88_01 ]: PITEST88_01


block [ LC001_CTRL ]: LC001_CTRL

PI Interface for Foxboro I/A 70 Series 31


FoxAPI/AIM*API Test Program

parameter [ SPT ]: OUT

name index
---- -----
PITEST88_01:LC001_CTRL.OUT 3

<<snipped>>

function[ 30]: 33
----mreaidx ----

index [ 1 ]: 1
end of indexes? [ N ]:
index [ 1 ]: 7
end of indexes? [ N ]:
index [ 7 ]: 3
end of indexes? [ N ]: Y

reterr = 0 -–( Success )


index value status chgcnt
----- ----- ----------- ------
1 77.6812 00000223x ActOffSec_OkFlt 683
7 76.6383 00000023x ActOffUns_OkFlt 4
3 75.5993 00000023x ActOffUns_OkFlt 667

<<snipped>>

function[ 33]:

32
Chapter 6. Digital States

For more information regarding Digital States, refer to the PI Data Archive documentation.

Digital State Sets


PI digital states are discrete values represented by strings. These strings are organized in the
PI Data Archive as digital state sets. Each digital state set is a user-defined list of strings,
enumerated from 0 to n to represent different values of discrete data. For more information
about PI digital points and editing digital state sets, see the PI Data Archive manuals.
An interface point that contains discrete data can be stored in the PI Data Archive as a digital
point. A digital point associates discrete data with a digital state set, as specified by the user.

Failover Status Digital Set


If interface failover is to be used on the system, create a digital set FXBAIS_FAILOVER
with the following digital states. See Chapter 10: “Interface Failover Configuration” for more
information
Value State Text Meaning
0 Stopped Interface is not running
1 1Init Primary wants to start data collection
2 1Collect Primary is the most recent program that collected data
3 1Exit After data collection, Primary exited normally
4 2Standby Secondary wants to start data collection
5 2Collect Secondary is the most recent program that collected data
6 2Exit After data collection, Secondary exited normally

System Digital State Set


Similar to digital state sets is the system digital state set. This set is used for all points,
regardless of type, to indicate the state of a point at a particular time. For example, if the
interface receives bad data from the data source, it writes the system digital state Bad Input
to the PI point instead of a value. The system digital state set has many unused states that can
be used by the interface and other PI clients. Digital States 193-320 are reserved for OSIsoft
applications.

PI Interface for Foxboro I/A 70 Series 33


Chapter 7. PointSource

The PointSource is a unique, single or multi-character string that is used to identify the PI
point as a point that belongs to a particular interface. For example, the string Boiler1 may be
used to identify points that belong to the MyInt interface. To implement this, the PointSource
attribute would be set to Boiler1 for every PI point that is configured for the MyInt
interface. Then, if /ps=Boiler1 is used on the startup command-line of the MyInt interface,
the interface will search the PI Point Database upon startup for every PI point that is
configured with a PointSource of Boiler1. Before an interface loads a point, the interface
usually performs further checks by examining additional PI point attributes to determine
whether a particular point is valid for the interface. For additional information, see the /ps
parameter. If the PI API version being used is earlier than 1.6.x or the PI Data Archive
version is earlier than 3.4.370.x, the PointSource is limited to a single character unless the
SDK is being used.

Case-sensitivity for PointSource Attribute


The PointSource character that is supplied with the /ps command-line parameter is not case
sensitive. That is, /ps=P and /ps=p are equivalent.

Reserved Point Sources


Several subsystems and applications that ship with the PI System are associated with default
PointSource characters. The Totalizer Subsystem uses the PointSource character T, the Alarm
Subsystem uses @ for Alarm points, G for Group Alarms and Q for SQC Alarm points,
Random uses R, RampSoak uses 9, and the Performance Equations Subsystem uses C. Do not
use these PointSource characters or change the default point source characters for these
applications. Also, if a PointSource character is not explicitly defined when creating a
PI point; the point is assigned a default PointSource character of Lab (PI 3). Therefore, it
would be confusing to use Lab as the PointSource character for an interface.

Note: Do not use a point source character that is already associated with another
interface program. However it is acceptable to use the same point source for multiple
instances of an interface.

PI Interface for Foxboro I/A 70 Series 35


Chapter 8. PI Point Configuration

The PI point is the basic building block for controlling data flow to and from the
PI Data Archive. A single point is configured for each measurement value that needs to be
archived.
If outputs to the data source device (control system) are not needed, configure the interface
instance to disable outputs from PI.

Security Note: Disabling outputs from PI defends against accidental or malicious


changes to the control system. See the –write command-line parameter for more
information.

Point Attributes
Use the point attributes below to define the PI point configuration for the interface, including
specifically what data to transfer.
This document does not discuss the attributes that configure UniInt or PI Data Archive
processing for a PI point. Specifically, UniInt provides exception reporting and the
PI Data Archive or PIBufss provides data compression. Exception reporting and compression
are very important aspects of data collection and archiving, which are not discussed in this
document.

Note: See the PI Universal Interface (UniInt) User Guide and PI Data Archive
documentation for information on other attributes that are significant to PI point data
collection and archiving.

Tag

The Tag attribute (or tag name) is the name for a point. There is a one-to-one correspondence
between the name of a point and the point itself. Because of this relationship, PI System
documentation uses the terms “tag” and “point” interchangeably.
Follow these rules for naming PI points:
 The name must be unique in the PI Data Archive.
 The first character must be alphanumeric, the underscore (_), or the percent sign (%).
 Control characters such as linefeeds or tabs are illegal.
 The following characters also are illegal: * ’ ? ; { } [ ] | \ ` '‘"”

PI Interface for Foxboro I/A 70 Series 37


PI Point Configuration

Length
Depending on the version of the PI API and the PI Data Archive, this interface supports Tag
attributes whose length is at most 255 or 1023 characters. The following table indicates the
maximum length of this attribute for all the different combinations of PI API and
PI Data Archive versions.
PI API PI Data Archive Maximum Length
1.6.0.2 or later 3.4.370.x or later 1023
1.6.0.2 or later Earlier than 3.4.370.x 255
Earlier than 1.6.0.2 3.4.370.x or later 255
Earlier than 1.6.0.2 Earlier than 3.4.370.x 255

If the PI Data Archive version is earlier than 3.4.370.x or the PI API version is earlier than
1.6.0.2, and you want to use a maximum Tag length of 1023, you need to enable the PI SDK.
See Appendix B. PI SDK Options for information.

PointSource

The PointSource attribute contains a unique, single or multi-character string that is used to
identify the PI point as a point that belongs to a particular interface. For additional
information, see the /ps command-line parameter and the PointSource chapter.

PointType

Typically, device point types do not need to correspond to PI point types. For example,
integer values from a device can be sent to floating-point or digital PI points. Similarly, a
floating-point value from the device can be sent to integer or digital PI points, although the
values will be truncated.
Float16, float32, float64, int16, int32, digital, string point types are supported. For more
information on the individual point types, see the PI Data Archive manuals.

Location1

Location1 attribute associates a point with a particular copy of PI Foxboro. Location1 is a


positive integer from 100 to 9900, inclusive. Its value is 100 times the -–d= argument used in
the startup command file (described later).
For example, if –id=1, set Location1 to 100.
Any remainder of Location1/100 is not used.

Location2

The Location2 attribute determines whether the Interface adds the point to a FoxAPI data set
and retrieves “buffered” values from the FoxAPI. Buffered values are those updated by the
FoxAPI in the system-shared memory. Unbuffered access to I/A objects makes requests to
the Foxboro CP for each data retrieval call. OSIsoft recommends the use of buffered access to
reduce the load on the Foxboro system.

38
The value of Location2 is the PI list number. Set the value of Location2 to a positive
number to indicate that PI Foxboro should use buffered access to retrieve I/A data. For tags
with a common value of Location2, the Interface groups these tags into a list for use with the
FoxAPI scopen() call. This FoxAPI function returns a unique data set number, which may
be different than the Location2 value.
Tags for read values must be in a PI list that is separate from those tags for write values. To
help optimize the network traffic it is helpful to group tags referencing I/A objects from
different Foxboro CP modules into different PI lists.
Some customers have experienced performance problems when there are many (~250) tags in
a PI List. OSIsoft recommends keeping the size of a PI List within this number. However,
large numbers of small lists will take the interface a long time to open, so a compromise is
needed.
To indicate that the Interface should use unbuffered access to I/A objects, set Location2 to 0.
Access to I/A string data is always unbuffered. The interface will reject PI tags that are
configured for buffered access (Location2<>0) which have an I/A string data type
(Location3=4 or -4).
In summary,
I/A Data Access Method Location2
Unbuffered 0 (see note below)
Buffered >0 (PI list number)

Note: Using unbuffered access can negatively impact the performance of the interface,
and should be used sparingly. Under normal operations, unbuffered access does not
typically cause problems. But if the unbuffered I/A objects become unavailable (station
rebooted, network problems, etc), when the interface attempts to access those objects, it
will stop scanning the other tags until the FoxAPI calls time out. This will make the
interface ‘flat line’ during this period. To minimize the impact of this, the interface will
disable the regular scanning of any bad unbuffered tags found, but will periodically
attempt to re-read them.

Upon processing a PI list (i.e., points with a common positive Location2), the Interface enters
this list into the FoxAPI shared memory as a data set named PILISTxxLyyy. The first two
digits (xx) refer to the interface number as defined by the –id= startup parameter. The next
3 digits (yyy) refer to the Location2 number.
For example, for points with Location2 equal to 5 and processed by a copy of the Interface
running with –id=1, the FoxAPI data set named PILIST01L5 is created.

Location3

The Location3 attribute indicates the I/A data type and direction of data transfer. For the
transfer of data from the I/A to PI (input), Location3 is positive. Otherwise, it is negative.
A special case is used when Location3 equals zero (0). In this case, instead of storing the
value of the I/A object, it will use the I/A FoxAPI status. In this way, the object status can be
stored in the PI database. The status is a bit mapped integer. The definitions of the bits are
listed in Appendix E.

PI Interface for Foxboro I/A 70 Series 39


PI Point Configuration

Location3 I/A Type I/A Data Range


1 1, char ‘0’ to ‘9’
2 2, short integer -32768 to 32767
3 3, float 1.175E-38 to 3.402E+38
4 4, string up to 256 bytes
5 5, Boolean 0 and 1
6 6, long integer -2,147,483,648 to 2,147,483,647
8 8, short integer 0 to 255
9 9, packed boolean 0 to 65535
10 10, long packed boolean 0 to 4,294,967,295
0 FoxAPI object status

Examples
Location3 I/A Type Data Transfer
2 short integer I/A to PI
-3 float PI to I/A

However, regardless of the Location3 value, PI Foxboro checks with the FoxAPI to
determine the correct data type of the I/A object. The Interface writes to the PI Message Log
occurrences of point type mismatches and uses the correct type internally. The user should
then correct the value of Location3.
For output points (transfer of data from PI to the I/A), remember to configure an appropriate
output source point in the SourceTag attribute of the output PI point.
Because access to I/A string objects must use unbuffered access, the interface will reject PI
tags that are configured for buffered access (Location2<>0) which have an I/A string data
type (Location3=4 or -4).

Location4

Scan-based Inputs
For interfaces that support scan-based collection of data, Location4 defines the scan class for
the PI point. The scan class determines the frequency at which input points are scanned for
new values. For more information, see the description of the /f parameter in the Startup
Command File chapter.

Trigger-based Inputs, Unsolicited Inputs, and Output Points


Location4 should be set to zero for these points.

Location5

The Location5 attribute is normally 0. If it is non-zero, it is used to total a PI Foxboro list’s


I/A object change counts. Please refer to Appendix A: Error Messages and Troubleshooting
for details.

40
InstrumentTag

This sets the Foxboro tag name (also called the I/A object or C:B.P) to be accessed for
reading/writing from/to the I/A. It may contain up to 32 characters in the
compound:block.parameter (C:B.P) or alias formats. The full Foxboro name with the proper
case must be used.
If this field is empty, the ExDesc attribute (see below) determines the I/A object. If both the
InstrumentTag and ExDesc attributes contain an I/A object, then PI Foxboro uses the I/A
object specified in the InstrumentTag.

Length
Depending on the version of the PI API and the PI Data Archive, this interface supports an
InstrumentTag attribute whose length is at most 32 or 1023 characters. The following table
indicates the maximum length of this attribute for all the different combinations of PI API
and PI Data Archive versions.
PI API PI Data Archive Maximum Length
1.6.0.2 or later 3.4.370.x or later 1023
1.6.0.2 or later Earlier than 3.4.370.x 32
Earlier than 1.6.0.2 3.4.370.x or later 32
Earlier than 1.6.0.2 Earlier than 3.4.370.x 32

If the PI Data Archive version is earlier than 3.4.370.x or the PI API version is earlier than
1.6.0.2, and you want to use a maximum InstrumentTag length of 1023, you need to enable
the PI SDK. See Appendix B. PI SDK Options for information.

ExcDev / ExcDevPercent

These attributes specify the exception deviation in engineering units. An event is sent to the
PI Data Archive if the PI point value changes by more than the exception deviation.
For buffered points (location2>0), the exception deviation is also used to specify the delta
values used with the FoxAPI for the I/A object. The I/A controllers monitor the scanned
objects, but will only send an update to the FoxAPI if the value has changed by more than the
delta value. In this way, it is possible to filter noise from signals and reduce the load between
the controller and the FoxAPI.
If the change in value exceeds the delta and the new value is sent to the FoxAPI, then the
change will also be sufficient for the new value to be sent to the PI Data Archive.
Note: An ExcDev/ExcDevPercent value of zero should be avoided as the Foxboro
system will always send an update to the I/A shared memory on every scan (by default, is
this every 0.5 seconds), regardless of whether the value has changed or not. The loading
on the I/A system caused by these unnecessary updates can cause issues.

ExDesc

This is the Extended Descriptor field. It can be used to define a number of various actions for
the point. It can define the Foxboro tag to access, define bit mapped operations on a value,
define profile points, trigger the reading of the point when another PI point changes, or it can
define points to monitor performance of the interface itself.

PI Interface for Foxboro I/A 70 Series 41


PI Point Configuration

Anything after an exclamation mark (!) is ignored and can be as a comment.

Length
Depending on the version of the PI API and the PI Data Archive, this interface supports an
ExDesc attribute whose length is at most 80 or 1023 characters. The following table indicates
the maximum length of this attribute for all the different combinations of PI API and
PI Data Archive versions.
PI API PI Data Archive Maximum Length
1.6.0.2 or later 3.4.370.x or later 1023
1.6.0.2 or later Earlier than 3.4.370.x 80
Earlier than 1.6.0.2 3.4.370.x or later 80
Earlier than 1.6.0.2 Earlier than 3.4.370.x 80

If the PI Data Archive version is earlier than 3.4.370.x or the PI API version is earlier than
1.6.0.2, and you want to use a maximum ExDesc length of 1023, you need to enable the PI
SDK. See Appendix B, PI SDK Options for information.

Foxboro Tag (I/A Object)


For backward compatibility, the ExDesc can be used to define the Foxboro tag name (I/A
object) that the point will be accessing, in the same way that the InstrumentTag attribute does.
This was required because with older versions of the software, the InstrumentTag was limited
to 32 characters and this was not long enough for some object names.
However, with the current versions of the interface, the InstrumentTag can now handle all I/A
object names, and so it is recommended that the InstrumentTag should be used.

Bit Processing Keywords

BTM= Keyword
BTM=x,y,z... is an optional field for bit masking values retrieved from I/A integer types.
The bit mask is x,y,z... where x is the bit location in the source whose value is put in the
low order bit (0) in the target. Then y is the bit location in the source whose value is put in
the next bit (1) in the target. Up to 31 bits can be put in the target and unspecified target bits
are set to 0.
To define the bit positions to be used, the interface supports using either the bit number, from
0 to 31 (0=LSB and 31=MSB) or using the Foxboro notation of B1 to B32 (B1=MSB and
B32=LSB).
MSB

LSB
31
30
29
28
27
26
25
24
23
22
21
20
19
18
17
16
15
14
13
12
11
10
9
8
7
6
5
4
3
2
1
0
B10
B11
B12
B13
B14
B15
B16
B17
B18
B19
B20
B21
B22
B23
B24
B25
B26
B27
B28
B29
B30
B31
B32
B1
B2
B3
B4
B5
B6
B7
B8
B9

The command also supports inverting specific bits by starting the bit position with a tilde (~)
character.
An example is BTM=31,0,7,8.

42
This specification puts
 bit 31 (B1) of the source to bit 0 of the target
 bit 0 (B32) of the source to bit 1 of the target
 bit 7 (B25) of the source to bit 2 of the target
 bit 8 (BB24) of the source to bit 3 of the target
The resulting value then sent to the PI tag.
Another example is BTM=B23,B1,~B7,B8.
This specification puts
 bit 9 (B23) of the source to bit 0 of the target
 bit 31 (B1) of the source to bit 1 of the target
 inverted bit 25 (B7) of the source to bit 2 of the target
 bit 24 (B8) of the source to bit 3 of the target
The resulting value then sent to the PI tag.

PRI_BITS= Keyword
PRI_BITS=x,y,z… (priority bits) is an optional field that checks the list of specified bits and
returns the offset of the first matching bit. If there are no matching bits then it will return 0.
This can be used to convert a bitmapped status into a simple digital point.
The x,y,z bit positions are specified in the same way as the BTM bit positions above. It also
supports the inverting of bits using the tilde (~) character.
For example, to get the controller status of a PID block as a digital state, configure the PI
point as a digital that will read the .BLKSTA parameter from the block. Because BLKSTA is
a long packed Boolean, use Location3=10. Then use the following
PRI_BITS=B25,~B21,B2,B22
This will return the following states. Define a digital state set to match.
State Controller Status
0 Auto – none of the checked bits match
1 On Hold – Hold bit B25 is set
2 Manual – Manual/Auto bit is NOT set (bit is set when in auto)
3 Supervisory – Supervisory control bit B2 is set
4 Remote – Local/Remote bit B22 is set

Another example is to use the AIN ALMSTA parameter to convert the alarms into a single PI
digital point (instead of having one digital point for each possible alarm). Use the following
PRI_BITS=B10,B4,B7,B8,B15,B16,B3,B2
This will return the following state values. Define a digital state set to match.
State Alarm Status
0 No Alarms
1 Bad I/O
2 Out-of-Range
3 High-High Absolute
4 Low-Low Absolute

PI Interface for Foxboro I/A 70 Series 43


PI Point Configuration

5 High Absolute
6 Low Absolute
7 Inhibited
8 Unacknowledged

Use the Foxboro ICC Block manuals (B0193AX) for more information on the meanings of
the bits in the various long packed 44oolean parameters available in the different block types.

Performance Points
For UniInt-based interfaces, the extended descriptor is checked for the string
“PERFORMANCE_POINT”. If this character string is found, UniInt treats this point as a
performance point. See the section called Scan Class Performance Points.

Trigger-based Inputs
For trigger-based input points, a separate trigger point must be configured. An input point is
associated with a trigger point by entering a case-insensitive string in the extended descriptor
(ExDesc) PI point attribute of the input point of the form:
keyword=trigger_tag_name
where keyword is replaced by “event” or “trig” and trigger_tag_name is replaced by the
name of the trigger point. There should be no spaces in the string. UniInt automatically
assumes that an input point is trigger-based instead of scan-based when the
keyword=trigger_tag_name string is found in the extended descriptor attribute.
An input is triggered when a new value is sent to the Snapshot of the trigger point. The new
value does not need to be different than the previous Snapshot value to trigger an input, but
the timestamp of the new value must be greater than (more recent than) or equal to the
timestamp of the previous value. This is different than the trigger mechanism for output
points. For output points, the timestamp of the trigger value must be greater than (not greater
than or equal to) the timestamp of the previous value.
Conditions can be placed on trigger events. Event conditions are specified in the extended
descriptor as follows:
Event='’rigger_tag_name'’event_condition
The trigger tag name must be in single quotes. For example,
Event='’inusoid'’Anychange
will trigger on any event to the PI point sinusoid as long as the next event is different than the
last event. The initial event is read from the snapshot.
The keywords in the following table can be used to specify trigger conditions.
Event Description
Condition
Anychange Trigger on any change as long as the value of the current event is different
than the value of the previous event. System digital states also trigger events.
For example, an event will be triggered on a value change from 0 to “Bad
Input,” and an event will be triggered on a value change from “Bad Input” to 0.
Increment Trigger on any increase in value. System digital states do not trigger events.
For example, an event will be triggered on a value change from 0 to 1, but an
event will not be triggered on a value change from “Pt Created” to 0. Likewise,
an event will not be triggered on a value change from 0 to “Bad Input.”

44
Event Description
Condition
Decrement Trigger on any decrease in value. System digital states do not trigger events.
For example, an event will be triggered on a value change from 1 to 0, but an
event will not be triggered on a value change from “Pt Created” to 0. Likewise,
an event will not be triggered on a value change from 0 to “Bad Input.”
Nonzero Trigger on any non-zero value. Events are not triggered when a system digital
state is written to the trigger point. For example, an event is triggered on a
value change from “Pt Created” to 1, but an event is not triggered on a value
change from 1 to “Bad Input.”

Obsolete Keywords
Care must be taken when upgrading from previous versions of the interface as the ExDesc
keywords TRG=, SOURCE=, SRC=, RTN= and MSG=are no longer supported by the
interface.
If the interface loads a point with one of the above keywords, the interface will refuse to load
the point, and log an error message. The functionality of these keywords is supported using
other methods within the interface.
Obsolete Keyword Replacement
TRG= EVENT=
SOURCE= SourceTag attribute
SRC= SourceTag attribute
RTN= Output point holds result or output.
SourceTag attribute point contains value to be written
MSG= String PI point

UserInt1

Handling a Bad Status


The UserInt1 attribute, in conjunction with the BadStatusIndication key of the
fxbais.ini file, tells the Interface how to proceed if it receives a value for an I/A object
that has its bad bit (bit 8) set. Please see the Configuration File section of this manual
for more information.
If the value of BadStatusIndication is 0, then the Interface looks at an individual tag’s
UserInt1 point attribute field for information on how to proceed.

UserInt1 Value written to PI


1 Bad Input
2 I/A value, with PI questionable bit set (PI 3 only)
3 I/A value

The default value for BadStatusIndication is 1, and so the Interface writes Bad Input
when the I/A object’s bad bit is set, and the values of UserInt1 are not used.

Point-Specific Debug Messages


The UserInt1 field also causes the Interface to print point-specific debugging messages. If bit
12 of UserInt1 is set (add 4096 to the value), then the interface will output detailed debug
messages to the message log files. If bit 13 of UserInt1 is set (add 8192 to the value), then the
PI Interface for Foxboro I/A 70 Series 45
PI Point Configuration

interface will output changes to the IA status of the object to the message log files. Please
refer to the section Appendix A: Error and Informational Messages for details.

Scan

By default, the Scan attribute has a value of 1, which means that scanning is turned on for the
point. Setting the Scan attribute to 0 turns scanning off. If the Scan attribute is 0 when the
interface starts, a message is written to the log and the point is not loaded by the interface.
There is one exception to the previous statement.
If any PI point is removed from the interface while the interface is running (including setting
the Scan attribute to 0), SCAN OFF will be written to the PI point regardless of the value of
the Scan attribute. Two examples of actions that would remove a PI point from an interface
are to change the point source or set the Scan attribute to 0. If an interface-specific attribute is
changed that causes the point to be rejected by the interface, SCAN OFF will be written to the
PI point.

Shutdown

The Shutdown attribute is 1 (true) by default. The default behavior of the PI Shutdown
Subsystem is to write the SHUTDOWN digital state to all PI points when PI is started. The
timestamp that is used for the SHUTDOWN events is retrieved from a file that is updated by the
Snapshot Subsystem. The timestamp is usually updated every 15 minutes, which means that
the timestamp for the SHUTDOWN events will be accurate to within 15 minutes in the event of
a power failure. For additional information on shutdown events, refer to PI Data Archive
manuals.

Note: The SHUTDOWN events that are written by the PI Shutdown Subsystem are
independent of the SHUTDOWN events that are written by the interface when
the /stopstat=Shutdown command-line parameter is specified.

SHUTDOWN events can be disabled from being written to PI points when the PI Data Archive
is restarted by setting the Shutdown attribute to 0 for each point. Alternatively, the default
behavior of the PI Shutdown Subsystem can be changed to write SHUTDOWN events only for
PI points that have their Shutdown attribute set to 0. To change the default behavior, edit the
Shutdown.dat file, as discussed in the PI Data Archive manuals.

Bufserv and PIBufss


It is undesirable to write shutdown events when buffering is being used. Bufserv and PIBufss
are utility programs that provide the capability to store and forward events to a
PI Data Archive, allowing continuous data collection when the PI Data Archive is down for
maintenance, upgrades, backups, and unexpected failures. That is, when the PI Data Archive
is shutdown, Bufserv or PIBufss will continue to collect data for the interface, making it
undesirable to write SHUTDOWN events to the PI points for this interface. Disabling Shutdown
is recommended when sending data to a Highly Available PI Data Archive collective. Refer
to the Bufserv or PIBufss manuals for additional information.

46
DataSecurity

The PI identity in the PI trust that authenticates the interface must be granted read access by
the DataSecurity attribute of every PI point that the interface services. If the interface is used
without a buffering application, write access also must be granted. (If the interface is used
with a buffering application, the buffering application requires write access but the interface
does not.)

PtSecurity

The PI identity in the PI trust that authenticates the interface must be granted read access by
the PtSecurity attribute of every PI point that the interface services.

Output Points
Output points control the flow of data from the PI Data Archive to any destination that is
external to the PI Data Archive, such as a PLC or a third-party database. For example, to
write a value to a register in a PLC, use an output point. Each interface has its own rules for
determining whether a given point is an input point or an output point. There is no de facto PI
point attribute that distinguishes a point as an input point or an output point.

Security Note: When output points are required, implement an output point
whitelist, which provides a defense against accidental or malicious changes to the
control system.

Outputs are triggered for UniInt-based interfaces. That is, outputs are not scheduled to occur
on a periodic basis. There are two mechanisms for triggering an output.
As of UniInt 3.3.4, event conditions can be placed on triggered outputs. The conditions are
specified using the same event condition keywords in the extended descriptor as described
under Trigger-based Inputs Or described below. The only difference is that the trigger point
is specified with the SourceTag attribute instead of with the “event” or “trig” keywords.
Otherwise, the behavior of event conditions described under Trigger-based Inputs is identical
for output points. For output points, event conditions are specified in the extended descriptor
as follows:
event_condition
The keywords in the following table can be used to specify trigger conditions.
Event Description
Condition
Anychange Trigger on any change as long as the value of the current event is different
than the value of the previous event. System digital states also trigger events.
For example, an event will be triggered on a value change from 0 to “Bad
Input,” and an event will be triggered on a value change from “Bad Input” to 0.
Increment Trigger on any increase in value. System digital states do not trigger events.
For example, an event will be triggered on a value change from 0 to 1, but an
event will not be triggered on a value change from “Pt Created” to 0. Likewise,
an event will not be triggered on a value change from 0 to “Bad Input.”

PI Interface for Foxboro I/A 70 Series 47


PI Point Configuration

Event Description
Condition
Decrement Trigger on any decrease in value. System digital states do not trigger events.
For example, an event will be triggered on a value change from 1 to 0, but an
event will not be triggered on a value change from “Pt Created” to 0. Likewise,
an event will not be triggered on a value change from 0 to “Bad Input.”
Nonzero Trigger on any non-zero value. Events are not triggered when a system digital
state is written to the trigger point. For example, an event is triggered on a
value change from “Pt Created” to 1, but an event is not triggered on a value
change from 1 to “Bad Input.”

Trigger Method 1 (Recommended)

For trigger method 1, a separate trigger point must be configured. The output point must have
the same point source as the interface. The trigger point can be associated with any point
source, including the point source of the interface. Also, the point type of the trigger point
does not need to be the same as the point type of the output point.
The output point is associated with the trigger point by setting the SourceTag attribute of the
output point equal to the tag name of the trigger point. An output is triggered when a new
value is sent to the Snapshot of the trigger point. The new value does not need to be different
than the previous value that was sent to the Snapshot to trigger an output, but the timestamp
of the new value must be more recent than the previous value. If no error is indicated, then
the value that was sent to the trigger point is also written to the output point. If the output is
unsuccessful, then an appropriate digital state that is indicative of the failure is usually written
to the output point. If an error is not indicated, the output still may not have succeeded
because the interface may not be able to tell with certainty that an output has failed.

Trigger Method 2

For trigger method 2, a separate trigger point is not configured. To trigger an output, write a
new value to the Snapshot of the output point itself. The new value does not need to be
different than the previous value to trigger an output, but the timestamp of the new value
must be more recent than the previous value.
Trigger method 2 may be easier to configure than trigger method 1, but trigger method 2 has
a significant disadvantage. If the output is unsuccessful, there is no point to receive a digital
state that is indicative of the failure, which is very important for troubleshooting.

Output Point Whitelist

For enhanced security, create a "“hitelist"”of output points. When this feature is enabled, the
interface verifies that an output point is in the whitelist before updating the data source.
The whitelist file is a .csv (comma-separated values) file that contains a list of approved
output PI points and the attributes that associate the PI point with a writable value in the data
source. For this interface, the following attributes must be in the whitelist file to secure the
output points:
 Tag
 InstrumentTag
 ExDesc
48
 Location2
 Location3
The whitelist feature also supports range checking of output values. The Zero and Span
attributes in the whitelist file specify the minimum (zero) and maximum (sum of zero and
span) allowed for the output value.
To create and configure an output point whitelist, see the PI Universal Interface (UniInt)
User Guide.

Point Configuration Examples


The interface distribution contains point configuration examples in a comma-delimited file
(examples_pts.csv) for use with Microsoft Excel and the PI-SMT Tag Configurator add-
in.
The following table summarizes the various point configurations and the values for the
InstrumentTag, Sourcetag, and the Location attributes.

Loc2 Loc3 Loc4 Loc5 InstrumentTag SourceTag


Buffered >0 >0 >0 0 I/A object -
Inputs
Buffered >0 <0 >= 0* 0 I/A object PI value to be
Outputs written
Unbuffered 0 >0 >0 0 I/A object -
Inputs
Unbuffered 0 <0 0 0 I/A object PI value to be
Outputs written

*For Buffered Outputs, a positive Location4 value is needed to set an update rate for the
FoxAPI/AIM*API write lists. However, the Interface does not use this value and the output
event will trigger the interface to write to the FoxAPI/AIM*API. If Location4 = 0 then the
FoxAPI/AIM*API update rate will default to 10 seconds.

PI Interface for Foxboro I/A 70 Series 49


Chapter 9. Startup Command File

Command-line parameters can begin with a / or with a -. For example, the /ps=M and
-ps=M command-line parameters are equivalent.
For Windows, command file names have a .bat extension. The Windows continuation
character (^) allows for the use of multiple lines for the startup command. The maximum
length of each line is 1024 characters (1 kilobyte). The number of parameters is unlimited,
and the maximum length of each parameter is 1024 characters.
The PI Interface Configuration Utility (PI ICU) provides a tool for configuring the interface
startup command file.

Configuring the Interface with PI ICU

Note: PI ICU requires PI 3.3 or later.

The PI Interface Configuration Utility provides a graphical user interface for configuring PI
interfaces. If the interface is configured by the PI ICU, the batch file of the interface
(fxbais.bat) will be maintained by the PI ICU and all configuration changes will be kept
in that file and the PI Module Database. The procedure below describes the necessary steps
for using PI ICU to configure the fxbais interface.
From the PI ICU menu, select Interface, then NewWindows Interface Instance from EXE. A
window such as the following opens:

PI Interface for Foxboro I/A 70 Series 51


Startup Command File

Browse to the fxbais.exe executable file. Then, enter values for Host PI Server/Collective,
Point Source, and Interface ID#. Interface name as displayed in the ICU (optional) will have
PI- pre-pended to this name and it will be the display name in the services menu.
Click Add.
The following message should appear:

Note that in this example the host PI Data server is “msltest1”. To configure the interface to
communicate with a remote PI Data server, select Connections… on the PI ICU Interface
menu and select the default server. If the remote node is not present in the list of servers, it
can be added.
Once the interface is added to PI ICU, near the top of the main PI ICU window, the interface
Type should be fxbais. If not, use the drop-down box to change the interface Type to
fxbais.
Click Apply to enable the PI ICU to manage this instance of the fxbais interface.

The next step is to make selections in the interface-specific page (that is, “fxbais”) that
allows you to enter values for the startup parameters that are particular to the fxbais interface.

52
Since the fxbais interface is a UniInt-based interface, in some cases you will need to make
appropriate selections in the UniInt page, which configures UniInt features through the PI
ICU.
To set up the interface as a Windows service, use the Service page. This page allows
configuration of the interface to run as a service as well as starting and stopping of the
interface service. The interface can also be run interactively from the PI ICU. To do that,
select Start Interactive on the Interface menu.
For more detailed information on how to use the above-mentioned and other PI ICU pages
and selections, please refer to the PI Interface Configuration Utility user guide. The next
section describes the selections that are available from the fxbais page. Once selections have
been made on the PI ICU window, press the Apply button in order for PI ICU to make these
changes to the interface’s startup file.

fxbais Interface Page

Since the startup file of the fxbais interface is maintained automatically by the PI ICU, use
the fxbais page to configure the startup parameters and do not make changes in the file
manually. The following is the description of interface configuration parameters used in the
PI ICU Control and corresponding manual parameters.

PI Interface for Foxboro I/A 70 Series 53


Startup Command File

Configuration Tab

The PI Interface for Foxboro I/A 70 Series – ICU Control has various sections. A yellow text
box indicates that an invalid value has been entered, or that a required value has not been
entered.

Additional I/O Rate Counter Numbers


Because it is a UniInt-based interface, PI Foxboro supports the standard I/O Rate point. This
I/O Rate point measures the number of events per minute that the Interface sends to PI Data
Archive. However, PI Foxboro also allows the user to keep track of
the number of buffered outputs per minute that it sends to the I/A, (-ecout=#)
the number of unbuffered inputs per minute that it sends to PI Data Archive, and (-
ecuinp=#)
the number of unbuffered outputs per minute that it sends to the I/A. (-ecuout=#)
To enable these additional I/O Rate counters, select the appropriate check box (e.g., buffered
outputs). Then, enter an I/O Rate counter number in the text box next to the check box. This
number must be between 2 and 34, or between 51 and 200, inclusive.
Please note that the PI Foxboro ICU control merely supplies the appropriate command line
parameters to the startup command file. In order to fully enable these additional I/O Rate
points, the user must also
create these I/O Rate point on the PI Data Archive, and
edit the IORates.dat file to reference these I/O Rate points with the I/O Rate counter
numbers.

Failover
The PI Foxboro Interface may be run in a failover configuration. If a copy of the Interface is
configured as the Primary node, it is responsible for collecting data whenever it is running. If
a copy of the Interface is configured as the Secondary node, it collects data only after it
detects that the Primary node is not currently running.

54
There are many additional parameters that need to be configured in order for Failover to
work. These parameters are entered by editing the fxbais.ini configuration file.
Appendix B describes Failover in more detail.
(-failover=mode where mode=primary or secondary)

Bad Status Digital States

Bad Bit (bit 8) Set


Enabling this parameter allows the user to choose a different digital state to send to a PI tag
when its value has the bad bit set. Usually the interface will send “Bad Input” to the
corresponding PI tag. (-DOUBTFUL=digitalstate)

Connection Status Bit (5,6,7)


Enabling this parameter allows the user to choose a different digital state to send to a PI tag
when its connection status bits (5,6,7) are set to something other than “being scanned”(1).
Usually the interface will send “I/O Timeout” to the corresponding PI tag.
(-NO_CONNECT=digitalstate)

Outputs
To enable the PI Foxboro Interface to write data to the Foxboro, check the enable outputs
box. (-write)

Configuration file

Edit fxbais.ini
This button allows the user to edit the fxbais.ini file from the ICU Control using Notepad.

Additional Parameters
This section is provided for any additional parameters that the current ICU Control does not
support.

Debug Settings Tab


To troubleshoot anomalous behavior of the Interface, one or more debugging parameters may
be enabled. These parameters tell the Interface to print informational messages to the PI
Message Log.

PI Interface for Foxboro I/A 70 Series 55


Startup Command File

These debugging parameters should not be used during the normal operation of the Interface.

Opening Data Sets


Enabling this parameter tells the Interface to print information regarding the return status of
the FoxAPI scopen() function. The Interface uses scopen() when it encounters PI points
whose Location2 value is positive. (-fdb=11)

Setup of Profile Library Tags


Enabling this parameter tells the Interface to print information when there is a point
configured as a profile trigger point. (-fdb=12)

Reading Profile Library Tags


Enabling this parameter tells the Interface to print information regarding the profile values
read via the FoxAPI function Praryrdel().(-fdb=13)

PI Server Time Offset


Enabling this parameter tells the Interface to print information regarding time offset between
the computer running the Interface and the computer running PI Data Archive. The Interface
prints this information every 10 minutes. (-fdb=15)

Point Loading
Enabling this parameter tells the Interface to print detailed information regarding points that it
has either loaded or not loaded. (-fdb=16)

Shutdown
Enabling this parameter tells the Interface to print information regarding shutdown signals
received. In addition, the Interface displays a message when it tells the FoxAPI to close a data
set. (-fdb=17)

56
Close All Data Sets
Unlike other debugging parameters, this one modifies the behavior of the Interface. Enabling
this parameter tells the Interface to close all FoxAPI data sets, even those that it did not open.
(-fdb=18)

Buffered Outputs
Enabling this parameter tells the Interface to print a message when a buffered output fails.
(-fdb=19)

Outputs in General
Enabling this parameter tells the Interface to print information regarding outputs. Enable this
parameter if there are problems with using PI Foxboro to send data from PI to the I/A.
(-fdb=21)

Detailed Data Set Opening


Enabling this parameter tells the Interface to print detailed information regarding the return
status of the FoxAPI scopen() function. The Interface uses scopen() when it encounters
PI points whose Location2 value is positive. (-fdb=24)

Log message for dev_hibernate()


Enabling this parameter tells the Interface to print a message when the dev_hibernate()
function is entered and exited. Typically, this function will be called several times a second
and so can quickly fill the log files and should be used with caution. To reduce the frequency
that dev_hibernate() is called, the HibernateDelay parameter in the fxbais.ini file can be
increased. (-fdb=25)

Log message for dev_service_input_list()


Enabling this parameter tells the Interface to print a message when the
dev_service_input_list() function is entered and exited. This function is called when each of
the scan classes needs to be processes and so can quickly fill the log files and should be used
with caution. (-fdb=26)

Detailed info on each FoxAPI call made by Int.


Enabling this parameter tells the Interface to print detailed information about each call made
to the FoxAPI. This will generate a lot of messages and will quickly fill the log files and
should be used with caution. (-fdb=27)

Log “Out of Service” and “Return to Service”


Enabling this parameter tells the Interface to log the “Out of Service” and “Return to Service”
messages for each of the I/A objects as they change status. By default, the interface will not
log these messages as they can fill the log files quickly when I/A compounds are turned off
and on. For troubleshooting of bad inputs, it may be necessary to log this status information.
(-fdb=28)

PI Interface for Foxboro I/A 70 Series 57


Startup Command File

Command-line Parameters

Note: The PI Universal Interface (UniInt) User Guide includes details about other
command-line parameters, which may be useful.

Parameter Description
/CacheMode Required for disconnected startup operation. If defined, the
Required when using /CacheMode startup parameter indicates that the interface will
disconnected startup be configured to utilize the disconnected startup feature.
Default: Not Defined
/CachePath=path Used to specify a directory in which to create the point caching
Optional files. The directory specified must already exist on the target
machine. By default, the files are created in the same location as
Default: Not Defined
the interface executable.
If the path contains any spaces, enclose the path in quotes.
Examples:
/CachePath=D:\PIPC\Interfaces\CacheFiles
/CachePath=D:/PIPC/Interfaces/CacheFiles
/CachePath=D:/PIPC/Interfaces/CacheFiles/

Examples with space in path name:


/CachePath="”:\Program Files\PIPC\MyFiles"”/
CachePath="”:/Program Files/PIPC/MyFiles"”/C
achePath="”:/Program Files/PIPC/MyFiles/"”

/CacheSynch=# NOTE: Care must be taken when modifying this parameter. This
Optional value must be less than the smallest scan class period defined with
the /f parameter. If the value of the /CacheSynch parameter
Default: 250 ms
is greater than the scan class value, input scans will be missed
while the point cache file is being synchronized.
The optional /CacheSynch=# startup parameter specifies the
time slice period in milliseconds (ms) allocated by UniInt for
synchronizing the interface point cache file with the
PI Data Archive. By default, the interface will synchronize the point
cache if running in the disconnected startup mode. UniInt allocates
a maximum of # ms each pass through the control loop
synchronizing the interface point cache until the file is completely
synchronized.
Synchronization of the point cache file can be disabled by setting
the value /CacheSynch=0. The minimum synchronization
period when cache synchronization is enabled is 50ms and the
maximum synchronization period is 3000ms (3s). Period values of
1 to 49 will be changed by the interface to the minimum of 50ms
and values greater than 3000 will be set to the maximum interval
value of 3000ms.
Default: 250 ms
Range: {0, 50 – 3000} time in milliseconds
Example: /CacheSynch=50 (use a 50ms interval)
/CacheSynch=3000 (use a 3s interval)
/CacheSynch=0 (do not synchronize the cache)

58
Parameter Description
/doubtful=digstate When the Interface receives a value for an I/A object that has its
Optional; seldom used bad bit (bit 8) or out-of-service bit (bit 11) set, it usually writes the
Bad Input digital state to the corresponding PI tag. (See the
discussion on BadStatusIndication above.) To write
another digital state, use the –doubtful parameter and specify
another digital state. For example,
/doubtful=”Invalid Data”
Notice quotation marks are used if the digital state contains a
space.
/ec=# The first instance of the /ec parameter on the command-line is
Optional used to specify a counter number, #, for an I/O Rate point. If the #
is not specified, then the default event counter is 1. Also, if the /ec
parameter is not specified at all, there is still a default event
counter of 1 associated with the interface. If there is an I/O Rate
point that is associated with an event counter of 1, every interface
that is running without /ec=# explicitly defined will write to the
same I/O Rate point. Either explicitly define an event counter other
than 1 for each instance of the interface or do not associate any I/O
Rate points with event counter 1. Configuration of I/O Rate points
is discussed in the section called I/O Rate Point.
For interfaces that run on Windows nodes, subsequent instances
of the /ec parameter may be used by specific interfaces to keep
track of various input or output operations. Subsequent instances
of the /ec parameter can be of the form /ec*, where * is any
ASCII character sequence. For example, /ecinput=10,
/ecoutput=11, and /ec=12 are legitimate choices for the
second, third, and fourth event counter strings.
/ecout=# The /ecout parameter specifies the I/O Rate counter number for
Optional measuring the rate of buffered outputs from PI to the I/A. The value
of x should be between 2 and 34, inclusive, or 51 and 200,
inclusive.
This I/O Rate counter can NOT be configured using the ICU under
Windows. Please use the methods described in the section
“Configuring I/O Rate Points Manually”.
/ecuinp=# The /ecuinp parameter specifies the I/O Rate counter number
Optional for measuring the rate of unbuffered inputs from the I/A to PI. The
value of x should be between 2 and 34, inclusive, or 51 and 200,
inclusive.
This I/O Rate counter can NOT be configured using the ICU under
Windows. Please use the methods described in the section
“Configuring I/O Rate Points Manually”.
/ecuout=# The /ecuout parameter specifies the I/O Rate counter number
Optional for measuring the rate of unbuffered outputs from PI to the I/A. The
value of x should be between 2 and 34, inclusive, or 51 and 200,
inclusive.
This I/O Rate counter can NOT be configured using the ICU under
Windows. Please use the methods described in the section
“Configuring I/O Rate Points Manually”.
/f=SS.## The /f parameter defines the time period between scans in terms
or of hours (HH), minutes (MM), seconds (SS) and sub-seconds (##).
/f=SS.##,ss.## The scans can be scheduled to occur at discrete moments in time
with an optional time offset specified in terms of hours ( hh),
or
minutes (mm), seconds (ss), and sub-seconds (##). If HH and MM
/f=HH:MM:SS.## are omitted, then the time period that is specified is assumed to be
or in seconds.
/f=HH:MM:SS.##,
PI Interface for Foxboro I/A 70 Series 59
Startup Command File

Parameter Description
hh:mm:ss.## Each instance of the /f parameter on the command-line defines a
scan class for the interface. There is no limit to the number of scan
Required for reading scan- classes that can be defined. The first occurrence of the /f
based inputs parameter on the command-line defines the first scan class of the
interface; the second occurrence defines the second scan class,
and so on. PI Points are associated with a particular scan class via
the Location4 PI Point attribute. For example, all PI Points that
have Location4 set to 1 will receive input values at the frequency
defined by the first scan class. Similarly, all points that have
Location4 set to 2 will receive input values at the frequency
specified by the second scan class, and so on.
Two scan classes are defined in the following example:
/f=00:01:00,00:00:05 /f=00:00:07
or, equivalently:
/f=60,5 /f=7
The first scan class has a scanning frequency of 1 minute with an
offset of 5 seconds, and the second scan class has a scanning
frequency of 7 seconds. When an offset is specified, the scans
occur at discrete moments in time according to the formula:
scan times = (reference time) + n(frequency) + offset
where n is an integer and the reference time is midnight on the day
that the interface was started. In the above example, frequency is
60 seconds and offset is 5 seconds for the first scan class. This
means that if the interface was started at 05:06:06, the first scan
would be at 05:07:05, the second scan would be at 05:08:05, and
so on. Since no offset is specified for the second scan class, the
absolute scan times are undefined.
The definition of a scan class does not guarantee that the
associated points will be scanned at the given frequency. If the
interface is under a large load, then some scans may occur late or
be skipped entirely. See the section “Performance Summaries” in
the PI Universal Interface (UniInt) User Guide for more information
on skipped or missed scans.
Sub-second Scan Classes
Sub-second scan classes can be defined on the command-line,
such as
/f=0.5 /f=00:00:00.1
where the scanning frequency associated with the first scan class
is 0.5 seconds and the scanning frequency associated with the
second scan class is 0.1 of a second.
Similarly, sub-second scan classes with sub-second offsets can be
defined, such as
/f=0.5,0.2 /f=1,0
Wall Clock Scheduling
Scan classes that strictly adhere to wall clock scheduling are now
possible. This feature is available for interfaces that run on
Windows and/or UNIX. Previously, wall clock scheduling was
possible, but not across daylight saving time. For example,
/f=24:00:00,08:00:00 corresponds to 1 scan a day starting
at 8 AM. However, after a Daylight Saving Time change, the scan
would occur either at 7 AM or 9 AM, depending upon the direction
of the time shift. To schedule a scan once a day at 8 AM (even
across daylight saving time), use
/f=24:00:00,00:08:00,L. The ,L at the end of the scan
class tells UniInt to use the new wall clock scheduling algorithm.
/failover=x Specify /failover=primary or /failover=secondary
Optional to run the Interface in a failover configuration. There are many

60
Parameter Description
additional parameters that need to be configured in order for
Failover to work. Enter these parameters by editing the
fxbais.ini configuration file. Appendix B describes Failover in
more detail.
/fdb=#,#,#,… To troubleshoot anomalous behavior of the Interface, enable one
Optional or more debugging parameters via /fdb. These parameters tell
the Interface to print informational messages to the PI Message
log.
The following are a list of the debug flags that can be set.
11 – Additional messages when opening lists of tags
12 – Setup of tags used with the libprofplot.so library
13 – Reading of data using libprofplot.so function calls
15 – Time offset between the PI Data Archive and the Interface
16 – Verbose messages during point loading
17 – Verbose messages during Interface shutdown
18 – Extra attempts to locate and close data sets. Unlike other
debugging values, this one affects the behavior of the Interface. If
/fdb=18 is specified, the Interface will close all data sets, even
those that it did not open.
19 – Messages for buffered outputs
20 – Messages for unbuffered outputs
21 – Messages for outputs in general
24 – Detailed error status after an scopen() call
25 – Log messages when interface enters and leaves
dev_hibernate()
26 – Log messages when interface enters and leaves
dev_service_input_list()
27 – Detailed information on each FoxAPI call made by the
interface
28 – Log “Out of service” and “Return to Service” status messages
For example, /fdb=16 will cause additional messages to be
logged when a point is loaded by the interface.
/host=host:port The /host parameter specifies the PI Data Archive node.
Required for Windows and Host is the IP address or the domain name of the PI Data Archive
UNIX node.
Port is the port number for TCP/IP communication. The port is
always 5450. It is recommended to explicitly define the host and
port on the command-line with the /host parameter.
Nevertheless, if either the host or port is not specified, the interface
will attempt to use defaults.

Examples:

The interface is running on an interface node, the domain name of


the PI Data Archive node is Marvin, and the IP address of Marvin is
206.79.198.30. Valid /host parameters would be:
/host=marvin
/host=marvin:5450
/host=206.79.198.30
/host=206.79.198.30:5450

PI Interface for Foxboro I/A 70 Series 61


Startup Command File

Parameter Description
/id=x The /id parameter is used to specify the interface identifier.
Highly Recommended The interface identifier is a string that is no longer than 9
characters in length. UniInt concatenates this string to the header
that is used to identify error messages as belonging to a particular
interface. See Appendix A Error and Informational Messages for
more information.
UniInt always uses the /id parameter in the fashion described
above. This interface also uses the /id parameter to identify a
particular interface instance number that corresponds to an integer
value that is assigned to one of the Location code point attributes,
most frequently Location1. For this interface, use only numeric
characters in the identifier. For example,
/id=1
/no_connect= When the Interface receives a value for an I/A object that has its
digstate object connection status bits (bits 5, 6, or 7) set to something other
than “being scanned” (1), it writes the IO Timeout digital state
Optional; seldom used
to the corresponding PI tag. To write a different digital state, use
the /no_connect parameter and specify another digital state.
For example,
/no_connect=”Not Connect”
Notice quotation marks are used if the digital state contains a
space.
/PISDK=# The /pisdk parameter can be used to enable or disable the PI
Optional SDK in some situations. Use /pisdk=1 to enable the PI SDK.
Default = 0 Use /pisdk=0 to disable the PI SDK. If a particular interface
requires the PI SDK, then the PI SDK will always be enabled and
the /pisdk parameter will be ignored.

Note: If the interface is running on an interface node with


the PI API version 1.6.x or later and the version of the
PI Data Archive is 3.4.370.x or later, the interface will ignore
the /pisdk parameter and the SDK will not be used to
retrieve point attributes.

/ps=x The /ps parameter specifies the point source for the interface. X
Required is not case sensitive and can be any multiple character string. For
example, /ps=P and /ps=p are equivalent. The length of X is
limited to 100 characters by UniInt. X can contain any character
except ‘*’ and ‘?’.
The point source that is assigned with the /ps parameter
corresponds to the PointSource attribute of individual PI Points.
The interface will attempt to load only those PI points with the
appropriate point source.
If the PI API version being used is earlier than 1.6.x or the
PI Data Archive version is earlier than 3.4.370.x, the PointSource is
limited to a single character unless the SDK is being used.

62
Parameter Description
/sio The /sio parameter stands for “suppress initial outputs.” The
Optional parameter applies only for interfaces that support outputs. If the
/sio parameter is not specified, the interface will behave in the
following manner.
When the interface is started, the interface determines the current
Snapshot value of each output point. Next, the interface writes this
value to each output point. In addition, whenever an individual
output point is edited while the interface is running, the interface
will write the current Snapshot value to the edited output point.
This behavior is suppressed if the /sio parameter is specified on
the command-line. That is, outputs will not be written when the
interface starts or when an output point is edited. In other words,
when the /sio parameter is specified, outputs will only be written
when they are explicitly triggered.
/stopstat=digstate If /stopstat=digstate is present on the command line, then
or the digital state, digstate, will be written to each PI point when
/stopstat the interface is stopped. For a PI Data Archive, digstate must
be in the system digital state table. UniInt will use the first
occurrence of digstate found in the table.
/stopstat only is
If the /stopstat parameter is present on the startup command
equivalent to
line, then the digital state Intf Shut will be written to each PI
/stopstat="”ntf
point when the interface is stopped.
Shut"”
If neither /stopstat nor /stopstat=digstate is specified
Optional
on the command line, then no digital states will be written when the
Default = no digital state interface is shut down.
written at shutdown.
Examples:
/stopstat=shutdown
/stopstat="”ntf Shut"”The entire digstate value must be
enclosed within double quotes when there is a space in digstate.
/uht_id=# The /uht_id=# command-line parameter is used to specify a
Optional unique ID for interfaces that are run in a redundant mode without
Required if any type of using the UniInt failover mechanism. There are several OSIsoft
failover other than UniInt interfaces that are UniInt based and implement their own version of
failover phase 1 or 2 is failover. In order for health point(s) to be configured to monitor a
supported. single copy of the Interface, an additional parameter is required. If
the /uht_id=# is specified; only health points with a Location3
value equal to # will be loaded.
/write The /write parameter enables the Interface to send data from
Optional PI to the I/A. If the /write parameter is omitted; the Interface
does not load output points.

PI Interface for Foxboro I/A 70 Series 63


Startup Command File

Sample fxbais.bat File


The following is an example file:
REM===============================================================
REM
REM fxbais.bat
REM
REM Sample startup file for the PI Interface for Foxboro I/A 70 Series
REM
REM===============================================================
REM
REM OSIsoft strongly recommends using PI ICU to modify startup files.
REM
REM Sample command line
REM
.\fxbais /host=XXXXXX:5450 /ps=fxbais /id=1 /f=2,0 /f=2,1 /f=10
REM
REM End of fxbais.bat File

64
fxbais.ini Configuration File
The behavior of PI Foxboro may be further customized by creating a configuration file called
fxbais.ini. This file is not needed for normal interface operation. Use this file only if
special behavior is needed for the Interface.
This fxbais.ini file resides in the same directory as the interface executable fxbais.exe.
The contents of fxbais.ini should have the following format:
[fxbais-1]
; comment lines begin with a semi-colon
; lines in this file have the format
; key=value
;
; BadStatusIndication=1
; FirstSetReopen=60
; SetReopen=24
; EditSetReopen=35
; HibernateDelay=100
; DebugFlags=11,12
;
; The following keys are used for failover
;
; failover_peer=casaba
; fail_time=4
; watchdog=PI_COMM:PI_WATCHDOG.LI01
; failover_status=fx:coll
The [fxbais-1] section indicates that the entries below it pertain to the copy of PI Foxboro
running with –id=1. (For a copy of PI Foxboro running with –id=2, put in a section called
[fxbais-2], and so on.)
The following sections describe the meaning of the different keys and their values. Details on
the failover variables are in section “Appendix C: Failover Support”.

PI Interface for Foxboro I/A 70 Series 65


Startup Command File

BadStatusIndication
The BadStatusIndication key tells the Interface how to proceed if it receives a value for
an I/A object that has its bad bit (bit 8) set. The following table describes the behavior:
BadStatusIndication Value written to PI
0 Action controlled on a tag-by-tag basis, using the value of PI
tag UserInt1 attribute.
1 Bad Input
2 I/A value, with PI questionable bit set (PI 3 only)
3 I/A value

If the value of BadStatusIndication is 0, then the Interface looks at an individual tag’s


UserInt1 point attribute field for information on how to proceed.

UserInt1 Value written to PI


0 or 1 Bad Input
2 I/A value, with PI questionable bit set (PI 3 only)
3 I/A value

The default value for BadStatusIndication is 1. That is, the Interface writes Bad Input
when the I/A object’s bad bit (bit 8) or out-of-service bit (bit 11) is set, and the value of
UserInt1 attribute is not used.

FirstSetReopen / SetReopen
When an attempt by PI Foxboro to open a FoxAPI data set fails, the Interface will try to
reopen this data set after FirstSetReopen seconds and again every SetReopen hours.
Fractional values for SetReopen are allowed. To prevent the reopening of a set, enter a
value of 0 for either FirstSetReopen or SetReopen. The default value is 0 (disabled) for
both entries.

EditSetReopen
If a tag that is part of a FoxAPI data set is edited, the Interface waits EditSetReopen
seconds before closing and reopening the set. The default value of EditSetReopen is 35
seconds.

HibernateDelay
After it has finished opening all its data sets, the Interface waits HibernateDelay
milliseconds before checking the I/A for new values. The default value of HibernateDelay
is 100 milliseconds.

DebugFlags
Contains a list of comma separated values used to enable different types of debug messages
within the interface. This is the same as the –fdb= command-line arguments.
The recognized debug values are:
11 – Additional messages when opening lists of tags
12 – Setup of tags used with the libprofplot.so library
13 – Reading of data using libprofplot.so function calls

66
15 – Time offset between the PI Data Archive and the Interface
16 – Verbose messages during point loading
17 – Verbose messages during Interface shutdown
18 – Extra attempts to locate and close data sets. Unlike other debugging values, this one
affects the behavior of the Interface. If –fdb=18 is specified, the Interface will close all
data sets, even those that it did not open.
19 – Messages for buffered outputs
20 – Messages for unbuffered outputs
21 – Messages for outputs in general
24 – Detailed error status after an scopen() call
25 – Log messages when interface enters and leaves dev_hibernate()
26 – Log messages when interface enters and leaves dev_service_input_list()
27 – Detailed information on each FoxAPI call made by the interface
28 – Log “Out of service” and “Return to Service” status messages

PI Interface for Foxboro I/A 70 Series 67


Chapter 10. Interface Failover Configuration

Introduction
In order to achieve continuous transfer of data between the Foxboro I/A and the PI Data
Archive, two copies of the PI Foxboro interface program may be run, each on a different
Foxboro AW workstation. The AW workstations may be either AW50 Series (Solaris) or
AW70 Series (Windows) models or one of each.
In a failover configuration, one copy of the interface is designated as PI Foxboro-Primary and
the other as PI Foxboro-Secondary. The Primary program is responsible for data collection
during the vast majority of the time.

However, should the Primary program terminate, the Secondary program automatically
assumes responsibility for transferring data between the I/A and PI.

PI Interface for Foxboro I/A 70 Series 69


Interface Failover Configuration

When the Primary program restarts, the Secondary program automatically stops data
collection. The transfer of data between the I/A and PI again becomes the responsibility of
the Primary.

70
Parameters for Operation

PI ICU
To designate that PI Foxboro is running in a failover configuration, check the “Enable
Failover” option, select Primary or Secondary and enter a value for the UniInt Health Tag ID.

The primary and secondary instances of the interface must have different Health Tag ID
values, so they will not attempt to overwrite the others health tag data. See the “UniInt Health
Points” below for more details.

Command Line
To designate that PI Foxboro is running in a failover configuration, provide the
-failover parameter on the interface command line. Specifically, run the copies of the
interface as
$ fxbais –ps=F –id=1 –failover=primary ...
on one machine and
$ fxbais –ps=F –id=1 –failover=secondary ...
on the other.

Initialization File
When PI Foxboro encounters the –failover option on the command line, it looks for other
failover-related parameters in the initialization file fxbais.ini. In particular, the Interface
needs to know
 machine is running the other instance of PI Foxboro
 maximum time that the user can tolerate neither copy of PI Foxboro collecting data
 name of the watchdog object on the I/A (to be described later)
 name of the PI tag that tracks the failover data collection status (also described later)
The following contents of fxbais.ini provide an example of how to specify the above
information:
[fxbais-1]
failover_peer=LBUG02
fail_time=2
watchdog=PI_COMM:PI_WATCHDOG.LI01
failover_status=FX_FAILOVER_PRI

PI Interface for Foxboro I/A 70 Series 71


Interface Failover Configuration

The section [fxbais-1] indicates that the entries below it pertain to the copy of PI Foxboro
running with –id=1. If PI Foxboro runs with –id=2, edit the fxbais.ini file and create a
section called [fxbais-2].
The value of the entry for failover_peer indicates the name of the workstation that is
running the other instance of PI Foxboro. The AW running the present copy of PI Foxboro
must be able to communicate to this other (peer) workstation via TCP/IP. To confirm, run the
standard ping command.
$ ping LBUG02
Alternatively, specify an IP address (in dotted-decimal form) for the failover_peer value.
[fxbais-1]
failover_peer=151.128.8.65
Confirm the communication between the two machines via TCP/IP by running ping.
$ ping 151.128.8.65
The value of the entry for fail_time indicates the maximum time in minutes for the
Secondary to wait before assuming data collection. In this example, at most 2 minutes will
elapse from the time that the Primary terminates to the time that the Secondary automatically
starts data collection. A value of fail_time that is too small (e.g., 1) can cause the
Secondary to start data collection even though the Primary is still collecting data. The
minimum fail_time will vary depending on the performance of the FoxAPI and the I/A
system. Because some FoxAPI calls can take some time to complete (opening lists etc) and
the interface is not able to check or update the watchdog when it waiting for the FoxAPI, the
FoxAPI delays are the limiting factor when setting fail_time.
The value of the watchdog entry is the name of the object residing on the Foxboro I/A.
The value of the failover_status entry is the name of a PI tag that keeps track of the
operational state of the failover configuration. Both of these items are described later.

I/O Rate Points


If the failover interfaces are to use iorates event counters then they require two sets of I/O
Rate points. The Primary uses one set of event counter PI points while the Secondary uses the
other. If both interface were to write to the same set of event counter PI points, then the
results would be of no use.
The Primary and Secondary copies of PI Foxboro may use the same –ec= command line
parameter, but the entries for the PI tag names in the iorates.dat file must be different.
For example, on the Primary machine the iorates.dat file may contain
syfxbais.in1,31
syfxbais.out1,32
and on the Secondary machine, the iorates.dat file may contain
syfxbais.in2,31
syfxbais.out2,32
Note that although both instances the primary and secondary interface would use
-ec=31 –ecout=32, because of the different iorates.dat files, the interfaces would write to
different PI points, as required.
72
An alternative configuration would be to use the same iorates.dat file which defined all the
iorates points on both machines, but use different –ec= and –ecout= parameters.
For example, both machines could use the iorates.dat file
syfxbais.in1,31
syfxbais.out1,32
syfxbais.in2,33
syfxbais.out2,34
And then the primary interface would use –ec=31 –ecout=32 and the secondary would use
–ec=33 –ecout=34.

UniInt Health Points


To use UniInt health points with interface failover, it is necessary to have two sets of health
points. One set of health points for the primary interface and another set of health points for
the second.
For an interface to be able to identify the points that it will update, the location3 attribute is
set to different values for each interface and the Health Tag ID: –uht_id= argument is used
to filter the tags loaded by the interface.

For example, the UniInt health points for the primary interface may have location3=1 and
the secondary interface have location3=2. Then the primary interface would be started with
-failover=primary –uht_id=1
and secondary interface would be started with
-failover=secondary –uht_id=2.
The value used must be greater than zero and must match the location3 value for that PI
tags.
For details on the data available from the UniInt health points, please refer to the UniInt
Interface User Manual.

Design Details

Watchdog Object on I/A


The failover feature of PI Foxboro relies on a watchdog object, which must be created on the
I/A before execution of the PI Foxboro programs. This object must be a Long Integer (I/A
Type 6).

PI Interface for Foxboro I/A 70 Series 73


Interface Failover Configuration

It is recommended that a CALC block be built (no program steps need to be configured) on
the I/A control database, and the LI01 parameters of the block used by the interface as the
failover watchdog object.
It provides the main method of communications between the Primary and Secondary
programs regarding the responsibility of data transfer between the I/A and PI. At startup, if PI
Foxboro cannot access the watchdog object, it exits.
During normal operation (i.e., when the Primary is collecting data), the Primary program
periodically writes to this watchdog object. The value written is between 110 and 115, and
increases monotonically. When the value reaches 115, it rolls back to 110.
At specific intervals, the Secondary program reads the value of the watchdog object. When it
determines that the value of the watchdog object has stopped changing, it sends a message via
UDP to the Primary. If it does not get a response from the Primary, it concludes that the
Primary program is not running. The Secondary program then starts transferring data between
the I/A and PI.
While the Secondary program is collecting data, it writes periodically to the watchdog object
a value between 210 and 215. However, before every write, it reads the value of the watchdog
object. It checks to see whether this value is 10 (scenario to be described below).
When the Primary program is re-started, it writes a value of 10 to the watchdog object,
indicating that it wishes to resume data collection. When the Secondary program sees that the
watchdog object has a value of 10, it stops collecting data, and writes a value of 20 to the
watchdog object.
When the Primary sees that the watchdog object has a value of 20, it begins data collection
and writes values of 110 through 115. At this point, the default configuration exists – the
Primary is collecting data and the Secondary is in standby mode.
Other scenarios are described in a later section.

Meaning of Watchdog I/A Object Values


Written by the Primary:
15 Primary wants to start/resume collecting data
110 – 115 Primary is currently collecting data
Written by the Secondary:
20 Primary should go ahead and start/resume collecting data
210 – 215 Secondary is currently collecting data

Prevention of Simultaneous Data Collection


The Interface has various safeguards to preclude simultaneous data collection by the Primary
and the Secondary. If after writing a value of 10 to the watchdog object, the Primary reads
this same value back, it then assumes that the Secondary is not collecting data. (Otherwise, it
would have read 210-215). However, in order to be certain, the Primary sends a message via
UDP to the Secondary to confirm. If the Secondary replies that it is collecting data, the
Primary writes a value of 10 again. Otherwise, the Primary begins data collection.
On the Secondary side, if after determining that the value of the watchdog object has stopped
changing, the Secondary assumes that the Primary is not running (and hence not collecting
data). However, in order to be certain, the Secondary sends a message via UDP to the
74
Primary to confirm. If the Primary replies that it is collecting data, the Secondary remains in
standby mode. Otherwise, the Secondary begins data collection.

FoxAPI/AIM*API Functions Used


The FoxAPI/AIM*API function used in writing a value to the watchdog object is uwrite().
For reading, it is uread(). The periodic time interval for these calls is one-half of the user
specified fail_time value. For example, if the failover time is set at 4 minutes, and both
programs are running, the Primary program calls uwrite() once every 2 minutes and the
Secondary program calls uread() once every 2 minutes.

PI Failover Status Point


Within the fxbais.ini file, one of the mandatory entries is failover_status. This
specifies a PI digital point that the interface will write to current failover status of the
interface to. Each instance of the interface should have a different failover status point to
write to.
For example, if the primary interface was to write its status to a PI point FX_FAILOVER_PRI
and the secondary interface was to write to FX_FAILOVER_SEC, then the fxbais.ini on the
primary interface node would contain
[fxbais-1]
failover_status=FX_FAILOVER_PRI
and the secondary interface node, fxbais.ini man contain
[fxbais-1]
failover_status=FX_FAILOVER_SEC
The failover status points should be created with the following attributes,
Attribute Details
Tag Tag name that appears in the fxbais.ini failover_status entry
Point Source L (or Lab)
Compressing Off
ExcDev/ExcDevPercent 0.0
PointType Digital
DigitalSet FXBAIS_FAILOVER
Descriptor Interface name + “ Failover Status”

The digital set FXBAIS_FAILOVER should have the following states


Value State Text Meaning
0 Stopped Interface is not running
1 1Init Primary wants to start data collection
2 1Collect Primary is the most recent program that collected data
3 1Exit After data collection, Primary exited normally
4 2Standby Secondary wants to start data collection
5 2Collect Secondary is the most recent program that collected data
6 2Exit After data collection, Secondary exited normally

PI Interface for Foxboro I/A 70 Series 75


Interface Failover Configuration

At startup, if PI Foxboro cannot access this PI tag, it exits. Therefore, the user must create
this failover status tag on the PI Data Archive machine before starting PI Foxboro. The tag
may be created with the default PI tag attributes. This PI point can also be used to enable
failover debug messages to be logged.
Note: The failover status point may not be updated correctly if the interface was to be
aborted without shutting down cleanly, or the AW is rebooted. Therefore, it is possible to
have both instances of the failover status point showing that both instances are collecting
when this is NOT the case. To determine which copy of the interface is actually collecting
data, look at the values of the I/A Watchdog object via a Foxboro console. Values that
continuously change from 110 to 115 indicate that the Primary is collecting data. Values
that continuously change from 210 to 215 indicate that the Secondary is collecting data.

Failover debug messages


Debug messages can be enabled to log the activity of the I/A watchdog object and the peer-
to-peer network messages. The debug messages are enabled by setting the value of the
userint1 attribute of the PI failover status point. (0=disabled, 1=primary, 2=secondary,
3=both). This is debug flag is only read at startup.
Note: The userint1 value of the failover PI point is not related in any way to the
BadStatusIndication parameter or the userint1 values of the other PI points used by the
interface. The value of the userint1 attribute of the failover PI point is only used to enable
failover debug messages.

Digital State Written when Interface Stops


The startup command for PI Foxboro usually contains a parameter specifying the digital state
that will be written to its list of tags when the interface stops. For example,
$ fxbais –ps=F –id=1 –stopstat=”Intf Shut” ...
In this example, when PI Foxboro stops, it writes the digital state Intf Shut to its list of
input tags.
However, for a failover configuration, this behavior of writing a digital state upon exit is not
desirable because there is usually another copy of the interface that will assume data
collection. Therefore, when running in a failover configuration, a copy of PI Foxboro writes
the digital state specified by –stopstat only if it has determined that the other copy of the
interface is not running.

Consistency of Startup Parameters


Either the Primary or the Secondary may start first. However, the one that does start up
before the other determines the common startup parameters. Specifically, if the Secondary
starts up first, it makes special note of the following information:
Point source character (-ps=)
Interface number (-id=)
PI Data Archive machine and PI communications port (-host=)
Watchdog I/A object (fxbais.ini watchdog=)
Failover time (fxbais.ini fail_time=)
The Secondary program then opens an UDP socket port. This port is used for
communications between the Primary and Secondary programs.

76
When the Primary program starts, it also makes special note of the following:
Point source character (-ps=)
Interface number (-id=)
PI Data Archive machine and PI communications port (-host=)
Watchdog I/A object (fxbais.ini watchdog=)
Failover time (fxbais.ini fail_time=)
The Primary program sends all of this information (via UDP) to the Secondary. The
Secondary confirms that this set of information is identical to its own. If these parameters do
not match, the Primary will exit and print out the mismatched parameters in the log file. The
Secondary itself will begin data collection within the failover time (scenario to be described
below).

Operational Scenarios
In the following scenarios, “WD=” indicates the value of the watchdog object. “WD=110-
115” means a periodic change in the value of the watchdog object from 110 to 111 to 112 to
113 to 114 to 115 to 110 and so on.

1 – Startup, Normal
At startup, neither the Primary nor the Secondary is collecting data.
The Secondary program starts. The Secondary continuously checks for WD=10 and
WD=110-115. If WD=10, the Secondary writes WD=20.
Meanwhile, the Primary program starts. It writes WD=10. It then checks for WD=20. Since
the Secondary wrote WD=20, the Primary starts data collection and periodically writes
WD=110-115.
End Result: Primary is collecting data.

2 – Startup, Primary Can Connect to the PI Server, but Secondary Cannot


At startup, neither the Primary nor the Secondary is collecting data.
The Secondary program starts, but cannot connect to the PI Data Archive. It will wait until
the connection to the PI Data Archive is established and will not respond to requests from the
primary interface.
Meanwhile, the Primary program starts. It writes WD=10. It then checks for WD=20.
Because the Secondary program is not running, WD=10. The Primary then sends a message
to the Secondary via UDP. The Secondary does not respond because it is not running. The
Primary starts data collection and periodically writes WD=110-115.
End Result: Primary is collecting data.

3 – Startup, Primary Cannot Connect to the PI Server but Secondary Can


At startup, neither the Primary nor the Secondary is collecting data.
The Secondary program starts. The Secondary continuously checks for WD=10 and
WD=110-115. If WD=10, the Secondary writes WD=20.

PI Interface for Foxboro I/A 70 Series 77


Interface Failover Configuration

Meanwhile, the Primary program starts but cannot connect to the PI Data Archive. It is wait
until the connection to the PI Data Archive is established and will not respond to requests
from the secondary interface.
The Secondary sees that the WD is not changing. It then sends a message to the Primary via
UDP. The Primary does not respond because it is not running. The Secondary starts data
collection and periodically writes WD=210-215.
End Result: Secondary is collecting data.

4 – Primary Currently Collecting Data; Primary Fails


The Primary is collecting data and periodically writes WD=110-115. The Secondary sees that
the WD=110-115.
The Primary program stops. The Secondary sees that the WD is not changing. It then sends a
message to the Primary via UDP. The Primary does not respond because it is not running.
The Secondary starts data collection and periodically writes WD=210-215.
End Result: Secondary is collecting data.

5 – Secondary Currently Collecting Data; Primary Re-starts


The Secondary is collecting data and periodically writes WD=210-215.
The Primary program starts. It writes WD=10.
Because the Secondary sees that WD=10, it writes WD=20 to indicate it going to standby. It
stops collecting data and continually checks for WD=110-115.
Since WD=20, the Primary starts data collection and periodically writes WD=110-115.
End Result: Primary is collecting data.

6 – Primary Currently Collecting Data; Secondary Fails; Secondary Re-starts


The Primary is collecting data and periodically writes WD=110-115.
The Secondary program fails.
The Secondary program re-starts. The Secondary first checks for WD=10. Because WD=110-
115, and periodically changes, the Secondary does not collect data. However, it is prepared to
do so.
End Result: Primary is collecting data.

7 – Power Outage and Recovery; Primary Re-starts much Earlier than the
Secondary
This scenario is the same as the sequence of scenarios 2 and 6.

8 – Power Outage and Recovery; Secondary Re-starts much Earlier than the
Primary
This scenario is the same as the sequence of scenarios 3 and 5.

78
9 – An interface cannot access the Watchdog Object on startup
An inability of an instance of the interface to access the watchdog object indicates a serious
problem on either the I/A System or the Foxboro NodeBus. On startup, the interface writes a
message to the PI log file and exits. It probably indicates a configuration issue. Ensure that
the watchdog object has been properly configured for read and write access (must not be
secured).

10 – An interface cannot access the Watchdog Object when running


An inability of an instance of the interface to access the watchdog object indicates a serious
problem on either the I/A System or the Foxboro NodeBus. Since the interface was able to
access the object on startup, we know that it was accessible. The cause of the problem likely
to be a temporary issue (i.e. station containing the watchdog object is rebooting) and so the
interface will log an error message but continue running in its current failover state.

Failover Installation Checklist


11. Confirm that PI Foxboro runs properly in a non-failover configuration on the two
machines. Specifically, on the machine that will be running the copy of the interface
that will be designated as the Primary, install and run the interface without the
-failover startup parameter. Stop the Interface on the Primary machine. On the
Secondary machine, Install and run the interface without the –failover startup
parameter. Stop the Interface on the Secondary.
12. Create the watchdog object on the Foxboro I/A. This object must be a Long Integer
(I/A Type 6). It is recommended that a CALC block be used (with no calculation
steps) and the LI01 parameter used as the watchdog object.
13. Create the PI tag that will track the operational status of the failover configuration.
14. If using the iorates event counters, make sure that two sets of event counter tags exist.
The Primary and Secondary copies of PI Foxboro may use the same –ec= command
line parameter, but the entries for the PI tag names in the iorates.dat file must be
different.
15. Create and/or edit the fxbais.ini file. Change the section name [fxbais-1] if –
id=1 is not used in the PI Foxboro interface startup command line. Put in values for
the entries failover_peer, fail_time, watchdog, and failover_status.
16. Confirm that the Primary machine can communicate to the Secondary machine via
TCP/IP and vice-versa. For example, use the ping command.
17. On the Primary machine, interactively start PI Foxboro with the parameter
-failover=primary. Confirm that this copy of the interface properly collects data.
18. Stop the interface on the Primary machine.
19. On the Secondary machine, interactively start PI Foxboro with the parameter
-failover=secondary. Confirm that this copy of the interface properly collects
data.
20. On the Primary machine, start PI Foxboro with –failover=primary. Confirm that
the Primary copy of the interface starts data collection. Confirm that the Secondary
copy of the interface goes into standby mode.
PI Interface for Foxboro I/A 70 Series 79
Interface Failover Configuration

21. Stop the interface on the Primary machine. Confirm that the Secondary copy of the
interface starts data collection.
22. Restart the interface on the Primary machine. Confirm that the Primary copy of the
interface takes over data collection.
23. Permanently install the two copies of PI Foxboro so that they run in the background
(Solaris) or as services (Windows).
If multiple copies of the interface are running on the same machine (for example, using
different –id= parameters), create entries for failover_port and failover_self_port
in the fxbais.ini file. See the next section for details.

Miscellaneous Information on Failover

Optional Parameters

Wait Time for Response from Peer


At startup, a copy of the PI Foxboro interface configured for failover communicates with its
peer via UDP in order to check for common startup parameters. By default, it waits 5 seconds
for a response from its peer. To change this wait time, put in a value for the entry
check_peer_time in the fxbais.ini file. For example, to increase this wait time to 10
seconds:
[fxbais-1]
...
check_peer_time=10

Socket Port Numbers


By default, a copy of the PI Foxboro interface listens for messages sent by its peer on the
socket port numbered 5451. If another application is currently using port 5451, edit the
fxbais.ini file on both machines and put in the same value for the entries
failover_port and failover_self_port. For example,
[fxbais-1]
...
failover_port=5500
failover_self_port=5500
Of course, for the above example, port 5500 should not be used by another application on
either the Primary or the Secondary machines.
If multiple copies of PI Foxboro are running on the same machine (for example, using
different –id= parameters), create entries for failover_port and failover_self_port
in the fxbais.ini file to correspond to each copy. For example, if there are two copies
(-id=1 and –id=2):
[fxbais-1]

failover_port=5451
failover_self_port=5451

[fxbais-2]

80

failover_port=5452
failover_self_port=5452

Questions and Answers

Why must two sets of I/O Rate points be created?


The Primary and Secondary PI Foxboro Interfaces work together to transfer data between PI
and the Foxboro I/A. At any given time, only one of these copies is sending data to PI.
However, each copy of PI Foxboro is an independent instance of the Interface. Accordingly,
every 10 minutes, each writes to the I/O Rate point (as referenced by the –ec= parameter on
the command line) a value that represents the data collection rate. While the Secondary is
running in standby mode, (and thus not collecting data) it will write a value of 0 to its I/O
Rate point. Therefore, two sets of I/O Rate points should be created, one for the Primary and
one for the Secondary.

How can I tell which copy is collecting data?


Look at the values of the I/A Watchdog object via a Foxboro console. Values that
continuously change from 110 to 115 indicate that the Primary is collecting data. Values that
continuously change from 210 to 215 indicate that the Secondary is collecting data.

PI Interface for Foxboro I/A 70 Series 81


Chapter 11. Interface Node Clock

The PI Data Archive time zone should always be set to the local time zone. Internally, the PI
Data Archive uses UTC time for the timestamps, and for that to be correct then the local time
zone must be set correctly.
The time zone settings on the Foxboro stations can vary depending on the configuration. On
all older systems, the time zone was always set to GMT, and the system clock was adjusted
so that the apparent time on the system matched the actual local time. On newer systems, they
can be configured to use either the GMT time zone, or the actual local time zone.
If the Foxboro stations are using the GMT time zone setting, when the interface attempts to
get the UTC time from the system clock on the Foxboro stations, it will return the wrong
value. It will be wrong by the difference between the GMT time and the local time, and by
clock drift. To get around this problem, the interface will periodically read the UTC time
from the PI Data Archive and calculate the difference between the actual UTC time on the
PI Data Archive and the apparent UTC time on the Foxboro Aws. This difference is then
applied to the time when the values are retrieved from the FoxAPI/AIM*API, and the
resulting adjusted time is used when the events are sent to PI.
The interface will update the offset every 10 minutes, or when it has detected a step change in
the system clock of the Foxboro AW.
This means that the interface does not need to be configured for any specific time zone
setting. It will automatically adjust to whatever time zone or system clock settings are using
on the Foxboro AW. It also means that the interface is able to handle daylight savings
transitions without the need change or restart anything, provided the current releases of the PI
API and the interface are being used.

PI Interface for Foxboro I/A 70 Series 83


Chapter 12. Security

Windows
The PI Firewall Database and the PI Trust Database must be configured so that the interface
is allowed to write data to the PI Data Archive.
The Trust Database, which is maintained by the PI Base Subsystem, replaces the Proxy
Database used prior to PI Data Archive version 3.3. The PI Trust Database maintains all the
functionality of the proxy mechanism while being more secure.
See “Manage Interface Authentication with PI Trusts” in the chapter “Manage Security” of
the PI Server Introduction to System Management Guide.
If the interface cannot write data to the PI Data Archive because it has insufficient privileges,
a -10401 error will be reported in the log file. If the interface cannot send data to a PI2 Data
Archive, it writes a -999 error. See the section Appendix A: Error and Informational
Messages for additional information on error messaging.

Authentication
Interface instances are usually configured to run as Windows services. Since a service runs in
a non-interactive context, a PI trust is required to authenticate the interface service to the
PI Data Archive. A PI trust is associated with one PI identity, PI user, or PI group. When an
interface successfully authenticates through a trust, the interface is granted the access rights
for the associated identity, user, or group.
OSIsoft discourages using highly-privileged identities, users, or groups in PI trusts for
interfaces.

Security Note: Avoid using the piadmin super-user and piadmins group. The
recommended best practice for PI Data Archive security is to create an identity, user,
or group that has only the access rights which are necessary for the interface to
operate.

PI Data Archive v3.3 and Later

Security Configuration using Trust Editor


The Trust Editor plug-in for PI System Management Tools edits the PI trust table.
See the “Manage Interface Authentication with PI Trusts” section in the PI Server
Introduction to System Management manual for more details on security configuration.

PI Interface for Foxboro I/A 70 Series 85


Security

Security configuration using p86ervicedFor PI Data Archive v3.3 and higher, the following
example demonstrates how to edit the PI trust table with ipconfig.
C:\PI\adm> ipconfig
@table pitrust
@mode create
@istr Trust,IPAddr,NetMask,PIUser
a_trust_name,192.168.100.11,255.255.255.255,trust_identity
@quit
For the preceding example,
Trust: An arbitrary name for the trust table entry; in the above example,
a_trust_name
IPAddr: the IP address of the computer running the interface; in the above example,
192.168.100.11
NetMask: the network mask; 255.255.255.255 specifies an exact match with IPAddr
PIUser: the PI identity, user, or group the interface is entrusted as; in the example,
trust_identity

PI Data Archive v3.2


For PI Data Archive v3.2, the following example demonstrates how to edit the PI Proxy table:
C:\PI\adm> p86ointed86@table pi_gen,piproxy
@mode create
@istr host,proxyaccount
piapimachine,piadmin
@quit
In place of piapimachine, put the name of the interface node as it is seen by the
PI Data Archive.

Authorization
For an interface instance to start and write data to PI points, the following permissions must
be granted to the PI identity, user, or group in the PI trust that authenticates the interface
instance.
Database Security Permission Notes
PIPOINT r

Point Database Permission Notes


PtSecurity r
DataSecurity r,w Unbuffered
r Buffered (the buffering application
requires r,w for the interface points)

The permissions in the preceding table must be granted for every PI point that is configured
for the interface instance. Observe that buffering on the interface node is significant to PI
point permissions.
86
When the interface instance is running on an unbuffered interface node, the interface instance
sends PI point updates directly to the PI Data Archive. Therefore, the DataSecurity attribute
must grant write access to the PI identity, user, or group in the PI trust that authenticates the
interface instance.
When the interface instance is running on a buffered interface node, the interface instance
sends PI point updates to the local buffering application, which relays the PI point updates to
the PI Data Archive. The buffering application is a separate client to the PI Data Archive and,
therefore, authenticates independently of the interface instances. The DataSecurity attribute
must grant write access to the PI identity, user, or group in the PI trust that authenticates the
buffering application.

PI Interface for Foxboro I/A 70 Series 87


Chapter 13. Starting / Stopping the Interface

This section describes starting and stopping the interface once it has been installed as a
service.

Starting Interface as a Service


If the interface was installed as service, it can be started from PI ICU, the Services control
panel or with the command:
fxbais.exe /start [ /serviced id ]

To start the interface service with PI ICU, use the button on the PI ICU toolbar.
A message will inform the user of the status of the interface service. Even if the message
indicates that the service has started successfully, double check through the Services control
panel applet. Services may terminate immediately after startup for a variety of reasons, and
one typical reason is that the service is not able to find the command-line parameters in the
associated .bat file. Verify that the root name of the .bat file and the .exe file are the same,
and that the .bat file and the .exe file are in the same directory. Further troubleshooting of
services might require consulting the log file, Windows Event Viewer, or other sources of log
messages. See the section Appendix A: Error and Informational Messages for additional
information.

Stopping Interface Running as a Service


If the interface was installed as service, it can be stopped at any time from PI ICU, the
Services control panel or with the command:
fxbais.exe /stop [ /serviced id ]

To stop the interface service with PI ICU, use the button on the PI ICU toolbar.
The service can be removed by PI ICU or with the command:
fxbais.exe /remove [ /serviced id ]

PI Interface for Foxboro I/A 70 Series 89


Chapter 14. Buffering for PI Interfaces

The interface node uses buffering to prevent data loss when PI Data Archive is not available.
UniInt interfaces can buffer data to store point values when network communication to the
PI Data Archive is unavailable. UniInt disconnected startup requires buffering, and it is
highly recommended for failover. Buffering for interfaces is configured and enabled through
PI ICU.

Buffering services
The PI System offers two services to implement buffering at interfaces:
• PI Buffer Subsystem (PIBufss)
• API Buffer Server (Bufserv)
PI Buffer Subsystem is the best option for most environments.
Use API Buffer Server only if one or more of the following conditions is true:
• The version of PI Data Archive receiving the buffered data is earlier than 3.4.375
• Your interfaces run on a non-Windows platform
If any of the above conditions apply to you, see the PI Buffering Manager Help
(PIPC/HELP/BufferManager.chm) documentation for PI Data Archive. Otherwise, use PI
Buffer Subsystem.

Buffering and collectives


PI Buffer Subsystem 4.3 and later can buffer data to multiple independent servers, including
those configured as PI Data Archive collectives. For interfaces to use PI Buffer Subsystem
with PI Data Archive collectives, the PI Data Archive servers must be running PI Data
Archive version 3.4.375 or later.
Caution:
API Buffer Server does not detect and validate the PI Data Archive collective configuration. As a
result, API Buffer Server requires manual configuration whenever a collective changes. Also,
because API Buffer Server results in compression at the PI Data Archive machine, archives at
different servers in the collective could contain different records.

Buffering configuration
Use PI Interface Configuration Utility (PI ICU) to configure interface buffering.

PI Interface for Foxboro I/A 70 Series 91


Buffering for PI Interfaces

The Tools > Buffering option helps you configure buffering. Depending on your current
configuration, this option does one of the following:
• If this computer is configured to buffer data using PI Buffer Subsystem 4.3 or later, the
Buffering Manager window opens and shows a buffering dashboard. The dashboard shows
information about the status of buffering on this computer.
• If this computer is not currently configured to buffer data, and PI Buffer Subsystem 4.3 or
later is installed, you are prompted to configure PI Buffer Subsystem. If you click Yes, the
Buffering Manager window opens and shows the installation wizard, which helps you
configure PI Buffer Subsystem.
• If this computer is configured to buffer data using API Buffer Server (Bufserv), and
PI Buffer Subsystem 4.3 or later is installed, you are prompted to convert to and configure
PI Buffer Subsystem. If you click Yes at both prompts, the Buffering Manager window
opens and shows the upgrade wizard, which helps you upgrade from API Buffer Server to
PI Buffer Subsystem.
• If PI Buffer Subsystem 4.3 is not yet installed, the Buffering window opens for API
Buffering or the earlier version of PI Buffer Subsystem.
For PI Buffer Subsystem 4.3, when configuring an interface to buffer data to a PI Data
Archive server which has not been added to the buffered server list you must enable
buffering. Click the Enable button in the Buffering Status box on the interface General
page. To verify that the buffering status is On, exit PI ICU, then restart and select the
interface.
You can use Buffering Manager to configure, monitor, and troubleshoot buffering using
PI Buffer Subsystem. PI Buffer Subsystem is recommended for applications connecting to
PI Data Archive 3.4.375 or later. Older versions of PI Data Archive require API Buffer
Server, as do some sites with custom solutions. See Buffering Manager help
(PIPC/HELP/BufferManager.chm) for more information.

92
Chapter 15. Interface Diagnostics Configuration

The PI Point Configuration chapter provides information on building PI points for collecting
data from the device. This chapter describes the configuration of points related to interface
diagnostics.

Note: The procedure for configuring interface diagnostics is not specific to this
interface. Thus, for simplicity, the instructions and screenshots that follow refer to an
interface named ModbusE.

Some of the points that follow refer to a “performance summary interval”. This interval is 8
hours by default. You can change this parameter via the Scan performance summary box in
the UniInt – Debug parameter category page:

Scan Class Performance Points


A scan class performance point measures the amount of time (in seconds) that this interface
takes to complete a scan. The interface writes this scan completion time to millisecond
resolution. Scan completion times close to 0 indicate that the interface is performing
optimally. Conversely, long scan completion times indicate an increased risk of missed or
skipped scans. To prevent missed or skipped scans, you should distribute the data collection
points among several scan classes.

PI Interface for Foxboro I/A 70 Series 93


Interface Diagnostics Configuration

You configure one scan class performance point for each scan class in this interface. From
the ICU, select this interface from the Interface drop-down list and click UniInt-Performance
Points in the parameter category pane:

Right-click the row for a particular Scan Class # to open the shortcut menu:

You need not restart the interface for it to write values to the scan class performance points.
To see the current values (snapshots) of the scan class performance points, right-click and
select Refresh Snapshots.

Create / Create All


To create a performance point, right-click the line belonging to the point to be created, and
select Create. Click Create All to create all the scan class performance points.

Delete
To delete a performance point, right-click the line belonging to the point to be deleted, and
select Delete.

94
Correct / Correct All
If the “Status” of a point is marked “Incorrect”, the point configuration can be automatically
corrected by ICU by right-clicking on the line belonging to the point to be corrected, and
selecting Correct. The performance points are created with the following PI point attribute
values. If ICU detects that a performance point is not defined with the following, it will be
marked Incorrect: To correct all points, click Correct All.
The performance points are created with the following PI point attribute values:
Attribute Details
Tag Tag name that appears in the list box
PointSource PointSource for points for this interface, as specified on the
General page
Compressing Off
ExcMax 0
Descriptor Interface name + “ Scan Class # Performance Point”

Rename
Right-click the line belonging to the point and select Rename to rename the performance
point.

Column descriptions

Status
The Status column in the Performance Points table indicates whether the performance point
exists for the scan class in the Scan Class # column.
Created – Indicates that the performance point does exist
Not Created – Indicates that the performance point does not exist
Deleted – Indicates that a performance point existed, but was just deleted by the user

Scan Class #
The Scan Class # column indicates which scan class the performance point in the Tagname
column belongs to. There will be one scan class in the Scan Class # column for each scan
class listed in the Scan Classes box on the General page.

Tagname
The Tagname column holds the performance point tag name.

PS
This is the point source used for these performance points and the interface.

Location1
This is the value used by the interface for the /ID=# point attribute.

PI Interface for Foxboro I/A 70 Series 95


Interface Diagnostics Configuration

ExDesc
This is used to tell the interface that these are performance points and the value corresponds
to the /ID=# command line parameter if multiple copies of the same interface are running on
the interface node.

Snapshot
The Snapshot column holds the snapshot value of each performance point that exists in the
PI Data Archive. The Snapshot column is updated when the Performance Points page is
selected and when the interface is first loaded. You may have to scroll to the right to see the
snapshots.

Performance Counter Points


Installing the interface as a Windows service creates Windows performance counters to
report performance data. Such data include items like:
 the amount of time that the interface has been running;
 the number of points the interface has added to its point list;
 the number of points that are currently updating
There are two types or instances of performance counters that can be collected and stored in
PI points. The first is (_Total) which is a total for the performance counter since the interface
instance was started. The other is for individual scan classes (Scan Class x) where x is a
particular scan class defined for the interface instance that is being monitored.
OSIsoft’s PI Interface for Performance Monitor is capable of reading these performance
values and writing them to PI points. Please see the Performance Monitor Interface for more
information.
If there is no PI Interface for Performance Monitor registered with the ICU in the Module
Database for the PI Data Archive the interface is sending its data to, you cannot use the ICU
to create any interface instance’s performance counters points:

96
After installing the PI Interface for Performance Monitor as a service, select this interface
instance from the Interface list, then click Performance Counters in the parameter categories
pane, and right-click on the row containing the performance counters point you wish to
create. This will open the shortcut menu:

Click Create to create the performance counters point for that particular row. Click Create All
to create all the performance counters points listed which have a status of Not Created.
To see the current values (snapshots) of the created performance counters points, right-click
on any row and select Refresh Snapshots.

PI Interface for Foxboro I/A 70 Series 97


Interface Diagnostics Configuration

Note: The PI Interface for Performance Monitor – and not this interface – is
responsible for updating the values for the performance counters points in the
PI Data Archive. So, make sure that the PI Interface for Performance Monitor is
running correctly.

Performance Counters

In the following lists of performance counters, the naming convention is:


“PerformanceCounterName” (.PerformanceCounterPointSuffix)
The tag name created by the ICU for each performance counter point is based on the setting
found under the Tools  Options  Naming Conventions  Performance Counter Points.
The default for this is “sy.perf.[machine].[if service]” followed by the performance counter
point suffix.

Performance Counters for both (_Total) and (Scan Class x)

“Point Count” (.point_count)


A .point_count performance counter point is available for each scan class of this interface as
well as a "“_Total)"”for the interface instance.
The .point_count performance counter point indicates the number of PI points per scan class
or the total number for the interface instance. This point is similar to the Health Point
[UI_SCPOINTCOUNT] for scan classes and [UI_POINTCOUNT] for totals.
The ICU uses a naming convention such that the point containing "“Scan Class 1)"”(for
example, "“y.perf.etamp390.E1(Scan Class 1).point_count"” refers to scan
class 1, “(Scan Class 2)” refers to scan class 2, and so on. The point containing
"“_Total)"”refers to the sum of all scan classes.

“Scheduled Scans: % Missed” (.sched_scans_%missed)


A .sched_scans_%missed performance counter point is available for each scan class of this
interface as well as a "“_Total)"”for the interface instance.
The .sched_scans_%missed performance counter point indicates the percentage of scans the
interface missed per scan class or the total number missed for all scan classes since startup. A
missed scan occurs if the interface performs the scan one second later than scheduled.
The ICU uses a naming convention such that the point containing “(Scan Class 1)” (for
example, "“y.perf.etamp390.E1(Scan Class 1).sched_scans_%missed"” refers
to scan class 1, “(Scan Class 2)” refers to scan class 2, and so on. The point containing
“(_Total)” refers to the sum of all scan classes.

“Scheduled Scans: % Skipped” (.sched_scans_%skipped)


A .sched_scans_%skipped performance counter point is available for each scan class of this
interface as well as a "“_Total)"”for the interface instance.
The .sched_scans_%skipped performance counter point indicates the percentage of scans the
interface skipped per scan class or the total number skipped for all scan classes since startup.

98
A skipped scan is a scan that occurs at least one scan period after its scheduled time. This
point is similar to the [UI_SCSKIPPED] Health Point.
The ICU uses a naming convention such that the point containing "“Scan Class 1)"”(for
example, "“y.perf.etamp390.E1(Scan Class 1).sched_scans_%skipped"”
refers to scan class 1, "“Scan Class 2)"”refers to scan class 2, and so on. The point containing
"“_Total)"”refers to the sum of all scan classes.

“Scheduled Scans: Scan count this interval” (.sched_scans_this_interval)


A .sched_scans_this_interval performance counter point is available for each scan class of
this interface as well as a "“_Total)"”for the interface instance.
The .sched_scans_this_interval performance counter point indicates the number of scans that
the interface performed per performance summary interval for the scan class or the total
number of scans performed for all scan classes during the summary interval. This point is
similar to the [UI_SCSCANCOUNT] Health Point.
The ICU uses a naming convention such that the point containing “(Scan Class 1)” (for
example, "“y.perf.etamp390.E1(Scan Class 1).sched_scans_this_interval"”
refers to scan class 1, “(Scan Class 2)” refers to scan class 2, and so on. The point containing
“(_Total)” refers to the sum of all scan classes.

Performance Counters for (_Total) only

“Device Actual Connections” (.Device_Actual_Connections)


The .Device_Actual_Connections performance counter point stores the actual number of data
source devices currently connected and working properly out of the expected number of data
source device connections to the interface. This value will always be less than or equal to the
Device Expected Connections counter.

“Device Expected Connections” (.Device_Expected_Connections)


The .Device_Expected_Connections performance counter point stores the total number of
data source device connections for the interface. This is the expected number of data source
device connections configured that should be working properly at runtime. If the interface
can only communicate with one data source device then the value of this counter will always
be one. If the interface can support multiple data source device connections then this is the
total number of expected working connections configured for this interface.

“Device Status” (.Device_Status)


The .Device_Status performance counter point stores communication information about the
interface and the connection to the data source device(s). The value of this counter is based
on the expected connections, actual connections and value of the /PercentUp command line
option. If the device status is good then the value is ‘0’. If the device status is bad then the
value is ‘1’. If the interface only supports connecting to one data source device then the
/PercentUp command line value does not change the results of the calculation. If for
example the interface can connect to 10 devices and 5 are currently working then the value of
the /PercentUp command line parameter is applied to determine the device status. If the
value of the /PercentUp command line parameter is set to 50 and at least 5 devices are
working then the device status will remain good (that is, have a value of zero).
PI Interface for Foxboro I/A 70 Series 99
Interface Diagnostics Configuration

“Failover Status” (.Failover_Status)


The .Failover_Status performance counter point stores the failover state of the interface when
configured for UniInt failover. The value of the counter will be ‘0’ when the interface is
running as the primary interface in the failover configuration. If the interface is running in
backup mode then the value of the counter will be '‘'’

“Interface up-time (seconds)” (.up_time)


The .up_time performance counter point indicates the amount of time (in seconds) that this
interface has been running. At startup the value of the counter is zero. The value will continue
to increment until it reaches the maximum value for an unsigned integer. Once it reaches this
value then it will start back over at zero.

“IO Rate (events/second)” (.io_rates)


The .io_rates performance counter point indicates the rate (in events per second) at which this
interface writes data to its input points. (As of UniInt 4.5.0.x and later, this performance
counter point is not available.) (This performance counter point has been reinstated as of
UniInt 4.6.0.x)

“Log file message count” (.log_file_msg_count)


The .log_file_msg_count performance counter point indicates the number of messages that
the interface has written to the log file. This point is similar to the [UI_MSGCOUNT] Health
Point.

“PI Status” (PI_Status)


The .PI_Status performance counter point stores communication information about the
interface and the connection to the PI Data Archive. If the interface is properly
communicating with the PI Data Archive then the value of the counter is ‘0’. If the
communication to the PI Data Archive goes down for any reason then the value of the
counter will be ‘1’. Once the interface is properly communicating with the PI Data Archive
again then the value will change back to ‘0’.

“Points added to the interface” (.pts_added_to_interface)


The .pts_added_to_interface performance counter point indicates the number of points the
interface has added to its point list. This does not include the number of points configured at
startup. This is the number of points added to the interface after the interface has finished a
successful startup.

“Points edited in the interface”(.pts_edited_in_interface)


The .pts_edited_in_interface performance counter point indicates the number of point edits
the interface has detected. The interface detects edits for those points whose PointSource
attribute matches the /ps= parameter and whose Location1 attribute divided by 100 matches
the /id= parameter of the interface.

100
“Points Good” (.Points_Good)
The .Points_Good performance counter point is the number of points that have sent a good
current value to the PI Data Archive. A good value is defined as any value that is not a
system digital state value. A point can either be Good, In Error, or Stale. The total of Points
Good, Points In Error, and Points Stale will equal the Point Count. There is one exception to
this rule. At startup of an interface, the stale timeout must elapse before the point will be
added to the Stale counter. Therefore the interface must be up and running for at least 10
minutes for all points to belong to a particular counter.

“Points In Error” (.Points_In_Error)


The .Points_In_Error performance counter point indicates the number of points that have
sent a current value to the PI Data Archive that is a system digital state value. Once a point is
in the In Error count, it will remain in the In Error count until the point receives a new, good
value. Points categorized as In Error do not transition to the stale counters. Only good points
become stale.

“Points removed from the interface” (.pts_removed_from_interface)


The .pts_removed_from_interface performance counter point indicates the number of points
that have been removed from the interface configuration. A point can be removed from the
interface when one of the point attributes is updated and the point is no longer a part of the
interface configuration. For example, changing the PointSource, Location1, or Scan attribute
can cause the point to no longer be a part of the interface configuration.

“Points Stale 10(min)” (.Points_Stale_10min)


The .Points_Stale_10min performance counter point indicates the number of good points that
have not received a new value in the last 10 minutes. If a point is good, then it will remain in
the good list until the stale timeout elapses. At this time if the point has not received a new
value within the stale period then the point will move from the good count to the stale count.
Only points that are good can become stale. If the point is in the In Error count then it will
remain in the In Error count until the error clears. As stated above, the total count of Points
Good, Points In Error, and Points Stale will match the Point Count for the interface.

“Points Stale 30(min)” (.Points_Stale_30min)


The .Points_Stale_30min performance counter point indicates the number of points that have
not received a new value in the last 30 minutes. For a point to be in the Stale 30 minute count
it must also be a part of the Stale 10 minute count.

“Points Stale 60(min)” (.Points_Stale_60min)


The .Points_Stale_60min performance counter point indicates the number of points that have
not received a new value in the last 60 minutes. For a point to be in the Stale 60 minute count
it must also be a part of the Stale 10 minute and 30 minute count.

“Points Stale 240(min)” (.Points_Stale_240min)


The .Points_Stale_240min performance counter point indicates the number of points that
have not received a new value in the last 240 minutes. For a point to be in the Stale 240
minute count it must also be a part of the Stale 10 minute, 30 minute and 60 minute count.
PI Interface for Foxboro I/A 70 Series 101
Interface Diagnostics Configuration

Performance Counters for (Scan Class x) only

“Device Scan Time (milliseconds)” (.Device_Scan_Time)


A .Device_Scan_Time performance counter point is available for each scan class of this
interface.
The .Device_Scan_Time performance counter point indicates the number of milliseconds the
interface takes to read the data from the data source device and package the data to send to
the PI Data Archive. This counter does not include the amount of time to send the data to the
PI Data Archive. This point is similar to the [UI_SCINDEVSCANTIME] Health Point.
The ICU uses a naming convention such that the point containing “(Scan Class 1)” (for
example, "“y.perf.etamp390.E1 (Scan Class 1).device_scan_time"” refers to
scan class 1, “(Scan Class 2)” refers to scan class 2, and so on.

“Scan Time (milliseconds)” (.scan_time)


A .scan_time performance counter point is available for each scan class of this interface.
The .scan_time performance counter point indicates the number of milliseconds the interface
takes to both read the data from the device and send the data to the PI Data Archive. This
point is similar to the [UI_SCINSCANTIME] Health Point.
The ICU uses a naming convention such that the point containing “(Scan Class 1)” (for
example, "“y.perf.etamp390.E1(Scan Class 1).scan_time"” refers to scan class 1,
“(Scan Class 2)” refers to scan class 2, and so on.

102
Interface Health Monitoring Points
Interface Health Monitoring Points provide information about the health of this interface. To
use the ICU to configure these points, select this interface from the Interface list and click
Health Points from the parameter category pane:

Right-click the row for a particular health point to open the shortcut menu:

Click Create to create the health point for that particular row. Click Create All to create all
the health points.
To see the current values (snapshots) of the health points, right-click and select Refresh
Snapshots.

PI Interface for Foxboro I/A 70 Series 103


Interface Diagnostics Configuration

For some of the health points described subsequently, the interface updates their values at
each performance summary interval (typically, 8 hours).

[UI_HEARTBEAT]
The [UI_HEARTBEAT] health point indicates whether the interface is currently running.
The value of this point is an integer that increments continuously from 1 to 15. After reaching
15, the value resets to 1.
The fastest scan class frequency determines the frequency at which the interface updates this
point:
Fastest Scan Frequency Update frequency
Less than 1 second 1 second
Between 1 and 60 Scan frequency
seconds, inclusive
More than 60 seconds 60 seconds

If the value of the [UI_HEARTBEAT] health point is not changing, then this interface is in
an unresponsive state.

[UI_DEVSTAT]
The Health tag with a string point type and the attribute Exdesc = [UI_DEVSTAT], is used to
represent the status of the interface. The possible values for this string point are:
 “1 | Starting” – The Interface remains in this state until it has loaded the PI points
and either starts scanning, or if running in failover, it initializes the failover state.
 “2 | Connected/No Data” – the interface is part of a failover pair and currently
initializing or changing failover state.
 “Good” – The interface is able to collect data. A value of “Good” does not mean
that all tags are receiving good values, but it is a good indication that there are no
hardware or network problems. When using failover, a “Good” status can
indicate that the interface is active or on standby. The failover status PI points
will show the status of the individual instances of the interface.
 “4 | Intf Shutdown” – The Interface has shut down.
The Interface updates this point whenever the interface is started or stopped

[UI_SCINFO]
The [UI_SCINFO] health point provides scan class information. The value of this point is a
string that indicates
 the number of scan classes;
 the update frequency of the [UI_HEARTBEAT] health point; and
 the scan class frequencies
An example value for the [UI_SCINFO] health point is:
3 | 5 | 5 | 60 | 120

104
The interface updates the value of this point at startup and at each performance summary
interval.

[UI_IORATE]
The [UI_IORATE] health point indicates the sum of
1. the number of scan-based input values the interface collects before it performs
exception reporting; and
2. the number of event-based input values the interface collects before it performs
exception reporting; and
3. the number of values that the interface writes to output points that have a SourceTag.
The interface updates this point at the same frequency as the [UI_HEARTBEAT] point. The
value of this [UI_IORATE] health point may be zero. A stale timestamp for this point
indicates that this interface has stopped collecting data.

[UI_MSGCOUNT]
The [UI_MSGCOUNT] health point tracks the number of messages that the interface has
written to the log file since start-up. In general, a large number for this point indicates that the
interface is encountering problems. You should investigate the cause of these problems by
looking in log messages.
The interface updates the value of this point every 60 seconds. While the interface is running,
the value of this point never decreases.

[UI_POINTCOUNT]
The [UI_POINTCOUNT] health point counts the number of PI points loaded by the interface.
This count includes all input, output, and triggered input points. This count does NOT include
any interface health points or performance points.
The interface updates the value of this point at startup, on change, and at shutdown.

[UI_OUTPUTRATE]
After performing an output to the device, this interface writes the output value to the output
point if the point has a SourceTag. The [UI_OUTPUTRATE] health point tracks the number
of these values. If there are no output points for this interface, it writes the system digital state
No Result to this health point.
The interface updates this point at the same frequency as the [UI_HEARTBEAT] point. The
interface resets the value of this point to zero at each performance summary interval.

[UI_OUTPUTBVRATE]
The [UI_OUTPUTBVRATE] health point tracks the number of system digital state values
that the interface writes to output points that have a SourceTag. If there are no output points
for this interface, it writes the system digital state No Result to this health point.
The interface updates this point at the same frequency as the [UI_HEARTBEAT] point. The
interface resets the value of this point to zero at each performance summary interval.

PI Interface for Foxboro I/A 70 Series 105


Interface Diagnostics Configuration

[UI_TRIGGERRATE]
The [UI_TRIGGERRATE] health point tracks the number of values that the interface writes
to event-based input points. If there are no event-based input points for this interface, it writes
the system digital state No Result to this health point.
The interface updates this point at the same frequency as the [UI_HEARTBEAT] point. The
interface resets the value of this point to zero at each performance summary interval.

[UI_TRIGGERBVRATE]
The [UI_TRIGGERBVRATE] health point tracks the number of system digital state values
that the interface writes to event-based input points. If there are no event-based input points
for this interface, it writes the system digital state No Result to this health point.
The interface updates this point at the same frequency as the [UI_HEARTBEAT] point. The
interface resets the value of this point to zero at each performance summary interval.

[UI_SCIORATE]
You can create a [UI_SCIORATE] health point for each scan class in this interface. The ICU
uses a tag naming convention such that the suffix “.sc1” (for example,
sy.st.etamp390.E1.Scan Class IO Rate.sc1) refers to scan class 1, “.sc2” refers to
scan class 2, and so on.
A particular scan class’s [UI_SCIORATE] health point indicates the number of values that
the interface has collected. If the current value of this point is between zero and the
corresponding [UI_SCPOINTCOUNT] point, inclusive, then the interface executed the scan
successfully. If a [UI_SCIORATE] point stops updating, then this condition indicates that an
error has occurred and the points in the scan class are no longer receiving new data.
The interface updates the value of a [UI_SCIORATE] point after the completion of the
associated scan.
Although the ICU allows you to create the point with the suffix “.sc0”, this point is not
applicable to this interface.

[UI_SCBVRATE]
You can create a [UI_SCBVRATE] health point for each scan class in this interface. The ICU
uses a tag naming convention such that the suffix "“sc1"”(for example,
sy.st.etamp390.E1.Scan Class Bad Value Rate.sc1) refers to scan class 1,
"“sc2"”refers to scan class 2, and so on.
A particular scan class’s [UI_SCBVRATE] point indicates the number system digital state
values that the interface has collected.
The interface updates the value of a [UI_SCBVRATE] point after the completion of the
associated scan.
Although the ICU allows you to create the point with the suffix “.sc0”, this point is not
applicable to this interface.

[UI_SCSCANCOUNT]
You can create a [UI_SCSCANCOUNT] health point for each scan class in this interface.
The ICU uses a tag naming convention such that the suffix "“sc1"”(for example,
106
sy.st.etamp390.E1.Scan Class Scan Count.sc1) refers to scan class 1,
"“sc2"”refers to scan class 2, and so on.
A particular scan class'’ [UI_ SCSCANCOUNT] point tracks the number of scans that the
interface has performed.
The interface updates the value of this point at the completion of the associated scan. The
interface resets the value to zero at each performance summary interval.
Although there is no "“can Class 0"” the ICU allows you to create the point with the suffix
"“sc0"” This point indicates the total number of scans the interface has performed for all of
its scan classes.

[UI_SCSKIPPED]
You can create a [UI_SCSKIPPED] health point for each scan class in this interface. The
ICU uses a tag naming convention such that the suffix "“sc1"”(for example,
sy.st.etamp390.E1.Scan Class Scans Skipped.sc1) refers to scan class 1,
"“sc2"”refers to scan class 2, and so on.
A particular scan class’s [UI_SCSKIPPED] point tracks the number of scans that the
interface was not able to perform before the scan time elapsed and before the interface
performed the next scheduled scan.
The interface updates the value of this point each time it skips a scan. The value represents
the total number of skipped scans since the previous performance summary interval. The
interface resets the value of this point to zero at each performance summary interval.
Although there is no "“can Class 0"” the ICU allows you to create the point with the suffix
"“sc0"” This point monitors the total skipped scans for all of the interface’s scan classes.

[UI_SCPOINTCOUNT]
You can create a [UI_SCPOINTCOUNT] health point for each scan class in this interface.
The ICU uses a tag naming convention such that the suffix "“sc1"”(for example,
sy.st.etamp390.E1.Scan Class Point Count.sc1) refers to scan class 1,
"“sc2"”refers to scan class 2, and so on.
This health point monitors the number of points in a scan class.
The interface updates a [UI_SCPOINTCOUNT] health point when it performs the associated
scan.
Although the ICU allows you to create the point with the suffix "“sc0"” this point is not
applicable to this interface.

[UI_SCINSCANTIME]
You can create a [UI_SCINSCANTIME] health point for each scan class in this interface.
The ICU uses a tag naming convention such that the suffix "“sc1"”(for example,
sy.st.etamp390.E1.Scan Class Scan Time.sc1) refers to scan class 1, "“sc2"”refers
to scan class 2, and so on.
A particular scan class'’ [UI_ SCINSCANTIME] point represents the amount of time (in
milliseconds) the interface takes to read data from the device, fill in the values for the points,
and send the values to the PI Data Archive.
The interface updates the value of this point at the completion of the associated scan.
PI Interface for Foxboro I/A 70 Series 107
Interface Diagnostics Configuration

[UI_SCINDEVSCANTIME]
You can create a [UI_SCINDEVSCANTIME] health point for each scan class in this
interface. The ICU uses a tag naming convention such that the suffix "“sc1"”(for example,
sy.st.etamp390.E1.Scan Class Device Scan Time.sc1) refers to scan class 1,
"“sc2"”refers to scan class 2, and so on.
A particular scan class'’ [UI_ SCINDEVSCANTIME] point represents the amount of time (in
milliseconds) the interface takes to read data from the device and fill in the values for the
points.
The value of a [UI_ SCINDEVSCANTIME] point is a fraction of the corresponding
[UI_SCINSCANTIME] point value. You can use these numbers to determine the percentage
of time the interface spends communicating with the device compared with the percentage of
time communicating with the PI Data Archive.
If the [UI_SCSKIPPED] value is increasing, the [UI_SCINDEVSCANTIME] points along
with the [UI_SCINSCANTIME] points can help identify where the delay is occurring:
whether the reason is communication with the device, communication with the
PI Data Archive, or elsewhere.
The interface updates the value of this point at the completion of the associated scan.

I/O Rate Point


An I/O Rate point measures the rate at which the interface writes data to its input points. The
value of an I/O Rate point represents a 10-minute average of the total number of values per
minute that the interface sends to the PI Data Archive.
When the interface starts, it writes 0 to the I/O Rate point. After running for ten minutes, the
interface writes the I/O Rate value. The interface continues to write a value every 10 minutes.
When the interface stops, it writes 0.
The ICU allows you to create one I/O Rate point for each copy of this interface. Select this
interface from the Interface list, click IO Rate in the parameter category pane, and select
Enable IORates for this interface.

108
As the preceding figure shows, the ICU suggests an Event Counter number and a Tagname
for the I/O Rate point. Click the Save button to save the settings and create the I/O Rate point.
Click the Apply button to apply the changes to this copy of the interface.
You need to restart the interface in order for it to write a value to the newly created I/O Rate
point. Restart the interface by clicking the Restart button:

(The reason you need to restart the interface is that the PointSource attribute of an I/O Rate
point is Lab.)
To confirm that the interface recognizes the I/O Rate point, look in the log file for a message
such as:
PI-ModBus 1> IORATE: tag sy.io.etamp390.ModbusE1 configured.
To see the I/O Rate point’s current value (snapshot), click the Refresh snapshot button:

Enable IORates for this Interface


The Enable IORates for this interface check box enables or disables I/O Rates for the current
interface. To disable I/O Rates for the selected interface, clear this box. To enable I/O Rates
for the selected interface, select this box.

Event Counter
The Event Counter correlates a point specified in the iorates.dat file with this copy of the
interface. The command-line equivalent is /ec=x, where x is the same number that is
assigned to a tag name in the iorates.dat file.

Tagname
The tag name listed in the Tagname box is the name of the I/O Rate point.

Tag Status
The Tag Status box indicates whether the I/O Rate point exists in the PI Data Archive. The
possible states are:
 Created – This status indicates that the point exist in the PI Data Archive
 Not Created – This status indicates that the point does not yet exist in the
PI Data Archive
 Deleted – This status indicates that the point has just been deleted
PI Interface for Foxboro I/A 70 Series 109
Interface Diagnostics Configuration

 Unknown – This status indicates that the PI ICU is not able to access the
PI Data Archive

In File
The In File box indicates whether the I/O Rate point in the Tagname box and the number in
the Event Counter box are in the IORates.dat file. The possible states are:
 Yes – This status indicates that the tag name and event counter are in the IORates.dat
file
 No – This status indicates that the tag name and event counter are not in the
IORates.dat file

Snapshot
The Snapshot column holds the snapshot value of the I/O Rate point, if the I/O Rate point
exists in the PI Data Archive. The Snapshot box is updated when the IORate page is selected
and when the interface is first loaded.

Create/Save
Create the suggested I/O Rate point with the tag name indicated in the Tagname box. Or, save
any changes for the tag name indicated in the Tagname box.

Delete
Delete the I/O Rate point listed in the Tagname box.

Rename
Change the tag name for the I/O Rate point listed in the Tagname box.

Add to File
Add the tag name to the IORates.dat file with the event counter listed in the Event Counter
box.

Search
Search the PI Data Archive for a previously defined I/O Rate point.

110
Appendix A. Error and Informational Messages

A string NameID is pre-pended to error messages written to the message log. Name is a
non-configurable identifier that is no longer than 9 characters. ID is a configurable identifier
that is no longer than 9 characters and is specified using the /id parameter on the startup
command-line.

Message Logs
The location of the message log depends upon the platform on which the interface is running.
For more information about logs for interfaces running on Windows, see UniInt Interface
Message Logging for UniInt 4.5.0.x and later Interfaces or knowledge base article 401 on the
OSIsoft technical support web site.
Messages are written to the log file at the following times.
 When the interface starts, many informational messages are written to the log. These
messages include the version of the interface, the version of UniInt, the
command-line parameters used, and the number of points.
 As the interface loads points, messages are sent to the log if there are any problems
with the configuration of the points.
 If the UniInt /dbUniInt parameter is found in the command-line, then various
informational messages are written to the log file.
 If the /fdb= is used on the command-line, then various informational messages are
sent to the log.

Extra Debugging Messages

Interface-level

The Interface can be configured to print out debugging messages by specifying various values
in the –fdb command line parameter. Alternatively, the DebugFlags section of the
fxbais.ini file may be used to specify these values. The available debugging values are:
11 – Additional messages when opening lists of tags
12 – Setup of tags used with the libprofplot.so library
13 – Reading of data using libprofplot.so function calls
15 – Time offset between the PI Data Archive and the Interface
1 Verbose messages during point loading

PI Interface for Foxboro I/A 70 Series 111


Error and Informational Messages

17 1 Verbose messages during Interface shutdown


17 18 – Extra attempts to locate and close data sets. Unlike other debugging values, this one affects
the behavior of the Interface. If –fdb=18 is specified, the Interface will close all data sets, even
those that it did not open.
19 – Messages for buffered outputs
20 – Messages for unbuffered outputs
21 – Messages for outputs in general
24 – Detailed error status after an scopen() call
25 – Log messages when interface enters and leaves dev_hibernate()
26 – Log messages when interface enters and leaves dev_service_input_list()
27 – Detailed information on each FoxAPI call made by the interface
28 – Log “Out of service” and “Return to Service” status messages
For example, to tell PI Foxboro to print verbose messages during point loading (debug value
16) and during Interface shutdown (debug value 17), add the following command line
parameter to the startup command file (fxbais.sh or fxbais.bat):
fxbais –ps=F –id=1 –fdb=16,17 …
Alternatively, edit the fxbais.ini file so that it contains:
[fxbais-1]
DebugFlags=16,17
PI Foxboro reads the contents of fxbais.ini on startup.

Point-level

The Interface may be configured to print out debugging messages for individual points. To
do so, add 4096 to the value of the point’s UserInt1 tag attribute field.
The advantage of point level debugging is that the user does not have to
stop the Interface
add –fdb parameters to the interface startup file
re-start the Interface
Because the Interface automatically incorporates PI tag attribute changes, point level
debugging can be disabled by setting the point’s UserInt1 attribute field to a value less than
4096.
The following are examples of point level debug messages:
14-Jul-09 13:47:52
FXBAIS 1> [mreaidx] Pitag (PITEST01_01:LC001_CTRL.MEAS) idx=92
status=0x223 val=40.925900 istat=0 changeCount=921
14-Jul-09 13:47:52
FXBAIS 1> ia_to_pi(): Pitag (PITEST01_01:LC001_CTRL.MEAS) drval=
40.9259 ival=0 istat=0 count=1
14-Jul-09 13:47:52

112
FXBAIS 1> dsil() – Pitag (PITEST01_01:LC001_CTRL.MEAS)
t=1247536082.00 istat=0 drval=40.9259 ival=0 sent to UniInt
This message indicates that for the PI point PITEST01_01:LC001_CTRL.MEAS, the call to
the FoxAPI function mreaidx() used the FoxAPI index of 92 to get the current value of the
object and resulted in a value of 40.925900 and an I/A object status of 0x223 (secured,
connected, float). This was converted to a drval=40.9259 and istat=0 for writing to PI.
Finally, the timestamp of 1247536082 UTC seconds was used when the event was sent to PI.
14-Jul-09 13:56:11
FXBAIS 1> [uread] error=0, status 0x23, val=94.824608; Pitag
(PITEST01_02:STATBITS001.RI01) istat=0
14-Jul-09 13:56:11
FXBAIS 1> dsil() – Pitag (PITEST01_02:STATBITS001.RI01)
t=1247536580.00 istat=0 drval=94.8246 ival=0 sent to UniInt
This message indicates that for the PI tag PITEST01_02:STATBITS001.RI01, the call to
the FoxAPI function uread() resulted in a value of 94.824608 and an I/A object status of
0x23 (connected, float). The timestamp of 1247536580 UTC seconds was used when the
event was sent to PI.
The pidiag –t utility can be used to convert the UTC seconds timestamp into a human
readable format. The pidiag utility is installed in the PIHOME/adm directory. The following
is an example of the pidiag –t command,
pidiag –t 1247536580 U
14-Jul-09 13:56:20 NZST – Local: 1247579780 UTC: 1247536580
Note: The trailing U on the pidiag –t command specifies that the timestamp passed is a
UTC time and not a local time. Timestamps logged in the interface debug messages will
always be in UTC seconds.

List Event Counters and Location5

If the event count appears too high or low, the user can determine the source of excess values.
There are event counters for the Interface and for the individual buffered lists.
The Interface may be configured to count all inputs (-ec), unbuffered inputs (-ecuinp),
buffered outputs (-ecout), and unbuffered outputs (-ecuout). Use of these counters will
provide an overview of events generated by each category.
If there are buffered input or output points (i.e., Location2 greater than zero), list event
counters may be used. These counters are configured by specifying a non-zero Location5
field and a positive Location2 for a point. Such a point will then contain the number of I/A
object change counts. Location2 corresponds to the PI list number. Location5 indicates the
frequency in seconds with which the Interface updates this point. (For example, Location5
may be 120 to indicate 2 minutes.) Location4 indicates a scanclass number whose frequency
is less than the Location5 value.

PI Interface for Foxboro I/A 70 Series 113


Error and Informational Messages

System Errors and PI Errors


System errors are associated with positive error numbers. Errors related to PI are associated
with negative error numbers.

Error Descriptions on Windows


On Windows and UNIX, descriptions of system and PI errors can be obtained with the pidiag
utility:
Windows: \PI\adm\pidiag /e error_number
UNIX: /PI/adm/pidiag –e error_number

114
Appendix B. PI SDK Options

To access the PI SDK settings for this interface, select this interface from the Interface list
and click UniInt – PI SDK in the parameter category pane.

Disable PI SDK
Select Disable PI SDK to tell the interface not to use the PI SDK. If you want to run the
interface in disconnected startup mode, you must choose this option.
The command line equivalent for this option is /pisdk=0.

Use the Interface’s default setting


This selection has no effect on whether the interface uses the PI SDK. However, you must not
choose this option if you want to run the interface in disconnected startup mode.

Enable PI SDK
Select Enable PI SDK to tell the interface to use the PI SDK. Choose this option if the
PI Data Archive version is earlier than 3.4.370.x or the PI API is earlier than 1.6.0.2, and you
want to use extended lengths for the Tag, Descriptor, ExDesc, InstrumentTag, or PointSource
point attributes. The maximum lengths for these attributes are:
Attribute Enable the Interface to use PI Data Archive earlier than 3.4.370.x
the PI SDK or PI API earlier than 1.6.0.2, without
the use of the PI SDK
Tag 1023 255
Descriptor 1023 26
ExDesc 1023 80
InstrumentTag 1023 32
PointSource 1023 1

However, if you want to run the interface in disconnected startup mode, you must not choose
this option.
The command line equivalent for this option is /pisdk=1.

PI Interface for Foxboro I/A 70 Series 115


Appendix C. Common Problems

Waiting for FoxAPI/AIM*API to Start


If the Interface is started and it appears to stop with the last message being “Waiting for
FoxAPI process “foxapi.exe” to start..” or “Waiting for AIM*API
process “apimgr.exe” to start..”, these warnings indicate that the
FoxAPI/AIM*API processes is not running.
After a reboot it may take several minutes for the FoxAPI processes to start. Under
Windows, use the Task Manager to see if the process is running.
If the process it not running and it is several minutes since the system was rebooted, then it
may be necessary to start the processes manually.
For the FoxAPI, this can be done by going to the Control Panel, and double-clicking on
“Foxboro API” and selecting “Start FoxAPI”. Also ensure that “Check if you want to start
FOXAPI at reboot” is selected on. Try running Foxboro’s foxtst program located in
D:\opt\fox\ais\bin. If the same warnings persist, stop and restart the FoxAPI software
via the aisstart command.
For the AIM*API, the process is a Windows service. Use the Windows “Administrative
Tools/Services” utility to locate the “Aim API Manager Service” and start the service. If there
is no “Aim API Manager Service”, then the AIM*API may not be installed correctly, or the
AIM*API version is an older release. The older AIM*API processes are controlled in the
same way as the FoxAPI processes, and there should be an icon in the Windows Control
panel to start and stop the processes.

Interface Crashes When Opening Lists (Data Sets)


This can be caused by either the FoxAPI/AIM*API running out of resources, or by
conflicting object manager lists.
To ensure that the FoxAPI/AIM*API has sufficient resources, refer to the FoxAPI/AIM*API
Configuration Settings (foxapi.cfg/aimapi.cfg) section.
If an interface configuration is changed to load a different set of I/A objects, or the PI points
are edited to read from different I/A objects, then the old I/A objects may still be using
resources within the FoxAPI. The restore_index.dat file is used by the FoxAPI to store
a list of objects accessed. When objects are removed, it is possible for them to remain in the
restore_index.dat file and consume resources within the FoxAPI, after they are no
longer required. To ensure that the old I/A objects are cleared from the FoxAPI, stop the
FoxAPI and remove the restore_index.dat file.
The restore_index.dat file can also cause conflicts in the object manager lists,
particularly if both the FoxAPI and the AIM*API are running on the same AW. Stopping the
FoxAPI and/or AIM*API, removing the restore_index.dat files and restarting can fix
these issues.

PI Interface for Foxboro I/A 70 Series 117


Common Problems

To remove the restore_index.dat file(s),


6) Stop the interface and any other FoxAPI/AIM*API applications (historians etc) running
on the AW.
7) Stop the FoxAPI processes (aisstop or FoxAPI control panel) and the AIM*API
processes (aisstop or AIM*API control panel)
8) Delete the restore_index.dat files from the AIM bin directories.
FoxAPI on AW70 D:\opt\fox\ais\bin
AIM*API on AW70 D:\opt\aim\bin
9) Restart the FoxAPI processes (aisstop or FoxAPI control panel) and the AIM*API
processes (aisstop or AIM*API control panel)
10) Restart the interface and other FoxAPI applications
The restore_index.dat files will be recreated by the FoxAPI and AIM*API as required.
With the AIM*API, it is possible that the interface will crash when opening the first data set
if the file “D:\opt\aim\bin\setname.dat” is set as read-only. This can happen because
of an error in the older AIM*API install kits. Using the Windows Explorer, right click on the
file and select the file properties. Then uncheck the Read-only attribute and select OK.

Warnings “open_action: not found” and “clsset_action : not found”


During normal operations, the fxbais interface calls the FoxAPI function scopen() and clsset()
to open and close FoxAPI datasets. When these functions are called, internally the
FoxAPI/AIM*API attempt to run the scripts open_action and clsset_action if they
exist.
If these scripts do not exist, warning messages may be output. These messages are harmless,
but it is better to correct the problem.
To eliminate these warnings, two scripts called open_action and clsset_action need to
be created in the FoxAPI/AIM*API directory. These scripts do not need to do anything, but
they need to be present to stop the warnings.
To create the files on Windows, from a command prompt
D:
For FoxAPI, cd \opt\fox\ais\bin
For AIM*API, cd \opt\aim\bin
touch open_action.ksh
touch clsset_action.ksh

Error 212 Seen


The pimesslogfile or pipc.log may show a message such as:
FXBIA- 1> Error 212 …
This error 212 is returned by the FoxAPI and indicates a problem caused by a lack of
permission/privileges.

118
Interface locks up when opening output lists
If the interface attempts to open a list with write access and one of the points within the list is
an output parameter then the interface will lock up. The only way to stop the process is with
a kill -9. This is a limitation of the FoxAPI. The interface will attempt to check the “secured”
status of the write objects when the PI points are loaded, but this will only trap input
parameters that are currently secured and will not detect problems with output parameters.
Therefore, care must be taken when configuring buffered output points (from PI) that they
will only write to input (unsecured) I/A parameters.
The Interface can only write to an INPUT parameter of a block. For example, the Interface
cannot change the value of an .OUT parameter of a PID block since that parameter is the
output of these blocks. One can determine whether a parameter is an OUTPUT by examining
the documentation for the block.
When writing to variable blocks (BOOL, LONG, PACK, REAL, STRING), the VALUE
parameter is an output parameter and cannot be used with buffered outputs. Only unbuffered
outputs (Location2=0) points can be used to write to these objects.
But, unbuffered outputs should also be used with care. Although they will not cause the
interface to lockup when opening lists, they can cause long delays within the interface if the
I/A object is not currently available (misconfigured or a CP is rebooting).

Time Difference Reported by the Interface

On some Foxboro nodes, the time zone may be set to GMT and the system clock adjusted to
show the correct local time. Because of this, the system clock (UTC seconds) is not correct
when compared to the actual UTC seconds from the PI Data Archive.
The interface is able to adjust for this difference when the timestamps are sent to the PI Data
Archive, but some misleading messages can be logged. For example,
16-Jul-09 14:08:48
FXBAIS 1> (UTC time on server node – UTC time on interface node) = -43190
seconds
16-Jul-09 14:08:48
FXBAIS 1> Local time on server node – local time on interface node) = 10
seconds

The above messages show the time difference between a Foxboro AW51 and a PI Data
Archive in New Zealand (GMT+12). The local times are different by 10 seconds (due to
clock drift) and the UTC times are difference by nearly 12 hours. This is expected for
Foxboro Aws were the time zone is set to GMT.

Operational Hints
The following information may be useful during the operation of the PI Foxboro Interface.

Updates and Hotfixes for the FoxAPI/AIM*API


Foxboro provides fixes and enhancements to their FoxAPI/AIM*API. Please be the latest
updates are installed.

PI Interface for Foxboro I/A 70 Series 119


Common Problems

FoxAPI max number objects (0) < 1


On Windows I/A version 8.x, if the interface fails to start and logs the message
“FoxAPI max number objects (0) < 1. Abort.” Then install QF1007921. If the problem
persists, ensure that the interface is being started by the fox user.

PI Points showing “Bad Input” on startup until the I/A value changed
There was a problem with older versions of the I/A Object Manager that would cause some
PI points get a “No Response” status from the FoxAPI when the FoxAPI data sets were
opened. This would cause the fxbais interface to see the value as a “Bad Input”. The value
status would not be updated until the I/A value changed in the controller and triggered an
update of the FoxAPI.
This problems was resolved with the following Foxboro Quickfixes
I/A 6.5.1 Windows NT QF1005127
I/A 7.1 Windows XP QF1005128

Reading an Entire MCIN/MCOUT Block


If desired, all of the inputs of an MCIN or all of the outputs of an MCOUT block may be read
into a single PI point. The MCIN block has a parameter of type Long Packed Boolean (10)
called PAKCIN. The MCOUT block has a parameter of type Packed Boolean (9) called
PAKCRB. These parameters are the packed equivalent of the .CO_x parameters of the
MCOUT and the .IN_x parameters of the MCIN blocks.
To read the individual inputs or outputs into separate PI tags, it is more efficient to have the
InstrumentTag attribute set to read the packed parameter (PAKCIN or PAKCRB), and use the
BTM= parameter in the ExDesc attribute to extract the bit required. This is because the
FoxAPI is able to read a single parameter instead of returning up to 32 separate parameters.

FoxAPI/AIM*API Configuration Settings (foxapi.cfg/aimapi.cfg)


The FoxAPI/AIM*API has a number of configurations settings that can be used to tune the
resources and performance of the API. These settings are stored in the text file
D:\opt\fox\ais\bin\foxapi.cfg (Windows FoxAPI)
D:\opt\aim\bin\aimapi.cfg (Windows AIM*API)
Normally, the FoxAPI/AIM*API and the fxbais interface will work together without
requiring any changes to the FoxAPI/AIM*API configuration file.
Use the default setting in the foxapi.cfg file if possible.
Note: The FoxAPI Release Notes (B0193UH) refer to “Special Instructions for Existing
OSI PI Applications”. These notes only apply to fxbais 2.2.5 or earlier and are not
relevant for the current release of the fxbais interface.
However, depending on the number of points loaded by the interface, or the loading on the
I/A system, it may be necessary to edit some of the parameters.
The following are some of the key parameters that may need to be changed. For a full list of
the available parameters, refer to the Foxboro I/A manuals
 FoxAPI User Manual (B0193UD), Appendix H – Configuration File Parameters
120
 AIM*API User Manual (B0193YN), Appendix J – Configuration File Parameters

maxobj
On startup, the FoxAPI / AIM*API processes allocate resources based on the maxima values
specified in the configuration file. Most of the maxima values are sufficient for most normal
operations.
The exception is maxobj, which is often too small for interfaces collecting large numbers of
points. The maxobj is the maximum number of objects that the API can maintain
connections to, and the default is 6000. When the interface attempts to open lists when the
6000 objects have been used, the call will fail and the interface will not be able to scan the
points.
Setting the maxobj to higher values allows the API to allocate more shared memory to the
lists. Typically, the maxobj should be 1.5 or 2 times the number of points scanned by the
interface.
For example, if an interface is scanning 6000 points, use
maxobj = 10000
This allows addition resources for when points are added or deleted from the interface, and
having extra resources allocated within the FoxAPI does not cause any problems.
Also note that it is possible for the resources to be used by points that are no longer being
scanned. To allow the FoxAPI to preserve object index values on a restart, the FoxAPI keeps
a list of the objects it has accessed in a file called restore_index.dat. The objects within
this list will reserve space in the FoxAPI, even if they are no longer in use. Therefore, it is
possible for the FoxAPI to run out of resources even when the fxbais interface and other
applications are not using maxobj objects.
To free the resources allocated for the restore_index.dat objects,
4. Stop the PI API and fxbais interface
$PIHOME/bin/pistop
5. Stop the FoxAPI processes
/opt/fox/ais/bin/aisstop
6. Delete the restore_index.dat file
rm /opt/fox/ais/bin/resource_index.dat
7. Restart the FoxAPI processes
/opt/fox/ais/bin/aisstart
8. Restart the PI API and the fxbais interface
$PIHOME/bin/pistart
The restore_index.dat file will be recreated and only objects that are used will be included in
the file.

maxds
This defines the maximum number of datasets. The default is 100. The range is 3 to 1000.
The number of datasets that the interface will open is the number of unique values in the

PI Interface for Foxboro I/A 70 Series 121


Common Problems

location2 attribute for the points in the interface. The default 100 datasets is usually
sufficient.

ctdlay and om_delay


If the interface is seeing large numbers of objects with No Response (0x0103) when the
interface is started, the ctdlay parameter can be increased to reduce the load on the
underlying systems. This should allow the FoxAPI more time to get the response from the
control stations before. Similarly, the om_delay parameter can also be used to increase the
delays between opening the OM lists, and so reduce the load on the underlying systems.
Typically values for the ctdlay and om_delay parameters are
ctdlay = 200
om_delay = 500
But, note that the “No Response” status when the lists are opened on startup will not cause
the PI point to show “I/O Timeout”. The interface will only show “I/O Timeout” is the status
is still 0x0103 when the interface is scanning the points normally. The status when the lists
are opened is not used to flag points as bad.

fastest_rsr
If the Object Manager (OM) loading on the control stations is too high, the OM can be
slowed to reduce the loads. The fastest_rsr parameter controls how often the control station
checked the objects in its scan lists to see whether they have exceeded the delta values, and is
in 0.5 second units (1=0.5 sec, 2=1 sec etc). The default value is 1 (0.5 seconds). A typical
setting for the fastest_rsr parameter is
fastest_rsr = 4
Increasing fastest_rsr to 4 (2 seconds) can significantly reduce the loads on the control
stations, but still giving an acceptable update rate to the interface.
Unfortunately, the fastest_rsr is applied to all connections from the FoxAPI and so it is not
possible to have different control stations using different rates.

useaimapi (AIM*API only)


AIM*API and FoxAPI are two separate subsystems. Some I/A Series programs use FoxAPI
and need FoxAPI to be running in order to operate. The fxbais interface and AIM*AT
applications only use AIM*API, and require it to be running in order to operate.
AIM*API and FoxAPI can share I/A Series Object Manager (OM) connection resources, if
FoxAPI is started first.
0 = AIM*API and FoxAPI share I/A Series OM connection resources.
1 = AIM*API and FoxAPI use separate I/A Series OM connection resources.
The default is 1 (separate resources)
Because of potential conflicts between the two subsystems, it is recommended to use separate
resources, which is the default (useaimapi=1)

122
Appendix D. FoxAPI/AIM*API Status Definition

When the fxbais interface reads a value from an I/A object, it also receives the object status.
The FoxAPI/AIM*API presents this status as a 32-bit word, with the bits numbered from 0 to
31. Bit 0 is the least significant. The fxbais interface can use this status to determine whether
the value is good. If the value is not good, then the interface can be configured to handle it in
different ways.

Status Definition for I/A Series Version 4.1 and Earlier


Bit Number Description
Bits 0 to 4 The object value type
1 character
2 integer
3 float
4 string
5 1 byte boolean
6 long integer
8 short integer
9 packed boolean
10 long packed boolean
Bits 5 to 7 Object Manager connect status
0 No response
1 Being scanned
2 Disconnected
3 Deleted
4 Bad data type or unconnectable compound
6 Non-connectable parameter
Bit 8 The object is BAD (1), disconnected (1), or OK (0).
Bit 9 The parameter is secured (1) or unsecured (0).
Bit 10 The compound is on (1) or off (0).
Bit 11 The block is out of service (1) or in service (0).
Bit 12 The point is a shadow parameter (1) or is not a shadow parameter (0).
Bit 13 Init. Acknowledge (1) / else (0)
Bit 14 Reserved.
Bit 15 There is an error condition upstream (1) or no upstream error detected (0).
Bits 16 to 31 Reserved

PI Interface for Foxboro I/A 70 Series 123


FoxAPI/AIM*API Status Definition

Status Definition for I/A Series Version 4.2 and Later


Bit Number Description
Bits 0 to 3 The object value type
1 character
2 integer
3 float
4 string
5 1 byte boolean
6 long integer
8 short integer
9 packed boolean
10 long packed boolean
Bit 4 Change (setval) (1) / else (0)
Bits 5 to 7 Object Manager connect status
0 No response
1 Being scanned
2 Disconnected
3 Deleted
4 Bad data type or unconnectable compound
6 Non-connectable parameter
Bit 8 The object is BAD (1), disconnected (1), or OK (0).
Bit 9 The parameter is secured (1) or unsecured (0).
Bit 10 Ack/uncond. Init (1) else (0)
Bit 11 The object is out of service (1) or in service (0).
Bit 12 The point is a shadow parameter (1) or is not a shadow parameter (0).
Bit 13 The parameter is limited high (1) or not (0)
Bit 14 The parameter is limited low (1) or not (0)
Bit 15 There is an error condition upstream (1) or no upstream error detected (0).
Bits 16 to 31 Reserved

For example, a status of 0x23 corresponds to binary


0000 0000 0010 0011
The value of bits 0 to 4 is 3. The value type of the object is float.
The value of bits 5 to 7 is 1. The object is connected.
Another example is a status of 0x963, or in binary
0000 1001 0110 0011
The value of bits 0 to 4 is 3. The value type of the object is float.
The value of bits 5 to 7 is 3. The object is deleted.
The value of bit 8 is 1. The object is bad.
The value of bit 11 is 1. The object is out of service.

124
Generally, the Interface sends the I/A object’s value to PI only if all three of the following
conditions are met:
9. Bits 5-7 indicate a connected status.
10. Bit 8 indicates okay.
11. Bit 11 indicates in service.
Otherwise, the Interface sends Bad Input to PI. However, the condition regarding the bad
status from Bit 8 may be ignored. See the description for BadStatusIndication in the
section regarding the fxbais.ini file.

Storing Status Values in PI


If Location3 (I/A data type) for a PI point is set to 0 then instead of storing the object value,
the interface will store the FoxAPI status instead.
Note that it is not practical to store the entire status into a digital PI point as the digital set
would need 65536 state strings to cover all the possible values. But, it is possible to use the
BTM= command in ExDesc attribute to select a subset of the status bits, and reduce the
number of possible values to a more practical level.
For example, to store just the connection status, extract bits 5 to 7 with the setting
BTM=5,6,7 and use a digital set with the 8 possible states “No Resp”, “Scanned”,
“Disconnect”, “Deleted”, “Bad Type”, “NA 5”, “Non-Conn”, “NA 7”.
If the Bad and Out-of-Service bits are desired, use BTM=8,11 and a digital set with the 4
states “OK”, “Bad”, “OOS”, “BadOOS”.
If the object status is configured to be stored in a PI string point, then the interface will
convert value into a suitable. For example, a real output of a CALC block running in AUTO
with the OOS flag set may have a status of 0x0a23. A PI string storing that status would
contain the string “0x0a23 OOS Secured Scanned Float”. Note that the format of this string
value is not configurable.
If the value is written to floating point or integer PI points then the value can be stored as read
from the FoxAPI.

PI Interface for Foxboro I/A 70 Series 125


Terminology

Appendix E. Terminology

To understand this interface manual, you should be familiar with the terminology used in this
document.

Buffering
Buffering refers to an interface node’s ability to store temporarily the data that interfaces
collect and to forward these data to the appropriate PI Data Archives.

N-Way Buffering
If you have PI Data Archives that are part of a collective, PIBufss supports n-way buffering.
N-way buffering refers to the ability of a buffering application to send the same data to each
of the PI Data Archives in a collective. (Bufserv also supports n-way buffering to multiple
PI Data Archives in a collective; however, it does not guarantee identical archive records
since point compression attributes could be different between PI Data Archives. With this in
mind, OSIsoft recommends that you run PIBufss instead.)

ICU
ICU refers to the PI Interface Configuration Utility. The ICU is the primary application that
you use to configure PI interface programs. You must install the ICU on the same computer
on which an interface runs. A single copy of the ICU manages all of the interfaces on a
particular computer.
You can configure an interface by editing a startup command file. However, OSIsoft
discourages this approach. Instead, OSIsoft strongly recommends that you use the ICU for
interface management tasks.

ICU Control
An ICU control is a plug-in to the ICU. Whereas the ICU handles functionality common to all
interfaces, an ICU control implements interface-specific behavior. Most PI interfaces have an
associated ICU control.

Interface Node
An interface node is a computer on which
 the PI API and/or PI SDK are installed, and
 PI Data Archive programs are not installed.

PI API
The PI API is a library of functions that allow applications to communicate and exchange
data with the PI Data Archive. All PI interfaces use the PI API.

PI Data Archive Collective


A PI Data Archive Collective is two or more replicated PI Data Archives that collect data
concurrently. Collectives are part of the High Availability environment. When the primary

126
PI Data Archive in a collective becomes unavailable, a secondary collective member node
seamlessly continues to collect and provide data access to your PI clients.

PI Data Archive Node


A PI Data Archive node is a computer on which PI Data Archive programs are installed. The
PI Data Archive runs on the PI Data Archive node. In earlier documentation, PI Data Archive
was referred to as the PI Server. (See PI Server Node.)

PIHOME
PIHOME refers to the directory that is the common location for PI 32-bit client applications.
A typical PIHOME on a 32-bit operating system is C:\Program Files\PIPC.
A typical PIHOME on a 64-bit operating system is C:\Program Files (x86)\PIPC.
PI 32-bit interfaces reside in a subdirectory of the Interfaces directory under PIHOME.
For example, files for the 32-bit Modbus Ethernet Interface are in
[PIHOME]\PIPC\Interfaces\ModbusE.
This document uses [PIHOME] as an abbreviation for the complete PIHOME or PIHOME64
directory path. For example, ICU files in [PIHOME]\ICU.

PIHOME64
PIHOME64 is found only on a 64-bit operating system and refers to the directory that is the
common location for PI 64-bit client applications.
A typical PIHOME64 is C:\Program Files\PIPC.
PI 64-bit interfaces reside in a subdirectory of the Interfaces directory under PIHOME64.
For example, files for a 64-bit Modbus Ethernet Interface would be found in
C:\Program Files\PIPC\Interfaces\ModbusE.
This document uses [PIHOME] as an abbreviation for the complete PIHOME or PIHOME64
directory path. For example, ICU files in [PIHOME]\ICU.

PI Message Log
The PI message log is the file to which OSIsoft interfaces based on UniInt 4.5.0.x and later
write informational, debug and error messages. When a PI interface runs, it writes to the
local PI message log. This message file can only be viewed using the PIGetMsg utility. See
the Message Logs section for more information on how to access these messages.

PI SDK
The PI SDK is a library of functions that allow applications to communicate and exchange
data with the PI Data Archive. Some PI interfaces, in addition to using the PI API, require the
use of the PI SDK.

PI Server Node
In earlier documentation, the term “PI Server” was used as a nickname for the
PI Data Archive and a PI Server node was a computer on which PI Data Archive programs
were installed. While the PI Data Archive remains a core server of the PI Server product, the

PI Interface for Foxboro I/A 70 Series 127


Terminology

product name “PI Server” now refers to much more than the PI Data Archive. OSIsoft
documentation, including this user manual, is changing to use “PI Server” in this broader
sense and “PI Data Archive” to refer to the historian core. (See PI Data Archive Node.)

PI SMT
PI SMT refers to PI System Management Tools. PI SMT is the program that you use for
configuring PI Data Archives. A single copy of PI SMT manages multiple PI Data Archives.
PI SMT runs on either a PI Data Archive node or an interface node.

Pipc.log
The pipc.log file is the file to which OSIsoft interfaces based on UniInt versions earlier
than 4.5.0.x write informational and error messages. When a PI interface runs, it writes to the
pipc.log file. The ICU allows easy access to the pipc.log.

Point
The PI point is the basic building block for controlling data flow to and from the
PI Data Archive. For a given timestamp, a PI point holds a single value.
A PI point does not necessarily correspond to a “point” on the data source device. For
example, a single “point” on the data source device can consist of a set point, a process value,
an alarm limit, and a discrete value. These four pieces of information require four separate PI
points.

Service
A Service is a Windows program that runs without user interaction. A service continues to
run after you have logged off from Windows. It has the ability to start up when the computer
itself starts up.
The ICU allows you to configure a PI interface to run as a service.

Tag (Input Tag and Output Tag)


The Tag attribute of a PI point is the name of the PI point. There is a one-to-one
correspondence between the name of a point and the point itself. Because of this relationship,
PI System documentation uses the terms “tag” and “point” interchangeably.
Interfaces read values from a device and write these values to an input tag. Interfaces use an
output tag to write a value to the device.

128
Appendix F. Technical Support and Resources

For technical assistance, contact OSIsoft Technical Support at +1 510-297-5828 or


techsupport@osisoft.com. The OSIsoft Technical Support website offers additional contact
options for customers outside of the United States.
When you contact OSIsoft Technical Support, be prepared to provide this information:
 Product name, version, and build numbers
 Computer platform (CPU type, operating system, and version number)
 Time that the difficulty started
 Log files at that time
 Details of any environment changes prior to the start of the issue
 Summary of the issue, including any relevant log files during the time the issue
occurred
To ask questions of others who use OSIsoft software, join the OSIsoft user community,
PI Square. Members of the community can request advice and share ideas about the
PI System. The PI Developers Club space within PI Square offers resources to help you with
the programming and integration of OSIsoft products.

PI Interface for Foxboro I/A 70 Series 129


Appendix G. Revision History

Date Author Comments


05-Jul-2002 Etam Added section FoxAPI Version 5
08-Jul-2002 Chrys Format / style changes; added section breaks and
headers
22-Oct-2002 Etam v2.2.5; used interface skeleton v1.11
06-Apr-2004 Kmillar v.2.2.6.x; updates for version 2.2.6.x and clarification
of UserInt1, I/A string access and PI API/FoxAPI
version requirements.
27-Apr-2004 Chrys 2.2.6.23 Rev A: Standardized content
24-May-2004 KMillar 2.2.6.23 Rev B: Updated PI API version
recommendations
05-Nov-2004 KMillar 2.2.7.35: Updated PI API version recommendation to
be the latest version. Added notes on available debug
options.
19-Dec-2004 Mkelly Fixed headers and Footer. Added additional item for
the ICU Control section of the manual. Updated as
necessary for the latest interface skeleton manual.
25-Jan-2005 KMillar Added comment about not being able to use Foxboro
WP machines to run the interface. Converted slashes
to dashes for all command-line parameters.
26-Jan-2005 Mkelly Added new screen shot of the ICU control to show
two additional command-line parameters added.
Sample batch file for Windows missing failover
parameter.
18-Nov-2005 KMillar Added support storing I/A object status (Location3=0)
and Appendix E : FoxAPI Status Definition
05-Jan-2006 Janelle Version 2.3.1.44 Rev A: fixed headers and footers,
updated How to Contact us page; alphabetized
command line parameters; removed first person
references; added the service id configuration
information; added a sample fxbais.sh file; changed –
host from optional to required, for use with the ICU;
removed references to PI 2.
30-Jan-2006 Chrys Version 2.3.1.44 Rev B: Removed tracking; format
changes
09-Mar-2006 KMillar Add failover userint1 debug flag
14-Apr-2006 Janelle Version 2.3.2.45 Rev A: removed PI 2 references,
updated manual to latest skeleton
20-Apr-2006 Mkelly Version 2.3.2.45 Rev B: Fixed headers and footers,
updated ICU Control section with new screenshots
for latest version of PI ICU, rearrange table for length
in tag, ExDesc and InstrumentTag, reformatted
sample batch file for both Window and Solaris to
prevent wrapping of text.

PI Interface for Foxboro I/A 70 Series 131


Revision History

Date Author Comments


15-Nov-2006 Prowe Version 2.3.2.45, Rev C; Updated manual to Skeleton
v2.5.3, applied template and spell checked document
20-Apr-2007 KMillar Version 2.3.3.39 Updates for UniInt 4.3.0.36 and
PLI#11200OSI8 – clarify use of excdev
PLI#13955OSI8 – starting FoxAPI in Appendix D
PLI#13497OSI8 – workaround for running on I/A 8.2
Added UniInt health points to Failover appendix.
08-Jun-2007 Janelle Version 2.3.3.39 Revision A: update hardware
diagram, ICU screen shots
14-Jun-2007 KMillar Version 2.3.3.39 Revision B: added SetDeviceStatus
26-Aug-2009 KMillar Version 2.3.8.66: Updated to skeleton 3.0.9.
Rewrite the installation instructions for Solaris
PLI#16604OSI8 – PI API v0 required
PLI#15930OSI8 – Fix/clarify automatic startup
PLI#15759OSI8 – Clarify location3/uht_id usage
PLI#16950OSI8 – Clarify –foxapiname argument
PLI#15496OSI8 – Clarify failover watchdog object
PLI#15758OSI8 – Add failover status digital set text
PLI#19626 – Clarify output point syntax
PLI#19572 – Clarify iorates for failover
01-Oct-2009 Mkelly Version 2.3.8.66, Revision A; Fixed headers, footers,
and Hyperlinks. Reformatted tables, updated TOC.
28-Oct-2009 KMillar Version 2.3.8.66, Revision B; Fixed
LD_LIBRARY_PATH definition in PI-API installation
section.
19-Nov-2009 KMillar Version 2.3.8.66, Revision C; Fixed reference to
Appendix in Location3 section.
WI#120314 -–Fixed requirements for failover status
tags
31-Jan-2013 Mkelly Version 2.4.0.x; Updated to Interface Skeleton 3.0.36,
Updated ICU Control screenshots.
5-Feb-2013 KMillar Add AIM*API and Secure I/A notes
6-Feb-2013 Twilliams Updated title to use the modified interface name
18-Feb-2013 KMillar Version 2.4.0.x, Revision B; Added notes to the
Interface Installation and the Troubleshooting section
on clearing and resetting the FoxAPI lists.
27-Feb-2013 KMillar Version 2.4.0.x, Revision C; Added notes for
changing the FoxAPI/AIM*API configuration
parameters to the installation section.
26-Jul-2013 KMillar Version 2.4.0.x, Revision D; Clarify software versions
required for running on older I/A systems.
15-Aug-2014 KMillar Version 2.4.0.x, Revision E; Clarify that failover works
with both FoxAPI and AIM*API builds of the interface.

132
Date Author Comments
15-Jan-2016 KMillar Version 2.4.1.x, Revision A; Various updates
WI#107930 – Clarify event counters with failover
WI#108887 – Show AIM*API can be used for failover
WI#116198 – Clarify that using kill -9 to stop
processes applies only to Solaris
WI#119195 – Fix chapter numbering
WI#120562 – Clarify use of the useaimapi parameter
WI#120567 – Clarify when the open_action &
clsset_action scripts are needed
29-Jan-2016 KMillar Version 2.4.1.x, Revision B; Update to skeleton 3.0.4.
Changes to a Windows specific manual. Remove
Solaris specific documentation (this will be in a
separate manual for the Solaris version of the
interface)
17-Aug-2016 KMillar Version 2.4.2.x; Update version
18-Nov-2016 MMoore Version 2.4.2.x: Skeleton 3.0.43

PI Interface for Foxboro I/A 70 Series 133

S-ar putea să vă placă și