Source Code
These source-code files were transcribed from a printout in Don Eyles's personal
collection, scanned by archive.org, and financially sponsored by Mike Higgins.
A team of volunteers performed the transcription and proof-reading. Note
that the scanned page images are available at
the Virtual AGC Project website, as well as higher-quality (but much larger)
images at
the Virtual AGC Project's section on archive.org. Report any problems by creating
"issues" at
the Virtual AGC Project's GitHub Repository. Notations on the program listing read, in part: YUL SYSTEM FOR BLK2: REVISION 0 OF PROGRAM RETRED44 BY NASA 2021100 JUL 9, 1965Note that the date is the date of the printout, not the date of the program revision. |
003695,000002: ## Copyright: Public domain.
003696,000003: ## Filename: INTER-BANK_COMMUNICATION.agc
003697,000004: ## Purpose: Part of the source code for Retread 44 (revision 0). It was
003698,000005: ## the very first program for the Block II AGC, created as an
003699,000006: ## extensive rewrite of the Block I program Sunrise.
003700,000007: ## This file is intended to be a faithful transcription, except
003701,000008: ## that the code format has been changed to conform to the
003702,000009: ## requirements of the yaYUL assembler rather than the
003703,000010: ## original YUL assembler.
003704,000011: ## Reference: pp. 105-106
003705,000012: ## Assembler: yaYUL
003706,000013: ## Contact: Ron Burkey <info@sandroid.org>.
003707,000014: ## Website: www.ibiblio.org/apollo/index.html
003708,000015: ## Mod history: 2016-12-13 MAS Created from Aurora 12 version.
003709,000016: ## 2016-12-17 MAS Transcribed.
003710,000017: ## 2016-12-27 RSB Proofed comment text using octopus/ProoferComments,
003711,000018: ## but no errors found.
003712,000019:
Page 105 The log section name, INTER-BANK COMMUNICATION, is circled in red. |
003715,000022:
003716,000023: # THE FOLLOWING ROUTINE CAN BE USED TO CALL A SUBROUTINE IN ANOTHER BANK. IN THE BANKCALL VERSION, THE
003717,000024: # CADR OF THE SUBROUTINE IMMEDIATELY FOLLOWS THE TC BANKCALL INSTRUCTION, WITH C(A) AND C(L) PRESERVED.
003718,000025:
003719,000026: 4063 SETLOC ENDINTFF
003720,000027:
003721,000028: 4063 52120 BANKCALL DXCH BUF2 # SAVE INCOMING A,L.
003722,000029: 4064 50002 INDEX Q # PICK UP CADR.
003723,000030: 4065 30000 CA 0
003724,000031: 4066 24002 INCR Q # SO WE RETURN TO THE LOC. AFTER THE CADR.
003725,000032:
003726,000033: # SWCALL IS IDENTICAL TO BANKCALL, EXCEPT THAT THE CADR ARRIVES IN A.
003727,000034:
003728,000035: 4067 54001 SWCALL TS L
003729,000036: 4070 22004 LXCH FBANK # SWITCH BANKS, SAVING RETURN.
003730,000037: 4071 76425 MASK LOW10 # GET SUB-ADDRESS OF CADR.
003731,000038: 4072 56002 XCH Q # A,L NOW CONTAINS DP RETURN.
003732,000039: 4073 52120 DXCH BUF2 # RESTORING INPUTS IF THIS IS A BANKCALL.
003733,000040: 4074 50002 INDEX Q
003734,000041: 4075 02000 TC 10000 # SETTING Q TO SWRETURN.
003735,000042:
003736,000043: 4076 56120 SWRETURN XCH BUF2 +1 # COMES HERE TO RETURN TO CALLER. C(A,L)
003737,000044: 4077 56004 XCH FBANK # ARE PRESERVED FOR RETURN.
003738,000045: 4100 56120 XCH BUF2 +1
003739,000046: 4101 00117 TC BUF2
003740,000047:
003741,000048:
003742,000049:
003743,000050: # THE FOLLOWING ROUTINE CAN BE USED AS A UNILATERAL JUMP WITH C(A,L) PRESERVED AND THE CADR IMMEDIATELY
003744,000051: # FOLLOWING THE TC POSTJUMP INSTRUCTION.
003745,000052:
003746,000053: 4102 56002 POSTJUMP XCH Q # SAVE INCOMING C(A).
003747,000054: 4103 50000 INDEX A # GET CADR.
003748,000055: 4104 30000 CA 0
003749,000056:
003750,000057: # BANKJUMP IS THE SAME AS POSTJUMP, EXCEPT THAT THE CADR ARRIVES IN A.
003751,000058:
003752,000059: 4105 54004 BANKJUMP TS FBANK
003753,000060: 4106 76425 MASK LOW10
003754,000061: 4107 56002 XCH Q # RESTORING INPUT C(A) IF THIS WAS A
003755,000062: 4110 50002 INDEX Q # POSTJUMP.
003756,000063: 4111 12000 TCF 10000
003757,000064:
Page 106 |
003759,000066: # THE FOLLOWING ROUTINE GETS THE RETURN CADR SAVED BY SWCALL OR BANKCALL AND LEAVES IT IN A.
003760,000067:
003761,000068: 4112 36425 MAKECADR CAF LOW10
003762,000069: 4113 70117 MASK BUF2
003763,000070: 4114 60120 AD BUF2 +1
003764,000071: 4115 00002 TC Q
003765,000072:
003766,000073: # THE FOLLOWING ROUTINE OBTAINS THE TWO WORDS BEGINNING AT THE ADDRESS ARRIVING IN A, AND LEAVES THEM IN
003767,000074: # A,L.
003768,000075:
003769,000076: 4116 54001 DATACALL TS L
003770,000077: 4117 22004 LXCH FBANK
003771,000078: 4120 22121 LXCH MPTEMP # SAVE FORMER BANK.
003772,000079: 4121 76425 MASK LOW10
003773,000080: 4122 00006 EXTEND
003774,000081: 4123 50000 INDEX A
003775,000082: 4124 32001 DCA 10000
003776,000083:
003777,000084: 4125 56121 XCH MPTEMP
003778,000085: 4126 54004 TS FBANK # RESTORE FBANK.
003779,000086: 4127 30121 CA MPTEMP
003780,000087: 4130 00002 TC Q
003781,000088:
003782,000089: 4131 ENDIBNKF EQUALS
End of include-file INTER-BANK_COMMUNICATION.agc. Parent file is MAIN.agc