Source Code

These source-code files are part of a reconstructed copy of Sunrise 45, the penultimate release of the Block I Command Module (CM) Apollo Guidance Computer (AGC) system test software.

They have been created via disassembly of binary dumps of original core rope memory modules, part numbers 1003133-18, 1003133-19, and 1003133-20. Corresponding portions of code have been copied from Solarium 55 where applicable. Extensive use was also made of the AGC Information Series documents, which were specifically written about the Sunrise software.

Since only binary dumps (rather than listings) of Sunrise are available as source material, all comments and labels are approximate. They have been taken from other AGC programs where possible, or, in some places, written from scratch to match what we believe would have been in the original listing.

006898,000002:                                                                                                  ## Copyright:   Public domain.
006899,000003:                                                                                                  ## Filename:    INTER-BANK_COMMUNICATION.agc
006900,000004:                                                                                                  ## Purpose:     A section of Sunrise 45.
006901,000005:                                                                                                  ##              It is part of the reconstructed source code for the penultimate
006902,000006:                                                                                                  ##              release of the Block I Command Module system test software. No
006903,000007:                                                                                                  ##              original listings of this program are available; instead, this
006904,000008:                                                                                                  ##              file was created via disassembly of dumps of Sunrise core rope
006905,000009:                                                                                                  ##              memory modules and comparison with the later Block I program
006906,000010:                                                                                                  ##              Solarium 55.
006907,000011:                                                                                                  ## Assembler:   yaYUL --block1
006908,000012:                                                                                                  ## Contact:     Ron Burkey <info@sandroid.org>.
006909,000013:                                                                                                  ## Website:     www.ibiblio.org/apollo/index.html
006910,000014:                                                                                                  ## Mod history: 2022-12-09 MAS  Initial reconstructed source.
006911,000015: 
006912,000016: 
006913,000017:                                                                                                  #        THE FOLLOWING SUBROUTINES ARE INTENDED TO FACILITATE INTER-BANK COMMUNICATION. ROUTINES ARE PROVIDED
006914,000018:                                                                                                  #  FOR JUMPING TO A LOCATION IN ANOTHER BANK, CALLING A SUBROUTINE IN ANOTHER BANK, AND OBTAINING DATA FROM ANOTHER
006915,000019:                                                                                                  #  BANK. IN ADDITION, A ROUTINE IS PROVIDED FOR MAKING UP A RETURN_ADDRESS CADR FOR USE BY THE CALLED SUBROUTINE.
006916,000020: 
006917,000021:    2516                                           BANK     1                                     
006918,000022:    2516           50061        BANKCALL           TS       ADDRWD                                #  SUBROUTINE CALL WITH TRANSMISSION BOTH
006919,000023:    2517           30001                           XCH      Q                                     #  WAYS IN A. THE CADR OF THE CALLED
006920,000024:    2520           64516                           AD       ONE                                   #  ROUTINE SHOULD IMMEDIATELY FOLLOW THE
006921,000025:    2521           50001                           TS       Q                                     #  TC BANKCALL.
006922,000026:    2522           20000                           INDEX    A                                     
006923,000027:    2523           27777                           CAF      0          -1                         #  PICK UP CADR AND FALL INTO SWCALL.
006924,000028: 
006925,000029:    2524           50070        SWCALL             TS       TEMQS                                 #  SWCALL IS ALOS USED TO CALL SUBROUTINES
006926,000030:    2525           30015                           XCH      BANKREG                               #  IN OTHER BANKS, BUT THE CADR ARRIVES IN
006927,000031:    2526           50071                           TS       BANKTEM                               #  A. DATA MAY BE TRANSMITTED BACK TO THE
006928,000032:    2527           30001                           XCH      Q                                     #  CALLING PROGRAM IN A, HOWEVER. 
006929,000033:    2530           30070                           XCH      TEMQS                                 #  RETURN INFORMATION NOW COMPLETE.
006930,000034:    2531           50113                           TS       ESCAPE                                
006931,000035:    2532           72201                           MASK     70K                                   #  PROVISION FOR CALLING A ROUTINE IN
006932,000036:    2533           10000                           CCS      A                                     #  FIXED-FIXED (OF QUESTIONABLE VALUE).
006933,000037:    2534           02536                           TC       +2                                    #  SPECIAL TREATMENT REQUIRED IF NON-ZERO.
006934,000038:    2535           02540                           TC       +3                                    #  INPUT CADR OK AS IS.
006935,000039: 
006936,000040:    2536           40015                           CS       BANKREG                               #  FORM PROPER 12 BIT ADDRESS.
006937,000041:    2537           64373                           AD       6K                                    
006938,000042:    2540           60113                 +3        AD       ESCAPE                                #  PROPER CADRS COME HERE WITH C(A) = 0.
006939,000043:    2541           30061                           XCH      ADDRWD                                #  SO A CAN TRANSMIT WITH BANKCALL.
006940,000044:    2542           20061                           INDEX    ADDRWD                                
006941,000045:    2543           00000                           TC       0                                     #  SETTING Q TO SWRETURN.
006942,000046: 
006943,000047:    2544           30071        SWRETURN           XCH      BANKTEM                               #  RETURN TO CALLER, TRANSMITTING THROUGH A
006944,000048:    2545           50015                           TS       BANKREG                               
006945,000049:    2546           30071                           XCH      BANKTEM                               #  RESTORE A AS UPON ARRIVAL TO SWRETURN.
006946,000050:    2547           00070                           TC       TEMQS                                 #  RETURN.
006947,000051: 
006948,000052: 
006949,000053:    2550           35500        MAKECADR           CAF      ZERO                                  #  LEAVES RETURN-ADDRESS CADR (AS SET BY
006950,000054:    2551           60070                           AD       TEMQS                                 #  SWCALL OR BANKCALL) IN ADDRWD.
006951,000055:    2552           50061                           TS       ADDRWD                                
006952,000056:    2553           62562                           AD       32K                                   #  SEE IF BANK INFORMATION NEEDED (USUAL).
006953,000057:    2554           50034                           TS       OVCTR                                 
006954,000058:    2555           00001                           TC       Q                                     #  ADDRWD SET OK IF NO OVERFLOW (IN FF).
006955,000059: 
006956,000060:    2556           30034                           XCH      OVCTR                                 #  CONTAINS LOW 10 BITS ONLY.
006957,000061:    2557           60071                           AD       BANKTEM                               
006958,000062:    2560           50061                           TS       ADDRWD                                #  RETURN CADR NOW COMPLETE.
006959,000063:    2561           00001                           TC       Q                                     
006960,000064: 
006961,000065:    2562           32000        32K                OCT      32000                                 
006962,000066:    2563           30001        POSTJUMP           XCH      Q                                     #  ONE-WAY BANK TO BANK JUMP, WITH NO
006963,000067:    2564           20000                           INDEX    A                                     #  RETURN ADDRESS. THIS VERSION TRANSMITS
006964,000068:    2565           30000                           CAF      0                                     #  THROUGH A IF DESIRED.
006965,000069: 
006966,000070:    2566           50015        BANKJUMP           TS       BANKREG                               #  SAME AS ABOVE ONLY ADDRESS ARRIVES IN A.
006967,000071:    2567           74605                           MASK     LOW10                                 #  BANKJUMP AND POSTJUMP MAY BE USED IN
006968,000072:    2570           30001                           XCH      Q                                     #  INTERRUPT OR UNDER EXEC, BUT BANKCALL
006969,000073:    2571           20001                           INDEX    Q                                     #  AND SWCALL MAY BE USED ONLY UNDER EXEC.
006970,000074:    2572           06000                           TC       6000                                  
006971,000075: 
006972,000076: 
006973,000077:    2573           50113        DATACALL           TS       ESCAPE                                #  SUBROUTINE TO RETRIEVE DATA IN ANOTHER
006974,000078:    2574           30015                           XCH      BANKREG                               #  BANK. THE CADR OF THE LOCATION OF INTER-
006975,000079:    2575           30113                           XCH      ESCAPE                                #  EST ARRIVES IN A AND ITS CONTENTS ARE IN
006976,000080:    2576           74605                           MASK     LOW10                                 #  A ON EXIT. THIS MAY BE USED ONLY UNDER
006977,000081:    2577           20000                           INDEX    A                                     #  EXECUTIVE.
006978,000082:    2600           36000                           CAF      6000                                  #  REQUESTED DATA NOW ACQUIRED.
006979,000083: 
006980,000084:    2601           30113                           XCH      ESCAPE                                
006981,000085:    2602           50015                           TS       BANKREG                               
006982,000086:    2603           30113                           XCH      ESCAPE                                
006983,000087:    2604           00001                           TC       Q                                     

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