Source Code

These source-code files are part of a reconstructed copy of Corona 261, the final, flown release of the Block I Command Module (CM) Apollo Guidance Computer (AGC) software for the AS-202 mission.

They have been created via disassembly of binary dumps of the original core rope memory modules actually flown on the mission, part numbers 1003733-171, 1003733-241, 1003733-191, 1003733-211, 1003733-221, and 1003733-241. The source code for the Apollo 4 and 6 software, Solarium 55, was used as a starting point, since it was directly derived from Corona and (at least in theory) only minimally modified.

Since only binary dumps (rather than listings) of Corona 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.

011000,000002:                                                                                                  ## Copyright:   Public domain.
011001,000003:                                                                                                  ## Filename:    ALARM_AND_DISPLAY_PROCEDURES.agc
011002,000004:                                                                                                  ## Purpose:     A section of Corona revision 261.
011003,000005:                                                                                                  ##              It is part of the source code for the Apollo Guidance Computer
011004,000006:                                                                                                  ##              (AGC) for AS-202. No original listings of this software are
011005,000007:                                                                                                  ##              available; instead, this file was created via disassembly of
011006,000008:                                                                                                  ##              the core rope modules actually flown on the mission.
011007,000009:                                                                                                  ## Assembler:   yaYUL
011008,000010:                                                                                                  ## Contact:     Ron Burkey <info@sandroid.org>.
011009,000011:                                                                                                  ## Website:     www.ibiblio.org/apollo/index.html
011010,000012:                                                                                                  ## Mod history: 2023-05-27 MAS  Created from Solarium 55.
011011,000013: 
011012,000014: 
011013,000015:                                                                                                  #        THE FOLLOWING SUBROUTINE MAY BE CALLED TO DISPLAY A NON-ABORTIVE ALARM CONDITION. IT MAY BE CALLED
011014,000016:                                                                                                  #  EITHER IN INTERRUPT OR UNDER EXECUTIVE CONTROL.
011015,000017: 
011016,000018:                                                                                                  #        CALLING SEQUENCE IS AS FOLLOWS:
011017,000019: 
011018,000020:                                                                                                  #        TC      ALARM
011019,000021:                                                                                                  #        OCT     AAANN           ALARM NO. NN IN GENERAL AREA AAA.
011020,000022:                                                                                                  #                                (RETURNS HERE)
011021,000023: 
011022,000024:    3015                                           BANK     1                                     
011023,000025:    3015           20017        ALARM              INHINT                                         
011024,000026:    3016           30001                           XCH      Q                                     
011025,000027:    3017           50577                           TS       ITEMP1                                
011026,000028: 
011027,000029:    3020           11763                           CCS      FAILREG                               #  SEE IF ONE FAILURE HAS OCCURRED SINCE
011028,000030:                                                                                                  #   THE LAST ERROR RESET.
011029,000031:    3021           03027                           TC       MULTFAIL                              #  YES - INDICATE MULTIPLE FAILURES.
011030,000032:    3022           03032                           TC       NEWALARM                              #  FIRST SINCE RESET.
011031,000033:    3023           30577        MULTEXIT           XCH      ITEMP1                                #  FREE ITEMP1 BEFORE RELINT.
011032,000034: 
011033,000035:    3024           20016        ENDALARM           RELINT                                         
011034,000036:    3025           20000                           INDEX    A                                     
011035,000037:    3026           00001                           TC       1                                     #  RETURN TO CALLER.
011036,000038: 
011037,000039:    3027           64664        MULTFAIL           AD       CSQ                                   #  BIT 15 = 1 INDICATES MULTIPLE FAILURES.
011038,000040:    3030           51763                           TS       FAILREG                               #  CSQ = BIT15 + BIT1.
011039,000041:    3031           03023                           TC       MULTEXIT                              
011040,000042: 
011041,000043:    3032           30577        NEWALARM           XCH      ITEMP1                                #  SAVE RETURN ADDRESS FOR CALL TO NOVAC.
011042,000044:    3033           51763                           TS       FAILREG                               
011043,000045: 
011044,000046:    3034           03044                           TC       PROGLARM                              #  TURN ON THE PROGRAM ALARM LIGHT.
011045,000047: 
011046,000048:    3035           32172                           CAF      PRIO37                                
011047,000049:    3036           02052                           TC       NOVAC                                 
011048,000050:    3037           23712                           CADR     DOALARM                               #  CALL (SEPARATE) JOB FOR DISPLAY.
011049,000051: 
011050,000052:    3040           21763                           INDEX    FAILREG                               #  (RETURN ADDRESS AT THIS POINT).
011051,000053:    3041           30000                           CAF      0                                     
011052,000054:    3042           31763                           XCH      FAILREG                               #  SET FAILREG AND GET BACK RETURN ADDRESS.
011053,000055:    3043           03024        NEWALM2            TC       ENDALARM                              
011054,000056: 
011055,000057: 
011056,000058:                                                                                                  #        JOB WHICH CALLS NVSUB FOR ALARM DISPLAY.
011057,000059: 
011058,000060: 11,7712                                           BANK     11                                    
011059,000061: 11,7712           03310        DOALARM            TC       GRABDSP                               #  DISPLAY FAILREG.
011060,000062: 11,7713           03316                           TC       PREGBSY                               
011061,000063: 11,7714           33051                           CAF      FAILDISP                              
011062,000064: 11,7715           03106                           TC       NVSUB                                 
011063,000065: 11,7716           03323                           TC       PRENVBSY                              
011064,000066: 11,7717           03370                           TC       FREEDSP                               
011065,000067: 11,7720           02124                           TC       ENDOFJOB                              
011066,000068: 
011067,000069: 
011068,000070: 
011069,000071:    3044                                           SETLOC   NEWALM2    +1                         
011070,000072: 
011071,000073:    3044           44516        PROGLARM           CS       ONE                                   #  TURNS ON PROGRAM FAIL LIGHT ON THE
011072,000074:    3045           70011                           MASK     OUT1                                  #  PANEL.  CALLED ONLY BY ALARM AND ABORT.
011073,000075:    3046           64516                           AD       ONE                                   
011074,000076:    3047           50011                           TS       OUT1                                  
011075,000077:    3050           00001                           TC       Q                                     
011076,000078: 
011077,000079:    3051           00531        FAILDISP           OCT      00531                                 
011078,000080: 
011079,000081: 
011080,000082:                                                                                                  #        THE FOLLOWING ROUTINE IS CALLED TO INITIATE AN ABORT. FAILREG IS SET (ACCORDING TO THE MULTIPLE
011081,000083:                                                                                                  #  FAILURES CONVENTION) AND A RE-START IS INITIATED BY TC-SELF. THIS IS CALLED ONLY UNDER RARE CIRCUMSTANCES.
011082,000084: 
011083,000085:    3052           20017        ABORT              INHINT                                         #  MAY BE CALLED IN INTERRUPT OR UNDER EXEC
011084,000086:    3053           20001                           INDEX    Q                                     #  PICK UP FAILURE CODE.
011085,000087:    3054           30000                           CAF      0                                     
011086,000088:    3055           50577                           TS       ITEMP1                                
011087,000089: 
011088,000090:    3056           11763                           CCS      FAILREG                               #  SEE IF THIS IS A MULTIPLE FAILURE.
011089,000091:    3057           03062                           TC       SETMULTF                              #  SET BIT 15 TO INDICATE YES.
011090,000092:    3060           03064                           TC       NEWABORT                              #  FIRST FAILURE.
011091,000093: 
011092,000094:    3061           03061        WHIMPER            TC       WHIMPER                               #  NOT WITH A BANG...
011093,000095: 
011094,000096:    3062           64664        SETMULTF           AD       CSQ                                   #  RESTORE AND SET BIT15
011095,000097:    3063           03066                           TC       +3                                    
011096,000098: 
011097,000099:    3064           03044        NEWABORT           TC       PROGLARM                              #  FIRST FAILURE - TURN ON ALARM LIGHT.
011098,000100:    3065           30577                           XCH      ITEMP1                                
011099,000101:    3066           51763                 +3        TS       FAILREG                               
011100,000102:    3067           03061                           TC       WHIMPER                               #  UNIVERSAL ABORT LOCATION.
011101,000103: 
011102,000104:    3070           30001        CCSHOLE            XCH      Q                                     
011103,000105:    3071           51764                           TS       SFAIL                                 
011104,000106:    3072           03052                           TC       ABORT                                 
011105,000107:    3073           01103                           OCT      1103                                  
011106,000108: 
011107,000109:                                                                                                  #        MISSION PROGRAM DETECTED FAILURES (ERROR RETURNS TO IMUSTALL, ETC.)
011108,000110: 
011109,000111:    3074           30001        CURTAINS           XCH      Q                                     #  PROGRAM DETECTED FLUSH.
011110,000112:    3075           05720                           TC       POSTJUMP                              
011111,000113:    3076           10777                           CADR     THATSALL                              #  FRESH START AND PROGRAM ALARM.
011112,000114: 
011113,000115:    3077                        ENDFAILF           EQUALS                                         

End of include-file ALARM_AND_DISPLAY_PROCEDURES.agc.  Parent file is MAIN.agc