1 /* ====== BEGIN INCLUDE SEGMENT         apl_dim_sdb.incl.pl1 ====================================== */
  2 
  3 /* format: style3,initlm0,idind30 */
  4 dcl       sdb_ptr                       ptr;
  5 
  6 dcl       1 stream_data_block           aligned based (sdb_ptr),
  7             2 outer_module_name         char (32) init (my_name),
  8                                                             /* standard I/O System SDB header */
  9             2 device_name_list_ptr      ptr init (addr (stream_data_block.device_name)),
 10             2 device_name               aligned,
 11               3 next_ptr                ptr init (null ()),
 12               3 name_size               fixed bin init (length (att_stream)),
 13               3 name                    char (32) init (att_stream),
 14             2 device_iocb_ptr           ptr,                /* ptr to IOCB for sdb.name */
 15             2 iocb_ptr                  ptr,                /* ptr to IOCB for this attachment */
 16                                                             /* info about conversion tables */
 17             2 sequence_table_ptr        ptr,                /* points to escape sequences in use */
 18             2 device_info_ptr           ptr init (null ()), /* pointer to dev-info table */
 19             2 conv_tab_ptr              ptr init (null ()), /* pointer to conversion tables */
 20             2 compression_in_ptr        ptr initial (null ()),
 21                                                             /* pointer to compression input table */
 22             2 compression_out_ptr       ptr initial (null ()),
 23                                                             /* pointer to compression output table */
 24                                                             /* parameters of the device */
 25             2 keying_time               fixed bin (71) init (0),
 26                                                             /* keying time of device */
 27             2 max_col                   fixed bin init (-1),/* number of columns per line */
 28             2 max_line                  fixed bin init (-1),/* number of lines per frame */
 29             2 actcol                    fixed bin init (0), /* present column */
 30             2 actline                   fixed bin init (0), /* present line */
 31             2 actshift                  unal bit (2) init ("11"b),
 32                                                             /* present shift */
 33                                                             /* modes of the device */
 34             2 tabm                      unal bit (1) init ("1"b),
 35                                                             /* tabs may be used */
 36             2 conm                      unal bit (1) init ("1"b),
 37                                                             /* canonicalization should be performed */
 38             2 graphic                   unal bit (1) init ("0"b),
 39                                                             /* graphic mode */
 40             2 escm                      unal bit (1) init ("1"b),
 41                                                             /* processing escapes on input */
 42             2 erklm                     unal bit (1) init ("1"b),
 43                                                             /* erase/kill on */
 44             2 rawim                     unal bit (1) init ("0"b),
 45                                                             /* raw input mode */
 46             2 red_mode                  unal bit (1) init ("1"b),
 47                                                             /* red/black shifts may be transmitted */
 48             2 escape_out_seen           unal bit (1) init ("0"b),
 49                                                             /* user typed overstruck O-U-T */
 50             2 tabsin_mode               unal bit (1) init ("0"b),
 51                                                             /* ON means let tabs thru, OFF means change to spaces */
 52             2 hndlquit_mode             unal bit (1) init ("1"b),
 53                                                             /* ON means dim does reset(read write), OFF it doesn't */
 54             2 padding                   unal bit (24),
 55             2 read_back                 fixed bin init (0), /* input processing mode */
 56                                                             /* info about read/write buffers */
 57             2 canonicalization_index    fixed bin init (1), /* offset in canonicalization_buffer of next "free" char */
 58             2 read_offset               fixed bin init (-1),/* offset in canonicalization_buffer of first character */
 59             2 character_error_index     fixed bin init (-1),/* index of last good character */
 60             2 error_mark_column         fixed bin init (0), /* column error marker goes in */
 61             2 inimax                    fixed bin init (0), /* index of last char (0-origin) + 1 */
 62             2 tab_width                 fixed bin init (10),/* how wide a tab stop is. */
 63             2 baud_rate                 fixed bin init (0), /* see apl_dim_table.incl.pl1 */
 64             2 internal_type             unal dim (0:255) bit (9),
 65                                                             /* copied from device_info.code_move */
 66             2 canonicalization_buffer   char (512),
 67             2 normal_read_buffer        char (512),
 68             2 quit_read_buffer          char (512);
 69 
 70 dcl       1 type                        unal dim (0:255) defined (stream_data_block.internal_type (0)),
 71                                                             /* indexed by internal code */
 72             2 white                     bit (1),            /* on if white space char */
 73             2 red                       bit (1),            /* on if red/black shift char */
 74             2 action                    bit (4),            /* 0 none, 1 esc, 2 erase, 3 kill, 4 delim, 5 break */
 75             2 move                      bit (3);            /* 0=+1, 1=0, 2=-1, 3=tab, 4=cr, 5=nl, 6=np, 7=vt */
 76 
 77 /* constants for stream_data_block.read_back field. */
 78 
 79 declare   read_back_names               char (16) dimension (0:2) internal static options (constant)
 80                                         initial ("read_back_spaces", "read_back_input", "read_back_output");
 81 
 82 dcl       (
 83           read_back_spaces              init (0),           /* just keep track of column input starts in */
 84           read_back_input               init (1),           /* just read what user typed */
 85           read_back_output              init (2)            /* remember output & recanonicalize entire line */
 86           )                             fixed bin internal static options (constant);
 87 
 88 dcl       status                        bit (72);
 89 
 90 dcl       1 status_bits                 based (addr (status)),
 91             2 status_code               fixed bin (35),
 92             (
 93             2 logical_initiation        bit (1),
 94             2 logical_completion        bit (1),
 95             2 physical_initiation       bit (1),
 96             2 physical_completion       bit (1),
 97             2 transaction_terminated    bit (1),
 98             2 unused_42_45              bit (4),
 99             2 end_of_logical_data       bit (1),
100             2 end_of_physical_data      bit (1),
101             2 unused_48_51              bit (4),
102             2 stream_detached           bit (1),
103             2 unused_53                 bit (1),
104             2 transaction_aborted       bit (1),
105             2 transaction_index         bit (18)
106             )                           unaligned;
107 
108 /* ------ END INCLUDE SEGMENT           apl_dim_sdb.incl.pl1 -------------------------------------- */