Digital PDFs
Documents
Guest
Register
Log In
DIGITAL-7-22A-IO
January 1966
26 pages
Original
0.9MB
view
download
Document:
DECTAPE Subrts
Order Number:
DIGITAL-7-22A-IO
Revision:
Pages:
26
Original Filename:
http://bitsavers.org/pdf/dec/pdp7/DIGITAL-7-22A-IO_DECTAPE_Subrts_Jan66.pdf
OCR Text
1. IDENTIFICATION 1.1 Di gi ta 1-7-22A-I/O 1.2 Bidirectional PDP-7 DECtape Subroutines 1.3 January 21, 1966 PDP 7 LIBRARY Dig ita 1-7- 22A -1/ 0 Page 1 2. ABSTRACT The Bidirectional PDP-7 DECtape Subroutines allow the programmer to transfer variable length records to or from DECtape in either direction depending on the current position of the tape. The only requirement is that the standard DECtape format be used (11 OOa usable blocks of 400a words each). Mainly the subroutines minimize access time to the DECtape, and allow program overlap with data transfers using the program interrupt or automatic priority interrupt facilities. With three exceptions,* the subroutines are completely compatible with the unidirectional subroutines described in Digital-7-22-I/O (which are not obsolete). Information written with either set can be read with the other. In addition, data is written as if it were in the forward direction; so that the record need not be read in the same direction as it was written. The amount of data transferred need not be an integral number of blocks. Though the routines themselves are loaded into the first aK of core, data transfers can address normal or extended memories. These new subroutines make more efficient use of the DECtape; however, as they are significantly larger than the basic set (450 locations for the unidirectional, 604 locations for the bidirectional), the user must choose the set most applicable to the job. a 3. REQUIREMENTS 3. 1 Storage a The subroutines occupy approximately 604a locations including variable registers and literals, and must be loaded into the first aK of memory. 3.3 Equipment . The subroutines function with a 555 or TU55 DECtape drive and a 550 or 550A DECtape control interfaced to a PDP-7. The subroutines will not run on a PDP-4. 4. USAGE 4.1 Loading The subroutines are in ASCII format designed to be assembled as part of the user1s program. The tapes contain no origin, no starting address, and no undefined symbols. In order to link with the user1s program, however, the following items are required as part of the main program. 4.1.1 In order to correctly use the program interrupt or automatic priority interrupt facilities, the main program must include the following coding. Reference should be made to the description of the interrupt faci lities in the PDP-7 Users Handbook (F-75). For the standard program interrupt control, the main program should store a JMP X instruction at location 1 where X must include the following instructions: * 1) The Search subroutine can no longer be used as a separate independent subroutine. 2) The register MMWA 1 no longer holds the next block to be transferred (or the next free block). See Section 4.2.7, page 5. 3) Starting and ending core addresses for the Read and Write Subroutines must be lS-bit addresses and can no longer be LAW instructions. Digitol-7-22A-I/O Page 2 x, DAC ACSAVE MMEF SKP JMP I MMERR MMDF SKP JMP I MMDATA MMBF SKP JMP I MMBLF (Any addit"ionaloptions attached to the interrupt are checked here) /SAVE THE ACCUMULATOR /SKIP ON DECTAPE ERROR FLAG /SKIP ON DECTAPE DATA FLAG /SKIP ON DECTAPE BLOCK END FLAG OR HLT /IF NO OTHER OPTIONS ATTACHED For the automatic priority interrupt ,the program should store a JMS X instruction at location 43 (assuming DECtape is attached to channel 3) where X must include the following instructions: X, o DAC ACSAVE MMEF SKP JMP I MMERR MMDF SKP JMP I MMDATA MMBF HLT /SAVE THE ACCUMULATOR /SKIP ON DECTAPE ERROR FLAG /SKIP ON DECTAPE DATA FLAG /SKIPON DECTAPE BLOCK END FLAG ERROR /UNLES"SOTHER OPTIONS ATTACHED JMP I MMBLF 4.1 .2 The tag "DISMIS" must be defined in the main program as a jump to the instructions which restore the link bit and accumulator and reenable the interrupt or channel. (The examples assume the " interrupt routines were coded as in Section 4.1 .1 above.) For the standard program interrupt control: " DISMIS = JMP. LAC 0 RAL LAC ACSAVE ION JMPIO /RESTORE LI NK /RESTORE ACCUMULA TOR /ENABLE INTERRUPT /RETURN TO MAIN PROGRAM For automatic priority interrupt: DISMIS = JMP. LAC X RAL LAC ACSAVE DBR JMPIX /RESTORE LINK /RESTORE ACCUMULATOR /DEBREAK, ENABLE CHANNEL /RETURN TO MAIN PROGRAM Digital-7-22A-I/O Page 3 4.1 .3 In order to differentiate between programs using the program interrupt and automatic priority interrupt facil ities, the main program must contain a register named "MMAPII" containing a + 0 if the program interrupt is used, and any nonzero word if the automatic priority interrupt is used. Since it is not destroyed or changed MMAPII may be defined as equal to any other register which always contains the zero or nonzero word as requ ired. 4.1.4 The subroutines assume that DECtapeis attached to channel 3 if the automatic priority interrupt is used. If attached to any other channel, the register named "MMAPIC", within the subroutines themselves, must be modified to contain a 1 bit in one of the bits 2-17 (representing channels 0-15 10 respectively) to indicate the channel. For example: If MMAPfC contains" 1" If MMAPIC contains 11100000" IfMMAPIC contains "40" channel 15 is used channel 0 is used channel lOis used MMAPIC need not be changed if the program interrupt, or channel 3 of the automatic priority interrupt, is used. 4.1 .5 The program interrupt or automatic priority interrupt (and channel) will be enabled by the subroutines themselves whether or not they were enabled by the user previously. The main program must guarantee that no flags can come up (or be up) from devices which are not checked by the user's interrupt service routine (as outl ined in Section 4. 1 . 1). 4.2 Call ing Sequence To transfer information the following call ing sequence must be used:. JMS MMRDS LAC BLOCK JMP XX ZZOOOO C1 C2 RETURN 4.2.1 writing. lOR JMS MMWRS /BLOCK NUM.BER /ERROR RETURN /UNIT /FIRST ADDRESS /LAST ADDRESS /MUL TIPROGRAMMING RETURN See Section 4.2. 1 See Section 4.2.2 See Section 4.2.3 See Section 4.2.4 See Section 4.2.5 See SectionA.2.6 See Section 4.2.7 The JMS MMRDS instruction is used for reading; the JMS MMWRS instruction is used for 4.2.2 The DECtape block number on which the information transfer is to begin can be loaded into the accumulator with a LAC instruction as shown (where BLOCK is any register containing the correct block number), or with a LAW instruction containing the correct block number. The user should always assume the information is being transferred in the forward direction. As the instruction is executed, the location cannot contain just the block number itself. The low order twelve bits of the block number are examined, however, only block nl.)mbers 1 through 11008 are acceptable to the subrouti~es. 4.2.3 The JMP XX instruction is the instruction executed shoul d any type of error occur. The accumulator contains a code indicating the type of error which occurred and location MMRSA contains the status of the DECtape system (obtained by means of an MMRS instruction) at the time of the error. The error may be detected in either the main program level or interrupt level of the program and, therefore, the interrupt system or the particular channel used will be disabled when this instruction is executed. Disitol-7-22A-I/O Page 4 NOTE: If the main program is normally in extend mode while the DECtape is running, the error return must be a JMP I (XX+400000) so that the extend mode wi II be restored if an error occurs. At the time the instruc:tion is executed, the contents of the accumulator can be interpreted as follows: Contents of Accumu lator Meaning LAW 100 Illegal format. Block number or corelocations requested were illegal. LAW 200 Block requested cannot pe found. * LAW 300 The DECtape error flag was raised while searching for other than an end-'of-tClpe condi ti on . * LAW 400 The DECtape error flag was raised while reading.** LAW 500- The ca Icu tated checksum does not agree with the checksum read from tape. ** LAW 600 The DECtape error flag was raised while writing.** LAW 700 The block number read was not the block mark number predicted, while reading or writing. ** At the present the DECtape error flag can only. be raised by end-of-tape, a timing error (the program di~ han~le data fast enough), or a ~ark-track error. 4.2.4 ZZ represents the unit number (1-10) which must be placed in bits 2 through 5 of the register. Only those bits are examined. 4.2.5 C1 represents the 15-bit address of the first core location to be read into or written from (always assuming the datciis transferred in the forward direction). It can be any address in normal or extended memory. (Only 15 bits are examined.) 4.2.6 C2 represents the 15-bit address of the 1ast core location {inclusive} to be read into or written from (again assuming the data is transferred in the forward direction). C2 must be equal to dI' greater than C1. (Only 15 bits are examined.) The area transferred should not normally include the subroutines themselves or location O. The subroutines are not designed to read over themselves. Since each block writt~n contains its own checksum, the area read need not be the same as that written. For example, if the user requested that locations 1000-3777 be written beginning with block 100, he could at some future time request that locations 2000-2777 be read beginning with block 102. *The number of the block being searched -for can be found in the register called MMBLKM. The block mark number last read can be found in the location whose address is contained in MMWA 1, (i.e., it has been stored with a DAC I MMWA 1 instruction). **The block number last read can be found in the location whose address is contained in MMWA 1, {i .e., it has been stored with a DAC I MMWA 1 instruction}. Digital-7-22A-I/O Page 5 Any number of words may be transferred. If a nonintegral number of blocks is specified, the following takes place: If reading, the correct number of words wi II be deposited in memory and the remainder of the last block wi II be read but not deposited in order to verify the checksum. If writing, the remainder of the last block wi II be fi lied with +O's and a correct checksum wri tten • 4.2.7 As soon as searching starts, the subroutines return to the register marked "return" with the interrupt enabled. Ifnecessary, this allows the programmer to continue processing while both the searching and data transfer takes place. In terms of usable programming time, the user has approximately 200 msec + 53 msec per block searched + 35 msec per block transferred which can be used after the subroutines are initially called. The register named MMDONE is set to a +0 after each block mark is passed and to -0 when the data transfer is complete or if an error occurs. This allows the user three possible ways of determining when the transfer has been completed: l. ISZ MMDONE JMP? /NOT DONE 2. LAM SAD MMDONE JMP? /DONE 3. LAC SNA JMP? /NOT DONE ETC. Method 1 has the advantage of not destroying the accumulator. However, if for any reason the DECtape data flag did not occur as it should, the ISZ would skip incorrectly after approximately 1.4 sec. If the user should call the DECtape subroutines before a previous DECtape transfer has been completed, the subroutines will remain in a wait loop and not return to the main program until the first transfer has been completed and the second has begun. It sometimes is necessar}' to determine what is the next forward block number on the tape, after the information just transferred. The following sequence of instructions places the correct block number in the accumulator: LAW 61 SAD MMWA3 /SEARCH BACK COMMAND /LAST COMMAND ISSUED JMP------------------------------~) LAM -2 TAD I MMWA1 /TO SUBTRACT 3 /ADD CURRENT POSITION J ( 4.3 LAC MMBLKM ADD (1) Switch Settings None /BLOCK SEARCHED FOR Di Si to 1-7-22A -1/ 0 Page 6 4.4 Start Up andlor Entry See Section 4.2, Calling Sequence 4.5 Errors in Usage Only one HLT exists in the subroutines: HLT Location MMERRX+1 5. Procedure Meaning Error return parameter was not 'a JMP~ instruction and an error occurred. Type 'of error is indicated by' the number in the accumulator. (See Section 4.2.3) Correct the calling sequence to prov'ide a JMP instruction for the error return. RESTRICTIONS None except those mentioned in the preceding paragraphs. The standard tape format of 1100a usable blocks of 400a words each must be used. 6. DESCRIPTION 6. 1 Discussion The subroutines attempt to make variable length DECtape data transfers as easy and efficient as possible. They are completely self-contained, include only one possible error halt, indicate all possible errors which can occur, and allow fastest access to the DECtape itself. The last is accomplished by keeping track of the current position of ~ach DECtape drive being used, calculating the effective starting and ending block numbers of the transfer requested, and starting the search in the direction causing the least number of turnaro~nds. Thus the direc,tion of the data transfer is predetermined before the tape is started and does notdeperid on the.first block actually re'ad during searching. If the tape is currently sitting within the area to 'be used by the data transfer, the ultimate transfer direction will be determined by which end of the DECtape area is nearest. The current position of the tape is always assumed to be the last b10ck number read ±3 blocks depending on the direction of the last transfer. Initially a II tapes are assumed to be sitting at block number 3. The main thing to remember is that the user 'need never worry about the actual directiontransfer of the data since data always appears in memory or on tape ~s if it were transferred in the forward direction. For example, assuming the user has requested that locations 1000 through 1477 be written beginning at block 100, the tape appears as follows irrespective of the direction in which it was written: ~<--BLOCK 100--~) < 1 o o o Locations 1000 - 1377 ( > BLOCK 101 ) ) ~ Locations -? ~300a Filler Word> 1400 -·1477 " of +0 11 34 70 70 1 4 7 7 Di gi ta 1-7-22A -1/0 Page 7 If the data is transferred in the forward direction, the core locations are written first in ascending order followed by 3008 filler words. If the data is transferred in reverse, 3008 filler words are written first followed by the core locations in descending order. In either case, the end result is the same, and the technique is applicable to both reading and writing.* 6.2 Examples The search routine has been rewritten:' to 'allow four different entrances: 1. Start the tape in the forward direction and 'exit when the correct block is . found in the forward direction. 2. Start the tape in the reverse direction and exit when the correct block is found in the reverse direction. 3. Start the tape in the forward direction and exit when the correct block is found in the revers.e direction. 4. Start the tape in the reverse direction and exit when the correct block is found in the forward direction. In the following example assume the tape is sitting at the locations indicated by the letters shown, and a request is made to transfer 20018 words beginning at block 100: 76 177 I 100 ~ \. 101 I 102 I 103 ~ ~ 104 105 ~. 106 ~ .. ) y Actual area used by the data tran~fer Case A Block 77 or less Case B Closest to initial block Case C Equidistant from start or end· Case D Closest to final block Case E Block 105 or more 7. The program will use entrance 1 The program will use entrance 4. The program will use entrance 4 The program will use entrance 3 The program will use entrance 2 METHODS See Description, Section 6. 8. FORMAT (Not Applicable) 9. EXECUTION'TfME (Not Applicable) *Should it ever become necessary to determine,which way a block on tape was actually written, the following method can be used. If written in the forward direction, a checksum of -0 will appear at the front of the block (the end near the preceding lower-numbered block). If wrfttenin reverse, the -0 checksum will be at the end of the block near the next higher-numbered block. Digitgl-7-22A-I!O Page 8 10. PROGRAM 10.4. Program LJsting PDP-? DEnTAPE SUBROUTINES IASSUMES STANDARD 400 (OCTAL) WORD BlOCKS ILM~ JANUARy 21, 1966 IUISMlS MUST ~E DEFINED AS JMP TO DISMISS INTERRUPT I~I~"I~ECTrONAl RO~T!NE IPDP.7 D£C",TAP£,S£ARCH suSRQUTINE MMW~:11701504 MMLC=7076riJ4 MMS!::11701644 MMRSII107612 MMDF'1I107501 M1'-1.8 F' II 1016" 1 MME:F'·707541 I'o1 MR O=107512 SKP7.703341 ASC.105502 E:PI.1i?J0044 O~R.'0!S6r211 l£'M.?07704 EEM.?07102 EMIR·707742 ILEAVE MMSC~R, I~ SEAHCH REVERS£ MODE, START REV£RS~ LAW 41 IS~ARC~ FWD OAC MMwAJ CLA JMP IS,T CURR!NT DIRECTION MMSC~8 ILEAVe: IN SEAHCH R~VERSE MODE, START FORWARD LAW A1 IS'ARC~ REVERSE JM.p MMSCIo!R+l' ILEAVE IN SEARCH FORwARD MODE, START REVERSE MMSr:R, LAW IS'ARC~, FORWARD MMSR~, 4, SKI=' ILEAVe: IN SEARCH FORWARD MODE, START FORWARD MMSOH~h LAw 61 DAC MMWA3 LAM DAC MMSSl( TAO (1) DAC MMSFI( LAW MMF.:RS OAC MMERR LAW MMOATS ,OAe MMDATA LAC MM8L.I<M ADD MMEK , SMA ISFARCH R!VERSE, USED AS CONSTANT IS~T CURRENT D!R£OTION IL6AD .0, ust~ AS CONSTANT Digital 7-22A-I/O Page 9 JMP MMSCl-l5 LAM -, DAr, MMSUM 135 1F't"lRMAT ERROR IC~G 0' DyRECTION COUNTER MILLtSECnND SELECT DELAY LOOP MMWAtT. MMW2. MMRS AND (4010) SZA IS4VE OONTROL TyPe: ONLY JMP MMSC~9 LAC ~1MCHK 1..01 SAn MMSEL JMP MMSC~9+1 DAC MMSEL CLA MMSE LAM DECIMAL -5000+1 OAC MMBL..F' INn DELAY FOR NEW DRIVES IPTCK uP SELEOT IP~EVIOUS SEL£OT ISAME SELECT IS~VE sELECT IUsED AS cONSTANT IS~LECT UNIT ,ERO OCTAL IT~MPORARy SToRAGe: AREA 11 MICROSEOONDS PER LOOP ICnUNT 35 MILLISEcONDS I u~, ITS ELEO TION IS' I .'" \.JMP ..... 1 LAC MMCHK1+1 MMSE LAC (NOP) DAC MMSAVE LAC MMAPtI SZA JMP MMAPt ON ApI INDICATOR IOn ION IP NOT ON API ITuRN nN API ID,.CTA~E I O~I tSz MMSUM SKI' JMP MMER)(2-1 LAC MMWA3 )(OR (2('1) MMLC MMSAVE, DAe MMWA3 SAO MMSCIo4Q1 JMP MMREV LAC MMCK3 OAe MMSC Io4 2 LAC MMBLKM TAn MMSFK OAe MMWA2 nZM M.. MOONE: NOP LAC MMR0:58+1 nAC MMSAVe: I'S2 MMWA F.:MIR JM'P J MM \tJ A LAC MMCK2 OAO MMSC~2 LAC MM9L.KM TAO MMsBK: JMP MMSAVE"!!2 INOT FOUND ICURRENT SELEoT ICnMPL£MENT DIREOTION IS,ARCH IN CORRECT DIRECTION ISAVE qELECTlnN ILAW 6, IS~T UP REVERSE O~NSTANTS IS~A, SET TO OONTtNUE IN FORWA~D I~ OCK DtREcTInN TO LOOK FOR IN THIS DIRECTION IO~ Dl~MIS IOtSMIS I!MDEX POyNTER IR,TURN TO MAIN PROGRAM ISpA. SET TO OONTrNuE IN REVERSE DyR£cTInN Di9ital~7-22A-I!O Page 10 11NSTRUOTION~ ~OR MMAP!, AUTOMATIC PRIORITY INT~RRUPT LAC MMAPIC IO~CTApE C~ANN!L NUMBER rpt IENABL~ ApI IENA8L~ DECTA~£ ASC JMP MMTURN IROUTINp':S TO ANSWER INTERHUPT MMRS C~ANNEL SEQUEN~E MMER~, ANO (4r7J~00) SZA ' JMP MMTURN LAW 300 EaT BIT IC~ECK IEffT, TURN AROUND INON-EOT ~RROR CURING SEARCH .IMP MMERx2 MMRD OAC r M"MWA1 SAn MMWA2 JMP MM~CI-!3 OMA ' ADD MMW,A2 SMA JM? .JM? SAD JMP JMP LAw ,JMP MMSAVE",1 MMTURN MMRL.KM t MMCHK ~'fMTUR;N lOR SPA rOR R~VERsE IKrrEP GOING ITtlRN AROUND IE~IT TO READ OR wRITE ROuTINES '0(}1 MM£RX2 IFnRM'AT DECIMAL -576 OCTAL ERROR It::RROR LOOP LAI.I 20~ OAC MMRLF' MMRS MMRSA JMS MMROLL LAr. MMERRX AND (20000) INOr" FOUND ISTORAGE AREA DAC SZA ~MtR IA~D ~OLL CONSTANT IJMP IJMP MME~RX, CLC DAC MMDONE LAC MM8LI=' MMLC JMP • MMSEL, PI MME~R, C'I IE~ROR r7J ID4TA RETuRN ISf'OCKFLAG RETU~N INORMAl DECTAP[ C~ANNEL.3 IPnSITtON OF' UNIT f< IPnSITrON OF UNIT 2 IPnSITrON OF UNIT 3 IPnSITrON OF UNIT 4 IPnSITrON Or UNIT 5 IPnSITtO N OF UNIT 6 MMDATA, MM8L~, MMAI)TC, MMWA)(, I-ILT ~ (0000 3 3 3 3 3 3 ISTORAGE AREA IERROR EXtT WAS NOr A JMP INSTRUCTION IS AvE sELECTION 'RETURN Digital-7-22A-I/O Page 11 IPoSITrON OF UNIT 7 IPnStTYON OF UNIT .0 IINTF:RLOCI( L~OP, HANGS UP MAIN PROGRAM UNTIL GO~0 IUcqED ~ORMMSUM '" LEM IL~AVE EXTEND MODE MMRS IG~T STATUS AND (4~0QJ) IC~ECK GO BIT SZA INOT GOING? JMP ."3 IWAIT JMP I MMITLK ISvSTEM AVAILABLE MMITlK, I~OOP TO ADD ROLL CON~TANT TO CURRENT ADORESS MMROLL, r2I IU~ED AS WORK AREA, MMSBK LAC MMWA3 ILAST SEAROH OOMMAND AND (2GO ISAVE olREOTloN BIT SZA IGnING FORWARD LAM .. 5 ADO ( :3 ) TAD MMWA1 ITn CREATE LAM .2 IRnLL OONSTANT lAnD CURRENT cOCATloN ISTORE CURRENT LOr-ATION MMwA1 OAC JMP t MMROI.L ICOMMON ROUTTN~ ,OR PICKTNG UP CONST!NTS AND SEARCHING IPI~K MMCHK, U~ PARAM£TF.Rs Q! 'J(CT I MMWA AND (,'71) IBLOCK NUMBER ['lAC MM8L'<M ISAVE ~LOOK NUMBER It~DEX POYNTER TO ERROR RETURN IE~ROR RETURN IS! MMWA LAC r MMWA OAC MMERRX ISl MMWA LAC I MMltJA AND (,,000Q1) OAC RCl RTl MMr.H~1"" RTL RTL ADO (MMWAX.1) OAC MMWA1 I I M SEA RCH ,E X r T IIMDEX POINTER TO UNIT IU~11 T IKP-'EP uNIT ONLY lIN CALLING SrQuENCE ICj'EAR ANO ROTATE LINK IPIIT U~IIT NUMBER IN L..o,PoSITION IAnDREss OP POSITION POINTEH lr:nR TSZ MMWA LAC I MM\Io1A ANn (71717) OAC MMAODR ISZ MMWA lions UNIT IINDEX POrNTER TO STARTING ADDRESS ISTARTYNG-ADD~ESS 11~ BIT ADDREsS ILnCATrON POINTER IINDEX POINTER TO ENDING-ADDRESS ICAU'lULATE NuMBER OF' DATA AND FILLER WaRns LAC J MtvlwA IFINAL. AOnRE9s ANn (,'77,) /t~ 81T ADDREsS CMA ADD M~1AUDR SMA JMP MMSCH5 OAC MMWDC ISTARTING ADDRESS III LEGAL I "'~'O. OF F-'ORMAT DATA WQRnS., Disital-7-22A-I!O Page 12 ILnW ORDER 8 elTS IMAKE NUMBER NEGATIVE AND (377) VOR (777400) TAn (377) CMA DAe MM2C~ I~~O DAC MMFILC IS,CTION OOUNTER LAC MM .. ~LKM "lei OOK LAM -, ,CALCULATE T~~ DtRECTION TO SEARCH 0' F!LLtR WORDS., DESIRED SI'JA MMCi( , , JMP MMSC~5 CMA, ADD t MMI'jA1 1810CK 0, FORMAT ERROR ICuRRE~!T JMP ~OSlTION HIG H~ R T~ AND e: SIR E1) BL0 CIe AND TRANSFER DATA FORwARD ~OTSTA~CE TO START BLOCK I-NUM8€R of DATA WORDS., INUMBEQ 0, DATA woROS!I!I1 IKPE~ NUMBER 0' BLOCKS.1 I D, V,I D£ 8 V 400 0 eTA L I CI) RREN T P,O SIT rON SPA MM~F IS~ARC~ OAe MMWA5 lAr MM .. ~OC CM~vC:LL ANn (717 4 00) RT ~ RTR RTR RTR ADn ~~MqLI(M OAC ISTARTING BLOCK ILAST BLOeK MMWA7 eMA ADD I ICIIRRE~IT MMl~A 1 qMA JMP MMGH2 Mt'>1C-< " wrTHTN TRANSFER sECTrON AND TRANSFER DATA!N REVERSE IDySTANCE TO sTA~T BLOOK ./START IN REVERSE. TRANSFER DATA FnRwARD ISTART FWo, TRANS~ER DATA IN REVERSE ,/S~ARC~ ADD MMIAIA15 SM~ JMP /STA~T I~ REvERS~, M~lGH TRANS~ER LAw MlI'1SFR pOSITION ICIIR.REt\IT ~OSITION Is DATA FORwARD SKP ISTA~~ A~O TqANSFER DATA FORWARD LAW MMSCH0 CAe MMWA~ IS~T u~ S~ARCH EN~RANCE LAC (1) nAC MMDK LAC (DAO I MMAODR) -/FnR IMCRe:MENTING AODRESS IS!T READ ROUTINE OAC MMRD;~ ISTA~T SEARC~ MMC~K'j LA~ (LAC I MMADDR) DAr. MMW~3+1 JMP I MM0A5 9! IS~T ~RIT[ ROuTIN~ IT~ SEARCH IUNIT AND WORK AR~A MMWA2 Digital-7-22A-I/O Page 13 ISTART ~ORWARU, MMG~. TRANRFER DATA IN REV~RSE LAW MMSRF SKP ,START AND TRANSFER DATA IN REVERSE MMGR2, LAW MMSCHR OAC MMI,JA5 LAM OAC MMDI'ii LA("! MM2CN SZAVCMA ADO (1) ITn DEcREMENT AOD~ESS IF'TLL.ER COUNTJ::R I+~ IF THERE ARE NO FILLERS OAC MMADDR IEMOING ADDRE~S IDATA LOCATION POyNTER LAC MHWA? IS~ARCH ADD I MMl~A [lAC MM~L.K~1 LAC MM2QN FOR LAST eLOCK SNA JMP MHr;R~ MMWA6 LAC MMWUC nAt; INr'l FILLERS IEvCHANGE MMWnC AND MM2CN DAC MM2CI\1 LAC MMwA6 nAC MMWDC LAC (NOP) nAC MMPD3 IFnR FtLL[RS TN ~o ROUTINE LAC MMW2 ,FOR FILLERS IN wRtT£ ROUTINE, CLA ~JMP MMCHK 1 ~ 1 tSl MMF'lLC JMP MMGF2 IUEC'TAPE SU8ROUTINE~ READ PDP-' IFORMAT JMS MMRuS I LAw 8 IO~ LAC (8), BLOCK NUMBER I JMP )( IE~ROR RETURN I ZZ0000 IU"IT SELE:CTlnN 01 11~-BIT CoRE STARTING ADDRESS I r.2 11~-BIT CORE ~NDtNG ADDRESS, INCLUSIVE I MULTI-PROGRAM RETURN , MMRDS, til •./MS MM r TLK LAC MMROS IC~ECK DAC MMI,./A ISTORE POrNTER TO ARGUMENTS IG~T ARGUMENT~ ANn sEARCH JMS MMCHK wITH ~LOCK FOUND LAW MMRU1 IS,T UP IP SYSTEM rS IRETURN PROM S£ARC~ MMR00, DAC f"iME:RR LAi.J MMRU4 ITAC MM8LF XCT MMWA3 IS'ARC~ ADn (,) IM~KE ~EAD MMLC LAw MMRU1A DAe MMOATA nZM MMDONE DISMIS INTERRU~T COMM4ND COMMANn FR~E RETURNS ,Di9itol~7"'22A-,J/o , Page 14 MMRD', LAI,.J IE~ROR FL~G 4Q)0! DUR1NG REAbING JMP MMEH)t2 MMRD CAe MMSUM REVERSE CHEcKSUM IR~AD LAW MMRD2 CAe MMOATA nISMtS 1 MMRD EEM ,. MM"AOOR'~' ' DAr. LEM JMS ~1MRU6 IS?' MM .. FtLC ~'MP MM~O'~,' LAC (f\io'P,< -MMRI)4, OAC MMRD3 OISMtS MMRO IREAD DATA , 1 E'" A8 L I=.: E ~ TEN ne: D MEMO RV IOQ NO'P IDTSAaLE EXTENDED MEMORy ICALCULATe: CHECKSUM Is~CTI'nN IS~~ ID~ OOUNTER UP FoR S~CTrnN NOT STORE REMAINDER AS OONSTANT IUqED IR~AD ~ORWARD OF SLOCK CHEcKSUM ADn MMSUM SAn 'MMSCIoIS .. l ,JMP ,+3 LAW JMP ~00 MM~AX2 ISUM CIoIECI< READING \JM~ MMQLC ,JM? MMRO!71 IC~ECK NExT BLOCK IR~AO t\IEXT BLnCx LAC 12'tDS~CTt ON cOUNTER' INn FILLERS IS~T Up WoRD ~OUNTE~ M'M .. 20N NUMB£R SNA JMP MMRD3A OAr MMWUC LAr. (Ole I MMADDR) ~An 1'-1MRD3 ,JMp MMRD3S .. ' .. IMP MMRD,~8 Tn CHECK:oUM M~RO~., A I ADD lSTORE Nap lSTORE DAO I N~TRUeT ION AND I NCR t:MEN T- 'OR 'DEI"!REM ENT ADDRESS IO~EDAS ~ORK AREA' MMWA5 ADn MMSUM IPQEVlnUSCALoULAT16~ DAr ISTORE NEw RE~ULT ICIIRRE"JT AODRE'SS 1+1 OR -, MM~UM LAr. MMAOOR TAn MM11K' OAr MMAUO~ IN~W AnDR~SS J 51:, 'MMI.' DC I wnR 0 JMP t MMRD6 IC~ECK nISMIS LA\,.J MMQLC2 OAf'! ~MnAT,A 'leeT MM\.IA:3 cOUNTER FOR FILLERS ETC. IUqED AS wORK AREA- MMSFK IS~T DATA FLAG RETURN COMMANO IS~ARC,", M~1L C nISj~ts LAf'! t ~MWA1 TAD MM .. DK I CIIRREN T aLO CK NUMB'ER 1+. OR -1 nAc I IN~W MMRO MM~vA 1 I BLOCK NUM8ER Digital-7-22A-I/O Page 15 SAn t Ml"lWA 1 ICnMPARE TO CORRECT NUMBER .JMP • +3 l,.A\4 700 ,.1 M~ MMf: R)( 2 18LOCt( MARK ERROR LAC IsrCTlnN COUNTER MM~lL.C SZA J M,P I MM8 L r. IR~TURN FOR Nr.~T eLOCK ISTOP THE TAPE: lAnD ROLL CONSTANT 'MMLC ,JMS MMROLL CLe DAr.: MMDONg. IUEC.T~PE IFORMAT I I I I I I DI~MIS WRyTE SUBROUTINE, IS~T pop-, JMS MMWHS LAW B JMP X lOR LAC (8), BLOCK NUMBER 1e:~ROR RETURN I U~I ITS ELe: CT I (') N 11~-8IT CORE STARTING 2Z0fOPJ0 C1 C2 MUtT! "pRr)(~RAM DONE SWITOH RETURN ADDRE~S 11~-BIT ENDING AOnRe:SS,INCLUSIVE IC~ECK IF SYSTEM t2! ,-JMS .JM~ IRETURN MMWR1, MM I TLK MMCHK IS FREE IPTCK uP ARGUMENT!=; AND SEARCH ~ROM Se:ARC~ wITH dLOCK FnUND LAW MMWR2 ISrT UP INTERRUPT RETURNS DAC MMERR LA!"} t-1MwR4 DAC MM~LF' LAW MMWR3 DAe MMDATA nZM MHOONe: OLe DAC MMSUM ISTART CHrCKSUM XCT MMWAJ ISpARC~ COMMAND ADD (2, IC~EAT£ WRITE COMMAND MMLC MMWR?, DISMtS LAW 600 IE~ROR FLAG DURING WRITING ,}MP MMERX~ MMWR~, EEM IE~A8LE LAC t MMAODH IO~ ExTENnED MODE LEM IDTSABLE EXTEND MoDE CLA ~MwR MMWR~8, JMS MMRD6 rSl MMFILc JMP MMWH~ LAC MMW2 nAC M~wR3+1 MMWR4, LAC MMSlJM MMWR'A, ICALCULATE CHEOKsuM ISrcTI"N COUNT~R ISrT UP FOR 2ND S£CTION ICI A nI~Mts IW~ITE CHE:CKSUM CMi\ MMWR JM~ JM~ MMRLC MMWA, IcwECK NExT SlOCK NUMBER Di Si tal-7~22A-I!O Page 16 LAC ·MM2CI\I SNA JMP MMW~3A DAC MMWJ)C LAC (LAC I MMADDR) MMWH3+, JMP MMWHJ8",t JMP MMWRJ8 SAD MMWA~=M~SAVE MMWAC;=M~R06 MMWA~,M~RDS ~~MSF'K=Mr.1AL.C MMWA?=MMCHK1.' MMS8K=M~ROLL. MMWA=MMWRS MMSUM=M~tTLK MMwA1.M'1SUM MMRS A• MM~-R R SlA~T 11. DIAGRAMS 11. 1 Flow Cha~ts FROM THIS POINT ALL ITEMS ARE DONE IN THE INTERRUPT SERVICE ROUTINES WHICH ARE OVERLAPPED WITH THE RUNNING OF THE MAIN PROGRAtot. Gross DECtape Subroutine Digital-7-22A-I/O Page 17 Read Routine Di 9ito 1-7-22A -1/0 Page 18 MMRD3 SWITCH I MMRD2 READ WORD. TURN ON EXTEND MODE Read Routine (continued) Di gi ta 1-7-22A -1/ 0 Page 19 PICK UP ERROR CODE 711l11l STOP TAPE. SET DONE INDICATOR Read Routine {continued} Di gital-7-22A-I/O Page 20 PICK UP ERROR CODE 7(11(11 Write Routine Di gi ta 1-7- 22A-1/ 0 Page 21 PICK UP ERROR CODE 6'" SAVE DECTAPE STATUS MMWR3+1 ~ LOAD CORRECT WORD FROM MEMORY Write Routine (continued) STOP TAPE. SET DONE INDICATOR Digital-7-22A-I/O Page 22 MMCHK CALCULATE LAST BLOCK AND SAVE SET TO ENTER SEARCH ROUTINE TO ...-----1 START IN REVERSE BUT TRANSFER FORWARD (MMSFR) Common Routi ne to Pi ck Up Parameters and Initiate Searching Di gi ta 1-7-22A -1/ 0 Page 23 EXCHANGE DATA WORD COUNT WITH FILLER WORD COUNT SET SWITCH I IN READ ROUTINE TO NOP Common Routine to Pick Up Parameters and Initiate Searching {continued} Digi ta 1-7-22A -I/O Page 24 SEARCH FORWARD TRANSFER IN REVERSE SEARCH AND TRANSFER IN REVERSE MMSH5 PICK UP ERROR CODE 100 Search Routine SEARCH IN REVERSE TRANSFER FORWARD SEACH AND TRANSFER FORWARD Di gi ta 1-7-22A -1/0 Page 25 PICK UP ERROR CODE 30'" ENABLE API ENABLE CHANNEL YES SET SWITCH 3 TO CONTINUE IN REVERSE DIRECTION ADD SEARCH - - -__ ~~:~~~TgO:~~~~~ ......--~ AND SAVE AT MMWA L..._ _--._ _ _- ' Search Routine (continued)
Home
Privacy and Data
Site structure and layout ©2025 Majenko Technologies