function sequence tables (fst) referencekernassociatesinc.com/services/function sequence...

14
This document is protected under United States copyright laws and international treaties and may not be duplicated or distributed. Any use of the contents in any form other than preparing information for our client is prohibited without the express written consent of Kern & Associates, Inc., P O Box 445, Marshalltown, IA 50158 U.S.A. Copyright © 1996-2007 Kern & Associates, Inc. All rights reserved. Function Sequence Tables

Upload: truongminh

Post on 24-Aug-2018

234 views

Category:

Documents


1 download

TRANSCRIPT

Page 1: Function Sequence Tables (FST) Referencekernassociatesinc.com/services/Function Sequence Tables.pdf · FST Development Environment FST (Function Sequence Table) creation, maintenance

This document is protected under United States copyright laws and international treaties and may not be duplicated or distributed. Any use of the contents in any form other than preparing information for our client is prohibited without the express written consent of

Kern & Associates, Inc., P O Box 445, Marshalltown, IA 50158 U.S.A.

Copyright © 1996-2007 Kern & Associates, Inc. All rights reserved.

Function Sequence Tables

Page 2: Function Sequence Tables (FST) Referencekernassociatesinc.com/services/Function Sequence Tables.pdf · FST Development Environment FST (Function Sequence Table) creation, maintenance

TABLE OF CONTENTS

FST Development Environment............................................................................1

Accessibility of HP Software Points ......................................................................2

Watch Dog Timer..................................................................................................4

Pulse Output FST .................................................................................................5

Stacked Differential Pressure Switching FST .......................................................6

Pressure Override FST.........................................................................................7

YZ Pump (Odorization) FST .................................................................................8

William Pump (Odorization) FST ..........................................................................9

Output Rate FST.................................................................................................10

Run Switching FST .............................................................................................11

Page 3: Function Sequence Tables (FST) Referencekernassociatesinc.com/services/Function Sequence Tables.pdf · FST Development Environment FST (Function Sequence Table) creation, maintenance

FST Development Environment FST (Function Sequence Table) creation, maintenance and review are performed using Excel as the design environment. The use of Excel as the design environment permits easy access and viewing of all FST. A single sheet represents an individual FST. This also permits all FST to reside in a single spreadsheet. When developing a new FST, the designer can copy fragments from an existing FST or develop standardized fragments to incorporate. This standardization permits the developer, as well as the field technician, to diagnose problems with greater ease since there is familiarity with portions of the FST rather instead having to determine the function each line performs.

In addition, the development environment permits the use of comments which simplifies the task of revisiting a FST and understanding its functionality. The use and incorporation of comments permits the designer to document or describe the functionality each line performs.

An Excel macro is used to export the FST from the development environment to a disk file in the appropriate format. There is also a macro to perform an import of a FST from disk file into the development environment.

© 1996-2007 Kern & Associates, Inc. 1

Page 4: Function Sequence Tables (FST) Referencekernassociatesinc.com/services/Function Sequence Tables.pdf · FST Development Environment FST (Function Sequence Table) creation, maintenance

© 1996-2007 Kern & Associates, Inc. 2

Accessibility of HP Software Points The FST (Function Sequence Table) Programmability of the ROC uses a ROC softpoint as an interface to exchange data with the HP software points. Care should be taken when using ROC “softpoint # 32” since this point is used to read and write the HP software points.

Note

In addition, caution should be taken when accessing HP data when multiple FSTs address “ROC softpoint # 32” simultaneously. If multiple FSTs addressing “ROC softpoint # 32” are required, then use some form of handshaking between the FSTs to inform the other that accessing “ROC softpoint # 32” is currently unavailable; otherwise, conflicting data can be read or written.

Accessing HP Data

The data contained in the HP Emulation Program database can be accessed from the FST by specifying the IOM, Channel, Function Block, Parameter, and Index of the data in question with “ROC softpoint # 32”, data registers 1 through 7.

Data # 1 = Instruction and Response 0 = Inactive or OK 1 = Read 2 = Write -x = Error Code Data # 2 = IOM Data # 3 = Channel Data # 4 = Function Block Data # 5 = Parameter Data # 6 = Index Data # 7 = Data

