Source Code

These source-code files are part of a reconstructed copy of Luminary 173, the second (unflown) release of the Apollo 14 Lunar Module (LM) Apollo Guidance Computer (AGC) software.

The reconstruction began with reconstructed source code for Luminary 178. Changes between revision 173 and 178 were backed out, as described by Luminary memo 167 (revision 1). The reconstruction was verified by matching memory-bank checksums to those listed in drawing 2021152N. Note that page numbers in the reconstructed code match those for the baseline log section mentioned in each file's changelog; the page numbers for a real Luminary 173 listing would be different.

Comments from the original source code are prefixed with a single '#' symbol, whereas comments added later are prefixed by "##" or "###". Report any errors noted by creating an issue report at the Virtual AGC project's GitHub repository.

059559,000002:                                                                                                  ## Copyright:   Public domain.
059560,000003:                                                                                                  ## Filename:    T6-RUPT_PROGRAMS.agc
059561,000004:                                                                                                  ## Purpose:     A section of Luminary revision 173.
059562,000005:                                                                                                  ##              It is part of the reconstructed source code for the second
059563,000006:                                                                                                  ##              (unflown) release of the flight software for the Lunar
059564,000007:                                                                                                  ##              Module's (LM) Apollo Guidance Computer (AGC) for Apollo 14.
059565,000008:                                                                                                  ##              The code has been recreated from a reconstructed copy of
059566,000009:                                                                                                  ##              Luminary 178, as well as Luminary memo 167 (revision 1).
059567,000010:                                                                                                  ##              It has been adapted such that the resulting bugger words
059568,000011:                                                                                                  ##              exactly match those specified for Luminary 173 in NASA
059569,000012:                                                                                                  ##              drawing 2021152N, which gives relatively high confidence
059570,000013:                                                                                                  ##              that the reconstruction is correct.
059571,000014:                                                                                                  ## Reference:   pp. 1391-1393
059572,000015:                                                                                                  ## Assembler:   yaYUL
059573,000016:                                                                                                  ## Contact:     Ron Burkey <info@sandroid.org>.
059574,000017:                                                                                                  ## Website:     www.ibiblio.org/apollo/index.html
059575,000018:                                                                                                  ## Mod history: 2019-09-18 MAS  Created from Luminary 178.
059576,000019: 

Page 1391

