-
Notifications
You must be signed in to change notification settings - Fork 0
/
rsts.html
554 lines (480 loc) · 39.2 KB
/
rsts.html
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="utf-8">
<title>fritzm.github.io - PDP-11/45: RSTS/E V06C attempts</title>
<meta name="description" content="">
<meta name="author" content="Fritz Mueller">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<!-- Le HTML5 shim, for IE6-8 support of HTML elements -->
<!--[if lt IE 9]>
<script src="https://fritzm.github.io/theme/html5.js"></script>
<![endif]-->
<!-- Le styles -->
<link href="https://fritzm.github.io/theme/bootstrap.min.css" rel="stylesheet">
<link href="https://fritzm.github.io/theme/bootstrap.min.responsive.css" rel="stylesheet">
<link href="https://fritzm.github.io/theme/local.css" rel="stylesheet">
<link href="https://fritzm.github.io/theme/pygments.css" rel="stylesheet">
<!-- Photoswipe -->
<link rel="stylesheet" href="https://fritzm.github.io/theme/photoswipe.css">
<link rel="stylesheet" href="https://fritzm.github.io/theme/default-skin/default-skin.css">
<script src="https://fritzm.github.io/theme/photoswipe.min.js"></script>
<script src="https://fritzm.github.io/theme/photoswipe-ui-default.min.js"></script>
<script src="https://fritzm.github.io/galleries.js"></script>
<script type="text/javascript">
var pswipe = function(gname, index) {
var pswpElement = document.querySelectorAll('.pswp')[0];
var items = galleries[gname];
var options = { index: index };
var gallery = new PhotoSwipe(pswpElement, PhotoSwipeUI_Default, items, options);
gallery.init();
};
</script>
<!-- So Firefox can bookmark->"abo this site" -->
<link href="https://fritzm.github.io/feeds/all.rss.xml" rel="alternate" title="fritzm.github.io" type="application/rss+xml">
</head>
<body>
<div class="navbar">
<div class="navbar-inner">
<div class="container">
<a class="btn btn-navbar" data-toggle="collapse" data-target=".nav-collapse">
<span class="icon-bar"></span>
<span class="icon-bar"></span>
<span class="icon-bar"></span>
</a>
<a class="brand" href="https://fritzm.github.io">fritzm.github.io</a>
<div class="nav-collapse">
<ul class="nav">
</ul>
</div>
</div>
</div>
</div>
<div class="container">
<div class="content">
<div class="row">
<div class="span9">
<div class='article'>
<div class="content-title">
<h1>PDP-11/45: RSTS/E V06C attempts</h1>
Mon 07 January 2019
by <a class="url fn" href="https://fritzm.github.io/author/fritz-mueller.html">Fritz Mueller</a>
</div>
<div><p>Okay, back in action after replacing the failed nand at B26 in the RK11-C. MAINDEC ZRKK now passes reliably.
Wish I'd been able to get to the bottom of this at the show, but it was really hard to effectively debug on
the floor there while the show was in progress -- you naturally want to stop and chat with everybody who drops
by to take a look, so its hard to get into a good technical flow.</p>
<p>Since one of the RK11-C diagnostics I needed to use writes a pack destructively, I had to sacrifice my working
RT-11 pack along the way. Rather than go back to the same old RT-11 image, I figured maybe time to try
something different? RSTS/E would probably be more fun with multiple terminals and the DZ11 that I have
anyway, and I've never actually played around with RSTS. So decided to give that a go...</p>
<p>Did some poking around looking at various available versions, and V06C seemed like a pretty good starting
point: it's new enough to explicitly support all of my hardware (including the DZ11 and excepting the VT100),
but old enough to still have relatively modest storage requirements so I can hope to run it with the single
RK05 that I currently have working. There is also complete distribution tape available at rsts.org, and a
fairly complete set of documentation at bitsavers.</p>
<p>Spent a bit of time reading the sysgen manual, and managed to sysgen under simh and generate a bootable
RK05 image for my hardware. I then transferred this image to my single working pack using PDP11GUI; this is
frustratingly slow (~3 hours to write a 2.5mb pack)!! I had forgotten how bad this is. I'm not quite sure
why it is as slow as it is; it shouldn't take much more than 45 minutes to push that much data through a DL11
at 9600 baud, even without compression, and the PDP-11 disk subsystem can easily keep up with that. I'm not
sure if PDP11GUI is spending a lot of time turning around the serial line, or has a bunch of per-character
overhead, or...? In any case, I'm motivated to do something about it; more on this some other time soon.</p>
<p>So, unfortunately, the RSTS image which works under simh fails to completely boot on the real hardware. It
runs through the initial "Option:" menu without trouble, and upon start the RSTS light chaser runs in the
data lights on the front panel. Characters are echoed on the console terminal, but it never reaches code to
print the banner or prompt for the initial control file. The system appears to be in a loop reading the same
section of disk repetitively, and the display register shows a continuously increasing count.</p>
<p>Got a lot of help from folks over on the cctalk mailing list on this one, since I'm a newbie to RSTS. Paul K.
provided some useful tips:</p>
<ul>
<li>
<p>RSTS displays an error count in the display register, so that's why I see an increasing count there.</p>
</li>
<li>
<p>The "fancy" idle pattern that includes both the address and data lights apparently shows up in a later
release of RSTS and requires a particular sysgen option, so its not surprising that I only see the pattern
in the data lights on my machine.</p>
</li>
<li>
<p>The ODT debugger may be loaded with RSTS for startup debugging by configuring it using an undocumented
option in the change memory layout section of the "DEFAULT" command at the boot prompt. Enter "ODT" there,
and provide a space for it in the memory map. After that, at ^P at the console will take you to the ODT
prompt. </p>
<div class="highlight"><pre><span></span>Memory allocation table:
0K: 00000000 - 00123777 ( 21K) : EXEC
21K: 00124000 - 00213777 ( 14K) : RTS (BASIC)
35K: 00214000 - 00227777 ( 3K) : ODT
38K: 00230000 - 00757777 ( 86K) : USER
124K: 00760000 - End : NXM
</pre></div>
</li>
<li>
<p>A handy way to query the RSTS symbol table is to use the "PATCH" command at the boot prompt (one can also
look through the .MAP files generated during sysgen):</p>
<div class="highlight"><pre><span></span>Option: PA
File to patch?
Module name?
Base address? ERL
Offset address?
Base Offset Old New?
041314 000000 005267 ? ^Z
Offset address? ^Z
Base address?
</pre></div>
</li>
<li>
<p>Paul also provided this procedure for triggering a crash dump from an ODT breakpoint under RSTS:</p>
<blockquote>
<p>1. Make sure crash dump is enabled (in the "default" option). Start the system. Let it run for at least
one minute. (I'm not entirely sure about older versions, but I think that a crash within one minute of
startup is handled differently and doesn't do all the usual dump and restart machinery.)</p>
<p>2. Set the data switches all UP. (In SIMH, enter "D SR 177777".)</p>
<p>3. Set a breakpoint.</p>
<p>4. When you hit the breakpoint, change the PC to 52, like this:</p>
<p>0B:055244<br>
_$7/055244 52<br>
_P </p>
<p>(you enter only "$7/" and "52<return>" and "P", the rest is output from ODT.)</p>
<p>The system will write the crashdump and then automatically restart.</p>
<p>5. You should now have the crash dump in [0,1]CRASH.SYS</p>
</blockquote>
</li>
</ul>
<p>Further experiments coordinated by Paul then led to the conclusion that an error like this could reasonably be
expected to be triggered by a corrupted INIT.BAC or BASIC.RTS file. This led me to wish to verify that the
disk pack contents really matched the image file I was running successfully under simh. Some standalone code
to dump a CRC of every sector on the pack seemed like it would be useful in this regard, so I coded up the
following:</p>
<table class="highlighttable"><tr><td class="linenos"><div class="linenodiv"><pre> 1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131</pre></div></td><td class="code"><div class="highlight"><pre><span></span> <span class="nt">RKDS</span><span class="o">=</span><span class="nt">177400</span>
<span class="nt">RKER</span><span class="o">=</span><span class="nt">177402</span>
<span class="nt">RKCS</span><span class="o">=</span><span class="nt">177404</span>
<span class="nt">RKWC</span><span class="o">=</span><span class="nt">177406</span>
<span class="nt">RKBA</span><span class="o">=</span><span class="nt">177410</span>
<span class="nt">RKDA</span><span class="o">=</span><span class="nt">177412</span>
<span class="nt">XCSR</span><span class="o">=</span><span class="nt">177564</span>
<span class="nt">XBUF</span><span class="o">=</span><span class="nt">177566</span>
<span class="p">.</span><span class="nc">ASECT</span>
<span class="o">.=</span><span class="nt">1000</span>
<span class="nt">START</span><span class="o">:</span>
<span class="nt">MOV</span> <span class="p">#</span><span class="nn">700</span><span class="o">,</span><span class="nt">SP</span> <span class="o">;</span><span class="nt">INIT</span> <span class="nt">STACK</span> <span class="nt">POINTER</span>
<span class="o">;</span><span class="nt">-----</span> <span class="nt">INIT</span> <span class="nt">CRC</span> <span class="nt">LOOKUP</span> <span class="nt">TABLE</span>
<span class="nt">MOV</span> <span class="p">#</span><span class="nn">10041</span><span class="o">,</span><span class="nt">R0</span> <span class="o">;</span><span class="nt">CRC</span> <span class="nt">POLYNOMIAL</span>
<span class="nt">MOV</span> <span class="p">#</span><span class="nn">CRCTBL</span><span class="o">,</span><span class="nt">R1</span> <span class="o">;</span><span class="nt">LOOKUP</span> <span class="nt">TABLE</span> <span class="nt">TO</span> <span class="nt">FILL</span>
<span class="nt">ADD</span> <span class="p">#</span><span class="nn">1000</span><span class="o">,</span><span class="nt">R1</span> <span class="o">;</span><span class="nt">START</span> <span class="nt">FILLING</span> <span class="nt">FROM</span> <span class="nt">END</span> <span class="o">(+</span><span class="nt">256</span> <span class="nt">WORDS</span><span class="o">)</span>
<span class="nt">MOV</span> <span class="p">#</span><span class="nn">377</span><span class="o">,</span><span class="nt">R2</span> <span class="o">;</span><span class="nt">COUNT</span> <span class="nt">DOWN</span> <span class="nt">FROM</span> <span class="nt">INDEX</span> <span class="nt">255</span>
<span class="nt">L0</span><span class="o">:</span> <span class="nt">MOV</span> <span class="nt">R2</span><span class="o">,</span><span class="nt">R4</span> <span class="o">;</span><span class="nt">GET</span> <span class="nt">COPY</span> <span class="nt">OF</span> <span class="nt">INDEX</span>
<span class="nt">SWAB</span> <span class="nt">R4</span> <span class="o">;</span><span class="nt">MOVE</span> <span class="nt">TO</span> <span class="nt">UPPER</span> <span class="nt">BYTE</span>
<span class="nt">MOV</span> <span class="p">#</span><span class="nn">10</span><span class="o">,</span><span class="nt">R3</span> <span class="o">;</span><span class="nt">LOOP</span> <span class="nt">OVER</span> <span class="nt">EIGHT</span> <span class="nt">BITS</span> <span class="nt">OF</span> <span class="nt">INDEX</span>
<span class="nt">L1</span><span class="o">:</span> <span class="nt">ASL</span> <span class="nt">R4</span> <span class="o">;</span><span class="nt">SHIFT</span><span class="o">,</span> <span class="nt">MSB</span> <span class="nt">TO</span> <span class="nt">CARRY</span> <span class="nt">FLAG</span>
<span class="nt">BCC</span> <span class="nt">L2</span> <span class="o">;</span><span class="nt">IF</span> <span class="nt">MSB</span> <span class="nt">NOT</span> <span class="nt">SET</span> <span class="nt">SKIP</span> <span class="nt">AHEAD</span>
<span class="nt">XOR</span> <span class="nt">R0</span><span class="o">,</span><span class="nt">R4</span> <span class="o">;</span><span class="nt">ELSE</span> <span class="nt">XOR</span> <span class="nt">IN</span> <span class="nt">POLYNOMIAL</span>
<span class="nt">L2</span><span class="o">:</span> <span class="nt">SOB</span> <span class="nt">R3</span><span class="o">,</span><span class="nt">L1</span> <span class="o">;</span><span class="nt">LOOP</span> <span class="nt">OVER</span> <span class="nt">BITS</span>
<span class="nt">MOV</span> <span class="nt">R4</span><span class="o">,</span><span class="nt">-</span><span class="o">(</span><span class="nt">R1</span><span class="o">)</span> <span class="o">;</span><span class="nt">SAVE</span> <span class="nt">RESULT</span> <span class="nt">IN</span> <span class="nt">LOOKUP</span> <span class="nt">TABLE</span>
<span class="nt">DEC</span> <span class="nt">R2</span> <span class="o">;</span><span class="nt">COUNT</span> <span class="nt">DOWN</span>
<span class="nt">BPL</span> <span class="nt">L0</span> <span class="o">;</span><span class="nt">LOOP</span> <span class="nt">OVER</span> <span class="nt">TABLE</span> <span class="nt">ENTRIES</span>
<span class="nt">CLR</span> <span class="nt">R5</span> <span class="o">;</span><span class="nt">INIT</span> <span class="nt">SECTOR</span> <span class="nt">COUNTER</span>
<span class="o">;</span><span class="nt">-----</span> <span class="nt">PRINT</span> <span class="nt">START</span> <span class="nt">OF</span> <span class="nt">LINE</span>
<span class="nt">L3</span><span class="o">:</span> <span class="nt">MOV</span> <span class="nt">R5</span><span class="o">,</span><span class="nt">R0</span> <span class="o">;</span><span class="nt">GET</span> <span class="nt">SECTOR</span> <span class="nt">COUNTER</span>
<span class="nt">JSR</span> <span class="nt">PC</span><span class="o">,</span><span class="nt">PRNW</span> <span class="o">;</span><span class="nt">PRINT</span> <span class="nt">IT</span>
<span class="nt">MOV</span> <span class="p">#</span><span class="nn">DELIM1</span><span class="o">,</span><span class="nt">R0</span> <span class="o">;</span><span class="nt">GET</span> <span class="nt">POST-SECTOR</span> <span class="nt">DELIMETER</span>
<span class="nt">JSR</span> <span class="nt">PC</span><span class="o">,</span><span class="nt">PRNSTR</span> <span class="o">;</span><span class="nt">PRINT</span> <span class="nt">IT</span>
<span class="o">;</span><span class="nt">-----</span> <span class="nt">READ</span> <span class="nt">8</span> <span class="nt">SECTORS</span> <span class="nt">FROM</span> <span class="nt">DISK</span>
<span class="nt">L4</span><span class="o">:</span> <span class="nt">MOV</span> <span class="nt">R5</span><span class="o">,@</span><span class="p">#</span><span class="nn">RKDA</span> <span class="o">;</span><span class="nt">SET</span> <span class="nt">START</span> <span class="nt">SECTOR</span>
<span class="nt">MOV</span> <span class="p">#</span><span class="nn">DBUF</span><span class="o">,@</span><span class="p">#</span><span class="nn">RKBA</span> <span class="o">;</span><span class="nt">SET</span> <span class="nt">TARGET</span> <span class="nt">ADDRESS</span>
<span class="nt">MOV</span> <span class="p">#</span><span class="nn">-4000</span><span class="o">,@</span><span class="p">#</span><span class="nn">RKWC</span> <span class="o">;</span><span class="nt">READ</span> <span class="nt">8</span> <span class="nt">SECTORS</span> <span class="o">(</span><span class="nt">2K</span> <span class="nt">WORDS</span><span class="o">)</span>
<span class="nt">MOV</span> <span class="p">#</span><span class="nn">5</span><span class="o">,@</span><span class="p">#</span><span class="nn">RKCS</span> <span class="o">;</span><span class="nt">READ</span> <span class="o">+</span> <span class="nt">GO</span>
<span class="nt">TSTB</span> <span class="o">@</span><span class="p">#</span><span class="nn">RKCS</span> <span class="o">;</span><span class="nt">CHECK</span> <span class="nt">RKCS</span> <span class="nt">RDY</span> <span class="nt">BIT</span>
<span class="nt">BPL</span> <span class="p">.</span><span class="nc">-4</span> <span class="o">;</span><span class="nt">LOOP</span> <span class="nt">IF</span> <span class="nt">BUSY</span>
<span class="o">;</span><span class="nt">-----</span> <span class="nt">HANDLE</span> <span class="nt">ERROR</span> <span class="nt">IF</span> <span class="nt">ANY</span>
<span class="nt">BIT</span> <span class="p">#</span><span class="nn">100000</span><span class="o">,@</span><span class="p">#</span><span class="nn">RKCS</span> <span class="o">;</span><span class="nt">CHECK</span> <span class="nt">FOR</span> <span class="nt">ERROR</span>
<span class="nt">BEQ</span> <span class="nt">L5</span> <span class="o">;</span><span class="nt">SKIP</span> <span class="nt">AHEAD</span> <span class="nt">IF</span> <span class="nt">NOT</span>
<span class="nt">MOV</span> <span class="p">#</span><span class="nn">ERRSTR</span><span class="o">,</span><span class="nt">R0</span> <span class="o">;</span><span class="nt">POINT</span> <span class="nt">TO</span> <span class="nt">ERROR</span> <span class="nt">INDICATOR</span>
<span class="nt">JSR</span> <span class="nt">PC</span><span class="o">,</span><span class="nt">PRNSTR</span> <span class="o">;</span><span class="nt">PRINT</span> <span class="nt">IT</span>
<span class="nt">MOV</span> <span class="o">@</span><span class="p">#</span><span class="nn">RKER</span><span class="o">,</span><span class="nt">R0</span> <span class="o">;</span><span class="nt">GET</span> <span class="nt">ERROR</span> <span class="nt">REG</span>
<span class="nt">JSR</span> <span class="nt">PC</span><span class="o">,</span><span class="nt">PRNW</span> <span class="o">;</span><span class="nt">PRINT</span> <span class="nt">IT</span>
<span class="nt">BR</span> <span class="nt">L8</span> <span class="o">;</span><span class="nt">MOVE</span> <span class="nt">ON</span> <span class="nt">TO</span> <span class="nt">NEXT</span> <span class="nt">8</span> <span class="nt">SECTORS</span>
<span class="nt">L5</span><span class="o">:</span> <span class="nt">MOV</span> <span class="p">#</span><span class="nn">DBUF</span><span class="o">,</span><span class="nt">R4</span> <span class="o">;</span><span class="nt">POINT</span> <span class="nt">TO</span> <span class="nt">START</span> <span class="nt">OF</span> <span class="nt">DATA</span> <span class="nt">JUST</span> <span class="nt">READ</span>
<span class="o">;</span><span class="nt">-----</span> <span class="nt">RUN</span> <span class="nt">CRC</span> <span class="nt">FOR</span> <span class="nt">ONE</span> <span class="nt">SECTOR</span><span class="o">.</span> <span class="nt">FOR</span> <span class="nt">EACH</span> <span class="nt">INPUT</span> <span class="nt">BYTE</span> <span class="nt">CH</span><span class="o">:</span>
<span class="o">;</span> <span class="nt">CRC</span> <span class="o">=</span> <span class="nt">CRCTBL</span><span class="cp">[</span><span class="p">((</span><span class="nx">CRC</span> <span class="o">>></span> <span class="mi">8</span><span class="p">)</span> <span class="p">^</span> <span class="nx">CH</span><span class="p">)</span> <span class="o">&</span> <span class="mi">255</span><span class="cp">]</span> <span class="o">^</span> <span class="o">(</span><span class="nt">CRC</span> <span class="o"><<</span> <span class="nt">8</span><span class="o">)</span>
<span class="nt">L6</span><span class="o">:</span> <span class="nt">CLR</span> <span class="nt">R0</span> <span class="o">;</span><span class="nt">RESET</span> <span class="nt">CRC</span>
<span class="nt">MOV</span> <span class="p">#</span><span class="nn">1000</span><span class="o">,</span><span class="nt">R1</span> <span class="o">;</span><span class="nt">LOOP</span> <span class="nt">OVER</span> <span class="nt">ONE</span> <span class="nt">SECTOR</span> <span class="o">(</span><span class="nt">256</span> <span class="nt">WORDS</span><span class="o">)</span>
<span class="nt">L7</span><span class="o">:</span> <span class="nt">MOV</span> <span class="nt">R0</span><span class="o">,</span><span class="nt">R2</span> <span class="o">;</span><span class="nt">GET</span> <span class="nt">COPY</span> <span class="nt">OF</span> <span class="nt">CRC</span>
<span class="nt">SWAB</span> <span class="nt">R2</span> <span class="o">;</span><span class="nt">MOVE</span> <span class="nt">HIGH</span> <span class="nt">BYTE</span> <span class="nt">DOWN</span>
<span class="nt">MOVB</span> <span class="o">(</span><span class="nt">R4</span><span class="o">)+,</span><span class="nt">R3</span> <span class="o">;</span><span class="nt">GET</span> <span class="nt">NEXT</span> <span class="nt">INPUT</span> <span class="nt">BYTE</span> <span class="nt">TO</span> <span class="nt">PROCESS</span>
<span class="nt">XOR</span> <span class="nt">R3</span><span class="o">,</span><span class="nt">R2</span> <span class="o">;</span><span class="nt">XOR</span> <span class="nt">ONTO</span> <span class="nt">MUNGED</span> <span class="nt">CRC</span>
<span class="nt">BIC</span> <span class="p">#</span><span class="nn">177400</span><span class="o">,</span><span class="nt">R2</span> <span class="o">;</span><span class="nt">MASK</span> <span class="nt">OFF</span> <span class="nt">HIGH</span> <span class="nt">BYTE</span>
<span class="nt">ASL</span> <span class="nt">R2</span> <span class="o">;</span><span class="nt">TIMES</span> <span class="nt">TWO</span> <span class="nt">INDEX</span> <span class="nt">INTO</span> <span class="nt">LOOKUP</span> <span class="nt">TABLE</span>
<span class="nt">MOV</span> <span class="nt">CRCTBL</span><span class="o">(</span><span class="nt">R2</span><span class="o">),</span><span class="nt">R3</span> <span class="o">;</span><span class="nt">LOOKUP</span> <span class="nt">VALUE</span>
<span class="nt">SWAB</span> <span class="nt">R0</span> <span class="o">;</span><span class="nt">MOVE</span> <span class="nt">LOW</span> <span class="nt">BYTE</span> <span class="nt">OF</span> <span class="nt">CRC</span> <span class="nt">UP</span>
<span class="nt">CLRB</span> <span class="nt">R0</span> <span class="o">;</span><span class="nt">MASK</span> <span class="nt">OFF</span> <span class="nt">THE</span> <span class="nt">BOTTOM</span>
<span class="nt">XOR</span> <span class="nt">R3</span><span class="o">,</span><span class="nt">R0</span> <span class="o">;</span><span class="nt">XOR</span> <span class="nt">IN</span> <span class="nt">THE</span> <span class="nt">LOOKED</span> <span class="nt">UP</span> <span class="nt">VALUE</span>
<span class="nt">SOB</span> <span class="nt">R1</span><span class="o">,</span><span class="nt">L7</span> <span class="o">;</span><span class="nt">LOOP</span> <span class="nt">OVER</span> <span class="nt">BYTES</span>
<span class="o">;</span><span class="nt">-----</span> <span class="nt">PRINT</span> <span class="nt">CRC</span><span class="o">,</span> <span class="nt">DELIMIT</span> <span class="nt">AND</span> <span class="nt">LOOP</span>
<span class="nt">JSR</span> <span class="nt">PC</span><span class="o">,</span><span class="nt">PRNW</span> <span class="o">;</span><span class="nt">PRINT</span> <span class="nt">CRC</span><span class="o">,</span> <span class="nt">ALREADY</span> <span class="nt">IN</span> <span class="nt">R0</span>
<span class="nt">CMP</span> <span class="nt">R4</span><span class="o">,</span><span class="p">#</span><span class="nn">DBUF</span><span class="o">+</span><span class="nt">10000</span> <span class="o">;</span><span class="nt">END</span> <span class="nt">OF</span> <span class="nt">DISK</span> <span class="nt">BUFFER</span><span class="o">?</span>
<span class="nt">BEQ</span> <span class="nt">L8</span> <span class="o">;</span><span class="nt">IF</span> <span class="nt">SO</span><span class="o">,</span> <span class="nt">EXIT</span> <span class="nt">LOOP</span>
<span class="nt">MOV</span> <span class="p">#</span><span class="nn">DELIM2</span><span class="o">,</span><span class="nt">R0</span> <span class="o">;</span><span class="nt">ELSE</span> <span class="nt">POINT</span> <span class="nt">TO</span> <span class="nt">POST-CRC</span> <span class="nt">DELIMETER</span>
<span class="nt">JSR</span> <span class="nt">PC</span><span class="o">,</span><span class="nt">PRNSTR</span> <span class="o">;</span><span class="nt">PRINT</span> <span class="nt">IT</span>
<span class="nt">BR</span> <span class="nt">L6</span> <span class="o">;</span><span class="nt">GO</span> <span class="nt">DO</span> <span class="nt">ANOTHER</span> <span class="nt">SECTOR</span>
<span class="o">;</span><span class="nt">-----</span> <span class="nt">DELIMIT</span> <span class="nt">END</span> <span class="nt">OF</span> <span class="nt">LINE</span><span class="o">,</span> <span class="nt">LOOP</span>
<span class="nt">L8</span><span class="o">:</span> <span class="nt">MOV</span> <span class="p">#</span><span class="nn">CRLF</span><span class="o">,</span><span class="nt">R0</span> <span class="o">;</span><span class="nt">POINT</span> <span class="nt">TO</span> <span class="nt">LINE</span> <span class="nt">DELIMETER</span>
<span class="nt">JSR</span> <span class="nt">PC</span><span class="o">,</span><span class="nt">PRNSTR</span> <span class="o">;</span><span class="nt">PRINT</span> <span class="nt">IT</span>
<span class="nt">ADD</span> <span class="p">#</span><span class="nn">10</span><span class="o">,</span><span class="nt">R5</span> <span class="o">;</span><span class="nt">MOVE</span> <span class="nt">AHEAD</span> <span class="nt">8</span> <span class="nt">SECTORS</span>
<span class="nt">CMP</span> <span class="nt">R5</span><span class="o">,</span><span class="p">#</span><span class="nn">11410</span> <span class="o">;</span><span class="nt">AT</span> <span class="nt">END</span> <span class="nt">OF</span> <span class="nt">PACK</span><span class="o">?</span>
<span class="nt">BLT</span> <span class="nt">L3</span> <span class="o">;</span><span class="nt">IF</span> <span class="nt">NOT</span><span class="o">,</span> <span class="nt">GO</span> <span class="nt">DO</span> <span class="nt">THE</span> <span class="nt">NEXT</span> <span class="nt">8</span>
<span class="nt">HALT</span> <span class="o">;</span><span class="nt">ALL</span> <span class="nt">DONE</span><span class="o">!</span>
<span class="o">;</span><span class="nt">-----</span> <span class="nt">PRINT</span> <span class="nt">A</span> <span class="nt">WORD</span> <span class="nt">IN</span> <span class="nt">OCTAL</span>
<span class="nt">PRNW</span><span class="o">:</span> <span class="nt">MOV</span> <span class="p">#</span><span class="nn">6</span><span class="o">,</span><span class="nt">R2</span> <span class="o">;</span><span class="nt">SIX</span> <span class="nt">DIGITS</span> <span class="nt">TO</span> <span class="nt">PRINT</span>
<span class="nt">MOV</span> <span class="nt">R0</span><span class="o">,</span><span class="nt">R1</span> <span class="o">;</span><span class="nt">MOVE</span> <span class="nt">OUTPUT</span> <span class="nt">WORD</span> <span class="nt">OVER</span> <span class="nt">TO</span> <span class="nt">R1</span>
<span class="nt">CLR</span> <span class="nt">R0</span> <span class="o">;</span><span class="nt">RESET</span> <span class="nt">OUTPUT</span> <span class="nt">CHAR</span>
<span class="nt">ASHC</span> <span class="p">#</span><span class="nn">1</span><span class="o">,</span><span class="nt">R0</span> <span class="o">;</span><span class="nt">AND</span> <span class="nt">SHIFT</span> <span class="nt">IN</span> <span class="nt">MSB</span> <span class="nt">TO</span> <span class="nt">START</span>
<span class="nt">L9</span><span class="o">:</span> <span class="nt">ADD</span> <span class="p">#</span><span class="nn">60</span><span class="o">,</span><span class="nt">R0</span> <span class="o">;</span><span class="nt">MAKE</span> <span class="nt">INTO</span> <span class="nt">ASCII</span> <span class="nt">DIGIT</span>
<span class="nt">MOV</span> <span class="nt">R0</span><span class="o">,@</span><span class="p">#</span><span class="nn">XBUF</span> <span class="o">;</span><span class="nt">PRINT</span> <span class="nt">IT</span>
<span class="nt">TSTB</span> <span class="o">@</span><span class="p">#</span><span class="nn">XCSR</span> <span class="o">;</span><span class="nt">CHECK</span> <span class="nt">IF</span> <span class="nt">XMIT</span> <span class="nt">DONE</span>
<span class="nt">BPL</span> <span class="p">.</span><span class="nc">-4</span> <span class="o">;</span><span class="nt">LOOP</span> <span class="nt">UNTIL</span> <span class="nt">SO</span>
<span class="nt">CLR</span> <span class="nt">R0</span> <span class="o">;</span><span class="nt">RESET</span> <span class="nt">OUTPUT</span> <span class="nt">CHAR</span>
<span class="nt">ASHC</span> <span class="p">#</span><span class="nn">3</span><span class="o">,</span><span class="nt">R0</span> <span class="o">;</span><span class="nt">SHIFT</span> <span class="nt">IN</span> <span class="nt">NEXT</span> <span class="nt">THREE</span> <span class="nt">BITS</span>
<span class="nt">SOB</span> <span class="nt">R2</span><span class="o">,</span><span class="nt">L9</span> <span class="o">;</span><span class="nt">LOOP</span> <span class="nt">DIGITS</span>
<span class="nt">RTS</span> <span class="nt">PC</span> <span class="o">;</span><span class="nt">RETURN</span> <span class="nt">TO</span> <span class="nt">CALLER</span>
<span class="o">;</span><span class="nt">-----</span> <span class="nt">PRINT</span> <span class="nt">A</span> <span class="nt">NULL-TERMINATED</span> <span class="nt">STRING</span>
<span class="nt">PRNSTR</span><span class="o">:</span> <span class="nt">MOVB</span> <span class="o">(</span><span class="nt">R0</span><span class="o">)+,@</span><span class="p">#</span><span class="nn">XBUF</span> <span class="o">;</span><span class="nt">PRINT</span> <span class="nt">ONE</span> <span class="nt">CHAR</span> <span class="nt">AND</span> <span class="nt">ADVANCE</span>
<span class="nt">TSTB</span> <span class="o">@</span><span class="p">#</span><span class="nn">XCSR</span> <span class="o">;</span><span class="nt">CHECK</span> <span class="nt">IF</span> <span class="nt">XMIT</span> <span class="nt">DONE</span>
<span class="nt">BPL</span> <span class="p">.</span><span class="nc">-4</span> <span class="o">;</span><span class="nt">LOOP</span> <span class="nt">UNTIL</span> <span class="nt">SO</span>
<span class="nt">TSTB</span> <span class="p">@</span><span class="k">R0</span> <span class="p">;</span><span class="nt">CHECK</span> <span class="nt">IF</span> <span class="nt">END</span> <span class="nt">OF</span> <span class="nt">STRING</span>
<span class="nt">BNE</span> <span class="nt">PRNSTR</span> <span class="o">;</span><span class="nt">LOOP</span> <span class="nt">IF</span> <span class="nt">NOT</span>
<span class="nt">RTS</span> <span class="nt">PC</span> <span class="o">;</span><span class="nt">ELSE</span> <span class="nt">RETURN</span> <span class="nt">TO</span> <span class="nt">CALLER</span>
<span class="nt">DELIM1</span><span class="o">:</span> <span class="p">.</span><span class="nc">ASCIZ</span> <span class="o">/:</span> <span class="o">/</span> <span class="o">;</span><span class="nt">POST-SECTOR</span> <span class="nt">DELIMETER</span>
<span class="nt">DELIM2</span><span class="o">:</span> <span class="p">.</span><span class="nc">ASCIZ</span> <span class="o">/</span> <span class="o">/</span> <span class="o">;</span><span class="nt">POST-CRC</span> <span class="nt">DELIMETER</span>
<span class="nt">CRLF</span><span class="o">:</span> <span class="p">.</span><span class="nc">ASCIZ</span> <span class="o"><</span><span class="nt">15</span><span class="o">><</span><span class="nt">12</span><span class="o">></span> <span class="o">;</span><span class="nt">LINE</span> <span class="nt">DELIMETER</span>
<span class="nt">ERRSTR</span><span class="o">:</span> <span class="p">.</span><span class="nc">ASCIZ</span> <span class="o">/</span><span class="nt">ERROR</span><span class="o">:</span> <span class="o">/</span> <span class="o">;</span><span class="nt">ERROR</span> <span class="nt">INDICATOR</span>
<span class="nt">CRCTBL</span><span class="o">:</span> <span class="p">.</span><span class="nc">BLKW</span> <span class="nt">400</span> <span class="o">;</span><span class="nt">CRC</span> <span class="nt">LOOKUP</span> <span class="nt">TABLE</span>
<span class="nt">DBUF</span><span class="o">:</span> <span class="p">.</span><span class="nc">BLKW</span> <span class="nt">4000</span> <span class="o">;</span><span class="nt">DISK</span> <span class="nt">DATA</span> <span class="nt">BUFFER</span>
<span class="p">.</span><span class="nc">END</span> <span class="nt">START</span>
</pre></div>
</td></tr></table>
<p>Running this indicated the RSTS pack was in good shape, and not corrupt. So, maybe I have had a lurking
hardware bug in my memory system (a 256KB MS11-L), which never tripped up RT-11 and so has to date
gone undiagnosed?</p>
<p>At this point, Noel suggested on cctalk that I give Release 6 Unix a try as well, and see if it suffers
similarly. Worth a shot! Out of time for now, and back to the day gig tomorrow after holiday break.
Happy new year, all!</p></div>
<hr>
</div>
</div>
<div class="span3">
<div class="well" style="padding: 8px 0; background-color: #FBFBFB;">
<ul class="nav nav-list">
<li class="nav-header">
Site
</li>
<li><a href="https://fritzm.github.io/archives.html">Archives</a>
<li><a href="https://fritzm.github.io/tags.html">Tags</a>
<li><a href="https://fritzm.github.io/feeds/all.rss.xml" rel="alternate">RSS feed</a></li>
</ul>
</div>
<div class="well" style="padding: 8px 0; background-color: #FBFBFB;">
<ul class="nav nav-list">
<li class="nav-header">
Categories
</li>
<li><a href="https://fritzm.github.io/category/arcade-games.html">Arcade Games</a></li>
<li><a href="https://fritzm.github.io/category/math.html">Math</a></li>
<li><a href="https://fritzm.github.io/category/micros.html">Micros</a></li>
<li><a href="https://fritzm.github.io/category/pdp-11.html">PDP-11</a></li>
<li><a href="https://fritzm.github.io/category/programming.html">Programming</a></li>
<li><a href="https://fritzm.github.io/category/radios.html">Radios</a></li>
</ul>
</div>
<div class="social">
<div class="well" style="padding: 8px 0; background-color: #FBFBFB;">
<ul class="nav nav-list">
<li class="nav-header">
Social
</li>
<li><a href="http://facebook.com/fritzmueller">facebook</a></li>
<li><a href="http://instagram.com/infrafritz">Instagram</a></li>
<li><a href="http://www.linkedin.com/pub/fritz-mueller/a/679/62/">LinkedIn</a></li>
<li><a href="http://jsfiddle.net/user/fritzm/fiddles/">JSFiddle</a></li>
<li><a href="https://github.com/fritzm">GitHub</a></li>
</ul>
</div>
</div>
</div>
</div> </div>
<footer>
<br />
<p><a href="https://fritzm.github.io">fritzm.github.io</a> © Fritz Mueller 2023</p>
</footer>
</div> <!-- /container -->
<!-- Photoswipe -->
<div class="pswp" tabindex="-1" role="dialog" aria-hidden="true">
<div class="pswp__bg"></div>
<div class="pswp__scroll-wrap">
<div class="pswp__container">
<div class="pswp__item"></div>
<div class="pswp__item"></div>
<div class="pswp__item"></div>
</div>
<div class="pswp__ui pswp__ui--hidden">
<div class="pswp__top-bar">
<div class="pswp__counter"></div>
<button class="pswp__button pswp__button--close" title="Close (Esc)"></button>
<button class="pswp__button pswp__button--share" title="Share"></button>
<button class="pswp__button pswp__button--fs" title="Toggle fullscreen"></button>
<button class="pswp__button pswp__button--zoom" title="Zoom in/out"></button>
<div class="pswp__preloader">
<div class="pswp__preloader__icn">
<div class="pswp__preloader__cut">
<div class="pswp__preloader__donut"></div>
</div>
</div>
</div>
</div>
<div class="pswp__share-modal pswp__share-modal--hidden pswp__single-tap">
<div class="pswp__share-tooltip"></div>
</div>
<button class="pswp__button pswp__button--arrow--left" title="Previous (arrow left)">
</button>
<button class="pswp__button pswp__button--arrow--right" title="Next (arrow right)">
</button>
<div class="pswp__caption">
<div class="pswp__caption__center"></div>
</div>
</div>
</div>
</div>
<script src="http://ajax.googleapis.com/ajax/libs/jquery/1.7.1/jquery.min.js"></script>
<script src="https://fritzm.github.io/theme/bootstrap-collapse.js"></script>
</body>
</html>