To read a value, set Data #2 to the IOM number, set Data #3 to the Channel number, set Data #4 to the Function Block, set Data #5 to the Parameter number, and if an array, set Data #6 to the element of the array. The next step would be to set Data #1 to a value of "1" to specify a read operation. When the operation is complete, Data #1 returns to "0" and the requested value is in Data #7.

To write a value, set Data #2 to the IOM number, set Data #3 to the Channel number, set Data #4 to the Function Block, set Data #5 to the Parameter number, and if an array, set Data #6 to the element of the array. Set Data #7 to the value to be written to the specified location. The next step would be to set Data #1 to a value of "2" to specify a write operation. When the operation is complete, Data #1 returns to "0".

Page 5: Function Sequence Tables (FST) Referencekernassociatesinc.com/services/Function Sequence Tables.pdf · FST Development Environment FST (Function Sequence Table) creation, maintenance

© 1996-2007 Kern & Associates, Inc. 3

If an error should occur during a read or write operation, Data #1 becomes a negative number specifying the error type. The errors are:

-1 = Illegal IOM -2 = Illegal Channel Number for IOM -3 = Function Block does not exist -4 = Parameter does not exist -5 = Field IOM does not exist -6 = Channel not in database -11 = Invalid Index specifier -12 = Data type mismatch -29 = Cannot write to this parameter

Page 6: Function Sequence Tables (FST) Referencekernassociatesinc.com/services/Function Sequence Tables.pdf · FST Development Environment FST (Function Sequence Table) creation, maintenance

Watch Dog Timer The following fragment calculates the number of 15 second intervals since midnight. The purpose of this fragment is to signal that the FST is executing regularly (i.e., heartbeat) while not necessarily indicating whether or not the FST is functioning correctly. The importance of incorporating this or something similar is that a host computer system can generate an alarm should the scanned value differ greatly from the host calculated number of 15 second intervals; or, if the scanned value has not changed since the last scan (remember to take into account that the timer only updates every fifteen seconds and not scan too frequently, but instead only as often as some multiple of fifteen seconds.) The alarm would alert the operator to the detection of a problem with the FST. This is only one example of a timer. Other formats (e.g., “hhmmss”) could be implemented also.

© 1996-2007 Kern & Associates, Inc. 4

Page 7: Function Sequence Tables (FST) Referencekernassociatesinc.com/services/Function Sequence Tables.pdf · FST Development Environment FST (Function Sequence Table) creation, maintenance

Pulse Output FST This FST outputs a single pulse for each 1 MCF accumulated. This pulse output permits a second device to measure and report volumes calculated by this device.

The following table lists the parameters being used by the FST. These parameters are used to store data and should not be altered.

Parameter Value Description of Use Point Tag Id. FST SEQ#1 Result Register .0000000 Register #1 .0000000 Day Record Register #2 .0000000 Current Hour Register #3 .0000000 Accumulator Register #4 .0000000 Current Hourly History Value Register #5 .0000000 Register #6 .0000000 Temporarily Save Hour Register #7 .0000000 Count Instances New Hour Detected Register #8 .0000000 Error Reported When Interfacing HP Data Register #9 .0000000 Perform Initialization Register #10 .0000000

© 1996-2007 Kern & Associates, Inc. 5

Page 8: Function Sequence Tables (FST) Referencekernassociatesinc.com/services/Function Sequence Tables.pdf · FST Development Environment FST (Function Sequence Table) creation, maintenance

Stacked Differential Pressure Switching FST This FST switches between three differential pressure transmitters for the measurement of differential pressure. Each transmitter is calibrated for a portion of the total span yet they overlap to permit switching from one range to the next. Measurement is taken from only one transmitter. Its process value is compared against setpoints, and when the setpoint is traversed then the measurement is taken from the transmitter defined for the span the process value has entered.

© 1996-2007 Kern & Associates, Inc. 6

Page 9: Function Sequence Tables (FST) Referencekernassociatesinc.com/services/Function Sequence Tables.pdf · FST Development Environment FST (Function Sequence Table) creation, maintenance

