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, 1965
Note that the date is the date of the printout, not the date of the program revision.

003694,000002:                                                                                                  ## Copyright:   Public domain.
003695,000003:                                                                                                  ## Filename:    INTER-BANK_COMMUNICATION.agc
003696,000004:                                                                                                  ## Purpose:     Part of the source code for Retread 44 (revision 0). It was
003697,000005:                                                                                                  ##              the very first program for the Block II AGC, created as an
003698,000006:                                                                                                  ##              extensive rewrite of the Block I program Sunrise.
003699,000007:                                                                                                  ##              This file is intended to be a faithful transcription, except
003700,000008:                                                                                                  ##              that the code format has been changed to conform to the
003701,000009:                                                                                                  ##              requirements of the yaYUL assembler rather than the
003702,000010:                                                                                                  ##              original YUL assembler.
003703,000011:                                                                                                  ## Reference:   pp. 105-106
003704,000012:                                                                                                  ## Assembler:   yaYUL
003705,000013:                                                                                                  ## Contact:     Ron Burkey <info@sandroid.org>.
003706,000014:                                                                                                  ## Website:     www.ibiblio.org/apollo/index.html
003707,000015:                                                                                                  ## Mod history: 2016-12-13 MAS  Created from Aurora 12 version.
003708,000016:                                                                                                  ##              2016-12-17 MAS  Transcribed.
003709,000017:                                                                                                  ##              2016-12-27 RSB  Proofed comment text using octopus/ProoferComments,
003710,000018:                                                                                                  ##                              but no errors found.
003711,000019: 

Page 105 The log section name, INTER-BANK COMMUNICATION, is circled in red.

003714,000022: 
003715,000023:                                                                                                  #           THE FOLLOWING ROUTINE CAN BE USED TO CALL A SUBROUTINE IN ANOTHER BANK. IN THE BANKCALL VERSION, THE
003716,000024:                                                                                                  #  CADR OF THE SUBROUTINE IMMEDIATELY FOLLOWS THE  TC BANKCALL  INSTRUCTION, WITH C(A) AND C(L) PRESERVED.
003717,000025: 
003718,000026:    4063                                           SETLOC   ENDINTFF                              
003719,000027: 
003720,000028:    4063           52120        BANKCALL           DXCH     BUF2                                  #  SAVE INCOMING A,L.
003721,000029:    4064           50002                           INDEX    Q                                     #  PICK UP CADR.
003722,000030:    4065           30000                           CA       0                                     
003723,000031:    4066           24002                           INCR     Q                                     #  SO WE RETURN TO THE LOC. AFTER THE CADR.
003724,000032: 
003725,000033:                                                                                                  #           SWCALL IS IDENTICAL TO BANKCALL, EXCEPT THAT THE CADR ARRIVES IN A.
003726,000034: 
003727,000035:    4067           54001        SWCALL             TS       L                                     
003728,000036:    4070           22004                           LXCH     FBANK                                 #  SWITCH BANKS, SAVING RETURN.
003729,000037:    4071           76425                           MASK     LOW10                                 #  GET SUB-ADDRESS OF CADR.
003730,000038:    4072           56002                           XCH      Q                                     #  A,L NOW CONTAINS DP RETURN.
003731,000039:    4073           52120                           DXCH     BUF2                                  #  RESTORING INPUTS IF THIS IS A BANKCALL.
003732,000040:    4074           50002                           INDEX    Q                                     
003733,000041:    4075           02000                           TC       10000                                 #  SETTING Q TO SWRETURN.
003734,000042: 
003735,000043:    4076           56120        SWRETURN           XCH      BUF2       +1                         #  COMES HERE TO RETURN TO CALLER. C(A,L)
003736,000044:    4077           56004                           XCH      FBANK                                 #  ARE PRESERVED FOR RETURN.
003737,000045:    4100           56120                           XCH      BUF2       +1                         
003738,000046:    4101           00117                           TC       BUF2                                  
003739,000047: 
003740,000048: 
003741,000049: 
003742,000050:                                                                                                  #           THE FOLLOWING ROUTINE CAN BE USED AS A UNILATERAL JUMP WITH C(A,L) PRESERVED AND THE CADR IMMEDIATELY
003743,000051:                                                                                                  #  FOLLOWING THE TC POSTJUMP INSTRUCTION.
003744,000052: 
003745,000053:    4102           56002        POSTJUMP           XCH      Q                                     #  SAVE INCOMING C(A).
003746,000054:    4103           50000                           INDEX    A                                     #  GET CADR.
003747,000055:    4104           30000                           CA       0                                     
003748,000056: 
003749,000057:                                                                                                  #           BANKJUMP IS THE SAME AS POSTJUMP, EXCEPT THAT THE CADR ARRIVES IN A.
003750,000058: 
003751,000059:    4105           54004        BANKJUMP           TS       FBANK                                 
003752,000060:    4106           76425                           MASK     LOW10                                 
003753,000061:    4107           56002                           XCH      Q                                     #  RESTORING INPUT C(A) IF THIS WAS A
003754,000062:    4110           50002                           INDEX    Q                                     #  POSTJUMP.
003755,000063:    4111           12000                           TCF      10000                                 
003756,000064: 

Page 106

003758,000066:                                                                                                  #           THE FOLLOWING ROUTINE GETS THE RETURN CADR SAVED BY SWCALL OR BANKCALL AND LEAVES IT IN A.
003759,000067: 
003760,000068:    4112           36425        MAKECADR           CAF      LOW10                                 
003761,000069:    4113           70117                           MASK     BUF2                                  
003762,000070:    4114           60120                           AD       BUF2       +1                         
003763,000071:    4115           00002                           TC       Q                                     
003764,000072: 
003765,000073:                                                                                                  #           THE FOLLOWING ROUTINE OBTAINS THE TWO WORDS BEGINNING AT THE ADDRESS ARRIVING IN A, AND LEAVES THEM IN
003766,000074:                                                                                                  #  A,L.
003767,000075: 
003768,000076:    4116           54001        DATACALL           TS       L                                     
003769,000077:    4117           22004                           LXCH     FBANK                                 
003770,000078:    4120           22121                           LXCH     MPTEMP                                #  SAVE FORMER BANK.
003771,000079:    4121           76425                           MASK     LOW10                                 
003772,000080:    4122           00006                           EXTEND                                         
003773,000081:    4123           50000                           INDEX    A                                     
003774,000082:    4124           32001                           DCA      10000                                 
003775,000083: 
003776,000084:    4125           56121                           XCH      MPTEMP                                
003777,000085:    4126           54004                           TS       FBANK                                 #  RESTORE FBANK.
003778,000086:    4127           30121                           CA       MPTEMP                                
003779,000087:    4130           00002                           TC       Q                                     
003780,000088: 
003781,000089:    4131                        ENDIBNKF           EQUALS                                         

End of include-file INTER-BANK_COMMUNICATION.agc.  Parent file is MAIN.agc