ttl Dartmouth Time-Sharing System 235 Executive 00001 stl Initial Loader 00002 loc 34000 Date of latest reassembly goes here 00003 #date bss 0 00004 oct 1032 Update August 26, 1965 [RPL] 00005 00006 00007 00008 Dartmouth College Time-Sharing System 00009 235 Executive 00010 00011 Richard P. Lacey [67] April 1965 - 00012 John S. McGeachie [65] April 1964 - April 65 00013 00014 Phase IV 00015 For 44 teletype disk allocation of July 13, 00016 1965. 00017 00018 00019 16K Loader - will load 16K GAP cards into 00020 upper or lower memory. Accepts single or 00021 multiple origin cards and octal corrections. 00022 Octal corrections may be single or multiple 00023 origin. Scan terminated by single character 00024 field. 00025 Author Charles G. Moore [65] 00026 00027 00028 loc 3000 00029 #r bss 42 read-in area 00030 #rw bss 41 analyze area 00031 octacc bss 1 working storage for octal corrections 00032 octadd bss 1 00033 #wdct oct 2017777 mask to leave address and sign bit 00034 #R2 dec #rw card move constants 00035 dec -40 00036 #mc dec 2 memory clear constants 00037 dec -1533 00038 #mc1 dec #last+1 00039 dec -12286 00040 #addr oct 1760000 address correction mask 00041 #8k dec 8192 00042 octc oct 3776000 octal correction mask 00043 #load1 ldz check switch 19 for memory clear 00044 sta #last clear to contents of switches 00045 sta 1 00046 ldx 8k 2 get upper bit 00047 lda #date 2 and save date 00048 sta #x3sv 00049 dld #mc 00050 mov 1 00051 rcs Check if clear later part 00052 sta #sflag Set systems flag 00053 bod 00054 bru #load No 00055 dld #mc1 00056 mov #last 00057 ldx #8k 1 Restore at earliest 00058 lda #x3sv 00059 sta #date 1 opportunity 00060 #load rcb #r Read first card - fill buffer 00061 hcr but is loaded normally 00062 ldz Make sure we start in lower bank 00063 sta #x3sv 00064 #r1 dld #r2 Normal entrance for card read 00065 bcn 00066 bru *-1 Wait for reader ready 00067 mov #r and then move from read buffer 00068 sta #rw+40 Set zero to end of card image 00069 ldx #zf 1 Set up for scan 00070 ldx #x3sv 3 Restore X3 00071 lda #rw 1 RW is working area - get control word 00072 bze 00073 bru #oct 00074 ext #wdct 00075 bze 00076 bru #t 00077 rcb #r 00078 hcr 00079 sra 13 00080 #ze sta 0 00081 lda #rw 1 00082 ext #addr Leave address and sign bit 00083 bmi If upper 8k add index bit 00084 #dart2 bru #dart1 First Dartmouth-style card found 00085 sto 3 Otherwise, GAL convention 00086 #ret inx 1 1 is return for each word in string 00087 lda #rw 1 00088 sta 0 3 Put it away 00089 add #rw-1 1 totaling for checksum 00090 bov 00091 ado 00092 sta #rw 1 Save present checksum 00093 inx -1 0 Bump down word counter 00094 inx 1 3 and bump up address counter - put away 00095 bxh 1 0 and check for end of string 00096 bru #ret If not, put away another word 00097 sub #rw+1 1 00098 bze Check checkword 00099 bru *+3 00100 lda #rrr If not, set up for error halt 00101 bru * Recover is backspace A-I start 00102 inx 2 1 00103 lda #rw 1 00104 ext #wdct 00105 bnz 00106 bru #ze-1 00107 #rrr bru #r1 Go get another card 00108 #t lda #rw 1 Get transfer address 00109 bmi 00110 #dart3 ldx #8k 3 If first Dartmouth-style, do not panic 00111 sto 3 Else GAL 00112 lda #sflag Save systems flag 00113 sta sload 00114 bru 0 3 exit 00115 add #8k 00116 #dart1 lda *-1 Set instructions for Dartmouth style 00117 sta #dart2 00118 sta #dart3 Reset transfer 00119 lda octe+1 00120 sta #dart2+1 00121 sta #dart3+1 00122 bru #ze+1 Get back 00123 00124 Free-form octal corrections - 00125 00126 #oct rcb #r 00127 hcr 00128 ldx #ze 2 00129 stx #x3sv 3 Save index register 3 00130 bru octe 00131 octb sra 10 00132 ext octc Get left half of word, and dump rest 00133 nor 16 00134 sla 1 00135 lda octacc 00136 bov If overflow, there is a word 00137 bru octd 00138 bxl 2 3 00139 bru octe 00140 bxl 3 3 00141 bru #r1 Single character field - get out 00142 bxh 7 3 00143 bru octf 00144 sta octadd Or address 00145 octe ldz 00146 sta 3 00147 lqa 00148 bru octa-1 00149 octd sld 3 00150 ext 0 00151 bno 00152 chs 00153 sta octacc 00154 octa inx 1 3 00155 bxh 40 1 00156 bru #r1 Card finished 00157 lda octc 00158 lqa 00159 lda #rw 1 00160 bxl 1 2 00161 spb octb 2 00162 inx 1 1 00163 ldx #ze 2 00164 bru octb+1 00165 octf ldx octadd 3 00166 sta 0 3 00167 inx 1 3 00168 stx octadd 3 00169 bru octf 00170 #x3sv bss 1 X 3 temporary save 00171 #sflag bss 1 Systems temporary flag 00172 #last equ * 00173 tcd #load1 00174 00175 stl Disk loader for systems and executive 00176 ejt 00177 00178 Load checks switch 7 - if down, then no 00179 billing is desired, so KBILL and IREC are 00180 inhibited. 00181 - if up, billing is desired. 00182 00183 00184 The SRES sequence performs a series of 00185 checks to insure that 00186 1] the SPR switch is set to the all position 00187 2] the disk is clear 00188 and the 6k mod is working 00189 3] the console switches are reset 00190 4] the AAU is ready 00191 If any of the above conditions fail to 00192 be true, the console typewriter will type 00193 a message to the operator and continue to 00194 do so until the condition has been corrected. 00195 00196 5] SRES also checks the batch flag. If on, 00197 it crumps the switch check and sets up an 00198 entry into the batch overlay in the task 00199 list. 00200 6] It reads in the summary record from the 00201 disk and resets it to zero if the bootstrap was 00202 typed on TTY 1. 00203 00204 loc 1000 00205 load bss 0 00206 ton 00207 sxg 0 Set zero in case switch bad 00208 ldx 8k 3 00209 lmo Set disk flag 2 on 00210 sta dkflg2 00211 ldz and set address for relinquish 00212 sta relad 3 00213 rcs Check billing switch 00214 ext $bmsk billing mask - oct 3767777 00215 sta $bf and set in flag 00216 bnz1 00217 bru *+4 Billing not set 00218 spb $ertyp 2 Billing flag on 00219 dec bon 00220 bru sres 00221 spb $ertyp 2 Billing flag off 00222 dec boff 00223 lda $nob Inhibit KBILL and IREC 00224 sta kbill 3 00225 sta irec 3 00226 00227 sres sxg 0 00228 set pbk and prevent interrupts 00229 lda sign 00230 sta pmbx0 00231 ton 00232 ldz Now find out what group we are in 00233 sta xr01 00234 sta z1 00235 spb *+1 1 00236 lda xr01 00237 bnz 00238 bru saok Ok, neither API not Trap 00239 lda z1 API... 00240 bnz 00241 set pst yes, exit 00242 set pbk 00243 set trpmode 00244 set ntpmode 00245 ldx zero 2 and exit 00246 bru *+1 2 00247 saok sxg 5 continue 00248 ldx 8k 3 Set upper 8k bit on 00249 ldx zero 1 Test SPB switch 00250 spb *+1 1 00251 bxh 1 1 If 1 is higher than 1, then SPB switch is 00252 bru *+6 set to all, else it is at 0 00253 sxg 0 set 0 00254 ldx 8k 3 Upper 8k bit on 00255 spb $ertyp 2 00256 dec rspb Reset SPB switch to all 00257 bru sres Go back and test again 00258 bar bar 7 See how AAU is 00259 bru *+4 00260 spb $ertyp 2 00261 dec raau Loafing 00262 bru sres and check again 00263 spb $dkstst 2 Get disk 00264 lda loadf Check for card load 00265 bmi If load flag on, 00266 bru loadc then punt message this time 00267 00268 If batch bootstrap do not bring in the summary 00269 lda sbak See if batch 00270 bpl 00271 bru *+12 00272 lda sbak+1 See if have a front 00273 sta io1 minus if a front card was around 00274 dld .sres. Batch - so set up return 00275 dst iplst 3 00276 dld bsums1 Get summary back 00277 mov bsums 00278 lac Compute batch running time 00279 sub otim1t 3 00280 add fkbat 00281 sta fkbat 00282 bru skex and get out 00283 00284 procede with normal bootstrap 00285 sel 0 00286 prf 0 Position for efficiency record 00287 oct 402 00288 bcs brn 0 00289 bru *-1 00290 sel 0 00291 rrd 1 0 00292 dec fclock 00293 bcs brn 0 Wait 00294 bru *-1 00295 bcs ber 0 00296 bru *-11 00297 lda sign Reset special mailbox to normal status 00298 sta pmbx0 00299 lda fclock Check starting time 00300 bnz If not zero, then regular bootstrap 00301 bru soak2 so skip initialization 00302 dld fclear If zero, clear summary area 00303 mov fclock 00304 sta acrun 00305 sta acswap 00306 sta acdisk Initialize accumulated time counts 00307 sta acbat 00308 lac Get starting time 00309 sta fclock 00310 sta acstrt 00311 spb $time 2 00312 Pick up starting times for short-run summary 00313 dst fstim 00314 dst astim2 Long run summary 00315 sel 0 Rewrite on disk 00316 prf 0 00317 oct 402 00318 bcs brn 0 00319 bru *-1 00320 sel 0 00321 wrf 1 0 00322 dec fclock 00323 bcs brn 0 00324 bru *-1 00325 bcs ber 0 00326 bru *-11 00327 soak2 ldx zero 1 Reset flag 00328 lda f4 1 and transmit summary so far to accumulator 00329 sta fkedit 1 00330 inx 1 1 Step count 00331 bxl fkbat-f31 and test if done 00332 bru *-4 No 00333 lda ohzyf 3 00334 sta bzyf 00335 00336 Further checks to make sure system is working 00337 ldz Check for switch 1 down 00338 bcs 00339 bze 00340 bru *+3 00341 spb $ertyp 2 00342 dec res Reset switches 00343 lda exec2+1 3 Check 6K mod on disk 00344 sub 1025 Left in from bootstrap 00345 bnz 00346 Bru *+4 OK 00347 spb $ertyp 2 00348 dec sdsd 00349 bru load1 Try again 00350 lda $bf Billing flag 00351 bnz 00352 bru stime Not on, crump 00353 sboot spb $twait 2 Wait for tape 00354 bru *-1 Try again 00355 sel 1 If OK, write 00356 wtb boot 0 Bootstrap message 00357 dec 30 Different length 00358 spb $twait 2 Check again 00359 bru sboot Try again 00360 bru stime Get around buffer 00361 stime spb $time 2 00362 sta d1 Store it in done statement 00363 laq 00364 sta d1+1 00365 spb $ertyp 2 00366 dec d 00367 lda tmm Temporary malfunction 00368 sta mbx1 00369 lda kermes Error message 00370 sta mbx0 00371 00372 skex spb $relin 2 Get rid of the disk 00373 ldx zero 2 00374 lda pmbx0 Wait for d-30 to answer 00375 bmi 00376 bru *+5 00377 inx 1 2 See how long he takes 00378 ldx zero 1 Waste time 00379 bxl 8190 2 00380 bru *-6 2/3 of a second 00381 kon Go on with load 00382 oct 2506014 Priority request 00383 bru wait 3 Get out 00384 00385 00386 $relin bru relin 3 00387 $time bru time 3 00388 00389 00390 00391 $twait lda dtime Get inteval 00392 bcs btr 1 If tape ready 00393 bru 2 2 return OK 00394 maq Save count 00395 rcs Check switches 00396 sra 19-7 and check switch 7 00397 bod 00398 bru stime If down, punt 00399 laq Else keep counting 00400 sbo else count 00401 bpl 00402 bru $twait+1 Still OK 00403 stx $temp 2 Save register 00404 spb $ertyp 2 and type message 00405 dec $tpnr Tape not ready 00406 ldx $temp 2 Get register 00407 bru 1 2 and bad return 00408 00409 00410 00411 $ertyp ldx zero 0 Initialize coutner 00412 lda 1 2 and get address of message 00413 sta temp 00414 ldx temp 1 00415 ton Turn on typewriter 00416 bnr and check if ready 00417 bru $type1 00418 inx 1 0 Count 00419 bxl 8190 0 00420 bru *-4 and keep trying 00421 bru 2 2 Exit if not ready 00422 00423 $type1 lda 0 1 Get word 00424 ext sign and get rid of sign 00425 srd 12 Get most in Q 00426 inx 1 1 and step pointer 00427 ldx zero 0 Reset counter 00428 00429 $type stx temp 0 Save character pointer 00430 bnn and wait for ready 00431 bru *-1 00432 inx 1 0 Step counter 00433 bxl 100 0 Stupid typewriter - IBM equipment 00434 bru *-4 Make sure ready 50 times before using 00435 ldx temp 0 Restore character pointer 00436 cab peom and check for end of message 00437 bru *+2 no 00438 bru 2 2 Exit 00439 san 6 else type 00440 typ 00441 inx 1 0 Step character counter 00442 bxh 3 0 One word typed... 00443 bru $type1 yes 00444 sld 6 Get next character 00445 bru $type and type it 00446 00447 00448 $tpnr bss 0 Tape controller not ready. 00449 oct 373772 Tape controller not ready 00450 alf tap Make sure handler 0 has a scratch tape 00451 alf e c and is on remote. Then clear controller 00452 alf ont 00453 alf rol 00454 alf ler 00455 alf no 00456 alf t r 00457 alf ead 00458 oct 701537 00459 oct 754421 00460 alf ke 00461 alf sur 00462 alf e h 00463 alf and 00464 alf ler 00465 alf 0 00466 alf has 00467 alf a 00468 alf scr 00469 alf atc 00470 alf h t 00471 alf ape 00472 alf an 00473 alf d i 00474 alf s o 00475 alf n r 00476 alf emo 00477 alf te. 00478 oct 376330 00479 alf en 00480 alf cle 00481 alf ar 00482 alf con 00483 alf tro 00484 alf lle 00485 oct 513355 00486 00487 Messages 00488 00489 res bss 0 Reset switches 00490 oct 374124 00491 alf set 00492 alf sw 00493 alf itc 00494 alf hes 00495 oct 557777 00496 00497 rspb bss 0 Set SPB switch to all 00498 oct 376225 00499 alf t s 00500 alf pb 00501 alf swi 00502 alf tch 00503 alf to 00504 alf al 00505 oct 435577 00506 00507 boot bss 0 00508 oct 2606060 00509 oct 557755 Special pattern 00510 alf boo 00511 alf tst 00512 alf rap 00513 alf no 00514 oct 333535 00515 alf 00516 alf 00517 alf 00518 alf --- 00519 alf 00520 00521 d bss 0 End load Date and time. 00522 oct 372545 00523 alf d l 00524 alf oad 00525 alf 00526 date alf 00527 alf 00528 alf 00529 alf 00530 alf 00531 alf t 00532 alf ime 00533 d1 alf Time goes in these two locations 00534 alf 00535 alf ho 00536 alf urs 00537 oct 373755 00538 oct 2606060 00539 00540 bon bss 0 Billing flag set to bill 00541 oct 372231 00542 alf lli 00543 alf ng 00544 alf fla 00545 alf g s 00546 alf et 00547 alf to 00548 alf bil 00549 oct 433355 00550 00551 boff bss 0 Flag set for no bill 00552 oct 372643 00553 alf ag 00554 alf set 00555 alf fo 00556 alf r n 00557 alf o b 00558 alf ill 00559 oct 335577 00560 00561 sdsd bss 0 00562 alf som 00563 alf e f 00564 alf ool 00565 alf ch 00566 alf ang 00567 alf ed 00568 alf the 00569 alf 6K 00570 alf mo 00571 alf d s 00572 alf wit 00573 oct 233037 00574 oct 557777 00575 00576 raau bss 0 AAU loafing 00577 alf aau 00578 alf lo 00579 alf afi 00580 alf ng. 00581 oct 373755 00582 ejt Page 19 00583 The main body of the executive is first put 00584 on the disk. The 16K loader is then 00585 re-entered to read in the executive 00586 overlays, each of which is put on the disk 00587 in turn. The last overlay is followed by two 00588 transfer cards, the second of which transfers 00589 to the SRES routine which types out the 00590 DONE message to signify loading has been 00591 completed. 00592 00593 00594 loadc ldz Reset load flag 00595 sta loadf 00596 lda sload Check system flag 00597 bpl If not on, 00598 bru lself Load executive 00599 dld .set. Set up linkage 00600 dst iplst 3 Set in list 00601 set pst Just in case 00602 oct 2506014 SET PRQ 00603 bru wait 3 and scram 00604 00605 set dld unset delete entry 00606 dst iplst 3 00607 inx sys 2 and set for system 00608 bru perget 3 00609 00610 write bootstrap on the disk 00611 lself bcs brn 0 Put loader on the disk first 00612 bru *-1 00613 sel 0 00614 prf Position 00615 oct 2476 Disk 0, Position 5, Record 31 00616 bcs brn 0 00617 bru *-1 00618 sel 0 00619 wrf 1 0 00620 dec load1 Loader 00621 bcs brn 0 00622 bru *-1 00623 bcs ber 0 00624 BRU *-11 00625 lda mask6 Convert loader to write executive on disk 00626 sra 3 Place a 37 in highorder bits 00627 ory load2 00628 ory load3 00629 lda zero 00630 sta in Zero out some critical locations 00631 sta mbx0 00632 lda $bldv Pick up branch and overwrite bootstrap 00633 sta ltrans 00634 bru load1 00635 00636 00637 loadov ldz Clear overlay areas 00638 sta execove 3 00639 dld ovclr 00640 mov execov 00641 sxg 0 Set zero for loader 00642 bru #load and reenter it 00643 00644 00645 lovwrt bss 0 00646 sxg 5 00647 ldx 8k 3 00648 ldx pernum+12 Pick up overlay address pointer 00649 lda 2 2 00650 bmi If negative, error, so crump works 00651 bru * 00652 sta relad 3 Set for relinquish 00653 sta *+5 Put away in position location 00654 bcs brn 0 Wait for disk ready 00655 bru *-1 00656 sel 0 00657 prf 0 Position 00658 oct 0 00659 bcs brn 0 00660 bru *-1 00661 sel 0 00662 wrd 8 0 Write 00663 dec execov 00664 bcs brn 0 Wait 00665 bru *-1 00666 bcs ber 0 Errors... 00667 Bru *-11 If so, rewrite 00668 bru loadov Continue picking up overlays 00669 00670 00671 $dktst ldx zero 0 Set counter 00672 ldo and ask for disk 00673 sta pmbx0 00674 lda dtime 00675 bcs brr 0 Check if ready 00676 bru 1 2 If so, exit 00677 sbo Decrement 00678 bpl and wait again 00679 bru *-4 00680 inx 1 0 Increment 00681 bxl 3 0 00682 bru $dktst+1 and try again 00683 stx $temp 2 Save entry 00684 spb $ertyp 2 and type a nasty mesage 00685 dec dc 00686 ldx $ttemp 2 Restore entry 00687 bru $dktst and wait again 00688 .set. ldx zero 2 Set pointer 00689 bru set 2 00690 bsums1 dec fkedit 00691 dec -8 00692 ovclr dec execov+1 00693 dec -511 00694 unset bru iplst+2 00695 dec 0 00696 fclear dec flapse Constant to clear out summary area 00697 dec f1-f2 00698 .bres. spb bres 1 Reset entry to batch 00699 dec -1 00700 date1 dec date Date move constants 00701 dec -5 00702 date2 dec sdate 00703 dec -6 plus coded date 00704 dtime oct 40000 Disk waiting time 00705 $bmsk oct 3767777 Billing flag mask 00706 $nor bru 1 2 Tape inhibit 00707 $bldv bru loadov Bootstrap overwrite 00708 pernum bss 2 Overlay number and address pointer 00709 $bf bss 1 Billing flag 00710 $temp bss 1 Storage 00711 00712 stl Bootstrap 00713 ejt Page 22 00714 00715 00716 Disk map of 235 executive 00717 00718 Tracks 0-4 are reserved for the D-30 00719 00720 0 5 0-30 Batchsim 00721 2476 0 5 31 Bootstrap 00722 2500 0 5 32 Lower memory portion 00723 2540 0 5 48 Upper memory portion 00724 2600 0 5 64 more upper memory 00725 00726 0 6 0-31 Batchsim 00727 3100 0 6 32 Card lister 00728 3120 0 6 40 Reproducer 00729 3140 0 6 48 System loader 00730 3160 0 6 56 Catalogue files 00731 3200 0 6 64 Catalogue printout 00732 3220 0 6 72 Disk dump 00733 3240 0 6 80 Disk load 00734 3260 0 6 88 Billing overlay 00735 00736 3400 0 7 00 Batch front card record 00737 3500 0 7 32 System loader 00738 3520 0 7 40 GAP lister 00739 3540 0 7 48 Efficiency summary of system 00740 3560 0 7 56 Time-sharing background monit 00741 3600 0 7 64 Background monitor part two 00742 3620 0 7 72 Sysout lister 00743 3640 0 7 80 Tape subroutine 00744 3660 0 7 88 Batch systems catalogue 00745 00746 4100 0 8 32 T-S batch system monitor 00747 4120 0 8 40 T-S batch part three 00748 4140 0 8 48 T-S batch part two 00749 4160 0 8 56 T-S batch part four 00750 4200 0 8 64 Card to tape 00751 00752 Tracks 10 to 31 are for systems 00753 00754 24100 0 40 32 Batch dump areas 00755 24500 0 41 32 00756 25100 0 42 32 00757 25500 0 43 32 00758 00759 30000 0 48 00 Batch scratch areas 00760 30400 0 49 00 00761 31000 0 50 00 00762 31400 0 51 00 00763 00764 32000 0 52 00 Batch loaders 00765 00766 40000 1 00 00 Batch programs 00767 to 00768 51400 1 19 00 00769 00770 loc 6000 225 Executive bootstrap 00771 load1 bcs brn 0 Wait for disk ready 00772 bru *-1 00773 sel 0 Position 00774 prf 0 00775 oct 2500 00776 bcs brn 0 00777 bru *-1 00778 sel 0 Read in lower memory part 00779 load2 rrf 16 0 16 records 00780 0 from beginning of memory 00781 bcs brn 0 Wait 00782 bru *-1 00783 bcs ber 0 Check for errors 00784 bru *-11 00785 sel 0 Position again 00786 prf 0 00787 oct 2540 00788 bcs brn 0 Wait 00789 bru *-1 00790 sel 0 Read in first K of program 00791 load3 oct 1210010 Read 24 records 00792 z01 exec1 1 00793 bcs brn 0 Wait 00794 bru *-1 00795 bcs ber 0 Check for errors 00796 bru *-11 00797 lda sbak 00798 bmi 00799 bru *+13 00800 sel 0 Position for OBA from last dump 00801 prf 0 00802 oct 25660 00803 bcs brn 0 Wait 00804 bru *-1 00805 sel 0 00806 rrf 8 0 Put it back 00807 execov 00808 bcs brn 0 Wait 00809 bru *-1 00810 bcs ber 0 Check for errors 00811 bru *-11 00812 sel 0 Pick up date for output message 00813 prf 0 00814 oct 400 00815 bcs brn 0 Wait 00816 bru *-1 00817 sel 0 Read in date 00818 rrf 1 0 00819 ldate into date region 00820 bcs brn 0 Wait 00821 bru *-1 00822 bcs ber 0 Error check 00823 bru *-11 If errors, re-read 00824 dld date1 00825 mov ldate+3 00826 dld date2 00827 mov ldate+2 00828 ltrans bru sres 00829 loc 6074 Special flags 00830 sbak dec 0 Background-in-operation flag 00831 dec 0 00832 sload dec 0 System load flag 00833 loadf dec -1 Initialize load flag at -1 00834 ldate eqo 10000 00835 00836 stl Lower-lower storage 00837 ejt 00838 loc 0 00839 bss 1 Index registers used by Edit 00840 xr01 bss 1 00841 xr02 bss 1 00842 xr03 bss 1 00843 xr10 bss 1 00844 xr11 bss 1 00845 bss 1 00846 bss 1 00847 ech2 bss 1 Character holders for echar 00848 ech3 bss 1 00849 eselec bss 1 Binary line number for selective list 00850 bss 1 Starting disk address for selective list 00851 edy bss 1 Address of CR at end of instruction 00852 edt bss 1 Address of CR at end previous instruction 00853 edz bss 1 Line number currently being adjusted 00854 bss 5 Other index registers 00855 bss 2 X-group 5 00856 xr52 bss 2 00857 ty bss 20 Typewriter input line build 00858 t bss 16 Temporary storage for peripheral routines 00859 ta equ t+4 Space for tape subroutine storage 00860 dkflg1 bss 1 Disk flag 1 for regular tasks 00861 dkflg2 bss 1 For extra tasks 00862 iadrs bss 2 Disk addresses, second is memory location 00863 in bss 2 Current system identifier and rep number 00864 mstemp bss 2 Temporary storage 00865 save bss 2 A and Q saved by interrupt routine 00866 00867 00868 bzyf bss 1 Busy flag 00869 dcnt bss 1 Disk operations counter 00870 dival bss 1 Disk operations elapsed time interval 00871 drcnt bss 1 Disk operations error counter 00872 dstakf bss 1 Gives number of disk requests stacked up 00873 .eff bss 1 Efficiency flag 00874 hdskd bss 1 Time counter for disk requests 00875 inov bss 1 Overlay in use by current system 00876 inpnt bss 1 Points to disk address of current system 00877 .ins bss 1 Insert task save 00878 int1 bss 1 Interrupt time for 235 00879 isum bss 1 Clock save at interrupt time 00880 itim bss 1 Real time + 1 minute 00881 kanswr bss 1 Answer for Datanet-30 00882 kret bss 1 Temporary storage for Datanet-30 routines 00883 pcnt bss 2 Word and character counters used by ptype 00884 pct bss 1 P counter save 00885 perin bss 1 Indicates peripheral task currently in mem. 00886 preg bss 1 P-counter save for kdump 00887 ptemp bss 1 Storage for word currently being type 00888 rawt bss 1 Temporary storage 00889 stack bss 1 Backlog of typewriter requests 00890 swflg bss 1 Switch flag for next sector and peripherals 00891 temp bss 1 Temporary storage 00892 typf bss 1 Typewriter usage flag 00893 00894 Accumulator for systems operation summary 00895 00896 fkedit bss 1 0 - Mailbox routine numbers 00897 fkstrt bss 1 1 00898 fkwtnu bss 1 2 00899 fkdump bss 1 3 00900 fkread bss 1 4 00901 fkwrit bss 1 5 00902 fktea bss 1 6 00903 fkbat bss 1 Batch accumulator 00904 f3 equ fkedit-1 00905 00906 00907 cmess oct 0 Peripheral communications 00908 cmessb bss 1 Batch flag 00909 eavail dec eplst End of list 00910 einit dec iplst Start of task list 00911 ovtsk dec 0 Either zero or pointing to routine loc. 00912 ty1 dec 0 Word pointer for typweriter input 00913 ty2 dec 8192 Character pointer for typewriter input 00914 00915 .dskc. spb dskc 1 Entries 00916 .dskd. spb dskd 1 00917 .dsec. spb dsec 1 dskop continuation 00918 .dskx. spb dskx 1 Disk request entry for dska, part 2 00919 .krst. bru krst 3 Trap restore branch 00920 .krex. spb krex 1 Special interrupt-trap branch 00921 .kset. spb kset 1 kdump disk write entry 00922 .ktri. bru ktri 3 Branch to check trapmode 00923 .ktrs. bru ktrs 3 Trap save check 00924 .ktrs] spb tx2 0 Trap check 00925 .kwrt. spb kwrt 1 Entry for source rewriting 00926 .syov. spb syov 1 Overlay read entry 00927 .pms1. spb pms1 1 Typewriter entry 00928 00929 org 128 00930 z0 dec 0 00931 z1 dec 0 00932 z2 dec 0 00933 z3 oct 20000 Upper 8K bit 00934 bru inter 3 Go to interrupt routine 00935 bss 1 AAU trapping mode - overflow 00936 itrap bss 1 AAU trapping mode - underflow 00937 bss 1 AAU trapping mode - divide check 00938 bss 2 AAU trapping mode index group 00939 tx2 bss 2 Registers 2 and 3 00940 00941 stl Mailbox area 00942 ejt 00943 Mailbox zero flag is set to indicate 00944 Datanet-30 message. 00945 Return message also goes in mailbox 0 00946 These messages [to D-30] are: 00947 +1 Error, mbx1 tells what type 00948 0 Temporary malfunction 00949 1 No program 00950 2 Unrecognizable system name 00951 +2 Read done 00952 +3 Write done 00953 +4 Request dump 00954 Messages used only after a dump from the D-30: 00955 +5 Terminal exit 00956 +6 Intermediate output 00957 +7 Call for input 00958 00959 ****************************************** 00960 Special message switching mailbox 00961 has the followind code: 00962 +1 Disk request from 235 00963 +2 235 finished with disk 00964 +3 Request Datanet-30 to stop counting time 00965 +4 Datanet-30 can start counting time again 00966 +5 Not used at present 00967 +6 Off 00968 +7 On 00969 -0 Acknowledge by D-30 and normal status 00970 +10 Start batch 00971 +11 Stop batch 00972 Special request by a running system... 00973 +12 Transfer ending disk address 00974 00975 00976 mbx0 bss 1 Points to routine to be executed 00977 mbx1 bss 1 Alfameric system name - first three letters 00978 bmx2 bss 1 Starting disk address 00979 mbx3 bss 1 Ending disk address and rel. loc. for LIST 00980 bss 2 User number - or Selective LIST line number 00981 bss 2 Problem name 00982 mbx8 bss 2 Real time for Datanet-30 00983 00984 pmbx0 bss 2 Special mailbox 00985 00986 00987 Upon receipt of a message from the Datanet-30 00988 The messages get moved into the saved mailbox 00989 area, which follows: 00990 00991 00992 smbx0 bss 1 Saved message 00993 smbx1 bss 1 Saved system name 00994 smbx2 bss 1 Saved starting disk address 00995 smbx3 bss 1 Saved ending disk address 00996 smbx4 bss 1 Saved user #, sel. LIST #, Teach address 00997 smbx5 bss 1 Saved ending Teach disk address 00998 bss 2 Saved problem name 00999 sdate bss 6 Date always kept here - used in billing 01000 sclock bss 4 Billing time information 01001 01002 stl Constants 01003 ejt 01004 01005 01006 Double-length constants 01007 01008 cov1 oct 1777777 Overflow-causing constant 01009 oct 1777777 01010 cun1 oct 2000000 Underflow causer 01011 oct 2000001 01012 edeof oct 777755 End of message mark 01013 edfill oct 777777 Fill character. 01014 .drmc. spb drmc 1 System disk usage entry 01015 z00 -- filled in by executive 01016 kfuge1 bru iplst Special regular mailbox entry delete constant01017 dec wait-5 Special for dexit 01018 kxo dec mkx0 Save index groups 0-4 01019 dec -20 01020 movmbx dec smbx1 Mailbox 1, 2, 3, 4, 5, 6, 7 save 01021 dec -7 01022 d15 dec 15 01023 dec -1 01024 trapr dec itrap-1 Trapping restore constant 01025 dec -7 01026 traps dec mktrp+1 Trapping mode save constant 01027 dec -7 01028 zero ddc 0 01029 .effy. spb effy 1 Efficiency entry 01030 dec -1 01031 .disk. spb disk 1 Dskop entry 01032 dec 0 01033 .iras bru 2 Erase entry 01034 oct 0 01035 .kbil. sbp kbil 1 Billing entry 01036 dec -1 01037 .pty. bnr Pty pointer 01038 spb pty 1 01039 01040 Constants 01041 01042 one oct 1 01043 mone dec -1 01044 two oct 2 01045 mtwo dec -2 01046 three oct 3 01047 four oct 4 01048 five oct 5 01049 six oct 6 01050 seven oct 7 01051 o10 oct 10 01052 ten dec 10 01053 o20 oct 20 Disk count stepping constant 01054 cr oct 37 Carriage return 01055 o40 oct 40 01056 o60 oct 60 Trailing blank... 01057 o100 oct 100 Position step for disk addresses 01058 o140 oct 140 96 records for disk 01059 o200 oct 200 Buffer flip for dump routine 01060 o300 oct 300 Illegal disk address test 01061 o400 oct 400 01062 o440 oct 440 Fudge constants for scratch algorithm 01063 8K oct 20000 Upper memory relocation constant 01064 mask1 oct 3777400 For disk address checking 01065 mask3 oct 3777770 Message protect mask 01066 mask4 oct 3760000 Disk protect mask 01067 mask6 oct 3000000 01068 mask7 oct 3777700 Edit mask 01069 mask8 oct 0000077 Edit mask 01070 mask9 oct 3600000 API mask 01071 mask10 oct 3700000 01072 mask11 oct 0077777 Special P-counter mask 01073 mask12 oct 0177777 Special edit mask 01074 bit3 oct 200000 Stacker full indicator on disk operations 01075 bit4 oct 100000 Error indicator on disk operations 01076 dinst oct 10040 Disk instruction less high order bits 01077 dstakp dec dstak-4 Special disk fudge factor 01078 kfudge dec iprior Special dska fudge factor 01079 mblnk oct 2606060 End of print line blank 01080 ovflo oct 1000000 Overflow constant 01081 sign oct -0 01082 stwo oct -2 01083 peom oct 55 End of message for ptype routine 01084 tend1 dec k3area-2 End of program 01085 nfl set nflpoint 01086 unf set uflpoint 01087 fix set fixpoint Set AAU modes 01088 01089 System table with disk addresses 01090 Standard overlay is 3K, system is on fast 01091 tracks and experimantal sys is on slow 01092 01093 sytab bss 0 01094 alf BAS Basic 01095 oct 5000 0 10 00 01096 oct 10540 0 17 48 01097 alf ALG Algol 01098 oct 5400 0 11 00 01099 oct 6140 0 12 48 01100 oct 6540 0 13 48 01101 oct 15400 0 27 00 01102 alf FOR Fortran 01103 oct 13400 0 23 00 01104 oct 14000 0 24 00 01105 oct 14400 0 25 00 01106 alf DIP Dartmouth Interpretive Program 01107 oct 7000 0 14 00 01108 alf TSA Time-Sharing Assembly processor 01109 oct 7400 0 15 00 01110 oct 15000 0 26 00 01111 alf XAL Experimental Algol 01112 oct 10000 0 16 00 01113 oct 6000 0 12 00 01114 oct 6400 0 13 00 01115 oct 16000 0 28 00 01116 alf XBA Experimental Basic 01117 oct 11000 0 18 00 01118 oct 10400 0 17 00 01119 alf XFO Experimantal Fortran 01120 oct 11400 0 19 00 01121 oct 12000 0 20 00 01122 oct 12400 0 21 00 01123 alf EDI Edit system 01124 oct 13000 0 22 00 01125 last equ *-sytab Maximum number of entries in table 01126 sexit1 bru sysex Exit branch 01127 sexit2 oct 20000 Exit constant [must have 8K bit set] 01128 syloc dec system Read-in location 01129 mendt oct 1400 Move test constant 01130 smove1 mov 0 Move constant 01131 wait1 dec wait Interrupt point test 01132 h1 oct 52140 Time constants [21600 = 3600*6] 01133 blzz alf 00 01134 h2 oct 550 [360 = 60*6] 01135 colon oct 150000 01136 dumpbl alf 01137 k2loc dec k2area 2K area 01138 k3loc dec k3area 3K area 01139 k6loc dec k6area 6K area 01140 k6area eqo 4000 6K area start 01141 k2area eqo 6000 2K area start 01142 k3area eqo 12000 3K area start 01143 kermes equ one Error answer 01144 kmes2 equ two Normal answer for reads 01145 kmes3 equ three Normal answer for writes 01146 kmesd equ four Request dump 01147 kmest equ five Terminal exit message 01148 kmeso equ six Intermediate output message 01149 kmesi equ seven Real-time input call message 01150 bit1 equ ovflo Parity error indicator 01151 hdreq equ one Disk request message 01152 exec1 eqo 34000 First part of 235 executive 01153 exec2 eqo 36000 Second part 235 executive 01154 imer oct -10 01155 01156 Edit constants 01157 01158 rog equ k3loc 01159 rog2 equ k2loc 01160 tend equ k3loc 01161 edsf equ o100 01162 edpnt2 dec smbx4 Points to selective list number 01163 $edig equ mask12 Edit mask 0177777 01164 edtwo equ mtwo 01165 edmsk1 equ mask7 oct 3777700 01166 edmsk2 equ mask8 oct 0000077 01167 edcarr equ cr Carriage return 01168 upper8 equ 8K 01169 table eqo 4000 Start of edit linkage table 01170 01171 stl Time-sharing typewriter options 01172 ejt 01173 01174 com bss 0 List of options available on typewriter 01175 oct 623700 Stop - same as crump 01176 bru icrump 3 01177 key equ *-2 Key to catalogue 01178 oct 3160 0 6 56 01179 01180 alf OFF Off tells the D-30 to stop counting time 01181 bru ioff 3 01182 summry equ *-2 Time-sharing operations efficiency summary 01183 oct 3540 0 7 48 01184 01185 c/p alf C/P Lister 01186 bru perget 3 01187 oct 3100 0 6 32 01188 01189 c/c alf C/C Reproducer 01190 bru perget 3 01191 oct 3120 0 6 40 01192 01193 sys alf SYS System loader 01194 bru perget 3 01195 oct 3140 0 6 48 01196 01197 cat alf CAT Catalogue printout 01198 bru perget 3 01199 oct 3200 0 6 64 01200 01201 dum alf DUM Disk dump 01202 bru perget 3 01203 oct 3220 0 6 72 01204 01205 loa alf LOA Disk loader 01206 bru perget 3 01207 oct 3240 0 6 80 01208 01209 bil alf BIL Billing pack program 01210 bru perget 3 01211 oct 3260 0 6 88 01212 01213 dbg alf DBG Debugging overlay 01214 bru perget 3 01215 oct 3500 0 7 32 01216 01217 g/p alf G/P GAP lister 01218 bru perget 3 01219 oct 3520 0 7 40 01220 01221 s/o alf S/O Sysout lister 01222 bru perget 3 01223 oct 3620 0 7 72 01224 01225 batch alf BAT Bacground processor 01226 bru perget 3 01227 oct 3560 0 7 56 01228 01229 c/t alf C/T Card to tape 01230 bru perget 3 01231 oct 4200 0 8 64 01232 01233 cru bss 0 01234 oba alf OBA Special batch system overlay 01235 bru * Will never come here 01236 oct 4100 0 8 32 01237 tap equ *-2 Tape read/write subroutine 01238 oct 3640 0 7 80 01239 ocat equ *-2 Batch Systems catalogue 01240 oct 3660 0 7 88 01241 bat2 equ *-2 Background part 2 01242 oct 3600 0 7 64 01243 01244 01245 stl Error messages 01246 ejt 01247 01248 tmm equ zero Temporary malfunction message 01249 npr equ one No program message 01250 usn equ two Unrecognizable system message 01251 01252 datnet bss 0 D-30 kept disk 01253 oct 372403 01254 oct 3755 01255 01256 dc bss 0 Disk controller 01257 oct 372431 01258 oct 624237 01259 oct 557777 01260 01261 dp bss 0 Parity 01262 oct 473755 01263 01264 ilg bss 0 Illegal 01265 oct 313755 01266 01267 adrs bss 0 Adrs xxxxxx 01268 oct 372160 01269 adr1 alf 01270 alf 01271 pcr oct 375577 01272 01273 mssage bss 0 Message 01274 oct 443755 01275 01276 full bss 0 Full 01277 oct 372643 01278 oct 433755 01279 01280 del bss 0 Deleted 01281 alf DE 01282 alf LET 01283 oct 252437 01284 oct 557777 01285 01286 rea bss 0 Ready 01287 oct 375125 01288 alf ADY 01289 oct 333755 01290 01291 bzy bss 0 Busy. 01292 oct 372264 01293 alf SY. 01294 oct 375577 01295 01296 ilr bss 0 Illegal task 01297 oct 373232 01298 oct 323755 01299 01300 stl Efficiency summary and buffer areas 01301 ejt 01302 01303 Efficiency summary of systems operations 01304 01305 01306 01307 loc 600 One 64-word record 01308 fclock bss 1 Starting time 01309 flapse bss 1 Elapsed time 01310 fstim bss 2 Actual time of start 01311 fcnt bss 1 Half-hour counter 01312 bss 5 Save 5 locations on principle 01313 f4 bss 0 01314 bss fkbat-f3 01315 f2 bss 0 01316 Day accumulators 01317 acstrt bss 1 01318 acrun bss 1 01319 acswap bss 1 01320 acdisk bss 1 01321 acbat bss 1 Accumulated batch 01322 astim2 bss 2 Start for accumulated storage 01323 ftem bss 4 Temporary storage 01324 01325 f1 equ flapse 01326 01327 01328 01329 loc 1000 01330 io1 bss 84 Buffer area no. 1 01331 loc 1200 Second buffer area 01332 io2 bss 84 Buffer area no. 2 01333 01334 Sysout buffer areas 01335 loc 600 01336 sio1 bss 80 80 words 01337 sio2 bss 40 40 words 01338 sio3 bss 40 40 words 01339 sio4 bss 111 110 words + 1 residue word 01340 sio5 bss 111 110 words + 1 residue word 01341 bss 1 Just to see how far I am 01342 01343 01344 Disk addresses to be used at load time only 01345 loc 2000 01346 oba2 equ *-2 More of batch system overlay 01347 oct 4140 0 8 48 01348 oba3 equ *-2 More batch 01349 oct 4120 0 8 40 01350 oba4 equ 4160 Still more 01351 oct 4160 0 8 56 01352 01353 stl Save area 01354 ejt 01355 01356 01357 The save area is used to save all 01358 the important registers and index groups 0-4 01359 when a program is temporarily dumped on the 01360 disk. 01361 01362 loc 4000 01363 kclock bss 1 Adjusted starting time for systems 01364 mkprnt bss 1 System output area pointer 01365 mksxg bss 1 Index group save - TEACH flag 01366 ilngth bss 1 Length of source program in memory 01367 mkdisk bss 1 Starting address of 6K area 01368 bss 1 Blank for now 01369 mkaq bss 2 A and Q registers save 01370 mkov bss 1 Overflow save 01371 mkp bss 1 P-counter save 01372 mkx0 bss 20 Index groups 0-4 save 01373 mkax bss 2 AX register save 01374 mkqx bss 2 QX register save 01375 mode bss 2 AAU mode and indicator save 01376 mktrp bss 6 Trapping mode flag and branch save 01377 mktx2 bss 2 Trapping mode index register 2 save 01378 movid bss 1 Overlay identifier # 01379 morep bss 1 Number of current replacement 01380 molen bss 1 Length of overlay 01381 momem bss 1 Memory location of overlay 01382 movint bss 1 Flag to indicate whether read completed 01383 clock bss 1 Elapsed time counter 01384 mdc bss 1 Dump code for D-30 01385 mdl bss 1 Dump length starts at 96 records 01386 mkpr1 eqo 4100 System output buffer 01387 01388 system eqo 20000 System read-in area 01389 sname equ system+4 Alfameric system name 01390 01391 stl Interrupt routine 01392 ejt 01393 01394 When not performing any specific 01395 task, the executive sits in its wait loop, 01396 displaying a distinctive pattern in the 01397 A register. 01398 01399 01400 loc 34001 01401 wait sxg 5 01402 spb time 2 Get time 01403 dst mbx8 and give to Datanet-30 01404 set pst If in interrupt mode, exit 01405 set trpmode If in trap program, exit 01406 set ntpmode with no trap set 01407 ldx 8K 3 01408 bru *+1 3 01409 bno Turn off overflow indicator 01410 nop 01411 lac 01412 cab int1 Check if 1 second elapsed 01413 bru *+4 No 01414 oct 2506014 Yes, interrupt 01415 add four Set timing interval for 2/3 seconds 01416 sta int1 01417 cab itim Check if 1+minute elapsed 01418 bru *+2 If less, do nothing 01419 bru wait If so, pick up time again 01420 cab .eff Check if efficiency save due 01421 bru *-10 01422 bru *-11 01423 set pbk Ten minutes elapsed, save 01424 lda cov1 Make sure no more called until completion 01425 sta .eff 01426 dld .effy. 01427 spb insert 2 Insert task in list 01428 bru wait+3 and get back 01429 ejt 01430 Inter saves the working registers, and 01431 first looks at the regular mailbox. If this 01432 is positive, it goes through the regular 01433 mailbox and then the peripheral mailbox 01434 task tables in turn. 01435 If the regular mailbox was negative, ireg 01436 isolates the low order end and performs 01437 a table lookup with the result. 01438 01439 01440 01441 oct 0 01442 ddc 0 Make sure itab is even 01443 bss -3 01444 inter dst save Save A and Q 01445 bov Turn off overflow indicator 01446 bru *+1 01447 stx pct 1 and save P-counter 01448 lda mbx0 Look at regular mailbox 01449 bmi Check if negative 01450 bru ireg If so, go service it 01451 01452 ****** WARNING...iprior must be even ****** 01453 01454 iprior bru *+2 Priority task entry 01455 oct 0 01456 01457 iplst bru *+2 0 01458 oct 0 01459 01460 bru *+2 1 01461 oct 0 01462 01463 bru *+2 2 01464 oct 0 01465 01466 bru *+2 3 01467 oct 0 01468 01469 bru *+2 4 01470 oct 0 01471 01472 bru *+2 5 01473 oct 0 01474 01475 bru *+2 6 01476 oct 0 01477 01478 bru *+2 7 01479 oct 0 01480 01481 bru ispmbx Last entry 01482 oct 0 01483 eplst equ * End of list 01484 eplen equ *-iplst List length 01485 01486 01487 ispmbx lda pct Check P-counter 01488 bmi If plus, then TON set 01489 bnn so crump 01490 bru irest+1 01491 ldx ty1 1 Restore register 1 01492 ldx ty2 2 and 2 01493 sna 19 Get character 01494 ext sign and get rid of a sign 01495 lqa Keep a copy in Q 01496 cab mask8 Check for line delete 01497 bru *+2 01498 bru indel Delete line 01499 inx 1 2 Increment character counter 01500 bxh 3 2 and check if over word 01501 ldx 8K 2 Yes 01502 stx ty2 2 Save 01503 bru *+1 2 Code for characters as follows 01504 bru inr Rightmost is 0 01505 bru inl Leftmost is 1 01506 sla 6 Middle is 2 01507 ory ty 1 Save middle character in word 01508 bru inchar and check for carriage returns 01509 inl sla 12 Get character into word 01510 sta ty 1 01511 bru inchar 01512 inr ory ty 1 Rightmost character 01513 inx 1 1 Increment word pointer 01514 stx ty1 1 and save 01515 01516 01517 inchar laq Get character 01518 sub cr Check for carriage return 01519 bze 01520 bru ianaly Yes, analyze command 01521 bxl 20 1 Check status of one 01522 bru irest 01523 01524 01525 indel spb messg 2 DELETED message 01526 dec del 01527 indelx ldz Reset pointers 01528 sta ty1 01529 sto ty2 01530 bru irest and get out 01531 01532 01533 ibusy sbp messg 2 Type message 01534 dec bzy BUSY 01535 bru indelx and get out 01536 01537 01538 ianaly sta ty1 Reset pointers 01539 sto ty2 01540 sta z2 01541 inc com 2 01542 lda ty and analyze command 01543 ianalz cab 0 2 01544 bru *+2 01545 bru 1 2 Go to task 01546 inx 3 2 Step pointer 01547 bxl cru 2 Check for end of list 01548 bru ianalz 01549 01550 01551 ild spb messg 2 Type message 01552 dec ilr Illegal task 01553 bru irest and crump 01554 01555 01556 ioff lda three Stop time count 01557 bru *+2 01558 icrump lda four Ask for time count again 01559 spb spmess 2 01560 iredy spb messg 2 Type READY message 01561 dec rea 01562 ldx ovtsk 1 Check if task used at all 01563 bxh 1 1 01564 spb irase 2 If greater than 1, then used 01565 iresp ldz Reset various pointers 01566 sta ovtsk Reset pointer 01567 sta bzyf and turn off busy flag 01568 sta cmessb Reset batch flag 01569 sta io1 for batch front card search 01570 sta kbfdg 3 Fix billing 01571 sta kbfdg+4 3 01572 01573 01574 irest lda pct Restore P-counter 01575 sta z1 01576 bov Make sure overflow is not on accidentally 01577 bru *+1 01578 ext mask9 and get rid of high order bits 01579 sla 4 Restore overflow 01580 dld save Restore A and Q 01581 set pst 01582 bru 0 1 Return 01583 01584 01585 irase dld .ipas Entered on 2 with pointer to be erased 01586 add z1 in register 1. Construct bru *+2 and 01587 ext 8K make for bank-compatible addresses 01588 dst 0 1 Delete entry 01589 bru 1 2 And return 01590 01591 01592 insert sta .ins Save entry. Insert sets up tasks for 01593 ldx zero 0 API time 01594 ldx eavail 3 Get next available location pointer 01595 ins1 inx 2 3 Actually is last available 01596 bxh eplst 3 and check for wraparound 01597 ldx einit 3 Yes, re-initialize 01598 stx eavail 3 Save pointer 01599 inx 2 0 Count 01600 bxh eplen+2 0 and check for end of table 01601 bru inful Yes 01602 lda 1 3 Check if entry free 01603 bnz Entries have second word non-zero 01604 bru ins1 Not free, keep searching 01605 lda .ins Yes 01606 dst 0 3 and set entries in list 01607 oct 2506014 Make sure it gets serviced soon 01608 lda eavail and set pointer in A 01609 ldx 8K 3 Reset register 3 01610 bru 1 2 and scram 01611 inful ldx 8K 3 Restore 8K bit 01612 ldx eavail 1 and get entry being looked at 01613 spb irase 2 Crump some task or other 01614 sbp messg 2 and give room to output m