PARCscript Summary and Overview
  • 05 Oct 2023
  • PDF

PARCscript Summary and Overview

  • PDF

Article summary

This information is specific to the latest release of PARCview:

7.2.x


PARCscript relates to general scripting available in PARCview which could be client-side scripts or MDE scripting. There is also server-side scripting available that is handled by PARCCalcServer, but is outside the scope of this overview. Client-side scripts are ad-hoc using data available from the source; typically a Trend. MDE scripts are calculated by MDE displays using cell values but are historized into the MDE source unlike the client-side scripts that are ad-hoc.

Client-side scripts are divided into three categories: Expressions, Simple Formulas, and Advanced Formulas. The scripts are saved independently from any tag that calls it.

Expressions are one-line modifiers that perform specified calculations on normalized data and can be added onto the end of any tag. Using the syntax /EXPR=”expression” after a tags name will apply the expression. Ideal for short, simple mathematical calculations.

Simple Formulas are very similar to Expressions, but with some added flexibility. You can do multi-line scripts including declaring a few variables to store values in if needed and Formulas can also accept arguments created for it. Both Simple and Advanced use the syntax /CALC=Formula after a tags name will apply the script to the tag.

Advanced Formulas allow the most flexibility, but also require the most knowledge to get running. Advanced Formula are capable of advanced logic and program flow including arguments just like Simple Formulas.

The Script Editor Tool is your one stop shop for managing everything from running test code to creating independent CALC Source Tags that can be used throughout PARCview. A CALC Tag can have its own name, description, units, range, interpolation type, and draw mode like other process tags.


PARCSecurity Permissions

Script Editor is available for any user, but only those users and/or groups with the ‘Calc Builder’ PARCsecurity Console permission allowed will be able to create or modify CALC tags.

  • Calc Builder: Enables adding and editing adding Calc tags via the Script Editor


Configuration

PARCscript has no real configuration that’s necessary apart from ensuring the correct permissions have been setup for the users that need it. Default installs come with a single CALC Source, but more can be added. This is the Source that all new Calc Tags are created in by default.


Log Files

PARCmessage is built-in error monitoring software. It creates an ongoing log of errors generated from PARCview on the specific computer where PARCmessage is running. Some client-side error messages can appear here.

The Script Editor includes tabs (ErrorList, Output Console, Autos, Calc View, and Settings) at the bottom of the Tool that will become useful when building scripts but can be limited in the type of errors that are shown.

Errors can also be stored in the PARCview install directory...\Capstone\PARCView\LogFiles


Required Server Applications

PARCAlarm Server: The server application generates Alarm events based on the Alarm Rules defined in the Alarm Configuration area.

UA Server: All PARCview vr 7 functionality requires a Universal Access (UA) server.

GDS: All PARCview vr 7 functionality requires a Global Discovery Server (GDS).


Was this article helpful?