Home 

     Systems Engineering 
     Subsea Control Systems 
     Software Development 
     Products and Applications 
     Tech Info 
     Contacts & Key Personnel 
      Products and Applications

     ZCalc Service 
    The Process IT Development ZCalc Service is an OPC client application that runs as a
    Windows NT service.

    It calculates the gas compressibility of multiple gas streams online using the Peng-Robinson
    Equation of State (EOS).

     

     Installation 
    Two install files are required:
     a. Microsoft Installer package for the ZCalc Service (1.3MB) Download
     b. Northern Dynamics OPC Automation DLL Installer (5.3MB) Download

     
    Note
    The download for the ZCalc Service includes some configuration files which demonstrate its use with an OPC server - in this case the Process IT Simulation OPC Server. The installation and configuration of the Simulation OPC Server is covered in the Tech Info section.
     

    There are three steps in the installation of the ZCalc Service:

    1. Run the Northern Dynamics installer to install the OPC Client DLL
    2. Run the Microsoft Installer package to install the main executable (ZCalcSvc.EXE)
    3. Run the InstallService.bat file to register ZCalcSvc.EXE as a Windows Service.

     Configuration 
    The ZCalc service uses an INI file for its main configuration data. It first looks for a file called 'YourMachineName'.INI (where 'YourMachineName' is the name of your PC), and if that is not found then it looks for a file called ZCalcSvc.INI.

    If the ZCalc service is licensed (see below), by default the license key will be written to a file called 'YourMachineName'.INI - this is just to simplify distribution of license keys. For example, if your PC is called JUPITER, the license key would be an entry in the file JUPITER.INI.

    Demo versions will therefore most likely use the ZCalcSvc.INI file as the configuration file.

     
     Section [ZCalc Service] 
    In the root of the configuration file, the elements are:

    LicenseKey
    The license key for the ZCalc Service is a string in the configuration INI file. For example: LicenseKey=1234-5678

    The license key string is based on the machine name and hard disk ID. Anything other than a valid string (for example LicenseKey=Demo) is treated as a demo license. After 2 hours, the service will stop writing the calculated compressibility to the nominated OPC server tags.

    OPC Server
    This specifies the OPC server that is the source of the process data (pressures and temperatures). The calculated compressibility is also written back to a specified tag in the same OPC server.

    For demonstration purposes, the ZCalc Service has been set up to use the Process IT OPC Simulation server. This can easily be changed to the relevant OPC server for your installation.

    The OPC Server is specified with the following directive:
    OpcServer=ProcessIT.SimulationSvr.1

    If in doubt as to the correct name of the OPC server to use, an easy approach is to use an OPC client and browse for available servers.

    Tag Definition File
    The Tag Definition file is a comma separated (CSV) file. Each record in the file represents a different gas stream.

    It is suggested that the tag definition file be given a name consistent with the OPC server with which it interfaces. For example, the file ProcdevSim.csv is the CSV file defining the gas streams in the Process IT Development OPC simulator demo:

     
       
     

    IMPORTANT
    OPC tag names are case sensitive

    There are eleven columns:

    1. Tag
      This is a short-form name for the gas stream. If omitted, it defaults to 'Stream N' where N goes 1,2,3,4 etc...
      It is recommended that this be kept relatively short, as this appears in the list box on the main page of the ZCalc Service.

    2. Pressure
      Name of the pressure OPC tag. The format of this tag will depend on the configuration of your OPC server. It could be something like 23PI0034.PV as shown below, or it could be something like RTU5.HoldingReg003.Float
      The engineering units can be bar, psi or kPa

    3. Temperature
      Name of the temperature OPC tag
      The engineering units can be degrees Celcius or Fahrenheit

    4. Z
      This is the tag that is to receive the calculated Z value calculated and written by the ZCalc Service. It must therefore be possible to write to this tag in the OPC server.
      This field can be left blank, in which case the compressibility factor is not written to the OPC server. This may be useful during testing. A warning is given in the log file if this field is blank.

    5. Critical Pressure
      This can be either a constant, or it can refer to a tag in the OPC server

    6. Critical Temperature
      This can be either a constant, or it can refer to a tag in the OPC server

    7. Acentric Factor
      From PVT results

    8. EU Pressure
      Allowable entries are Bar, Psi or kPa, although it is not case-sensitive. Gauge pressure is assumed, although can be made expicit with a trailing "G", or absolute specified with a trailing "A", for example:
      • bar
      • bar G
      • psi A
      Note that this field is not case sensitive, so "bar g" is the same as "bar G" or "BAR G"

    9. EU Temperature
      Allowable entries are degrees Celcius or degrees Fahrenheit. This can be written with or without a space, for example:
      • degC
      • deg C
      • degF
      • deg F
      Note that this field is not case sensitive, so "deg c" is the same as "deg C" or "DEG C"

    10. Status
      This is a tag in the OPC server to which the ZCalc service will write the status as a floating point number. This field can be left blank, in which case the status will not be written to the OPC server. A warning is given in the log file if this field is blank.

    11. Description
      A description for the stream (optional)

     

    IMPORTANT
    The critical pressure (Pc) and critical temperature (Tc) must be specified in absolute units consistent with the engineering units for the actual pressure and temperature.

    For the pressure, the supported engineering units are:
    Actual PressureCritical Pressure
    bar A, bar Gbar
    psi A, psi Gpsi
    kPa A, kPa GkPa

    For temperature, the supported engineering units are:
    Actual TemperatureCritical Temperature
    deg CKelvin
    deg FRankine

    The engineering units used for critical pressure and critical temperature are inferred from the engineering units specified for actual pressure and actual temperature, based on the above table.

     

    Visible at Run Time
    It is suggested that the service is initially run as visible - this allows the service to interact with the desktop, so it is easier to test the application. The service will be visible if the Visible setting is set to Yes, True or 1. e.g. Visible=Yes

    In a field installation, it is probably better to set the service so that it is not visible. This can be done by setting the Visible setting to No,False or 0. e.g. Visible=No

    UpdateIntervalSeconds
    This specifies the OPC update interval. An interval of 5 seconds is usually sufficient.

    StartupDelaySeconds
    This is the length of time the service should wait at startup before attempting to connect to the OPC server. This parameter is useful when the PC is rebooted or powered-up, so that there is some control over the startup of OPC clients.

     Account 
    By default, the ZCalc Service runs under the Local System account:

    You may wish to change the account for the ZCalc Service, in the event that the OPC server that you are connecting to runs under a different account.

    Note that you may need to change the OPC server's DCOM settings (using DCOMCNFG) to grant the selected account permission to launch and access the OPC server.

     
     Problems or Questions 
    Please get in touch by telephone or email in the event of any problems with the installation or operation of the ZCalc Service.
    Tel: +47 99724942
    Alternatively, from 0800 to 1800 Western European time: +47 55009860
    Email: