ASM1130 CROSS ASSEMBLER V1.22 -- V2M12 -- Sun Nov 1 19:25:11 2020
Source File: \w5tstty.asm
TSTTY - MTCA TELETYPE TERMINAL MODULE
2 | *************************************************** W5E00020
3 | *STATUS - VERSION 2, MODIFICATION 9 * W5E00030
4 | * * W5E00040
5 | *SUBROUTINE NAME - * W5E00050
6 | * FULL NAME - TELETYPE TERMINAL SELECT MODULE * W5E00060
7 | * FOR THE MULTIPLE TERMINAL * W5E00070
8 | * COMMUNICATIONS ADAPTER (MTCA) * W5E00080
9 | * CODE NAME - TSTTY * W5E00090
10 | * * W5E00100
11 | *PURPOSE - * W5E00110
12 | * THIS SUBROUTINE, IN CONJUNCTION WITH MTCA0 * W5E00120
13 | * PROVIDES THE NECESSARY FUNCTIONS TO CONTROL * W5E00130
14 | * COMMUNICATIONS LINES CONNECTED BETWEEN THE * W5E00140
15 | * MTCA AND TELETYPE TERMINALS * W5E00150
16 | * DATA IS TRANSFERED ON A PER CHARACTER BASIS * W5E00160
17 | * * W5E00170
18 | *METHOD - * W5E00180
19 | * THE SUBROUTINE HAS TWO ENTRY POINTS - * W5E00190
20 | * * INITIATE WRITE - A CHARACTER IS * W5E00200
21 | * TRANSMITTED TO A SPECIFIC TERMINAL * W5E00210
22 | * * INTERRUPT SERVICE - THE ADAPTER STATUS * W5E00220
23 | * IS EXAMINED FOR THE REQUESTED SERVICE * W5E00230
24 | * (TMT AND/OR RCV) * W5E00240
25 | * THE DIAGNOSE FUNCTION (WRAP MODE) IS * W5E00250
26 | * CONTINUED BY TSTTY ONCE MTCA0 HAS TRANSMITTED * W5E00260
27 | * THE FIRST WRAP CHARACTER * W5E00270
28 | * * W5E00280
29 | *CAPABILITIES AND LIMITATIONS - * W5E00290
30 | * TSTTY IS ONLY ENTERED BY MTCA0 * W5E00300
31 | * * W5E00310
32 | *SPECIAL FEATURES - * W5E00320
33 | * NONE * W5E00330
34 | * * W5E00340
35 | *ADDITIONAL INFORMATION - * W5E00350
36 | * ERROR PROCEDURES - * W5E00360
37 | * ANY DATA RCVD WILL NOT BE PASSED ON TO THE * W5E00370
38 | * USER UNLESS A VALID INPUT COUNT (UNITY) * W5E00380
39 | * IS PRESENT IN THE LCB (LINE CONTROL BLOCK) * W5E00390
40 | * FOR THAT LINE * W5E00400
41 | * DATA OVERRUN AND VRC (BAD PARITY) ERRORS * W5E00410
42 | * ARE REPORTED TO THE USER * W5E00420
43 | * CALLING SEQUENCE - * W5E00430
44 | * TSTTY IS NOT ENTERED IN THE NORMAL MANNER. * W5E00440
45 | * ITS STARTING ADDRESS IS PLACED IN THE LCB * W5E00450
46 | * FOR ALL LINES OF THAT TYPE DURING * W5E00460
47 | * INITIALIZATION. MTCA0 ENTERS TSTTY BY * W5E00470
48 | * MEANS OF A BSI INSTRUCTION AT TSTTY+0 FOR * W5E00480
49 | * INTERRUPT SERVICE, AND AT TSTTY+2 FOR * W5E00490
50 | * INITIATE WRITE SERVICE. * W5E00500
51 | * LOCATION TSTTY+4 CONTAINS THE FIRST WRAP * W5E00510
52 | * CHARACTER (USED BY MTCA0 DURING DIAGNOSE) * W5E00520
53 | * * W5E00530
54 | *************************************************** W5E00540
55 | * W5E00550
56 | * W5E00560
57 | *************************************************** W5E00570
58 | * * W5E00580
59 | * USE OF 'CNTRL' BY TSTTY * W5E00590
60 | * * W5E00600
61 | *************************************************** W5E00610
62 | * * W5E00620
63 | * BIT 0 WRAP MODE * W5E00630
64 | * 12 RCV INTERRUPT RCVD IN WRAP MODE * W5E00640
65 | * 13 TMT INTERRUPT RCVD IN WRAP MODE * W5E00650
66 | * 15 WRAP CALLED FROM A TERMINAL * W5E00660
67 | * * W5E00670
68 | *************************************************** W5E00680
69 | * W5E00690
70 | * W5E00700
71 | *************************************************** W5E00710
72 | * * W5E00720
73 | * USE OF 'TIMER' BY TSTTY * W5E00730
74 | * * W5E00740
75 | *************************************************** W5E00750
76 | * * W5E00760
77 | * 'X00Y' * W5E00770
78 | * WHERE - * W5E00780
79 | * X IS THE FUNCTION DIGIT, * W5E00790
80 | * 1 RCV DATA TIMEOUT * W5E00800
81 | * 2 TMT DATA TIMEOUT * W5E00810
82 | * 3 CONNECT ADAPTER TIMEOUT * W5E00820
83 | * 4 DISCONNECT ADAPTER TIMEOUT * W5E00830
84 | * 5 REQUEST WRAP AND TEST ADAPTER * W5E00840
85 | * 6 WRAP ADAPTER TIMEOUT * W5E00850
86 | * 7 WRAP DATA TIMEOUT * W5E00860
87 | * 8 RECONNECT ADAPTER TIMEOUT * W5E00870
88 | * 9 REPORT PRE-TMT ERROR * W5E00880
89 | * Y IS THE COUNT IN TIMER UNITS * W5E00890
90 | * * W5E00900
91 | *************************************************** W5E00910
92 | * W5E00920
93 | * W5E00930
94 | *************************************************** W5E00940
95 | * * W5E00950
96 | * EQUATE STATEMENTS * W5E00960
97 | * * W5E00970
98 | *************************************************** W5E00980
99 | * W5E00990
100 | ENT TSTTY W5E01000
101 | * W5E01010
0000 102 | LNBSY EQU 0 LINE BUSY FLAG W5E01020
0001 103 | TSMAD EQU 1 T.S.M. ADDRESS W5E01030
0002 104 | IPPTR EQU 2 INPUT POINTER W5E01040
0003 105 | IPCNT EQU 3 INPUT COUNT W5E01050
0004 106 | OPPTR EQU 4 OUTPUT POINTER W5E01060
0004 107 | LPDAT EQU OPPTR LOOPED DATA W5E01070
0005 108 | OPCNT EQU 5 OUTPUT COUNT W5E01080
0006 109 | ERROR EQU 6 ERROR ADDRESS W5E01090
0007 110 | CNTRL EQU 7 CONTROL FLAGS W5E01100
0008 111 | DIAGN EQU 8 DIAGNOSTIC CONTROL W5E01110
0009 112 | TIMER EQU 9 TIMER CONTROL WORD W5E01120
000A 113 | RXPTR EQU 10 RCV DATA LOCATION W5E01130
000B 114 | TXPTR EQU 11 TMT DATA LOCATION W5E01140
000C 115 | STATC EQU 12 STATISTICS COUNT W5E01150
116 | * W5E01160
117 | * W5E01170
118 | *************************************************** W5E01180
119 | * * W5E01190
120 | * TERMINAL SELECT ENTRY POINTS * W5E01200
121 | * * W5E01210
122 | *************************************************** W5E01220
123 | * W5E01230
0000 0000 124 | TSTTY DC *-* INTERRUPT SERVICE ENTRY W5E01240
0001 7066 125 | B TT300 BR TO CONTINUE W5E01250
126 | * W5E01260
0002 0000 127 | TT002 DC *-* INITIATE WRITE ENTRY W5E01270
0003 7001 128 | B TT100 BR TO CONTINUE W5E01280
129 | * W5E01290
0004 0003 130 | TT004 DC /0003 FIRST WRAP CHARACTER W5E01300
131 | * W5E01310
132 | * W5E01320
133 | *************************************************** W5E01330
134 | * * W5E01340
135 | * INITIATE WRITE ROUTINE * W5E01350
136 | * * W5E01360
137 | *************************************************** W5E01370
138 | * W5E01380
0005 4C20 0016R 139 | TT100 BNZ TT110 BR IF LINK NOT ACTIVE W5E01390
140 | * W5E01400
0007 C205 141 | LD 2 OPCNT CHECK UNITY O/P COUNT W5E01410
0008 901A 142 | S TT905 W5E01420
0009 4C20 0018R 143 | BNZ TT120 BR IF NOT W5E01430
144 | * W5E01440
000B C204 145 | LD 2 OPPTR CALCULATE USER'S W5E01450
000C 8016 146 | A TT905 *DATA AREA W5E01460
000D D001 147 | STO *+1 W5E01470
000E C400 0000 148 | LD L *-* GET O/P CHARACTER W5E01480
0010 1806 149 | SRA 6 POSITION AND W5E01490
0011 E8F2 150 | OR TT004 *ADD STOP BITS W5E01500
0012 D680 000B 151 | STO I2 TXPTR TRANSMIT W5E01510
0014 C00F 152 | LD TT906 GET TMT TIMEOUT CODE W5E01520
0015 7005 153 | B TT130-1 GO SET UP W5E01530
154 | * W5E01540
155 | * * * * * * * * * * * * * * * * * * * * * * * * * * W5E01550
156 | * INITIATE WRITE ERROR REPORTING * W5E01560
157 | * * * * * * * * * * * * * * * * * * * * * * * * * * W5E01570
158 | * W5E01580
0016 C011 159 | TT110 LD TT910 GET LINK NOT ACTIVE W5E01590
0017 7001 160 | B *+1 *ERROR CODE W5E01600
0018 C010 161 | TT120 LD TT911 ILLEGAL COUNT ERROR W5E01610
0019 D204 162 | STO 2 OPPTR SAVE W5E01620
001A C015 163 | LD TT918 GET ERROR TIMEOUT W5E01630
001B D209 164 | STO 2 TIMER SET UP TIMEOUT W5E01640
001C 4C80 0002R 165 | TT130 B I TT002 RETURN TO MTCA0 W5E01650
166 | * W5E01660
167 | * W5E01670
168 | *************************************************** W5E01680
169 | * * W5E01690
170 | * IOCC'S AND CONSTANTS * W5E01700
171 | * * W5E01710
172 | *************************************************** W5E01720
173 | * W5E01730
001E 174 | BSS E 0 FORCE EVEN BOUNDARY W5E01740
001E FF01 175 | TT900 DC /FF01 SENSE AND RESET E W5E01750
001F 0000 176 | DC *-* *DSW2 IOCC W5E01760
0020 0002 177 | TT902 DC 2 CONSTANT - TWO E W5E01770
0021 FC0A 178 | DC /FC0A ENABLE MTCA FOR TMT W5E01780
0022 FC04 179 | TT904 DC /FC04 CONNECT IOCC W5E01790
0023 0001 180 | TT905 DC 1 CONSTANT - ONE W5E01800
0024 2002 181 | TT906 DC /2002 TMT TIMEOUT W5E01810
0025 7002 182 | TT907 DC /7002 WRAP TIMEOUT W5E01820
0026 8002 183 | TT908 DC /8002 RECONNECT TIMEOUT W5E01830
0027 E009 184 | TT909 DC /E009 DATA OVERRUN ERROR W5E01840
0028 E00A 185 | TT910 DC /E00A LINK NOT ACTIVE ERROR W5E01850
0029 E00B 186 | TT911 DC /E00B INVALID COUNT ERROR W5E01860
002A E00E 187 | TT912 DC /E00E PARITY (VRC) ERROR W5E01870
002B 000C 188 | TT913 DC /000C BITS 12 AND 13 W5E01880
002C 000F 189 | TT914 DC /000F MASK LAST DIGIT W5E01890
002D 0000 190 | TT915 DC *-* SAVE RCV LOCATION W5E01900
002E 0000 191 | TT916 DC *-* SAVE DSW2 W5E01910
002F 0000 192 | TT917 DC *-* SAVE RCV DATA W5E01920
0030 9001 193 | TT918 DC /9001 PRE-TMT ERROR TIMEOUT W5E01930
194 | * W5E01940
195 | * W5E01950
196 | *************************************************** W5E01960
197 | * * W5E01970
198 | * WRAP MODE SERVICE * W5E01980
199 | * * W5E01990
200 | *************************************************** W5E02000
201 | * W5E02010
0031 08EC 202 | TT200 XIO TT900 SENSE/RESET DSW2 W5E02020
0032 180C 203 | SRA 12 ISOLATE RCV/TMT BITS W5E02030
0033 EA07 204 | OR 2 CNTRL SET INTO CONTROL W5E02040
0034 D207 205 | STO 2 CNTRL W5E02050
0035 E0F5 206 | AND TT913 CHECK FOR BOTH W5E02060
0036 F0F4 207 | EOR TT913 *INTERRUPTS IN W5E02070
0037 4C20 007CR 208 | BNZ TT320 BR IF NO W5E02080
209 | * W5E02090
0039 C207 210 | LD 2 CNTRL RESET INTERRUPTS W5E02100
003A F0F0 211 | EOR TT913 *IN BITS W5E02110
003B D207 212 | STO 2 CNTRL W5E02120
213 | * W5E02130
214 | * * * * * * * * * * * * * * * * * * * * * * * * * * W5E02140
215 | * COMPARE LOOPED DATA * W5E02150
216 | * * * * * * * * * * * * * * * * * * * * * * * * * * W5E02160
217 | * W5E02170
003C C0F0 218 | LD TT915 GET RCV DATA W5E02180
003D 1807 219 | SRA 7 REMOVE ASSEMBLY AREA W5E02190
003E 6101 220 | LDX 1 1 SET UP INDEX W5E02200
003F 4804 221 | TT210 SKP E SKIP IF NO BIT 15 W5E02210
0040 7101 222 | MDX 1 1 INCREMENT INDEX W5E02220
0041 1801 223 | SRA 1 MOVE ALONG DATA W5E02230
0042 4820 224 | SKP Z SKIP IF ALL DONE W5E02240
0043 70FB 225 | B TT210 COUNT FURTHER BITS W5E02250
226 | * W5E02260
0044 69EA 227 | STX 1 TT917 EXAMINE STATE W5E02270
0045 C0E9 228 | LD TT917 *OF XR1 W5E02280
0046 4C04 007CR 229 | BOD TT320 BR IF BAD PARITY W5E02290
230 | * W5E02300
0048 C0E4 231 | LD TT915 GET RCV DATA W5E02310
0049 1001 232 | SLA 1 FORMAT W5E02320
004A 1808 233 | SRA 8 W5E02330
004B F204 234 | EOR 2 LPDAT COMPARE WITH TMT DATA W5E02340
004C 4C20 007CR 235 | BNZ TT320 BR IF BAD COMPARE W5E02350
236 | * W5E02360
237 | * * * * * * * * * * * * * * * * * * * * * * * * * * W5E02370
238 | * SET UP DISABLE TMT TIMEOUT * W5E02380
239 | * * * * * * * * * * * * * * * * * * * * * * * * * * W5E02390
240 | * W5E02400
004E C0D1 241 | LD TT902 SET A CONSTANT W5E02410
004F 148C*3054 242 | CALL MTCAM *OF VALUE TWO W5E02420
004F 243 | ORG *-2 *INTO THE TRANSFER W5E02430
004F D400 244 | DC /D400 *VECTOR FOR W5E02440
0051 245 | ORG *+1 *MTCAM SUBROUTINE W5E02450
246 | * W5E02460
0051 08CE 247 | XIO TT902 ENABLE TMT W5E02470
248 | * W5E02480
0052 C204 249 | LD 2 LPDAT INCREMENT LOOP DATA W5E02490
0053 80CF 250 | A TT905 *BY ONE W5E02500
0054 D204 251 | STO 2 LPDAT W5E02510
0055 1008 252 | SLA 8 ALL DATA WRAPPED W5E02520
0056 4C18 005FR 253 | BZ TT220 BR IF YES W5E02530
254 | * W5E02540
0058 1806 255 | SRA 6 FORMAT W5E02550
0059 E8AA 256 | OR TT004 ADD STOP BITS W5E02560
005A D680 000B 257 | STO I2 TXPTR TRANSMIT W5E02570
258 | * W5E02580
005C C0C8 259 | LD TT907 SET UP TMT W5E02590
005D D209 260 | STO 2 TIMER *TIMEOUT CONDITION W5E02600
005E 701D 261 | B TT320 RETURN TO MTCA0 W5E02610
262 | * W5E02620
263 | * * * * * * * * * * * * * * * * * * * * * * * * * * W5E02630
264 | * WRAP COMPLETED - RECONNECT LINE * W5E02640
265 | * * * * * * * * * * * * * * * * * * * * * * * * * * W5E02650
266 | * W5E02660
005F C0C6 267 | TT220 LD TT908 SET UP CONNECT W5E02670
0060 D209 268 | STO 2 TIMER *TIMEOUT W5E02680
0061 C20B 269 | LD 2 TXPTR GENERATE W5E02690
0062 100C 270 | SLA 12 *CONNECT W5E02700
0063 1808 271 | SRA 8 *ADAPTER W5E02710
0064 E8BD 272 | OR TT904 *IOCC W5E02720
0065 D0B9 273 | STO TT900+1 *FOR THIS LINE W5E02730
0066 08B7 274 | XIO TT900 CONNECT LINE W5E02740
0067 7014 275 | B TT320 RETURN TO MTCA0 W5E02750
276 | * W5E02760
277 | * W5E02770
278 | *************************************************** W5E02780
279 | * * W5E02790
280 | * INTERRUPT SERVICE ROUTINE * W5E02800
281 | * * W5E02810
282 | *************************************************** W5E02820
283 | * W5E02830
0068 C20A 284 | TT300 LD 2 RXPTR GENERATE W5E02840
0069 1004 285 | SLA 4 *SENSE AND W5E02850
006A E8B3 286 | OR TT900 *RESET DSW2 W5E02860
006B D0B3 287 | STO TT900+1 *IOCC AND SAVE W5E02870
006C C680 000A 288 | LD I2 RXPTR GET RCV DATA W5E02880
006E D0BE 289 | STO TT915 SAVE FOR LATER USE W5E02890
006F C207 290 | LD 2 CNTRL CHECK FOR WRAP MODE W5E02900
0070 4C28 0031R 291 | BN TT200 BR IF YES W5E02910
292 | * W5E02920
0072 08AB 293 | XIO TT900 SENSE/RESET DSW2 W5E02930
0073 D0BA 294 | STO TT916 SAVE DSW2 W5E02940
0074 4C28 007ER 295 | BN TT330 BR IF RCV SERVICE W5E02950
296 | * W5E02960
0076 1001 297 | TT310 SLA 1 CHECK FOR TMT SERVICE W5E02970
0077 4C10 007CR 298 | BNN TT320 BR IF NO W5E02980
299 | * W5E02990
300 | * * * * * * * * * * * * * * * * * * * * * * * * * * W5E03000
301 | * TMT CHARACTER SERVICE * W5E03010
302 | * * * * * * * * * * * * * * * * * * * * * * * * * * W5E03020
303 | * W5E03030
0079 1010 304 | SLA 16 CLEAR W5E03040
007A D209 305 | STO 2 TIMER *TIMER WORD W5E03050
007B D200 306 | STO 2 LNBSY *LINE BUSY FLAG W5E03060
007C 4C80 0000R 307 | TT320 B I TSTTY RETURN TO MTCA0 W5E03070
308 | * W5E03080
309 | * * * * * * * * * * * * * * * * * * * * * * * * * * W5E03090
310 | * RCV CHARACTER SERVICE * W5E03100
311 | * * * * * * * * * * * * * * * * * * * * * * * * * * W5E03110
312 | * W5E03120
007E C0AE 313 | TT330 LD TT915 FETCH RCV LOCATION W5E03130
007F 1001 314 | SLA 1 REMOVE VRC CHECK BIT W5E03140
0080 E09D 315 | AND TT900 REMOVE ASSEMBLY AREA W5E03150
0081 D0AD 316 | STO TT917 SAVE THE CHARACTER W5E03160
0082 C203 317 | LD 2 IPCNT GET I/P COUNT W5E03170
0083 909F 318 | S TT905 CHECK FOR UNITY W5E03180
0084 4C20 0096R 319 | BNZ TT360 BR IF NO W5E03190
320 | * W5E03200
0086 C0A7 321 | LD TT916 GET DSW2 W5E03210
0087 4C04 009AR 322 | BOD TT380 BR IF OVERRUN W5E03220
323 | * W5E03230
0089 C0A3 324 | LD TT915 CHECK VRC W5E03240
008A 4C10 0098R 325 | BNN TT370 BR IF ODD W5E03250
326 | * W5E03260
008C C202 327 | TT340 LD 2 IPPTR CALCULATE USER'S W5E03270
008D 8095 328 | A TT905 *I/P LOCATION W5E03280
008E D002 329 | STO TT350+1 *AND SAVE W5E03290
008F C09F 330 | LD TT917 GET RCV DATA W5E03300
0090 D400 0000 331 | TT350 STO L *-* PUT IN USER AREA W5E03310
332 | * W5E03320
0092 1010 333 | SLA 16 CLEAR W5E03330
0093 D200 334 | STO 2 LNBSY *LINE BUSY FLAG W5E03340
0094 D209 335 | STO 2 TIMER *TIMER WORD W5E03350
0095 D203 336 | STO 2 IPCNT *I/P COUNT W5E03360
337 | * W5E03370
0096 C097 338 | TT360 LD TT916 GET DSW2 W5E03380
0097 70DE 339 | B TT310 GO TEST FOR TMT W5E03390
340 | * W5E03400
341 | * * * * * * * * * * * * * * * * * * * * * * * * * * W5E03410
342 | * RCV ERROR HANDLING * W5E03420
343 | * * * * * * * * * * * * * * * * * * * * * * * * * * W5E03430
344 | * W5E03440
0098 C091 345 | TT370 LD TT912 FETCH VRC ERROR CODE W5E03450
0099 7001 346 | B *+1 W5E03460
009A C08C 347 | TT380 LD TT909 FETCH OVERRUN ERR CODE W5E03470
009B 18D0 348 | XCH SAVE W5E03480
009C C20B 349 | LD 2 TXPTR GENERATE LINE W5E03490
009D E08E 350 | AND TT914 *NUMBER W5E03500
009E 8084 351 | A TT905 PUT INTO W5E03510
009F 18D0 352 | XCH *EXTENSION W5E03520
00A0 4680 0006 353 | BSI I2 ERROR GO TELL USER W5E03530
354 | * W5E03540
00A2 70E9 355 | B TT340 CONTINUE SERVICE W5E03550
356 | * W5E03560
00A3 357 | END W5E03570
There were no errors in this assembly
=== CROSS REFERENCES ==========================================================
Name Val Defd Referenced
CNTRL 0007 110 204 205 210 212 290
DIAGN 0008 111
ERROR 0006 109 353
IPCNT 0003 105 317 336
IPPTR 0002 104 327
LNBSY 0000 102 306 334
LPDAT 0004 107 234 249 251
OPCNT 0005 108 141
OPPTR 0004 106 107 145 162
RXPTR 000A 113 284 288
STATC 000C 115
TIMER 0009 112 164 260 268 305 335
TSMAD 0001 103
TSTTY 0000R 124 307
TT002 0002R 127 165
TT004 0004R 130 150 256
TT100 0005R 139 128
TT110 0016R 159 139
TT120 0018R 161 143
TT130 001CR 165 153
TT200 0031R 202 291
TT210 003FR 221 225
TT220 005FR 267 253
TT300 0068R 284 125
TT310 0076R 297 339
TT320 007CR 307 208 229 235 261 275 298
TT330 007ER 313 295
TT340 008CR 327 355
TT350 0090R 331 329
TT360 0096R 338 319
TT370 0098R 345 325
TT380 009AR 347 322
TT900 001ER 175 202 273 274 286 287 293 315
TT902 0020R 177 241 247
TT904 0022R 179 272
TT905 0023R 180 142 146 250 318 328 351
TT906 0024R 181 152
TT907 0025R 182 259
TT908 0026R 183 267
TT909 0027R 184 347
TT910 0028R 185 159
TT911 0029R 186 161
TT912 002AR 187 345
TT913 002BR 188 206 207 211
TT914 002CR 189 350
TT915 002DR 190 218 231 289 313 324
TT916 002ER 191 294 321 338
TT917 002FR 192 227 228 316 330
TT918 0030R 193 163
TXPTR 000B 114 151 257 269 349