EM3270 Manual
Color-Mapping and Function-Key Mapping
Tandem EM3270 Manual—110332 E-11
Alternate Function-Key Mapping
Figure E-7. Procedure for Terminal Function-Key Mapping for IBM 5250 Data-
Stream Sessions
PROC user^function^key^mapping^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;
INT f^to^aid [0:45] = 'p' :=
[ 5, 6, 7, 8, 9, 10, 11, 12, ! F1 - F8
13, 14, 15, 16, 36, 37,-14,-15, ! F9 - F16
-6, 39, -7, -4,-13, -1, 0, ! ROLL UP -
RETURN
17, 18, 19, 20, 21, 22, 23, 24, ! SF1 - SF8
25, 26, 27, 28, -9, 4, -2, -3, ! SF9 - SF16
-10,-12, -8, -11, 38, -1, 40 ]; ! SROLL UP -
SRETURN
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;