BPX1TST (tcsettables) example

The following code sets code page names, conversion tables and Code Page Change Notification (CPCN) capability. For the callable service, see tcsettables (BPX1TST, BPX4TST) — Set terminal code page names and conversion tables. For the data structure, see BPXYTCCP — Map the terminal control code page structure. AMODE 64 callers use BPX4TST (tcsettables) example.
                                              
         XC    TCCP(TCCP#LENGTH),TCCP  Clear area                       
         OI    TCCPFLAGB4,TCCPFASTP  Set local translation              
         MVC   TCCPSRCNAME(8),=CL8'IBM-1047'  Set source code page name 
         MVC   TCCPTRGNAME(9),=CL9'ISO8859-1' Set target code page name 
         MVC   TBLSOURCE,..          Initialize source conversion table
         MVC   TBLTARGET,..          Initialize target conversion table
         SPACE ,                                                        
         CALL  BPX1TST,              Set code page names and tables    +
               (=A(STDIN_FILENO),    Input: File descriptor            +
               =A(TCCP#LENGTH),      Input: Length of BPXYTCCP         +
               TCCP,                 Termcp structure, BPXYTCCP        +
               TBLSOURCE,            Source conversion table           +
               TBLTARGET,            Target conversion table           +
               RETVAL,               Return value: 0 or -1             +
               RETCODE,              Return code                       +
               RSNCODE),             Reason code                       +
               VL,MF=(E,PLIST)       ----------------------------------