1 /TC08 DECTAPE FORMATTER, V4
14 /DIGITAL EQUIPMENT CORPORATION, MAYNARD, MASS.
18 /THIS SOFTWARE IS FURNISHED UNDER A LICENSE FOR USE ONLY ON A
19 /SINGLE COMPUTER SYSTEM AND MAY BE COPIED ONLY WITH THE INCLU-
20 /SION OF THE ABOVE COPYRIGHT NOTICE. THIS SOFTWARE, OR ANT OTHER
21 /COPIES THEREOF, MAY NOT BR PROVIDED OR OTHERWISE MADE AVAILABLE
22 /TO ANY OTHER PERSON EXCEPT FOR USE ON SUCH SYSTEM AND TO ONE WHO
23 /AGREES TO THESE LICENSE TERMS. TITLE TO AND OWNERSHIP OF THE
24 /SOFTWARE SHALL AT ALL TIMES REMAIN IN DEC.
27 /THE INFORMATION IN THIS SOFTWARE IS SUBJECT TO CHANGE WITHOUT
28 /NOTICE AND SHOULD NOT BE CONSTRUED AS A COMMITMENT BY DIGITAL
29 /EQUIPMRNT COROPATION.
31 /DEC ASSUMES NO RESPONSIBILITY FOR THE USE OR RELIABILITY OF ITS
32 /SOFTWARE ON EQUIPMENT WHICH IS NOT SUPPLIED BY DEC.
39 \f/COPYRIGHT 1970 DIGITAL EQUIPMENT CORP.
43 / TOG-8 TO MARK AND CHECK PDP-8 DECTAPE
44 /THIS PROGRAM WRITES TIMING AND MARK TRACKS ON
45 /DECTAPE MOUNTED ON THE TCO1-TU55 TAPE CONTROL UNIT.
54 /SYMBOL TABLE AUGMENTATION
64 /SET 0 FOR THE LOGIN FEATURE
69 CONC /CONTROL "C" AND LOGIN
155 DBUFPT, 0 /POINTER TO CURRENT POSITION IN DTA LIST
161 /TYPE THE CHARACTER IN THE AC ON THE KEYBOARD PRINTER
164 TLS /LOAD AND PRINT, CLEAR FLAG
165 TSF /WAIT FOR CONFIRMATION
167 TCF /CLEAR THE FLAG ANYWAY
171 /PRINT A "?" ON THE KEYBOARD TYPER
174 IOF /KILL LOG AND CONTROL C FCTN
175 CLA CLL /C(AC)+C(L)=0
177 JMS RSEND /TYPE THE CHARACTER
181 /DECTAPE CONTROL WORDS
202 /CONSTANTS FOR FORMULA TRANSLATION SECTION
210 /TYPE CANNED MESSAGES.....
211 /THANKS TO DIGITAL 8-18-U
214 IOF /KILL LOG AND CONTROL FUNCTION
215 CLA CMA /SET C(AC)=-1
216 TAD MESAGE /ADD LOCATION
217 DCA 10 /AUTO INDEX REGISTER
218 TAD I 10 /FETCH FIRST WORD
222 RTR /ROTATE 6 BITS TO THE RIGHT
225 TAD MSRGHT /GET DATA AGAIN
226 JMS TYPECH /TYPE RIGHT HALF
227 JMP MESAGE+5 /CONTINUE
228 MSRGHT, 0 /TEMPORARY STORAGE
229 TYPECH, 0 /TYPE CHARACTER IN C(AC)6-11
231 SNA /IS IT END OF MESSAGE?
236 TAD C340 /YES: ADD 300
237 JMP MTP /TO CODES <40
241 TAD C212 /YES: CODE 43 IS
242 JMP MTP /LINE-FEED (212)
246 TAD C215 /YES: CODE 45 IS
247 JMP MTP /CARRIAGE RETURN (215)
248 TAD C245 /ADD 200 TO OTHERS >40
249 MTP, TLS /TRANSMIT CHARACTER
250 TSF /WAIT FOR THE FLAG
252 CLA /SET: CLEAR C(AC)
262 \f/ROUTINE WAITS UNTILL A COMPLETE MESSAGE HAS BEEN ENTERED
266 IOF /KILL THE LOG AND CONTROL C FUNCTION
267 KCC /CLEAR AC, KEYBOARD FLAG
268 TAD BADD /GET BUFFER ADDRESS
269 DCA W1 /STORE FOR THE CHARACTER STRING
271 /READ AND RESPOND WITH THE CHARACTER
273 NTYRTN, ISZ W1 /NORMAL RETURN. INCREMENT BUFFER
274 KSF /WAIT FOR KEYBOARD
275 JMP .-1 /FLAG TO RAISE
276 KRB /GOT FLAG, RESET IT, GET CHARACTER
277 JMS RSEND /SEND CHARACTER BACK
278 AND (177 /TAKE CARE OF PARITY
280 DCA I W1 /LOAD CHARACTER INTO BUFFER AREA
281 TAD I W1 /CHECK FOR CTRL C
285 JMP CHKSP /NO- CHECK FOR SPACE
286 6007 /CTRL C -CLEAR ALL FLAGS
287 NOP /FOR OLD MACHINES
289 DTLB /CLEAR STATUS REGISTER B
292 /IF CHARACTER IS A SPACE, IGNORE IT
294 CHKSP, TAD I W1 /CHARACTER INTO THE AC
295 CIA /SUBTRACT FROM SPACE CODE (240)
296 TAD SPCOD /COMPLETE COMPARISON
297 SNA CLA /WAS IT A SPACE?
298 JMP NTYRTN+1 /YES: DO NOT INCREMENT BUFFER
300 /IF CHARACTER IS A CR, EXIT FROM ROUTINE
302 TAD I W1 /CHARACTER TO AC
303 CIA /SET AC TO SUBTRACT CR (215)
304 TAD CRCOD /COMPLETE COMPARISON
306 JMP NTYRTN /NO: INCREMENT BUFFER + WAIT
308 /CARRIAGE RETURN FOUND, EXIT FROM ROUTINE
310 TAD LFCOD /GIVE KEYBOARD LINE FEED
311 JMS RSEND /EXECUTE LINE FEED
312 CLA CLL /EXIT WITH C(ACC) + AND C(L)=0
313 ION /RESET LOG AND CONTROL C FUNCTION
314 JMP I TYPN /RETURN TO CALL
315 \f/COMPARE A STRING OF CHARACTERS IN "BUFFER"
316 /TO A CHARACTER STRING AFTER A JMS IN ASCII
320 TAD COMPRE /SUBTRACT 1 FOR INDEX REG 1
321 DCA 10 /AUTO INDEX 1 SET TO CHA STRING
322 TAD BADD /AUTO INDEX 2 SET TO BUFFER-1
325 /COMPARE CHARACTERS TILL ONE DOESN'T COMPARE OR TILL
326 /A 0 IS FOUND IN X1. IF OK, RETURN TO TWO PLUS THE
327 /ZERO, IF BAD ONE PLUS
329 TAD I X1 /CHARACTER FROM PROGRAM
330 CIA /TO SUBTRACT FROM
331 TAD I X2 /CHARACTER IN BUFFER
333 JMP CERR /NO:RESYNC FOR NON COMPARE EXIT
334 TAD I X1 /YES: CHECK FOR GOOD EXIT
336 JMP .-6 /NO: TEST NEXT CHAACTER
337 ISZ X1 /+1 TO X1(TOTAL 2 FROM THE 0)
338 JMP I X1 /+1 TO X1, EXIT
340 /ERROR FOUND. RESYNC AND EXIT NO COMPARE
342 CERR, TAD I X1 /CHARACTER FROM PROGRAM
343 SZA CLA /IS THIS EXIT KEY? (0000)
344 JMP .-2 /NO: GET NEXT
345 JMP I X1 /YES: EXIT, NOT COMPARE
347 /VARIOUS ERROR MESSAGES
385 /"NOT DIVISIBLE BY 3"
402 \f/THE CODING BELOW CREATES THE BLOCK NUMBER
403 /CONVERSION PRIOR TO THE TAPE WRITE.
406 DCA W4 /BLOCK NUMBER GIVEN IN AC
407 TAD W4 /RESTORE TO AC AGAIN
413 AND C7000 /ISOLATE HIGH CHA
414 DCA V2 /FORWARD BLOCK NUMBER
415 TAD W5 /SHIFTED VALUE
416 AND C0070 /ISOLATE 6,7,8
417 DCA V1 /FORWARD BLOCK NUMBER
418 TAD W4 /ORIGIONAL SET
424 AND C0700 /ISOLATE 3,4,5
425 TAD V2 /COMBINE FORWARD BLOCK NUMBER
428 TAD W5 /SHIFTED VALUE
429 AND C0007 /ISOLATE 9, 10,11
430 TAD V1 /COMBINE WITH BN
431 DCA V1 /FORWARD BLOCK NUMBER COMPLETE
433 /CONVERT REVERSE BLOCK NUMBER
435 CMA /-1 TO GIVEN BLOCK #
436 TAD W4 /ORIGIONAL BLOCK #
442 AND C0077 /ISOLATE LOW
444 TAD W5 /COMPLEMENT ORIGIONAL -1
448 AND C7700 /ISOLATE HIGH
449 DCA V4 /REVERSE COMPLETED
451 \f/FORM USED TO WRITE 12 DATA WORDS FOR BLOCK NUMBERING
465 \f//THIS ROUTINE ALLOWS KEYBOARD INTERRUPTION
466 /FOR LOGGING ON THE KEYBOARD, OR FOR A MAJOR
467 /CLEAR IN THE PROGRAM. BY HITTING "CONTROL C"
468 /A SYSTEM RESTART WILL OCCUR.
470 CONC, TSF /IS THE PRINTER FLAG ON?
471 JMP .+5 /NO, CHECK READER
473 KSF /IS THE READER FLAG ON?
474 JMP RTNS /NO: RETURN TO SEQUENCE
479 /OK. CHECK FOR EITHER LOG OR CONTROL C.
483 DCA RSYC+6 /FOR LOGGING
484 KRB /GET CHARACTER FROM KEYBOARD
485 TLS /RETURN CHARACTER
487 TAD C203 /"CONTROL C"
489 JMP RSYC /YES: RESYNC THE PROGRAM
490 TAD RSYC+6 /RESTORE THE LINK
493 RTNS, ION /INTERRUPT ON
497 /RESYNC THE SYSTEM TO START
499 RSYC, TSF /WAIT FOR FLAG
500 JMP .-1 /ON LAST SENDOFF
506 TAD DTA /TO KILL EXISTING TAPE MOTION
508 JMP I STX /RETURN TO START
509 \f/WAIT FOR THE DECTAPE FLAG TO RISE
513 DTRB /READ TCU "B" REGISTER
515 JMP ERROR /YES, DECIDE WHAT TO DO
516 RAR /DECTAPE FLAG TO LINK
518 JMP .-5 /NO: CONTINUE WATCH
519 RERR, DTXA /RESET THE DECTAPE FLAG
520 DCA ERX /CLEAR THE END TAPE FLAG
521 JMP I STALL /GOT FLAG, EXIT
523 /DRIVE TAPE INTO THE END ZONE, AND TURN IT
525 /IF C(AC)=0400, TAPE INTO REVERSE END ZONE
526 /IF C(AC)=0000, TAPE INTO FORWARD END ZONE
529 ISZ ERX /END ZONE IS LEGAL
530 DCA W4 /SAVE DIRECTION
531 TAD DT0200 /MOVE FUNCTION,GO
532 TAD W4 /DIRECTION TO MOVE
533 TAD DTA /DRIVE TO MOVE
534 DTCX /CLEAR AND RESET "A"
535 JMS I WAIT /FOR END ZONE FLAG
536 TAD DT0610 /SEARCH, GO
537 TAD W4 /DIRECTION TO SEARCH
538 AND C0777 /DELETE OVERFLOW BIT
539 TAD DTA /SET THE DECTAPE
540 DTCX /RESET STATUS "A"
541 DCA ERX /END ZONE NOT LEGAL NOW
542 JMP I TRN /RETURN TO SEQUENCE
545 \f/AN ERROR FLAG HAS BEEN SET. IN SOME CASES
546 /END ZONE IS LEGAL, OTHERWISE, A RESTART ATTEMPT
549 /DETERMINE WHICH FLAG SET THE DECTAPE FLAG
551 ERROR, DCA W5 /SAVE "B" REGISTER
552 TAD DTA /GOING TO KILL
554 TAD W5 /RESTORE "B" REGISTER
555 RTL /POSITION BITS 1+2
556 SPA /END OF TAPE FLAG?
557 JMP ZEOT /YES: GO TO ROUTINE
558 SZL /MARK TRACK ERROR?
559 JMP ZMKTK /YES: GO TO ROUTINE
560 RTL /POSITION BITS 2+3
562 JMP ZPAR /YES: GO TO PARITY ERROR ROUTINE
563 SZL CLA /SELECT ERROR?
564 JMP ZSEL /YES: GO TO ROUTINE
565 JMP ZTIM /MUST BE TIMING ERROR
567 /END OF TAPE FLAG FOUND, SEE IF IT'S LEGAL
569 ZEOT, CLA CLL /CLEAR REMAINS
572 JMP RERR /OK, IT'S LEGAL
574 /NOT LEGAL END ZONE FLAG
620 /TYPE "ERROR PHASE X"
622 ZCOM, TAD PHASE /WHAT PHASE OF OPERATION
623 TAD PFORM /WAS THE MACHINE IN
624 DCA TFORM /WHEN ERROR OCCURED
637 /HE CAN RESTART IF HE TYPES "RETRY"
646 JMP I IT /GUESS HE DOESN'T WISH TO TRY AGAIN
647 \f/ATTEMPT RESTART. NOTE, "ATTEMPT"
649 TAD PHASE /RESTART ACCORDING TO
650 TAD ZFORM /WHICH PHASE WAS HE IN
669 /HERE STARTS THIS PROGRAM. IT WILL ASK THE
670 /OPERATOR FOR DRIVE NUMBERS, THEN ASK HIM FOR
671 /A DIRECTION ON WHAT TO DO WITH THE DRIVES.
673 /THE SEQUENCE FOR MARKING A TAPE WOULD APPEAR AS:
676 /DTA? (3 OR 1 2 3 OR 2 4 7)
678 /2277 WORDS, 0256 BLOCKS.OK? YES OR NO
682 /THAT DATA IN PARENTHESIS IS TYPED BY THE OPERATOR
683 /(HE DOESN'T TYPE THE PARENTHESIS)
684 /IF HE HAD ANSWERED NO, "DIRECT?" WOULD BE TYPED OUT.
685 /IF THE DRIVE WAS WRONG, HE WOULD TYPE RESTART.
686 /IF HE HAD TYPED "MARK" IN RESPONSE TO "DIRECT?" THE
687 /TAPE WOULD BE MARKED WITH THE STANDARD PDP-8 CONFIGURATION.
688 /IF HE HAD TYPED "MARK 384" THE TAPE WOULD
689 /BE MARKED WITH THE STANDARD PDP-10 CONFIGURATION
690 /NOTE: THE WORD AND BLOCK NUMBERS ARE TYPED IN OCTAL
691 /IF A MISTAKE OCCURS ON THE OPERATORS PART (WITH REFERANCE
692 /TO BLOCK + WORD SIZE) HE WILL BE TOLD ABOUT IT
700 /MAKE A CALL FOR THE DECTAPE NUMBERS TO BE
704 START0, JMS I TYPE /PRINT TITLE
711 START, JMS I TYPE /SET UP TYPER
714 TYQU, JMS I TYPE /"DTA?"
721 JMS I TYPIN /GET NUMBERS
722 TAD BADD /INITIALIZE POINTER (BFR)
723 IAC /(BADD=BUFFER-1, SO BUMP THE AC)
724 DCA BFR /TO START OF INPUT BUFFER
725 DCA DCTR /INITIALIZE DTA COUNTER TO 0
726 DCA CRFLAG /CLEAR FLAG SO CR NOT ACCEPTIBLE
727 CRCHK, TAD CRCOD /GET CODE FOR CAR. RETN
729 TAD I BFR /SEE IF NEXT CHAR. IN
730 SNA /BUFFER IS CAR. RETN.
731 JMP OKCR /YES: SEE IF C.R. LEGAL HERE
732 DCA CRFLAG /NO: SO C.R. IS LEGAL NOW
733 VALCHK, TAD C261 /SEE IF # IS LESS THAN
735 TAD I BFR /SUBTRACT BUFFER DATA
736 SPA CLA /IS IT LESS THAN ASII 0?
737 JMP TYQU /YES: TELL OUTSIDE WORLD
738 TAD C270 /NO: SEE IF GREATER THAN
740 TAD I BFR /SUBTRACT BUFFER DATA
741 SMA CLA /GREATER THAN ASCII 7?
742 JMP TYQU /YES: TELL OUTSIDE WORLD
743 TAD I BFR /NO: ACCEPT BUFFER
746 AND C7000 /ISOLATE DTA
747 JMS REPEAT /GO CHECK FOR REPEATED DTA AND STORE #
748 ISZ BFR /INCREMENT INPUT BUF. PTR.
749 JMP CRCHK /GO LOOK AT NEXT CHAR.
751 /THIS SECTION CHECKS TO SEE IF THERE HAS BEEN ANY
752 /VALID INPUT ONCE A CARRIAGE RETURN IS SEEN
754 TAD CRFLAG /LOAD CR FLAG; 0 MEANS NO GOOD
756 JMP START /0: NO VALID INPUT; RESTART
757 TAD DCTR /NOT 0: SO HAVE VALID INPUT
758 TAD DBUFAD /CALCULATE END OF DTA LIST +1
759 DCA DBUFPT /STORE IT IN BUFFER POINTER, THEN
760 CMA /COMPLEMENT THE AC AND
761 DCA I DBUFPT /TERMINATE DTA LIST WITH 7777
762 INIT1, CLA /CLEAR AC IF COME THRU LOC IT
763 TAD DBUFAD /AND RESET LIST POINTER
764 DCA DBUFPT /TO START OF LIST
765 JMS I GETDTA /GO GET A DTA NUMBER
767 /INFORM THE OPERATOR THAT THE PROGRAM IS SET TO START
768 /TYPE "DIRECT" AND WAIT FOR THE REPLY
770 INIT, JMS I TYPE /MESSAGE OUT
776 JMS I TYPIN /WAIT FOR A REPLY
777 JMS I COMPAR /DID HE TYPE "MARK"?
786 \f/SEE IF HE TYPED "RDR" (READ AND TYPE FIRST 12
787 /BLOCK NUMBERS IN REVERSE).
798 /SEE IF HE TYPED "RDF" (READ AND TYPE FIRST 12
799 /BLOCK NUMBERS FORWARD).
810 /SEE IF HE TYPED "SAME" (MEANING MARK A TAPE
811 /USING THE SAME CONSTANTS AS BEFORE).
821 RSTSM /TO MARK AS BEFORE
823 /SEE IF HE TYPED "RESTART"
834 JMS QU /MUST BE NONSENSE
835 JMP START /START ALL OVER
836 GETDTA, NUDTA /POINTER TO ROUTINE TO SWITCH UNITS
837 CRFLAG, 0 /=0, CR NO GOOD; NOT 0, CR IS OK
840 /MARK WAS TYPED IN, IF W1-1 IS NOT A "K",ASSUME THAT
841 /A NUMBER WAS TYPED IN, AND VERIFY THIS. IF W1-1 IS
842 /A "K", ASSUME STANDARD FORMAT.(W1=LAST ENTRY INTO THE BUFFER)
844 MARK, TAD BINCON /ADDRESS OF FIRST BINARY
845 DCA W5 /CONSTANT FOR DEC TO BIN
846 DCA TOTAL /WILL BE BINARY EQUIVILANT
848 /SAVE C(X1) FOR DECREMENT THROUGH BUFFER
850 DNC, CLA CMA /DECREMENT BUFFER ADDRESS
852 DCA W1 /W1=SWEEP ADDRESS
854 /LOOK FOR END OF PROCESSING BY LOOKING FOR A "K" IN BUFFER
856 TAD LETK /LETTER ASCII "K"
857 CIA /SUBTRACT FROM CHARACTER
860 JMP DIV3 /YES: SEE IF DIVISIBLE BY 3
862 /VERIFY THIS CHARACTER AS BEING OF DECIMAL ORIGIN
864 TAD C260 /ASCII FOR 0
865 CIA /TO SEE IF CHARACTER
866 TAD I W1 /IS LESS THAN 260
868 JMP I QU1 /YES: NOT DECIMAL CHARACTER
869 TAD C271 /ASCII FOR 9
870 CMA /TO SEE IF GREATER THAN
873 JMP I QU1 /NOT A DECIMAL CHARACTER
874 \f/CHARACTER IS DECIMAL. NOW CONVERT IT TO BINARY
875 /REMEMBER POSITION OF CHARACTER IN BUFFER MAY BE
878 TAD I W1 /ISOLATE THE NUMBER
879 AND C0017 /FOR PROPER CONVERSION
880 SNA /IF 0, NO BINARY CONVERSION NEEDED
881 JMP IBS /YES: 0: INCREMENT BINARY CONVERSION
883 /NOT 0, SET UP CONVERSION LOOP
885 CLL CIA /NUMBER OF ADDITIONS
886 DCA W4 /TO NEGATIVE FOR ISZ
887 TAD I W5 /BINARY POSITION TO C(ACC)
888 TAD TOTAL /ADD TO PRESENT TOTAL
889 SZL /CHECK ON TO MANY WORDS
890 JMP I QU2 /TO MANY WORDS CALLED FOR
891 DCA TOTAL /KEEP RUNNING SUM
892 ISZ W4 /LAST ADDITION?
893 JMP .-6 /NO: ADD AGAIN
895 /FINAL ADDITION FOR THIS POSITION COMPLETED
897 IBS, ISZ W5 /NEXT POSITION
898 JMP DNC /DO NEXT CHARACTER
900 /LAST CHARACTER COMPLETED. SEE IF DIVISIBLE BY 3
901 /IF NOT A NORMAL INPUT
903 DIV3, TAD TOTAL /GET TOTAL WORDS
904 SNA /IF TOTAL 0, NORMAL INPUT
905 TAD C201 /129 OCT. THIS TEST REDUNDANT
906 TAD C0017 /ADD CONSTANT 15 TO TOTAL
907 DCA TOTAL /FOR FUTURE CONSIDERATIONS
908 DCA VAR1 /# OF WORDS/3 FOR MARK TRACK WRITING
909 TAD TOTAL /RESTORE IN THE ACC
910 CLL /TO DIVIDE BY 3, LINK KEEPS OVERFLOW
912 ISZ VAR1 /ON EACH DIVISION, KEEP RUNNING SUM
913 SZA /IF AC = 0,NO REMAINDER
914 SNL /WHEN LINC GOES TO 0, DIVISION ENDED
915 SKP /NOW SEE IF IT DIVIDED EVENLY
916 JMP .-6 /SUBTRACT 3 MORE
917 SZA CLA /IF 0,OK. OTHERWISE ERROR
918 JMP I QU4 /NOT DIVISIBLE BY 3
920 /CORRECT "VAR1" ( THE NUMBER OF WORDS/3) FOR THE +15
921 /ADDED JUST ABOVE AND AN INHERANT +2 DUE TO MARK TRACK
922 /CONFIGURATION TO BE WRITTEN.
924 TAD M7 /SUBTRACT 7 FROM PHONY SETUP
925 TAD VAR1 /GIVING THE NUMBER OF TIMES
926 CIA /TO BE USED LATER IN A ISZ
927 DCA VAR1 /DATA MARK WILL BE WRITTEN
929 /COMPUTE A VALUE FOR TOTAL NUMBER OF BLOCKS
930 /RECORD SIZE + 15 INTO 636160 OCT.
932 TAD C7714 /EXTENDED 64 VALUE. SETS AC#2
933 DCA W1 /SET FOR 640000
934 JMS I FORM10 /PATCH TO CHECK FOR STD.10 FORMAT
935 TAD C1620 /VERNIER ADJUSTMENT FOR FORMULA
936 CLL /ACC#2 CARRY FUNCTION
937 TAD TOTAL /WORD COUNT
938 ISZ BLOCKS /+1 TO BLOCK COUNT
940 JMP I QU3 /TO MANY BLOCKS CALLED FOR
941 SNL /CARRY INTO ACC#2?
942 JMP .-5 /NO: CONTINUE COUNT
943 ISZ W1 /YES: FULLY DIVIDED?
944 JMP .-10 /NO: CONTINUE PROCESS
945 CLA CLL /C(ACC)+ C(L)=0
946 F10RTN, TAD BLOCKS /FOR MARK TRACK (COME HERE FR F10PAT IF 10 FRMT)
948 DCA VAR2 /SEE MARK WRITE
950 /VALUES FOR BLOCK AND RECORD SIZE HAVE BEEN
951 /COMPUTED. TELL OUTSIDE WORLD AND GET THE OK.
953 TAD TOTAL /SUBTRACT 15 FROM TOTAL
954 TAD C7761 /WORDS FOOLING OPERATOR
955 DCA TOTAL /CORRECTED FOR TAPE WRITING
956 TAD TOTAL /FOR OCTAL TYPEOUT
957 JMS I TYOCT /TYPE OCTAL WORDS
958 JMS I TYPE /TYPE MESSAGE
963 TAD BLOCKS /TYPE OUT BLOCK #S
964 IAC /TO FOOL THE OPERATOR
965 JMS I TYOCT /IN OCTAL
966 JMS I TYPE /TYPE MESSAGES
980 JMS I TYPIN /WAIT FOR REPLY
981 \f/SEE IF A YES OR NO ANSWER WAS GIVEN
990 /SEE IF THE DRIVE IS OK
992 RSTSM, TAD DT0060 /GIVE WRTM, NO GO
995 DCA W1 /STALL FUNCTION
996 CDTRD, DTRB /READ STATUS "B"
998 JMP CIZ /NO: TIME OUT STALL
999 JMS I TYPE /YES: INCORRECT SETUP
1007 /STALL FOR A WHILE FOR THE INTERRUPT
1009 CIZ, ISZ W1 /ONE ROUND'S WORTH
1012 STMK /OK, GO DO THE MARK TRACK
1016 /SET THE TAPE INTO MOTION. ALL VARIABLES ARE
1017 /SET. FROM THIS POINT ON, CONTROL IS EXECUTED
1018 /VIA THE WCO INTERRUPT
1020 /CLEAR OUT STATUS "A" AND RELOAD IT WITH CONTINUOUS
1021 /WRITE TIMING AND MARK TRACK COMMAND
1023 STMK, TAD DT0360 /FWD, CONT, T+M,GO,INT
1024 TAD DTA /ADD IN THE DTA
1025 DTCX /CLEAR FLAGS START MOTION
1026 DCA PHASE /FOR ERROR ROUTINE
1027 TAD VAR2 /TO MAKE A RESTART FOR THE "SAME"
1028 DCA W6 /OPTION POSSIBLE
1030 /WRITE END ZONE. WRITE ABOUT 10' OF THIS
1031 /CONFIGURATION. 4044
1033 / 4404 (5555) OCTAL.
1035 DCA W1 /CLEAR COUNTER, 7777= ABOUT 10'
1036 CEZ, TAD REZ /LOAD ADDRESS OF DATA
1037 DCA I CA /TO BE WRITTEN INTO THE CA
1038 TAD M3 /LOAD # WORDS TO BE WRITTEN INTO
1039 DCA I WC /WC LOCATION
1041 /WAIT FOR INTERRUPT, TEST FOR END OF
1044 JMS I WAIT /FOR INTERRUPT
1045 ISZ W1 /END OF FOOTAGE?
1046 JMP CEZ /NOT END FOOTAGE, CONTINUE
1047 /OK, WRITE INTERBLOCK SYNC
1049 /WRITE INTERBLOCK SYNC. SINCE THIS CONFIGURATION
1050 /ACT AS A NOP TO THE TCU, AT THE BEGINING OF
1051 /TAPE, MORE LENGTH OF THIS IS NEEDED FOR TURN AROUND
1052 /TIME TO GUARANTEE BLOCK 0000 TO THE LIBRARY SYSTEM
1053 /THEREFORE AT THE BEGINING OF TAPE ONLY, WRITE SEVERAL
1056 TAD M144 /NUMBER OF TIMES TO
1057 DCA W1 /WRITE INTERBLOCK SYNC
1058 JMS INBLSY /WRITE 1 INTERBLOCK SYNC
1059 ISZ W1 /CONFIGURATION, TEST END
1060 JMP .-2 /NOT TOTAL FOOTAGE. WRITE AGAIN
1061 JMP WDZ /COMPLETED, GO ON
1062 \f/AT NORMAL RETURN, WRITE ONLY ONE INTERBLOCK SYNC
1063 /CONFIGURATION. APPEARS AS 0404
1068 TAD IBZ /COUNTER AND WORD
1069 DCA I CA /COUNT WITH KEYS
1072 TAD VAR1 /RESET THE WORDS
1073 DCA W5 /PER BLOCK COUNTER
1075 /WAIT FOR INTERRUPT, RETURN TO SEQUENCE
1077 JMS I WAIT /FOR INTERRUPT
1081 /WRITE FORWARD BLOCK MARK AND REVERSE GUARD
1086 WDZ, TAD FBM /ADDRESS OF PATTERN
1087 DCA I CA /TO CURRENT ADDRESS
1088 TAD M3 /NUMBER OF WORDS
1089 DCA I WC /TO WORD COUNTER
1090 JMS I WAIT /DROP THROUGH AFTER WRITE
1093 /WRITE LOCK MARK, REVERSE CKSUM, REVERSE FINAL,REV PREFINAL
1094 /SIX WORDS 1. 0040 4. 0040
1095 / 2. 0000 5. 0000 ON TAPE OCTAL
1096 / 3. 4000 6. 4000 10101010
1098 TAD WLMRF /ADDRESS OF PATTERN
1099 DCA I CA /TO CURRENT ADDRESS
1100 TAD M6 /NUMBER OF WORDS
1101 DCA I WC /TO WORD COUNTER
1102 JMS I WAIT /DROP THROUGH AFTER WRITE
1105 / WRITE THE DATA TRACK. SINCE THE LENGTH OF EACH
1106 /RECORD IS A VARIABLE, "VAR1" KEEPS TRACK OF THE
1107 /NUMBER OF TIMES THIS CONFIGURATION WILL BE WRITTEN
1108 /"VAR1" WAS DECIDED FROM ABOVE IN THE FORMULA
1109 /TRANSLATION SECTION
1113 DTRK, TAD DZ /LOAD ADDRESS OF THE DATA
1114 DCA I CA /CONFIGURATION INTO CA
1115 TAD M3 /LOAD # WORDS
1116 DCA I WC /INTO WORD COUNT
1117 \f/WRITE ONE SET TEST "VAR1" FOR LAST SET
1119 JMS I WAIT /ONE CONFIGURATION
1121 JMP DTRK /NOW WRITE DATA MARK TRACK AGAIN
1123 / MARK TRACK CODE FOR DATA IS COMPLETE. NOW WRITE
1124 /PREFINAL, FINAL, CHECKSUM AND REVERSE CHECKSUM.
1125 /SIX WORDS 1 4440 4 4440
1126 / 2 4444 5 4444 ON TAPE AS
1127 / 3 4044 6 4044 73737373 OCTAL
1129 TAD FEZ /LOAD ADDRESS OF
1130 DCA I CA /DATA CONFIGURATION INTO CA
1131 TAD M6 /LOAD # WORDS
1132 DCA I WC /INTO WORD COUNT
1133 JMS I WAIT /TILL COMPLETED WRITE
1137 /WRITE GUARD, REVERSE BLOCK
1142 TAD GRZ /DATA ADDRESS TO
1144 TAD M3 /NUMBER OF WORDS
1145 DCA I WC /TO WORD COUNT
1146 JMS I WAIT /TILL COMPLETE
1150 /THIS COMPLETE SET OF DATA TRANSFERES
1151 /COMPLETES ONE BLOCK ON TAPE. SINCE THE
1152 /NUMBER OF BLOCKS IS VARIABLE, "VAR2" IS
1153 /USED TO RECYCLE. "VAR2" WAS SET UP ABOVE IN
1154 /THE FORMULA TRANSLATION SECTION
1156 JMS INBLSY /WRITE INTERBLOCK SYNC
1157 ISZ W6 /TOTAL NUMBER OF BLOCKS
1158 JMP WDZ /WRITTEN? NO:
1161 \f/ALL DATA BLOCKS HAVE BEEN WRITTEN.
1162 /NOW PROVIDE A BUFFER ZONE OF INTERBLOCK SYNC AT THE END
1163 /OF TAPE AS AT THE START OF TAPE
1165 TAD M144 /ABOUT TWO BLOCKS(STANDARD) WORTH
1166 DCA W1 /ABOUT 100 TIMES
1167 JMS INBLSY /WRITE ONE PATTERN
1169 JMP .-2 /NO CONTINUE WRITING INTERBLOCK SYNC
1171 /COMPLETED BLOCK WRITING
1172 /WRITE ANOTHER 10' OF END ZONE (FORWARD)
1173 /BEFORE LOADING BLOCK NUMBERS.
1179 WEZF, TAD EZM /LOAD ADDRESS OF DATA
1181 TAD M3 /NUMBER OF WORDS
1182 DCA I WC /WORD COUNT
1184 /WRITE 1 SET, CHECK END OF 10'.
1186 JMS I WAIT /TILL COMPLETE
1187 ISZ W1 /END OF FOOTAGE?
1188 JMP WEZF /NO, CONTINUE WITH END ZONE
1189 JMP I .+1 /GO AND START BLOCK NUMBER
1191 \f/THESE ARE THE DATA CONFIGURATIONS FOR THE MARK TRACK
1197 4044 /ON TAPE AS 5555 (OCT)
1204 0404 /ON TAPE AS 2525 (OCT)
1208 /FORWARD BLOCK MARK AND REVERSE GUARD
1211 0404 /ON TAPE AS 2632 (OCT)
1215 /LOCK MARK, REVERSE CHECKSUM, REVERSE FINAL
1216 /AND REVERSE PREFINAL
1219 0040 /ON TAPE AS 10101010 (OCT)
1229 4440 /ON TAPE AS 7070 (OCT)
1233 /PREFINAL, FINAL, FWD CHECKSUM, AND REVERSE LOCK
1236 4440 /ON TAPE AS 73737373 (OCT)
1242 \f/FORWARD GUARD AND REVERSE BLOCK NUMBER
1245 4040 /ON TAPE AS 5145 (OCT)
1252 0400 /ON TAPE AS 2222 (OCT)
1255 /SUBROUTINE TO SEE IF USER TYPED MARK 384
1256 /TO SPECIFY STANDARD PDP-10 FORMAT
1258 DCA BLOCKS /CLEAR LOC. BLOCKS IN CASE NOT 10-FORMAT
1259 TAD TOTAL /AND GET NUMBER TYPED BY USER
1260 TAD M617 /WAS IT 384?
1262 JMP I F10PAT /NO-RETURN
1263 DCA W1 /YES-CLEAR W1 FOR WAIT LOOP
1264 TAD C1101 /AND ADJUST BLOCK TOTAL FOR
1265 DCA BLOCKS /1102(OCTAL) BLOCKS.
1272 /THE MARK TRACK HAS BEEN WRITTEN, AND TAPE IS
1273 /MOVING FORWARD IN THE FORWARD END ZONE. STOP
1274 /THE TAPE AND SEE IF THERE ARE ANY TAPES LEFT TO
1275 /MARK--IF SO GO DO THEM, ELSE TELL OPERATOR TO THROW THE
1276 /"NORMAL/WRTM/RDTM" SWITCH TO "NORMAL"
1277 /HE WILL THEN CONTINUE AFTER THIS ACTION
1279 /KILL WRITE, STOP TAPE
1281 MWTM, TAD DT0070 /STOP TAPE WITH SELECT ERROR
1282 TAD DTA /LOAD DTA INTO ORDER
1283 DTCX /EXECUTE THE ABOVE
1284 JMS NUDTA /ANY MORE DTAS TO MARK?
1285 JMP I DOMARK /YES: GO MARK THEM
1287 /MESSAGE TO OPERATOR
1289 JMS I TYPE /NO: BACK TO FIRST DTA AND CONTINUE
1301 JMS I TYPIN /WAIT FOR CR
1303 /REVERSE TAPE FOR A FEW SECONDS TO GUARANTEE
1304 /BLOCK MARK SECT WILL BE UNDER THE HEAD
1306 PSER, TAD DT0600 /REVERSE, MOVE, GO
1307 TAD DTA /ADD DTA TO ORDER
1308 DTCX /CLEAR TCU,GET MOVING IN REVERSE
1310 /STALL A FEW SECONDS
1312 TAD M300 /AROUND 2 SECONDS
1314 MSTALL, ISZ W1 /MINOR STALL
1320 JMP MSTALL /LOOP MAJOR
1321 \f/TAPE OUT ON MARK TRACK NOW, TURN AND GET IT
1322 /MOVING FORWARD. AT THIS POINT, THE LAST REVERSE
1323 /BLOCK NUMBER WILL BE WRITTEN UNTILL END ZONE IS
1324 /REACHED. THEREFORE, WHEN THE BOUNCE OUT OF THE END
1325 /ZONE TAKES PLACE, THE SYSTEM WILL BE ABLE TO SYNC ON
1326 /THE REVERSE BLOCK NUMBER TO WRITE THE REST OF
1327 /THE BLOCK NUMBERS AND KNOWN GOOD DATA IN REVERSE.
1328 /THIS PROCESS WILL ELIMINATE A NEEDLESS REWIND AND
1329 /KEEP THE ENTIRE PROCESS TO TWO COMPLETE PASSES
1331 /WRITE LAST REVERSE BLOCK NUMBER GOING FORWARD
1335 TAD DT0210 /FORWARD, SEARCH, GO
1336 TAD DTA /ADD IN THE DTA
1337 DTCX /CLEAR STATUS "A" AND RELOAD IT
1338 TAD C1 /PHASE 1 ERROR
1339 DCA PHASE /FOR ERROR ROUTINE
1341 /WAIT HERE FOR DECTAPE FLAG. CHECK ALSO FOR ERRORS
1342 /SET BLOCK NUMBER (REVERSE) INTO FORM
1344 TAD BLOCKS /INTO AC WITH LAST BLOCK NUMBER
1345 JMS I MESS /CONVERT BLOCK NUMBER FOR TAPE
1347 /INTERRUPTED? ERROR?
1349 DTRB /READ STATUS "B"
1350 RAR /DECTAPE FLAG TO LINK
1352 JMP .-3 /NO: CONTINUE WAIT
1354 /BLOCK FOUND. SWITCH TO READ DATA WITH WC ONE LESS THAN
1355 /NUMBER OF WORDS TO BE READ. READ TILL WC=0
1357 TAD DT0130 /TO SET STATUS "A" INTO
1358 RCYBR, DTXA /THE READ DATA MODE
1359 CLA CMA /SUBTRACT 1 FROM TOTAL
1360 TAD TOTAL /GIVING TOTAL-1 (HO HO)
1364 DCA I CA /JIMMIED TO DO NOTHING
1365 DTRB /READ "B" REGISTER
1366 AND C1000 /ISOLATE END ZONE BIT
1368 JMP I GDBLK /YES: GO AND WRITE THE BLOCK NUMBERS
1369 TAD I WC /WAIT TILL WORD COUNT ZERO
1370 SZA CLA /EQUAL TO ZERO?
1371 JMP .-10 /NO: LOOP AGAIN
1372 \f/END OF BLOCK FOUND. WRITE JUNK AND REVERSE BLOCK NUMBER
1374 TAD M14 /12 WORDS TO BE WRITTEN
1375 DCA I WC /TO WORD COUNT REG.
1376 TAD FORMB /FORM TO CA
1377 DCA I CA /OF NUMBERING FORM
1378 TAD DT0070 /SWITCH TO WRITE ALL
1381 /LOOK FOR THE DECTAPE FLAG INDICATING ANOTHER RECYCLE
1383 DTRB /NO: GET "B" AGAIN
1386 JMP .-3 /NO: BE PATIENT. HAST NOT.
1387 TAD DT0070 /TO SWITCH TO READ DATA
1390 DOMARK, STMK /POINTER TO START OF MARK ROUTINE
1392 /SUBROUTINE TO GET NEXT DTA UNIT # FROM INPUT LIST OR
1393 /RECYCLE TO FIRST UNIT IF ALL HAVE BEEN PROCESSED UP TO
1394 /THIS POINT--CALL SEQUENCE
1395 / JMS NUDTA /CALL THE ROUTINE
1396 / (RETN1) /RETURNS HERE IF MORE DTAS TO PROCESS
1397 / (RETN2) /RETURNS HERE IF END OF LIST
1398 /END OF LIST MEANS RESET TO FIRST AND RETURN TO (RETN2)
1399 /RETURN IS WITH DTA SET TO NEW VALUE AND AC=0
1402 TAD I LSTPT /GET CURRENT VALUE OF DTA LIST PTR
1403 DCA TBUFPT /STORE IT AS TEM. BUF. PTR.
1404 TAD I TBUFPT /GET A DTA # FROM THE LIST
1405 AND C0007 /ISOLATE LOW ORDER DIGIT
1406 SZA CLA /IS IT 7777?
1407 JMP LSTEND /YES: END OF LIST
1408 TAD I TBUFPT /NO: GET IT BACK
1409 DCA DTA /AND STORE AS NEW DTA #
1410 ISZ I LSTPT /INCREMENT LIST POINTER
1412 /COMES HERE AT END OF LIST TO RESET PTRS AND RETN TO CALL+2
1413 LSTEND, ISZ NUDTA /INCREMENT RETURN POINTER
1414 TAD I STRTPT /GET ADR. OF START OF LIST
1415 DCA I LSTPT /STORE TO RE-INITIALIZE LIST PTR.
1416 JMP NUDTA+1 /GO GET FIRST DTA # AND RETURN
1418 STRTPT, DBUFAD /POINTER TO START OF DTA LIST
1419 TBUFPT, 0 /TEM. STORAGE FOR BUF. PTR.
1420 LSTPT, DBUFPT /POINTER TO CURRENT VALUE OF DTA LIST PTR
1421 DTABUF, 0 /START OF DTA # LIST - MAX. 9 WORDS
1424 /SUBROUTINE TO CHECK FOR REPEATED DTA NUMBERS
1425 /DTA # TO COMPARE TO LIST IS IN AC ON ENTRY--THIS
1426 /ROUTINE STORES THE DTA # IF IT IS NEW AND IGNORES IT
1427 /IF IT IS NOT-CALL BY JMS REPEAT WITH DTA # IN AC
1429 DCA DNUM /TEM STORAGE FOR NEW DTA #
1430 TAD DBUFAD /INITIALIZE POINTER (DBUFPT)
1431 DCA DBUFPT /TO START OF DTA LIST
1432 TAD DCTR /LOAD NUM. OF DTAS STORED
1434 DCA COMCTR /STORE IN COMPARE COUNTER
1435 COMCHK, ISZ COMCTR /DONE WITH ALL COMPARES?
1436 JMP DOCOMP /NO: GO DO COMPARE
1437 TAD DNUM /YES: STORE NEW DTA#
1438 DCA I DBUFPT /AT END OF LIST
1439 ISZ DCTR /INCR. # OF DTAS STORED
1440 JMP I REPEAT /RETURN
1442 /THIS SECTION DOES THE ACTUAL COMPARISON BETWEEN
1443 /THE DTA# PASSED TO THE ROUTINE AND A NUMBER ON THE LIST
1445 DOCOMP, TAD I DBUFPT /GET NEXT DTA NUMBER FROM LIST
1447 TAD DNUM /ADD IN DTA NUMBER PASSED
1448 SNA CLA /ARE THEY THE SAME?
1449 JMP I REPEAT /YES: RETURN
1450 ISZ DBUFPT /NO: INCREMENT LIST POINTER
1451 JMP COMCHK /SEE IF DONE ALL COMPARES
1454 COMCTR, 0 /COUNTER FOR # OF LIST COMPARISONS TO BE DONE
1455 DCTR, 0 /COUNTER FOR # OF DTAS IN LIST
1456 DBUFAD, DTABUF /START OF DTA NUM. LIST
1457 DNUM, 0 /TEM STORAGE FOR DTA #
1460 /GO INTO SEARCH IN REVERSE MODE LOOKING FOR
1461 /THE LAST BLOCK NUMBER. WHEN FOUND, SYNC THE SYSTEM
1462 /AND WRITE ALL DATA AND BLOCK NUMBERS
1464 DOBLK, JMS I TURN /INTO REVERSE AND SEARCH MODE
1465 TAD BLOCKS /TO SET UP
1466 DCA BLOCKA /FOR BLOCK DECREMENTING
1467 TAD C2 /PHASE 2 ERROR
1468 DCA PHASE /FOR ERROR ROUTINE
1470 /LOOK FOR INTERRUPT INDICATING BLOCK NUMBER
1472 JMS I WAIT /FOR DECTAPE FLAG
1474 /SWITCH TO WRITE ALL. SYSTEM NOW IN SYNC
1476 TAD DT0140 /SWITCH TO WRITE ALL
1478 NEXTBN, TAD ADF3 /ADDRESS OF FIRST 3 WORDS INCLUDING
1479 DCA I CA /THE FORWARD CHECKSUM TO BE WRITTEN
1480 TAD M3 /NUMBER OF WORDS TO BE WRITTEN
1481 DCA I WC /TO WORD COUNT
1482 JMS CEZN /CHECK FOR END ZONE
1483 TAD I WC /CHECK FOR WC=0
1485 JMP .-3 /NOPE: TRY AGAIN
1486 DTXA /YUP: CLEAR THE FLAG
1488 /WRITE DATA TRACK. REMEMBER CORRECT DATA IS BEING WRITTEN
1490 TAD TOTAL /ONE FROM TOTAL NUMBER
1491 CIA /OF WORDS FOR COUNTING
1492 DCA I WC /DATA WORDS WRITTEN
1493 TAD AD7777 /ADDRESS OF SEVENS
1494 DCA I CA /DATA TO BE WRITTEN
1496 /MONITOR WORD COUNT FOR A ZERO READING
1497 /SOME OF THIS TIME IS USED TO SET THE NEXT
1498 /BLOCK NUMBER INTO THE FORM.
1500 TAD BLOCKA /CURRENT BLOCK NUMBER
1501 JMS I MESS /CONVERT INTO FORM
1502 CLA CMA /TO DECREMENT
1503 TAD BLOCKA /THE BLOCK COUNT
1504 DCA BLOCKA /DOWN TO ZERO
1505 JMP CEZB /BYPASS FOLLOWING ROUTINE
1509 DTRB /READ STATUS "B"
1510 AND C1000 /ISOLATE END ZONE
1512 JMP I CEZN /NOT EZ, RETURN
1513 JMP I GDBN /COMPLETED
1514 \f/CHECK HERE ALSO TO SEE IF END ZONE, INDICATING
1515 /THAT THE LAST BLOCK HAS BEEN WRITTEN
1517 CEZB, JMS CEZN /END ZONE?
1519 /LOOK FOR WORD COUNT AS BEING EQUAL TO ZERO
1521 TAD I WC /WC TO C(AC)
1522 SNA CLA /END OF DATA WRITE?
1523 JMP WBN /YES: GO TO WRITE BLOCK NUMBER
1524 TAD AD7777 /RESET CURRENT ADDRESS COUNT
1525 DCA I CA /DON'T LET THE CA ADVANCE TO
1528 /DATA HAS BEEN WRITTEN. NOW WRITE REVERSE
1529 /BLOCK NUMBER, FORWARD BLOCK NUMBER, AND REVERSE
1530 /CHECKSUM. (12 WORDS)
1532 WBN, DTXA /CLEAR OUT DECTAPE FLAG
1533 TAD M14 /WILL WRITE 12 WORDS
1534 DCA I WC /FOR THIS BIT
1535 TAD FORMA /FROM A FORM CONTAINING
1536 DCA I CA /BLOCK NUMBERS
1541 TAD I WC /NO: SEE IF DONE THE WRITE
1543 JMP .-3 /NO: PATIENCE IS A VIRTUE????
1544 DTXA /RESET THE CURRENT FLAG
1545 JMP NEXTBN /YES: GO RECYCLE COMPLETLY
1548 / FIRST 3 WORDS TO BE WRITTEN
1555 /DATA TO BE WRITTEN ON TAPE (REVERSE)
1562 /CHECK IF ALL DTAS ARE DONE BEFORE RESTARTING
1564 SETDTA, JMS I GDTA /ALL DTAS DONE?
1565 JMP I CONTNU /NO: BACK TO WRITE BLOCK #S ON NEXT
1566 JMP I IT /YES: GO ASK "DIRECT?"
1567 GDTA, NUDTA /POINTER TO SUBR FOR GETTING NEXT UNIT #
1568 CONTNU, PSER /POINTER TO START OF BLOCK # WRITE ROUTINE
1571 /TYPE ONE FOUR CHARACTER OCTAL WORD GIVEN TO THE
1572 /ROUTINE VIA C(ACC). C(ACC)=0 ON EXIT
1575 DCA TW1 /STORE WORD GIVEN
1576 TAD TW1 /TO C(ACC) AGAIN
1580 DCA TYCT1+2 /SAVE ROTATED VALUE, 1ST TWO
1581 TAD TYCT1+2 /TO C(ACC) AGAIN
1582 AND C0007 /ISOLATE SECOND CHARACTER
1583 TAD C6060 /CONVERT TO ASCII
1584 DCA TYCT1+1 /STORE AS FIRST PARTIAL 2
1585 TAD TYCT1+2 /ROTATED VALUE STORED ABOVE
1588 AND C0700 /ISOLATE FIRST CHARACTER
1589 TAD TYCT1+1 /CONVERT 1ST TO ASCII
1590 DCA TYCT1+1 /1ST AND 2ND CHARACTERS READY
1591 TAD TW1 /ORIGIONAL WORD
1592 AND C0007 /ISOLATE 4TH CHARACTER
1593 TAD C6060 /CONVERT 4 TH TO ASCII
1594 DCA TYCT1+2 /STORE 4TH FOR A MOMENT
1595 TAD TW1 /ORIGIONAL WORD
1597 RAL /POSITION IT 3RD CHARACTER
1598 AND C0700 /ISOLATE 3RD CHARACTER
1599 TAD TYCT1+2 /CONVERT TO ASCII
1600 DCA TYCT1+2 /CONVERSION COMPLETE
1601 TYCT1, JMS I TYPE /TYPE THE FOUR CHARACTERS
1605 JMP I TYCT /EXIT FROM ROUTINE
1607 /SOME CONSTANTS FOR THE ROUTINE
1612 /VERIFY THE TAPE AS BEING WRITTEN CORRECTLY
1613 /WITH DATA AND BLOCK NUMBERS. THE INFORMATION WRITTEN
1614 /WAS WRITTEN IN SUCH A WAY AS TO BE CORRECT
1615 /UPON READING IT BACK
1618 /TURN TAPE AND HAVE IT GOING FORWARD
1620 DBN, TAD ISZV /RESET INCREMENT
1621 DCA VISZ /BLOCK NUMBERS FORWARD
1622 DCA FCON /WILL BE ZEROS FORWARD
1623 DCA W1 /FIRST BLOCK NUMBER FORWARD
1624 TAD C0400 /TURN TO GO FORWARD
1626 TAD C3 /ERROR IN PHASE 3
1627 DCA PHASE /FOR ERROR ROUTINE
1629 /SET SOME OF THE CONTROL REGS
1631 DAB, DCA I WC /WORD COUNT DON'T CARE
1632 TAD ADBA /SOME WHERE UP ABOVE
1633 DCA I CA /TO GET BLOCK NUMBERS
1637 JMS I WAIT /INTERRUPT
1638 TAD W1 /FIRST OR NEXT BLOCK NUMBER
1640 TAD I ADBA /GET THE BLOCK NUMBER
1641 SZA CLA /COMPARE OK?
1642 JMP BLKERZ /BLOCK ERROR FOUND
1644 /BLOCK COMPARES, NOW CHECK DATA
1646 TAD DT0030 /TO SWITCH INTO READ
1648 DCA I WC /DON'T CARE ABOUT THE WC
1649 CTST, TAD ADWA /FOR COMPARING
1652 /EVERY TIME THE WORD COUNT MOVES
1653 /A DATA TRANSFERE HAS BEEN COMPLETED.
1654 /MAKE SURE THAT THE INFORMATION IS OK
1656 TAD I WC /GET WORD COUNT
1657 SNA CLA /STILL AT ZERO?
1658 JMP CEFR /YES: SEE IF AT END
1659 TAD FCON /NO: SEE IF DATA
1660 CIA /IS SAME AS WRITTEN
1661 TAD I ADWAB /RECEIVED DATA
1663 JMP DTAR /DATA ERROR FOUND
1664 DCA I WC /YES: RESET WORD COUNT
1665 \f/CHECK FOR DECTAPE FLAG INDICATING END OF
1668 CEFR, DTRB /READ "B" REGISTER
1670 JMP PARIR /PARITY ERROR, I GUESS
1672 /NO ERROR, END OF BLOCK?
1674 RAR /FLAG TO THE LINK
1676 JMP CTST /NO: CONTINUE CHECKING
1677 TAD DT0030 /CLEAR DECTAPE FLAG
1678 DTXA /AND RETURN TO SEARCH
1680 /END OF BLOCK. SEE IF END OF TAPE
1682 TAD W1 /BLOCK NUMBER JUST TESTED
1683 VISZ, ISZ W1 /+1 OR -1 TO BLOCK COUNT
1686 CIA /TO BE COMPARED WITH
1687 TAD BLOCKS /TOTAL BLOCKS
1689 JMP DAB /NO, DO ANOTHER BLOCK
1692 /HERE PUT IN THE REVERSE CHECK
1694 DDSF, DTSF /WAIT FOR ANY FLAG TO APPEAR
1696 CLA CLL /RID AC OF GARBAGE
1697 DTRB /READ THE "B" REGISTER
1698 AND C1000 /BETTER BE END ZONE
1700 JMP LNE /LAST INTERRUPT NOT END ZONE
1702 \f/BLOCK NUMBERS AND DATA HAVE BEEN CHECKED FORWARD
1703 /AND ARE OK. USING THE ABOVE ROUTINE FOR CHECKING
1704 /RESET A FEW THINGS AND CHECK IN REVERSE
1706 /WAS COMPLETION FOUND FORWARD? IF SO GO CHECK
1707 /IN REVERSE; IF NOT GO SEE IF ALL TAPES HAVE BEEN CHECKED.
1710 TAD FCON /IF 0'S, IT WAS FWD
1712 JMP I FINCHK /N0: REVERSE-SEE IF ALL DTAS DONE
1714 /RESET THE ABOVE ROUTINE TO READ IN REVERSE
1716 CMA /DATA WILL BE AS WRITTEN
1717 DCA FCON /I.E., 7777'S
1718 TAD SJMP /INSTEAD OF INCREMENTING
1719 DCA VISZ /WE WILL DECREMENT BLOCK NUMBERS
1720 TAD BLOCKS /STARTING WITH THE HIGHEST
1721 DCA W1 /AND WILL WORK TO ZERO
1722 JMP DBNAUX /ALL SET, TRAVEL ONWARD
1724 /RETURN HERE AFTER EACH BLOCK FOR CHECKING WHEN LAST BLOCK
1725 /HAS BEN PROCESSED????????????
1728 SNA /IF AC = 0, WE ARE DONE
1729 JMP DDSF /AND NEXT FLAG SHOULD BE END ZONE
1730 CIA /OTHERWISE, SUBTRACT ONE FROM
1731 CMA /BLOCKS GIVING BLOCKS-1......?
1733 JMP DAB /GO DO ANOTHER BLOCK
1735 ISZV, ISZ W1 /VARIABLE TAG
1737 \f/BLOCK ERROR FOUND
1739 BLKERZ, TAD DTA /TO RESET TAPE
1741 TAD I ADBA /GET BAD BLOCK NUMBER
1742 JMS I TYOCT /AND TYPE IT OUT
1743 JMS TYSB /TYPE "SHOULD BE"
1744 TAD W1 /GOOD BLOCK NUMBER
1745 JMS I TYOCT /TYPE IT OUT
1769 DTAR, TAD DTA /TO STOP TAPE
1771 TAD I ADWA /GET THE BAD WORD
1773 JMS TYSB /TYPE "SHOULD BE"
1775 JMS I TYOCT /TYPE IT OUT
1784 \f/PARITY ERROR FOUND
1787 ERROR /MAIN ERROR ROUTINE
1789 /LAST INTERRUPT WAS NOT END ZONE
1804 / TYPE OUT THE DTA UNIT NUMBER AND THE FIRST 12 BLOCK
1805 /NUMBERS IN EITHER DIRECTION. IF RDR, IN REVERSE
1806 /IF RDF, TYPE THEM OUT GOING IN THE FORWARD
1807 /DIRECTION FROM THE BEGINING OF TAPE
1809 RDFA, TAD C0400 /DIRECTION FOR TURNING
1810 DCA SAVEIT /STORE DIRECTION FOR NEXT DTA UNIT
1811 TAD SAVEIT /GET DIRECTION FOR TURNING
1813 TAD M14 /READ 12 BLOCK
1815 TAD BADD /ADDRESS OF BUFFER
1816 DCA X2 /TO AUTO INDEX 2
1817 TAD ADW3 /ADDRESS OF W2
1818 DCA I CA /FOR DATA XFER
1819 JMS I WAIT /FOR BLOCK INTERRUPT
1820 TAD W2 /BLOCK NUMBER
1821 DCA I X2 /STORE BLOCK NUMBER
1823 JMP .-4 /NO: GRAB NEXT
1824 TAD DTA /KILL TAPE MOTION
1827 /TYPE OUT BLOCK NUMBERS AND DTA UNIT #
1829 JMS I TYPE /TYPE "DTA"
1834 JMS I TYOCT /AND TYPE IT OUT
1838 TAD M14 /WILL TYPE ALL
1839 DCA W1 /TWELVE WORDS
1840 TAD BADD /ADDRESS OF BLOCK
1841 DCA X2 /NUMBERS TO INDEX 2
1842 TAD I X2 /FIRST OR NEXT BLOCK
1843 JMS I TYOCT /TYPE IT OUT
1844 JMS I TYPE /CR AND LINE FEED
1849 JMS I NEWDTA /YES: ANY MORE DTAS?
1850 JMP RDFA+2 /YES: GO GET BLOCK #S
1851 JMP I IT /NO: GO ASK FOR "DIRECT?"
1852 RDR, JMP RDFA+1 /OTHER DIRECTION
1854 SAVEIT, 0 /TEM. STORAGE FOR DIRECTION
1855 NEWDTA, NUDTA /POINTER TO SUBR. TO GET A NEW DTA UNIT #
1857 /INPUT BUFFER FOR THE TELETYPE.
1858 /NOTE ,,,,,,,THIS MUST BE AT THE END OF THE PROGRAM