From 3f46e646b8adadfe1520e09c2c77d5fa1606a6d2 Mon Sep 17 00:00:00 2001 From: Lars Brinkhoff Date: Thu, 23 Apr 2020 12:26:54 +0200 Subject: [PATCH] Build Imlac secondary block loader from source code. BLKLDR 1 is from the IMLAC; IML DEVICE archive file dated 1976-11-02. The archive was found in three identical copies on ToTS tapes 7006990, 701351, and 90606; they were extracted by Brad Parker. The BLKLDR 1 timestamp inside the archive is 1975-01-26. Tape database records from DM show a BLKLDR 4 dated 1974-08-19. To build the IMLAC; IMLAC BLKLDR file, it's first assembled with MIDAS. Regular IMTRAN writes the block loader format, but the block loader itself is in the "special TTY" boostrap format. IMTRAN is runtime patched to skip the block framing. --- Makefile | 2 +- bin/imlac/imlac.blkldr | 6 --- build/misc.tcl | 25 ++++++++++++ doc/programs.md | 1 + src/imsrc/blkldr.1 | 86 ++++++++++++++++++++++++++++++++++++++++++ 5 files changed, 113 insertions(+), 7 deletions(-) delete mode 100644 bin/imlac/imlac.blkldr create mode 100644 src/imsrc/blkldr.1 diff --git a/Makefile b/Makefile index 19ec8fe2..a9091499 100644 --- a/Makefile +++ b/Makefile @@ -39,7 +39,7 @@ DOC = info _info_ sysdoc sysnet syshst kshack _teco_ emacs emacs1 c kcc \ digest prs decus BIN = sys sys1 sys2 emacs _teco_ lisp liblsp alan inquir sail comlap \ c decsys graphs draw datdrw fonts fonts1 fonts2 games macsym \ - maint imlac _www_ gt40 llogo bawden sysbin -pics- lmman r shrdlu \ + maint _www_ gt40 llogo bawden sysbin -pics- lmman r shrdlu \ pdp10 MINSRC = midas system $(DDT) $(SALV) $(KSFEDR) $(DUMP) diff --git a/bin/imlac/imlac.blkldr b/bin/imlac/imlac.blkldr deleted file mode 100644 index 364d9c6b..00000000 --- a/bin/imlac/imlac.blkldr +++ /dev/null @@ -1,6 +0,0 @@ -!blk ldr! -@BAJH@@IBGOLBGOMCONGCONGH@@FBGONCOMOGOOHAGLL@@@@BGOOCOMOJGO -OCOMHCGOOCGONAGLMCOMOGGOLHD@AAGL@@@@@@@@@H@@HFOOL@D@DH@@DBGO -LIGMH@@@@H@@IBGOMCONGCONGCONGCONGIGMO@@@@@DB@AGNHH@@I@BAKBG -KODOOIGOOJAGNHFGKODOOKBOOM@F@C@F@AEGOMBGOMIGNGOOOO@@G@@@D@@ -@@O@@@@OOOOOO@A@OJJOOL@ diff --git a/build/misc.tcl b/build/misc.tcl index 9b9a88de..6856e94d 100644 --- a/build/misc.tcl +++ b/build/misc.tcl @@ -1360,6 +1360,31 @@ expect ":KILL" respond "*" ":midas sys2; ts tvedit_sysen2; tvedit\r" expect ":KILL" +# BLKLDR, Imlac secondary block loader. +respond "*" ":midas sysbin;_imsrc; blkldr\r" +expect ":KILL" +# IMTRAN will put the file IMLAC; IMLAC BLKLDR first in its output. +# The BLKLDR file should say !blk ldr! on the first line. +respond "*" ":create imlac; imlac blkldr\r" +respond "help." "!blk ldr!\r\003" +respond "*" "imtran\033\013" +# The IMTRAN output is in block loader format, but the block loader +# itself is in the special TTY bootstrap format. Patch IMTRAN to not +# write flat data without blocks. +respond "@" "\032" +type "smalup+5/" +respond "EMIT2" "jfcl\r" +type "smalup+11/" +respond "EMIT4" "jfcl\r" +type "datlup+4/" +respond "EMIT4" "jfcl\r" +type "prgend/" +type "jrst prgen1+4\r" +type "\033p" +type "imlac; imlac blkldr_sysbin; blkldr bin\r" +respond "@" "\021" +expect ":KILL" + # SSV 22, Imlac scroll saver respond "*" ":midas;324 sysbin;_imsrc; ssv22\r" expect ":KILL" diff --git a/doc/programs.md b/doc/programs.md index 9823aa83..2e194960 100644 --- a/doc/programs.md +++ b/doc/programs.md @@ -39,6 +39,7 @@ - BINPRT, display information about a binary executable file. - BITPRT, print JCL as bits. - BKG, a Backgammon game. +- BLKLDR, Imlac secondary block loader. - BOLIO, typesetting. - BOOTVT, GT40 boot ROM. - BYE, say goodbye to user. Used in LOGOUT scripts. diff --git a/src/imsrc/blkldr.1 b/src/imsrc/blkldr.1 new file mode 100644 index 00000000..03d0b5d5 --- /dev/null +++ b/src/imsrc/blkldr.1 @@ -0,0 +1,86 @@ +TITLE BLKLDR 1 (PDL) 12/7/73 + +.INSRT IMDEFS > +LDADR=37700 + LOC LDADR + ; ADDR CHAR OCTAL + +START: RCF ; 00: @BAJ 001032 + CAL ; H@@I 100011 + DAC CHKSUM ; BGOL 023774 + DAC WRD ; BGOM 023775 + JMS GET4 ; CONG 037747 + JMS GET4 ; CONG 037747 + CIA ; H@@F 100006 + DAC COUNT ; BGON 023776 + JMS GET16 ; 10: COMO 037737 + SAM MINUS1 ; GOOH 077770 + JMP .+2 ; AGLL 013714 + HLT ; @@@@ 000000 ; DONE. THIS LOC GETS GLOBBERED FOR AUTOSTART. + DAC ADDRES ; BGOO 023777 +BLKLUP: JMS GET16 ; COMO 037737 + DAC @ADDRES ; JGOO 123777 + JMS CKS ; COMH 037730 + ISZ ADDRES ; 20: CGOO 033777 + ISZ COUNT ; CGON 033776 + JMP BLKLUP ; AGLM 013715 + JMS GET16 ; COMO 037737 + SUB CHKSUM ; GGOL 073774 + ASN ; HD@A 102001 + JMP START ; AGL@ 013700 + HLT ; @@@@ 000000 ; CHECKSUM FAILED (SHOULD BE FIXED!). + +; update checksum +CKS: 0 ; 30: @@@@ 000000 + CLL ; H@@H 100010 + ADD CHKSUM ; FOOL 067774 + LSZ ; @D@D 002004 + IAC ; H@@D 100004 + DAC CHKSUM ; BGOL 023774 + JMP @CKS ; IGMH 113730 + +; get word +GET16: 0 ; @@@@ 000000 + CAL ; 40: H@@I 100011 + DAC WRD ; BGOM 023775 + JMS GET4 ; CONG 037747 + JMS GET4 ; CONG 037747 + JMS GET4 ; CONG 037747 + JMS GET4 ; CONG 037747 + JMP @GET16 ; IGMO 113737 + +; get good character +GET4: 0 ; @@@@ 000000 +GETCHR: RSF ; 50: @DB@ 002040 + JMP .-1 ; AGNH 013750 + CAL ; H@@I 100011 + RRC ; @BAK 001033 + DAC START-1 ; BGKO 023677 + AND M160 ; DOOI 047771 + SAM M100 ; GOOJ 077772 + JMP GETCHR ; AGNH 013750 + LAC START-1 ; 60: FGKO 063677 + AND M17 ; DOOK 047773 + XAM WRD ; BOOM 027775 + RAL 3 ; @F@C 003003 + RAL 1 ; @F@A 003001 + IOR WRD ; EGOM 053775 + DAC WRD ; BGOM 023775 + JMP @GET4 ; IGNG 113747 + +; constant area +MINUS1: -1 ; 70: OOOO 177777 +M160: 160 ; @@G@ 000160 +M100: 100 ; @@D@ 000100 +M17: 17 ; @@@O 000017 + +; variable area +CHKSUM: 0 ; @@@@ 000000 +WRD: 0 ; @@@@ 000000 +COUNT: 0 ; @@@@ 000000 +ADDRES: 0 ; @@@@ 000000 + +GOADDR: LDADR ; 0: COL@ 37700 + + END + \ No newline at end of file