059578,000021:                                                                                                  #  PROGRAM NAMES:  (1) T6JOBCHK      MOD. NO. 5    OCTOBER 2, 1967
059579,000022:                                                                                                  #                 (2) DOT6RUPT
059580,000023: 
059581,000024:                                                                                                  #  MODIFICATION BY: LOWELL G HULL (A.C.ELECTRONICS)
059582,000025:                                                                                                  #  THESE PROGRAMS ENABLE THE LM DAP TO CONTROL THE THRUST TIMES OF THE REACTION CONTROL SYSTEM JETS BY USING TIME6.
059583,000026:                                                                                                  #  SINCE THE LM DAP MAINTAINS EXCLUSIVE CONTROL OVER TIME6 AND ITS INTERRUPTS, THE FOLLOWING CONVENTIONS HAVE BEEN
059584,000027:                                                                                                  #  ESTABLISHED AND MUST NOT BE TAMPERED WITH:
059585,000028:                                                                                                  #           1. NO NUMBER IS EVER PLACED INTO TIME6 EXCEPT BY LM DAP.
059586,000029:                                                                                                  #           2. NO PROGRAM OTHER THAN LM DAP ENABLES THE TIME6 COUNTER.
059587,000030:                                                                                                  #           3. TO USE TIME6, THE FOLLOWING SEQUENCE IS ALWAYS EMPLOYED:
059588,000031:                                                                                                  #                  A. A POSITIVE (NON-ZERO) NUMBER IS STORED IN TIME6.
059589,000032:                                                                                                  #                  B. THE TIME6 CLOCK IS ENABLED.
059590,000033:                                                                                                  #                  C. TIME6 IS INTERROGATED AND IS:
059591,000034:                                                                                                  #                         I. NEVER FOUND NEGATIVE(NON-ZERO) OR +0.
059592,000035:                                                                                                  #                        II. SOMETIMES FOUND POSITIVE(BETWEEN 1 AND 240D) INDICATING THAT IT IS ACTIVE.
059593,000036:                                                                                                  #                       III. SOMETIMES FOUND POSMAX INDICATING THAT IT IS INACTIVE AND NOT ENABLED.
059594,000037:                                                                                                  #                        IV. SOMETIMES FOUND NEGATIVE ZERO INDICATING THAT:
059595,000038:                                                                                                  #                                A. A T6RUPT IS ABOUT TO OCCUR AT THE NEXT DINC, OR
059596,000039:                                                                                                  #                                B. A T6RUPT IS WAITING IN THE PRIORITY CHAIN, OR
059597,000040:                                                                                                  #                                C. A T6RUPT IS IN PROCESS NOW.
059598,000041:                                                                                                  #           4) ALL PROGRAMS WHICH OPERATE IN EITHER INTERRUPT MODE OR WITH INTERRUPT INHIBITED MUST CALL T6JOBCHK
059599,000042:                                                                                                  #              EVERY 5 MILLISECONDS TO PROCESS A POSSIBLE WAITING T6RUPT BEFORE IT CAN BE HONORED BY THE HARDWARE.
059600,000043: 
059601,000044:                                                                                                  #          (5. PROGRAM JTLST, IN Q,R-AXES, HANDLES THE INPUT LIST.)
059602,000045:                                                                                                  #  T6JOBCHK CALLING SEQUENCE:
059603,000046: 
059604,000047:                                                                                                  #                                          L        TC     T6JOBCHK
059605,000048:                                                                                                  #                                          L +1    (RETURN)
059606,000049: 
059607,000050:                                                                                                  #  DOT6RUPT CALLING SEQUENCE:
059608,000051: 
059609,000052:                                                                                                  #                                                   DXCH   ARUPT           T6RUPT LEAD IN AT LOCATION 4004.
059610,000053:                                                                                                  #                                                   EXTEND
059611,000054:                                                                                                  #                                                   DCA    T6ADR
059612,000055:                                                                                                  #                                                   DTCB
059613,000056: 
059614,000057:                                                                                                  #  SUBROUTINES CALLED: DOT6RUPT CALLS T6JOBCHK.
059615,000058: 
059616,000059:                                                                                                  #  NORMAL EXIT MODES: T6JOBCHK RETURNS TO L +1.
059617,000060:                                                                                                  #                     DOT6RUPT TRANSFERS CONTROL TO RESUME.
059618,000061: 
059619,000062:                                                                                                  #  ALARM/ABORT MODES: NONE.
059620,000063: 
059621,000064:                                                                                                  #  INPUT: TIME6    NXT6ADR      OUTPUT: TIME6     NXT6ADR     CHANNEL 5
059622,000065:                                                                                                  #         T6NEXT   T6NEXT +1            T6NEXT    T6NEXT +1   CHANNEL 6
059623,000066:                                                                                                  #         T6FURTHA T6FURTHA +1          T6FURTHA  T6FURTHA +1 BIT15/CH13
059624,000067:                                                                                                  #  DEBRIS: T6JOBCHK CLOBBERS A.  DOT6RUPT CLOBBERS NOTHING.
059625,000068: 
059626,000069: 
059627,000070:    5754                                           BLOCK    02                                    

Page 1392

