1 /* Begin include file ..... ibm3270_io_info.incl.pl1 */
  2 
  3 /* 3270 input/output information structure */
  4 /* Initially constructed 09/08/77 by Larry Johnson and Warren Johnson */
  5 
  6 /* Following structure must be supplied for "read" order */
  7 
  8 dcl  read_ctlp ptr;
  9 
 10 dcl 1 read_ctl aligned based (read_ctlp),
 11     2 version fixed bin,                                    /* Currently one */
 12     2 areap ptr,                                            /* Pointer to area where "read_info" is allocated */
 13     2 read_infop ptr,                                       /* Pointer to read_info structure, allocatd by I/O module */
 14     2 max_len fixed bin,                                    /* Max character length */
 15     2 max_fields fixed bin;                                 /* Max number of fields in array */
 16 
 17 /* The following structure is allocate by the I/O module on a read order */
 18 /* It must be freed by the caller when no longer needed */
 19 
 20 dcl 1 read_info aligned based (read_ctl.read_infop),
 21     2 version fixed bin,                                    /* Currently 1 */
 22     2 next_read_infop ptr,                                  /* Used by I/O module internally for chaining blocks */
 23     2 controller fixed bin,                                 /* Controller which data is for */
 24     2 device fixed bin,                                     /* Which device on that controller */
 25     2 reason,                                               /* Reason for this data */
 26       3 key fixed bin,                                      /* Indicates which key pressed, see codes below */
 27       3 sub_key fixed bin,                                  /* For PF or PA, which one */
 28       3 code fixed bin (35),                                /* If reason is error, an error code */
 29     2 status,                                               /* If reason STATUS, the status data */
 30       3 bits bit (12) unal,
 31       3 fill bit (24) unal,
 32     2 cursor_position fixed bin,                            /* Current cursor position */
 33     2 max_fields fixed bin,                                 /* Used to define array */
 34     2 max_len fixed bin,                                    /* Used to define array */
 35     2 mod_fields fixed bin,                                 /* Number of elements in array actually filled in */
 36     2 data (read_ctl.max_fields refer (read_info.max_fields)),
 37       3 field_position fixed bin,                           /* Address of field */
 38       3 contents char (read_ctl.max_len refer (read_info.max_len)) var;
 39 
 40 /* Possible values for read_info.key */
 41 
 42 dcl (ERROR init (1),                                        /* Serious error, see read_info.code */
 43      STATUS init (2),                                       /* Device reported status */
 44      ENTER init (3),                                        /* Entry key hit */
 45      PF_KEY init (4),                                       /* One of PF keys hit, see read_info.sub_key */
 46      PA_KEY init (5),                                       /* One of PA keys hit, see read_info.sub_key */
 47      CLEAR init (6),                                        /* Clear key hit */
 48      ID_READER init (7),                                    /* Operatior identification card reader */
 49      LIGHT_PEN init (8),                                    /* Light pen used */
 50      TEST_REQ init (9))                                     /* Test request key hit */
 51      int static options (constant);
 52 
 53 dcl  write_infop ptr;
 54 dcl  max_write_fields fixed bin;
 55 dcl  max_write_len fixed bin;
 56 
 57 dcl 1 write_info aligned based (write_infop),
 58     2 version fixed bin,
 59     2 controller fixed bin,
 60     2 device fixed bin,
 61     2 from_device fixed bin,                                /* used with COPY command */
 62     2 command fixed bin,                                    /* write, erase/write, copy, etc. */
 63     2 write_ctl_char,
 64       3 bits unal,
 65         4 print_format bit (2) unal,                        /* 00 = use NL order, 01 = 40, 10 = 60, 11 = 80 */
 66         4 start_printer bit (1) unal,
 67         4 sound_alarm bit (1) unal,
 68         4 keyboard_restore bit (1) unal,
 69         4 reset_mdt bit (1) unal,
 70       3 copy_bits bit (2) unal,                             /* which fields to copy */
 71       3 pad bit (28) unal,
 72     2 max_fields fixed bin,
 73     2 max_len fixed bin,                                    /* max length of data.contents */
 74     2 mod_fields fixed bin,                                 /* number of fields actually filled in */
 75     2 data (max_write_fields refer (write_info.max_fields)),
 76       3 orders unal,                                        /* orders to precede this block of data */
 77         4 set_buffer_addr bit (1),                          /* defines starting address */
 78         4 start_field bit (1),                              /* define field, using attribute char */
 79         4 insert_cursor bit (1),
 80         4 program_tab bit (1),
 81         4 repeat_to_addr bit (1),                           /* repeat supplied char */
 82         4 erase_to_addr bit (1),
 83       3 attributes unal,                                    /* used in field definition if start_field = "1"b */
 84         4 protected bit (1),
 85         4 numeric bit (1),
 86         4 display_form bit (2),                             /* 00 = display, ^pen, 01 = display,pen, 10 = intensified */
 87                                                             /* 11 = invisible */
 88         4 reserved bit (1),
 89         4 mdt bit (1),                                      /* modified data tag */
 90       3 pad1 bit (12) unal,
 91       3 field_position fixed bin,
 92       3 contents char (max_write_len refer (write_info.max_len)) varying;
 93 
 94 /* possible values for write_info.command */
 95 
 96 dcl (WRITE init (1),
 97      ERASE_WRITE init (2),
 98      COPY init (3),
 99      ERASE_UNPROTECTED init (4),
100      READ_MODIFIED init (5),
101      READ_BUFFER init (6))
102      fixed bin int static options (constant);
103 
104 /* End include file ..... ibm3270_io_info.incl.pl1 */