EasyManua.ls Logo

ABB PGC5000 Generation 2 - Create a New Script; Add;Run a Script

ABB PGC5000 Generation 2
142 pages
Print Icon
To Next Page IconTo Next Page
To Next Page IconTo Next Page
To Previous Page IconTo Previous Page
To Previous Page IconTo Previous Page
Loading...
892 J006 MNAH | PGC5000 G EN 2 | 119
The scripting language also supports invoking a script as a schedule entry and/or on the change of
state. A script is either an End-Of-Analysis (EOA) script or an event-driven script (a script that runs
during the analysis). The time offset (execution time) of the script determines the script type. If the
cycle time of the longest method in an analysis (analyses can have more than one method) is
exceeded by the time offset of the script, then it will be a script of End of Analysis type; otherwise it is
a script of event-driven type.
The time offset of a script, which script is an End-Of-Analysis type, does nothing more than to cause
that script to be identified as an End-Of-Analysis script by comparing its time offset with the cycle
time.
The End-Of-Analysis scripts are simply executed in bulk, in no particular order. The following are End-
of-Analysis scripting rules for analysis, method scoped and sequence scoped scripts.
All Analysis Scoped scripts are EOA scripts and must have an execution time greater than the
maximum Cycle Time of all contained Methods within that Analysis.
Any scripts at the Sequence and Method scope are EOA scripts if their execution time exceeds
the Cycle Time of the longest Method (e.g.: maximum Cycle Time). Scripts at Sequence or
Method scope having an execution time less than the longest Method's Cycle Time and greater
than the Cycle Time of the Method that contains it are considered in error.
A script at the Sequence or Method scope, whose execution time is less than the Cycle Time of
the Method that contains it, is allowed.
IMPORTANT NOTE: This type of script cannot perform the functions of an End-Of-Analysis script
because it runs within the Cycle Time of the Method containing it. It will not be able to operate on
or query the Analysis Report because that report does not exist until after the Analysis has been
completed.
An Analysis completes all EOA scripts executed irrespective of the execution time defined.
Example: An Analysis has two EOA scripts. Their execution times resolve to 181 and 182
seconds respectively. The analysis contains a Method with a maximum Cycle Time of 180
seconds. In this scenario, there is no guarantee as to which script gets executed first.
Line numbers are updated after a statement is added or deleted if the statement is not the last
statement in the script.
7.2.1 Create a new script
1. Select the Program tab to open the script editor.
2. Select the Create New Script icon.
3. Enter the name in the area provided.
4. Press the Accept button and the script input page appears.
5. Enter lines of script (see Figure 7-1).
6. Enter MAX TIME and (if applicable) choose AUTO RUN.
IMPORTANT NOTE: AUTO RUN starts the script at initial SBC power up and runs the script
continuously.
7. Save the script by selecting the Save icon.
7.2.2 Add/run a script
1. Select the Analysis tab.
2. Open an existing analysis by selecting the Add icon.
3. Choose location and press the Next button.
4. Choose the analysis name and press the Next button.
5. Confirm selections by pressing the Accept button.
6. To select the script insertion point, select the button. (The script TCF appears below the
selected button.)
7. Select the Add New icon.
8. Choose TCF Sequence Scope and press the Next button.
9. Choose Script and press the Next button to continue.
10. Confirm selections by pressing the Accept button.
11. Select the newly added script button.
12. Select the Tabular Editor subtab.
13. Enter a DESCRIPTION and a TIME OFFSET.
14. Select SCRIPT NAME from the drop-down list.

Table of Contents

Related product manuals