Pathway/iTS TCP and Terminal Programming Guide

Writing User Conversion Procedures
Compaq NonStop™ Pathway/iTS TCP and Terminal Programming Guide426751-001
4-15
Intelligent Device Output Procedures
items cannot. Declarations for the numeric and alphanumeric device output procedures
are shown in Figure 4-10 and Figure 4-11.
USERCODE
contains the numeric literal specified in the USER CONVERSION clause. The
procedure uses the supplied value of this parameter to determine which subset of
code to execute.
OUTPUT
contains the string of characters to be sent to the intelligent device. The TCP
expects OUTPUT to contain the value from INTERNAL as converted by this
procedure.
OUTPUT^LEN
contains the number of characters in the output message (the data pointed to by
INTERNAL). If the user conversion procedure changes this length, it should set
Figure 4-10. Device Numeric Output Procedure Declaration
PROC USER^NUMERIC^OUTPUT^MSG^CONV ( USERCODE, OUTPUT,
OUTPUT^LEN, MAX^OUTPUT^LEN, INTERNAL, INTERNAL^SCALE,
FILL^CHAR, FILL^OFF );
INT USERCODE; ! Supplied by TCP
STRING .EXT OUTPUT; ! Generated by user procedure
INT .OUTPUT^LEN; ! Supplied by TCP; modifiable by user
INT MAX^OUTPUT^LEN ! Supplied by TCP
FIXED .INTERNAL; ! Supplied by TCP
INT INTERNAL^SCALE; ! Supplied by TCP
STRING .FILL^CHAR; ! Supplied by TCP
INT FILL^OFF; ! Supplied by TCP
Figure 4-11. Device Alphanumeric Output Procedure Declaration
PROC USER^ALPHA^OUTPUT^MSG^CONV ( USERCODE, OUTPUT,
OUTPUT^LEN, MAX^OUTPUT^LEN, INTERNAL, INTERNAL^LEN,
FILL^CHAR, FILL^OFF, RIGHT^JUSTIFIED );
INT USERCODE; ! Supplied by TCP
STRING .EXT OUTPUT; ! Generated by user procedure
INT .OUTPUT^LEN; ! Supplied by TCP; modifiable by
user
INT MAX^OUTPUT^LEN ! Supplied by TCP
STRING .EXT INTERNAL ! Supplied by TCP
INT INTERNAL^LEN; ! Supplied by TCP
STRING .FILL^CHAR; ! Supplied by TCP
INT FILL^OFF; ! Supplied by TCP