EasyManua.ls Logo

GSE 574 - Page 188

Default Icon
339 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...
GSE Scale Systems - 169
Chapter 16 Macro Programming Operations Technical Reference Manual
simply leave a value unchanged if the operator simply
presses < ENTER > without making an entry. However
other situations may require that the operator definitely
key in a value. This command can be used together with
the TAG and JUMP commands to repeat a %G prompt
until the operator actually makes an entry. In other
applications, a default value may need to be entered if the
operator has not made the requested entry.
Example:
80%s Select var #1.
%T TAG this location to allow a branch
back to here.
KeyinTargt%G Prompt operator and wait for response.
%\ IF NO ENTRY...
%J JUMP back and re-prompt operator.
%E ENDIF
%e Store away operator entry.
x%@ Set delay for subsequent PAUSE commands
This command allows the delay incurred during the
PAUSE command to be set to the desired time duration.
The variable delay for the macro's pause (%P) command,
x%@, has been enhanced. The delay may now be
fractional (with resolution to around 1/20th of a second)
and may be as long as 5 million seconds. This is over 57
days.
n%_ IF DATABASE ERROR
This command can be used to check for any error or a
specific error that may have occurred during the last
DATABASE operation. If the "n" preceding the %_
command is omitted then the IF clause can be interpreted
as "IF ANY DATABASE ERROR". If a numeric value
precedes the %_ command then the IF clause is testing
for that specific error number. If 0%_ is used, the IF
clause is effectively "IF NO DATABASE ERRORS".
Using these commands virtually any database error that
may occur can be handled appropriately within a macro.
The error code definitions are listed below.
0 No error occurred.
1 Bad entry. Did not meet criteria for the
parameter being accessed.
2 Invalid database selection. Database not
defined.
3 Invalid column selection. Specified column not
defined in current database.
4 Record not found.
5 Out of Data Storage Memory
6 Sumcheck error. The accessed row's data
appears corrupted.
7 List Corrupt. The list of rows stored in
memory is not in tact.
8 Operation aborted. The search, print, sort, or
upload was aborted.
9 "IDtooLong!"
Example 1:
%_ IF ANY DATABASE ERROR...
Any Error%P Displays prompt if any error occurred.
%E ENDIF
Example 2:
4%_ IF RECORD NOT FOUND...
%5 Call macro 5 (if error 4 occurred).
%E ENDIF
Comparing a Parameter's Numeric Value as to
whether its (>, < or =) another Parameter's Numeric
Value,
"IF" commands (>, < or =)%'
The (%') command is used to compare two parameters to
each other or compare a parameter to a fixed number.
The compare function is dependent on what equation
character preceeds the (%') ie. (>, < or =). Some of the
same comparisons performed below can be accomplished
using setpoints. These commands in some respect
expand these capabilities within a macro.
1. Comparing two parameters can be done in
three ways, greater than, less than or equal to.
The statements below are used to compare any
parameter to another. ("n" is the variable
compared to the "m" variable). The "P" should
be placed immediately following the m variable
so as the firmware recognizes it as a parameter
and does not mistake it for a fixed number.
The %' is the completion of the compare
statement.
n>mP%'
n<mP%'
SECTION - 16.8

Table of Contents