1 /*  BEGIN INCLUDE FILE:       mowse_io_constants.incl.pl1               *  *  *  *  *  *  *  *  *  *  *  *  */
  2 
  3 /****^  HISTORY COMMENTS:
  4   1) change(86-11-06,Flegel), approve(87-07-15,MCR7580),
  5      audit(87-07-30,RBarstad), install(87-08-07,MR12.1-1075):
  6      Created.
  7   2) change(86-11-27,Flegel), approve(86-11-27,MCR7580),
  8      audit(87-07-30,RBarstad), install(87-08-07,MR12.1-1075):
  9      Approved.
 10                                                    END HISTORY COMMENTS */
 11 
 12 /* Protocol constants */
 13 /* format: style4,indattr,ifthen,^indcomtxt,thendo,^indproc,^indblkcom,initcol1,declareind8,dclind4,struclvlind3,comcol55 */
 14 dcl INIT_CRC               fixed bin int static options (constant) init (63);
 15 dcl CONVERT_CRC            fixed bin int static options (constant) init (32);
 16 dcl REVPOLY                fixed bin int static options (constant) init (101001b); /* Bit N is coeff of x**(5-N) of generator */
 17 dcl OR                     bit (4) int static options (constant) init ("0111"b);
 18 dcl XOR                    bit (4) int static options (constant) init ("0110"b);
 19 dcl And                    bit (4) int static options (constant) init ("0001"b);
 20 
 21 /* Debugging Switches */
 22 dcl DBGPKTS                bit (1) int static options (constant) init ("0"b);
 23                                                       /* show packets */
 24 dcl DBGREJS                bit (1) int static options (constant) init ("1"b);
 25                                                       /* diagnose rejects */
 26 dcl DBGXCHRS               bit (1) int static options (constant) init ("0"b);
 27                                                       /* show extraneous received chars */
 28 
 29 /* ASCII Control Characters */
 30 
 31 dcl CR                     char (1) int static options (constant)
 32                            init ("^M");
 33 dcl ESC                    char (1) int static options (constant)
 34                            init ("^[");
 35 dcl LF                     char (1) int static options (constant)
 36                            init ("
 37 ");
 38 dcl SI                     char (1) int static options (constant)
 39                            init ("^O");
 40 dcl SO                     char (1) int static options (constant)
 41                            init ("^N");
 42 dcl SOH                    char (1) int static options (constant)
 43                            init ("^A");
 44 
 45 /* Protocol Bit-field Constants */
 46 dcl ChnCnt                 fixed bin int static options (constant) init (2);
 47                                                       /* no. logical channels */
 48 dcl SeqFld                 fixed bin int static options (constant) init (2);
 49                                                       /* no. bits in seq. field */
 50 dcl SeqCnt                 fixed bin int static options (constant) init (4);
 51                                                       /* 2**SeqFld */
 52 dcl SeqMsk                 fixed bin int static options (constant) init (3);
 53                                                       /* SeqCnt-1 */
 54 
 55 /* Protocol Byte-field Constants */
 56 dcl MaxDatLen              fixed bin int static options (constant) init (124);
 57                                                       /* Maximum packet length */
 58 dcl SOPLen                 fixed bin int static options (constant) init (1);
 59                                                       /* Characters in SOP field */
 60 dcl TypLen                 fixed bin int static options (constant) init (1);
 61                                                       /* Characters in type field */
 62 dcl ChkLen                 fixed bin int static options (constant) init (1);
 63                                                       /* Characters in check field */
 64 dcl LenLen                 fixed bin int static options (constant) init (1);
 65                                                       /* Characters in length field */
 66 dcl EOPLen                 fixed bin int static options (constant) init (1);
 67                                                       /* Characters in EOP field */
 68 dcl MinPktLen              fixed bin int static options (constant) init (5);
 69                                                       /* SOPLen+TypLen+LenLen+ChkLen+EOPLen */
 70 dcl MaxPktLen              fixed bin int static options (constant) init (129);
 71                                                       /* MinPktLen+MaxDatLen */
 72 
 73 /* Protocol Packet Type Constants */
 74 dcl RstOff                 fixed bin (8) int static options (constant)
 75                            init (32);                 /* <SPACE> */
 76 dcl Request                fixed bin (8) int static options (constant)
 77                            init (0);
 78 dcl Confirm                fixed bin (8) int static options (constant)
 79                            init (1);
 80 dcl RstCnt                 fixed bin (8) int static options (constant)
 81                            init (2);                  /* Confirm+1 */
 82 dcl FGBrk                  fixed bin (8) int static options (constant)
 83                            init (36);                 /* BrkOff+2*FG*/
 84 dcl DisCon                 fixed bin (8) int static options (constant)
 85                            init (34);                 /* BrkOff+2*BG */
 86 dcl FastDis                fixed bin (8) int static options (constant)
 87                            init (86);                 /* NakOff+NakCnt */
 88 dcl BrkOff                 fixed bin (8) int static options (constant)
 89                            init (34);                 /* RstOff+RstCnt */
 90 dcl BrkCnt                 fixed bin (8) int static options (constant)
 91                            init (4);                  /* ChnCnt*(Confirm+1) */
 92 dcl DatOff                 fixed bin (8) int static options (constant)
 93                            init (38);                 /* BrkOff+BrkCnt */
 94 dcl DatCnt                 fixed bin (8) int static options (constant)
 95                            init (32);                 /* ChnCnt*SeqCnt*SeqCnt */
 96 dcl AckOff                 fixed bin (8) int static options (constant)
 97                            init (70);                 /* DatOff+DatCnt */
 98 dcl AckCnt                 fixed bin (8) int static options (constant)
 99                            init (8);                  /* ChnCnt*SeqCnt */
100 dcl NakOff                 fixed bin (8) int static options (constant)
101                            init (78);                 /* AckOff+AckCnt */
102 dcl NakCnt                 fixed bin (8) int static options (constant)
103                            init (8);                  /* ChnCnt*SeqCnt */
104 
105 /* Protocol Parameters */
106 dcl RQS                    fixed bin int static options (constant) init (2);
107                                                       /* rcvchr's queue size (upper bound of r_pkt) */
108 dcl RWS                    fixed bin int static options (constant) init (3);
109                                                       /* Receiver's window size (upper bound of r_dat */
110 dcl SWS                    fixed bin int static options (constant) init (3);
111                                                       /* Sender's window size (upper bound of s_dat */
112 dcl Lim_r_timer            fixed bin int static options (constant) init (7);
113                                                       /* Limit for r_timer */
114 dcl Lim_s_timer            fixed bin int static options (constant) init (15);
115                                                       /* Limit for s_timer */
116 dcl Lim_p_timer            fixed bin int static options (constant) init (30);
117                                                       /* Limit for pending_timer */
118 dcl Timer_Interval         fixed bin (71) int static options (constant)
119                            init (125000);             /* Next wakeup of timer */
120 
121 /* Tasking priority values */
122 dcl Modem_Reader_Task      fixed bin int static options (constant) init (0);
123                                                       /* Modem Reader */
124 dcl FG_task                fixed bin int static options (constant) init (1);
125                                                       /* FG processing */
126 dcl BG_task                fixed bin int static options (constant) init (2);
127                                                       /* BG processing */
128 dcl Idle                   bit (1) int static options (constant) init ("0"b);
129                                                       /* Task not executing */
130 
131 /* Capability constants */
132 dcl NO_MINOR               fixed bin int static options (constant) init (-1);
133 
134 /* WSTERM modes string indices */
135 
136 dcl WST_INIT_PL            fixed bin int static options (constant) init (23);
137 dcl WST_INIT_LL            fixed bin int static options (constant) init (79);
138 
139 dcl WST_HEADER_1           fixed bin int static options (constant) init (1);
140 dcl WST_HEADER_2           fixed bin int static options (constant) init (2);
141 dcl WST_HEADER_3           fixed bin int static options (constant) init (3);
142 dcl WST_LENGTH_HIGH        fixed bin int static options (constant) init (4);
143 dcl WST_LENGTH_LOW         fixed bin int static options (constant) init (5);
144 dcl WST_MODES              fixed bin int static options (constant) init (6);
145 dcl WST_KILL               fixed bin int static options (constant) init (7);
146 dcl WST_ERASE              fixed bin int static options (constant) init (8);
147 dcl WST_ESCAPE             fixed bin int static options (constant) init (9);
148 dcl WST_LINE_LENGTH        fixed bin int static options (constant) init (10);
149 dcl WST_PAGE_LENGTH        fixed bin int static options (constant) init (11);
150 
151 /*  END INCLUDE FILE:         mowse_io_constants.incl.pl1               *  *  *  *  *  *  *  *  *  *  *  *  */