Pressure Override FST This FST monitors outlet pressure. Should the outlet pressure exceed the maximum allowable operating pressure (MAOP), then the FST overrides current set point(s) being sent to a smart regulator. The override action implemented decrements the set point(s) to the smart regulator by 10 every two minutes while the outlet pressure exceeds MAOP. Once the outlet pressure is measured within MAOP, the FST will cease overriding the set point(s), which are set by Gas Control. In addition, Gas Control is monitoring the pressure, also. Finally, the FST does not attempt to control the outlet pressure to MAOP.

© 1996-2007 Kern & Associates, Inc. 7

Page 10: Function Sequence Tables (FST) Referencekernassociatesinc.com/services/Function Sequence Tables.pdf · FST Development Environment FST (Function Sequence Table) creation, maintenance

YZ Pump (Odorization) FST There are several variants of this FST. The differences result due to varying forms of measurement (primary, secondary, as well as the possibility of a signal from the supplier.) There is a common interface shared by all variants. It is through this interface that the form of measurement and any supporting constants are communicated. This permits the capability to switch from one measurement to the other and to download conversion factors. Another difference can be the number of runs comprising the station.

The FST calculates an odorization rate based on the hourly flow rate or the rate can be set manually. An output signal (4-20 milliamps) is sent to the odorizer. In addition, the RTU receives feedback from the odorizer both in pulses (which indicates an odorization rate) as well as a status (which signals an alarm.) Real-time monitoring permits the SCADA Host to determine whether or not the RTU and the odorizer are operating properly.

© 1996-2007 Kern & Associates, Inc. 8

Page 11: Function Sequence Tables (FST) Referencekernassociatesinc.com/services/Function Sequence Tables.pdf · FST Development Environment FST (Function Sequence Table) creation, maintenance

William Pump (Odorization) FST The William Pump odorization FST outputs a pulse to activate a relay, which provides power to activate the pump. The pulse output cycle is configurable in order to permit the pump sufficient time to fully stroke and retract. The RTU also counts the number of times the relay switch opens and closes. Real-time monitoring permits the SCADA Host to determine whether or not the RTU and the odorizer are operating properly.

© 1996-2007 Kern & Associates, Inc. 9

Page 12: Function Sequence Tables (FST) Referencekernassociatesinc.com/services/Function Sequence Tables.pdf · FST Development Environment FST (Function Sequence Table) creation, maintenance

Output Rate FST The output rate FST is useful to output an analog signal to another device. Whenever the rate differs from the output, then the output changes to reflect the rate.

© 1996-2007 Kern & Associates, Inc. 10

Page 13: Function Sequence Tables (FST) Referencekernassociatesinc.com/services/Function Sequence Tables.pdf · FST Development Environment FST (Function Sequence Table) creation, maintenance

Run Switching FST The run switching FST is used to deploy flow measurement across multiple metering runs by limiting or controlling which meters are used. In this example, there are three meter runs being controlled. Two of the meters are the same size and the third meter is half that size. There is a stepping order or sequence to be followed when switching amongst the three meters. The current state of the runs as well as the flow rate determines the opening and closing of the individual meter runs. The FST includes delay timers as well as other checks to insure that certain events occur appropriately.

The FST includes a watchdog timer to verify that the FST is active and provides a status indicator for the host monitoring system to generate an alarm accordingly.

A status field is provided for the host computer to report each meter switching event. A change of meter configuration would also be evident from flow rate changes.

The FST generates a third-party (customer) pulse for each MCF accumulated.

In addition to the primary run-switching logic there is a secondary FST that acts as a safety mechanism and allows the operator to override the run-switching logic and open the two largest runs followed by the closing of the remaining run.

While in the normal mode of operation the FST also monitors outlet pressure. If the outlet pressure drops below a preset minimum, two of the runs are opened and the remaining run is closed.

Both FST support auto-manual mode for local maintenance activities and the secondary FST includes a watchdog timer mechanism for host system monitoring.

© 1996-2007 Kern & Associates, Inc. 11

Page 14: Function Sequence Tables (FST) Referencekernassociatesinc.com/services/Function Sequence Tables.pdf · FST Development Environment FST (Function Sequence Table) creation, maintenance

Finally, there are a number of values and statuses provided for monitoring and reporting operational events and alarms.

© 1996-2007 Kern & Associates, Inc. 12