EM3270 Manual

Installation of Alternate Procedure
E-12 110332Tandem EM3270 Manual
Color-Mapping and Function-Key Mapping
Installation of Alternate Procedure
The alternate function-key mapping procedure is installed using the following command
sequence:
TAL/IN mapscr, OUT $s/mapobj
BIND/IN cmdfile, OUT $s/
where cmdfile contains, for the Tandem terminal:
ADD * FROM $system.system.EM3270
REPLACE CODE user^function^key^mapping FROM mapobj
BUILD $system.system.EM3270X, inspect on, data 64 pages
The new object file $system.system.EM3270x can then be specified in a SET
PROGRAM command.
Figure E-8. Procedure for PCT Function-Key Mapping for IBM 5250 Data-Stream
Sessions
PROC user^function^key^mapping^tnt^5 ( key^value, key^index );
INT key^value, ! Contains the 6530 function key value
! upon entry
.key^index; ! Contains the EM3270 key index on the
! return
LITERAL f1 = %100,
f^return = %126,
sf1 = %140,
sf^return = %166;
BEGIN
! Table for conversion of PCT function keys to 5250 AIDS
INT f^to^aid [0:45] = 'p' :=
[ 5, 6, 7, 8, 9, 10, 11, 12, ! F1 - F8
13, 14, 15, 16, -4, 39,-14,-15, ! F9 - F16
-7, -6, 36, 37,-13, -1, 0, ! ALT UP ARW -
ENTER
17, 18, 19, 20, 21, 22, 23, 24, ! SF1 - SF8
25, 26, 27, 28, -9, 4, -2, -3, ! SF9 - SF16
-8,-10,-12, -11, 38, -1, 40 ]; ! ALT SHFT UP ARW
-
! SHFT ENTER
IF key^value >= f1 AND key^value <= f^return THEN
key^index := f^to^aid[key^value - %100]
ELSE IF key^value >= sf1 AND key^value <= sf^return THEN
key^index := f^to^aid[key^value - %111]
ELSE key^index := -1; ! Invalid key^value - ignore
END;