059629,000072: 17,2055                                           BANK     17                                    
059630,000073: 17,2000                                           SETLOC   DAPS2                                 
059631,000074: 17,2000                                           BANK                                           
059632,000075: 17,2055  E6,1466                                  EBANK=   T6NEXT                                
059633,000076: 17,2055                                           COUNT*   $$/DAPT6                              
059634,000077: 
059635,000078: 17,2055           10031        T6JOBCHK           CCS      TIME6                                 #  CHECK TIME6 FOR WAITING T6RUPT:
059636,000079: 17,2056           00002                           TC       Q                                     #  NONE: CLOCK COUTING DOWN.
059637,000080: 17,2057           05706                           TC       CCSHOLE                               
059638,000081: 17,2060           05706                           TC       CCSHOLE                               
059639,000082:                                                                                                  #  CONTROL PASSES TO T6JOB ONLY WHEN C(TIME6) = -0 (I.E. WHEN A T6RUPT MUST BE PROCESSED).
059640,000083: 
059641,000084: 17,2061           34733        T6JOB              CA       POSMAX                                
059642,000085: 17,2062           22007                           ZL                                             
059643,000086: 17,2063           53471                           DXCH     T6FURTHA                              
059644,000087: 17,2064           53467                           DXCH     T6NEXT                                
059645,000088: 17,2065           23465                           LXCH     NXT6ADR                               
059646,000089: 17,2066           54031                           TS       TIME6                                 
059647,000090: 
059648,000091: 17,2067           67730                           AD       PRIO37                                
059649,000092: 17,2070           54000                           TS       A                                     
059650,000093: 17,2071           12075                           TCF      ENABLET6                              
059651,000094: 17,2072           34733                           CA       POSMAX                                
059652,000095: 17,2073           54031                           TS       TIME6                                 
059653,000096: 17,2074           12115                           TCF      GOCH56                                
059654,000097: 17,2075           00006        ENABLET6           EXTEND                                         
059655,000098: 17,2076           23265                           QXCH     C13QSAV                               
059656,000099: 17,2077           22070                           LXCH     RUPTREG1                              
059657,000100: 17,2100           06022                           TC       C13STALL                              
059658,000101: 17,2101           00006                           EXTEND                                         
059659,000102: 17,2102           23265                           QXCH     C13QSAV                               
059660,000103: 17,2103           22070                           LXCH     RUPTREG1                              
059661,000104: 17,2104           34735                           CAF      BIT15                                 
059662,000105: 17,2105           00006                           EXTEND                                         
059663,000106: 17,2106           05013                           WOR      CHAN13                                
059664,000107: 17,2107           31466                           CA       T6NEXT                                
059665,000108: 17,2110           67730                           AD       PRIO37                                
059666,000109: 17,2111           54000                           TS       A                                     
059667,000110: 17,2112           12115                           TCF      GOCH56                                
059668,000111: 17,2113           34733                           CA       POSMAX                                
059669,000112: 17,2114           55466                           TS       T6NEXT                                
059670,000113: 17,2115           50001        GOCH56             INDEX    L                                     
059671,000114: 17,2116           15754                           TCF      WRITEP     -1                         
059672,000115: 
059673,000116:    5754                                           BLOCK    02                                    
059674,000117:    4000                                           SETLOC   FFTAG9                                
059675,000118:    4000                                           BANK                                           
059676,000119:    5754  E6,1634                                  EBANK=   CDUXD                                 
059677,000120:    5754                                           COUNT*   $$/DAPT6                              

Page 1393

059679,000122:    5754           31472                           CA       NEXTP                                 
059680,000123:    5755           00006        WRITEP             EXTEND                                         
059681,000124:    5756           01006                           WRITE    CHAN6                                 
059682,000125:    5757           00002                           TC       Q                                     
059683,000126: 
059684,000127:    5760           31473                           CA       NEXTU                                 
059685,000128:    5761           54001        WRITEU             TS       L                                     
059686,000129:    5762           45775                           CS       00314OCT                              
059687,000130:    5763           00006                           EXTEND                                         
059688,000131:    5764           02005                           RAND     CHAN5                                 
059689,000132:    5765           60001                           AD       L                                     
059690,000133:    5766           00006                           EXTEND                                         
059691,000134:    5767           01005                           WRITE    CHAN5                                 
059692,000135:    5770           00002                           TC       Q                                     
059693,000136: 
059694,000137:    5771           31474                           CA       NEXTV                                 
059695,000138:    5772           54001        WRITEV             TS       L                                     
059696,000139:    5773           35775                           CA       00314OCT                              
059697,000140:    5774           15763                           TCF      -9D                                   
059698,000141:    5775           00314        00314OCT           OCT      00314                                 
059699,000142: 
059700,000143: 17,2117                                           BANK     17                                    
059701,000144: 17,2000                                           SETLOC   DAPS2                                 
059702,000145: 17,2000                                           BANK                                           
059703,000146: 
059704,000147: 17,2117  E6,1466                                  EBANK=   T6NEXT                                
059705,000148: 17,2117                                           COUNT*   $$/DAPT6                              
059706,000149: 
059707,000150: 17,2117           22016        DOT6RUPT           LXCH     BANKRUPT                              #  (INTERRUPT LEAD INS CONTINUED)
059708,000151: 17,2120           00006                           EXTEND                                         
059709,000152: 17,2121           22012                           QXCH     QRUPT                                 
059710,000153: 
059711,000154: 17,2122           02055                           TC       T6JOBCHK                              #  CALL T6JOBCHK.
059712,000155: 
059713,000156: 17,2123           15301                           TCF      RESUME                                #  END TIME6 INTERRUPT PROCESSOR.

End of include-file T6-RUPT_PROGRAMS.agc.  Parent file is MAIN.agc