Micromod MOD: 30ML Display Script Guide User Manual
Page 63

MOD 30ML Display Guide
Application Examples
5.3 Example 3: PID & Totalizer Operation on a Single Display
In this example, one Tag display is used for PID loop operation and display/operation of
an indicating totalizer. The Totalizer value and commands appear only when requested.
This is the script used for the compound PIDTOT1 included in Visual Application
Designer’s Project Gallery.
In addition to changing the Output and Setpoint values on Line 6, the Scroll key is used to
display total value and to activate the Totalizer commands: RUN, HOLD, RESET, STOP
and EXIT.
The complete script for this example is shown in the next figure. Much of it is identical to
the first example. Four new inputs and two new formats must be added to those shown in
Example 1, and two new State Tables added to the State Table file.
Script for PID and
Totalizer Operation
DEFAULTS:
{
MANUAL_PRESSED:
{
IF OPMS != 3 THEN
{
OPMS = 0;
#LINE5 = " OP";
#LINE6.SRC = OP;
}
}
AUTO_PRESSED:
{
IF OPMS != 3 THEN
OPMS = 1;
}
SCROLL_PRESSED:
{
#UPDN = 7;
IF SCRLCNT >= 2 THEN
SCRLCNT = 0;
ELSE SCRLCNT = SCRLCNT + 1;
CASE SCRLCNT OF
{
0:
#LINE5 = " OP";
#LINE6.SRC = OP;
BREAK;
1:
#LINE5 = " SP";
#LINE6.SRC = SP;
BREAK;
2:
#LINE5 = "TOT";
#UPDN = 1;
#LINE6.SRC = TOTAL;
BREAK;
}
}
UP_PRESSED:
Arrow keys are under ‘system’
control
Causes UP arrow to appear
Change control mode to AUTO
unless mode is already TRACK
Changes control mode to MANUAL
unless mode is already TRACK.
Displays output value on Line 6.
Displays TOT
on Line 5
Current total appears on Line 6
5 - 9
If input DELTA is true (1) then show