GSE Scale Systems - 167
Chapter 16 Macro Programming Operations Technical Reference Manual
%%N%e otherwise (if not between 0
and 9)
229%%(%e if next key is [ENTER]...
%%]%e retrieve entry....
;21%%C%e and copy it into ID 1.
%%B%e and then break (done!).
%%N%e otherwise (if not between 0
and 9 and not [ENTER])
233%%(%e if next key is [ID]...
%%]%e retrieve entry....
%% %e back-space one character
%%[%e save new entry
%%N%e otherwise (if not any of above
characters)
Must!be0-9%%P%e warn of improper entry...
%%E%e end if
%%]%e retrieve entry for display
%%\%e if no entry...
%%J%e jump to start
%%N%e otherwise (valid entry has
begun)
%%I%e display entry
2%%J%e jump back for next character
CLEAR Keypad and/or RS-232 Receive Buffer "%)"
A macro may clear out either the one character keypad
buffer, the RS-232 receive buffer, or both buffers. Refer
to the following variations to the command:
%) Clear both the RS-232 receive buffer
and the keypad buffer.
1%) Clear the front panel keypad buffer.
2%) Clear the RS-232 receive data buffer.
Determine String Length: xx,yy%C
This macro command allows comparisons to be made on
alpha-numeric data:
where 'xx' represents a numeric parameter ID and 'yy' an
alpha parameter ID.
If an alpha type parameter (ID 1 - 6) is copied to a
numeric type parameter (Vars, Regs, tare, etc...), then the
numeric parameter is set to the number of characters
entered in the alpha parameter. This can be used in
conjunction with a setpoint to insure an operator entry
always consists of a certain number of characters. Note
that the numeric parameter may be any numeric
parameter, including the time/date parameter ID's 50 -
54.
Examples:
%T Tag location
Enter ID%G Prompt and get operator
entry.
%\ If no entry...
%J Jump to tag.
%E End IF
;21%C Store entry in ID 1.
21,88%C set Var 8 = to number of
characters entered.
1%F If setpt 1 is inactive... (setpt 1
would be setup to be active
between the desired range for
number of characters entered.
EntryMust%P Warn operator
be 5 long!%P Complete warning.
%J Jump to Tag.
%E End IF.
Compare Two Strings: xx,yy%-
or... aaaa;yy%-
This macro commands allow comparisons to be made on
alpha-numeric data: where 'xx' and 'yy' represent alpha
parameter ID's, and 'aaaa' represents alpha text.
This variation of the subtract command actually operates
the same as a standard IF statement. Two alpha values
are compared to determine if they are exactly the same.
This ability allows a simple method of verifying the
proper entry of an access code. Also, this command may
be used in critical data entry situations where the
operator is required to key in a value twice in order to
insure that a mistake is not made.
Example:
New ?Targt%Y Prompt operator, if
[ENTER]...
%N Otherwise
%B Break... ie abort macro.
%E End IF.
191823;26%C Store correct code into ID 6.
%T Tag location.
EnterCode:%G Prompt operator, get code
entry.
;26%- Compare entry to correct
code. if same...
EnterTargt%G Prompt operator, get target
weight entry.
;80%C Store entry into Var #0.
%N otherwise
SECTION - 16.8