Source Code

These source-code files were transcribed from scans made from Don Eyles's personal copy of Luminary 069. They were scanned at archive.org's Boston facility, and the scanning was sponsored by Onno Hommes. The code was transcribed from these scans by a team of volunteers who are referenced in the program comments. Comments from the original source code are prefixed with a single '#' symbol, whereas comments added later are prefixed by "##" or "###". In some cases, where similar code blocks exist in previously-transcribed AGC programs (primarily Luminary 99, from Apollo 11) those code blocks were used as a starting point and then corrected to agree with the Luminary 69 scans. The full scans are available at the Virtual AGC project's collection at archive.org, while more-convenient reduced-size (but reduced-quality) images are available at the main Virtual AGC website. Report any errors noted by creating an issue report at the Virtual AGC project's GitHub repository. Notations on the program listing read, in part:

	GAP:  ASSEMBLE REVISION 069 OF AGC PROGRAM LUMINARY BY NASA 2021112-011
	19:02 NOV. 25,1968
Note that the date is the date of the printout, not the date of the program revision.

060636,000002:                                                                                                  ## Copyright:   Public domain.
060637,000003:                                                                                                  ## Filename:    T6-RUPT_PROGRAMS.agc
060638,000004:                                                                                                  ## Purpose:     The main source file for Luminary revision 069.
060639,000005:                                                                                                  ##              It is part of the source code for the original release
060640,000006:                                                                                                  ##              of the flight software for the Lunar Module's (LM) Apollo
060641,000007:                                                                                                  ##              Guidance Computer (AGC) for Apollo 10. The actual flown
060642,000008:                                                                                                  ##              version was Luminary 69 revision 2, which included a
060643,000009:                                                                                                  ##              newer lunar gravity model and only affected module 2.
060644,000010:                                                                                                  ##              This file is intended to be a faithful transcription, except
060645,000011:                                                                                                  ##              that the code format has been changed to conform to the
060646,000012:                                                                                                  ##              requirements of the yaYUL assembler rather than the
060647,000013:                                                                                                  ##              original YUL assembler.
060648,000014:                                                                                                  ## Reference:   pp. 1398-1400
060649,000015:                                                                                                  ## Assembler:   yaYUL
060650,000016:                                                                                                  ## Contact:     Ron Burkey <info@sandroid.org>.
060651,000017:                                                                                                  ## Website:     www.ibiblio.org/apollo/index.html
060652,000018:                                                                                                  ## Mod history: 2016-12-13 MAS  Created from Luminary 99.
060653,000019:                                                                                                  ##              2016-12-18 MAS  Updated from comment-proofed Luminary 99 version.
060654,000020:                                                                                                  ##              2016-12-24 RRB  Updated for Luminary 69.
060655,000021:                                                                                                  ##              2017-01-28 RSB  Proofed comment text using octopus/prooferComments
060656,000022:                                                                                                  ##                              but no errors found.
060657,000023:                                                                                                  ##              2017-08-29 MAS  Fixed a comment-text error found while transcribing
060658,000024:                                                                                                  ##                              Zerlina 56.
060659,000025: 

Page 1398

060661,000027:                                                                                                  #  PROGRAM NAMES:        (1) T6JOBCHK    MOD. NO. 5      OCTOBER 2, 1967
060662,000028:                                                                                                  #                        (2) DOT6RUPT
060663,000029:                                                                                                  #  MODIFICATION BY:      LOWELL G HULL (A.C.ELECTRONICS)
060664,000030: 
060665,000031:                                                                                                  #  THESE PROGRAMS ENABLE THE LM DAP TO CONTROL THE THRUST TIMES OF THE REACTION CONTROL SYSTEM JETS BY USING TIME6.
060666,000032:                                                                                                  #  SINCE THE LM DAP MAINTAINS EXCLUSIVE CONTROL OVER TIME6 AND ITS INTERRUPTS, THE FOLLOWING CONVENTIONS HAVE BEEN
060667,000033:                                                                                                  #  ESTABLISHED AND MUST NOT BE TAMPERED WITH:
060668,000034:                                                                                                  #        1.      NO NUMBER IS EVER PLACED INTO TIME6 EXCEPT BY LM DAP.
060669,000035:                                                                                                  #        2.      NO PROGRAM OTHER THAN LM DAP ENABLES THE TIME6 COUNTER.
060670,000036:                                                                                                  #        3.      TO USE TIME6, THE FOLLOWING SEQUENCE IS ALWAYS EMPLOYED:
060671,000037:                                                                                                  #                A.      A POSITIVE (NON-ZERO) NUMBER IS STORED IN TIME6.
060672,000038:                                                                                                  #                B.      THE TIME6 CLOCK IS ENABLED.
060673,000039:                                                                                                  #                C.      TIME6 IS INTERROGATED AND IS:
060674,000040:                                                                                                  #                        I.      NEVER FOUND NEGATIVE (NON-ZERO) OR +0.
060675,000041:                                                                                                  #                        II.     SOMETIMES FOUND POSITIVE (BETWEEN 1 AND 240D) INDICATING THAT IT IS ACTIVE.
060676,000042:                                                                                                  #                        III.    SOMETIMES FOUND POSMAX INDICATING THAT IT IS INACTIVE AND NOT ENABLED.
060677,000043:                                                                                                  #                        IV.     SOMETIMES FOUND NEGATIVE ZERO INDICATING THAT:
060678,000044:                                                                                                  #                                A.      A T6RUPT IS ABOUT TO OCCUR AT THE NEXT DINC, OR
060679,000045:                                                                                                  #                                B.      A T6RUPT IS WAITING IN THE PRIORITY CHAIN, OR
060680,000046:                                                                                                  #                                C.      A T6RUPT IS IN PROCESS NOW.
060681,000047:                                                                                                  #        4)      ALL PROGRAMS WHICH OPERATE IN EITHER INTERRUPT MODE OR WITH INTERRUPT INHIBITED MUST CALL T6JOBCHK
060682,000048:                                                                                                  #                EVERY 5 MILLISECONDS TO PROCESS A POSSIBLE WAITING T6RUPT BEFORE IT CAN BE HONORED BY THE HARDWARE.
060683,000049:                                                                                                  #       (5.      PROGRAM JTLST, IN Q,R-AXES, HANDLES THE INPUT LIST.)
060684,000050: 
060685,000051:                                                                                                  #  T6JOBCHK CALLING SEQUENCE:
060686,000052:                                                                                                  #                L       TC      T6JOBCHK
060687,000053:                                                                                                  #                L+1     (RETURN)
060688,000054: 
060689,000055:                                                                                                  #  DOT6RUPT CALLING SEQUENCE:
060690,000056:                                                                                                  #                        DXCH    ARUPT           T6RUPT LEAD IN AT LOCATION 4004.
060691,000057:                                                                                                  #                        EXTEND
060692,000058:                                                                                                  #                        DCA     T6ADR
060693,000059:                                                                                                  #                        DTCB
060694,000060: 
060695,000061:                                                                                                  #  SUBROUTINES CALLED:   DOT6RUPT CALLS T6JOBCHK.
060696,000062: 
060697,000063:                                                                                                  #  NORMAL EXIT MODES:    T6JOBCHK RETURNS TO L +1.
060698,000064:                                                                                                  #                        DOT6RUPT TRANSFERS CONTROL TO RESUME.
060699,000065: 
060700,000066:                                                                                                  #  ALARM/ABORT MODES:    NONE.
060701,000067: 
060702,000068:                                                                                                  #  INPUT:        TIME6           NXT6ADR         OUTPUT:         TIME6           NXT6ADR         CHANNEL 5
060703,000069:                                                                                                  #                T6NEXT          T6NEXT +1                       T6NEXT          T6NEXT +1       CHANNEL 6
060704,000070:                                                                                                  #                T6FURTHA        T6FURTHA +1                     T6FURTHA        T6FURTHA +1     BIT15/CH13
060705,000071: 
060706,000072:                                                                                                  #  DEBRIS:       T6JOBCHK CLOBBERS A.  DOT6RUPT CLOBBERS NOTHING.
060707,000073: 
060708,000074:    5744                                           BLOCK    02                                    

Page 1399

060710,000076: 17,2000                                           BANK     17                                    
060711,000077: 17,2000                                           SETLOC   DAPS2                                 
060712,000078: 17,2000                                           BANK                                           
060713,000079: 17,2000  E6,1464                                  EBANK=   T6NEXT                                
060714,000080: 17,2000                                           COUNT*   $$/DAPT6                              
060715,000081: 
060716,000082: 17,2000           10031        T6JOBCHK           CCS      TIME6                                 #  CHECK TIME6 FOR WAITING T6RUPT:
060717,000083: 17,2001           00002                           TC       Q                                     #  NONE: CLOCK COUTING DOWN.
060718,000084: 17,2002           05677                           TC       CCSHOLE                               
060719,000085: 17,2003           02003                           TC       T6JOBCHK   +3                         
060720,000086: 
060721,000087:                                                                                                  #  CONTROL PASSES TO T6JOB ONLY WHEN C(TIME6) = -0 (I.E. WHEN A T6RUPT MUST BE PROCESSED).
060722,000088: 
060723,000089: 17,2004           34733        T6JOB              CAF      POSMAX                                #  DISABLE CLOCK: NEEDED SINCE RUPT OCCURS
060724,000090: 17,2005           00006                           EXTEND                                         #  1 DINC AFTER T6 = 77777. FOR 625 MUSECS
060725,000091: 17,2006           03013                           WAND     CHAN13                                #  MUST NOT HAVE T6 = +0 WITH ENABLE SET
060726,000092: 
060727,000093: 17,2007           34733                           CA       POSMAX                                
060728,000094: 17,2010           22007                           ZL                                             
060729,000095: 17,2011           53467                           DXCH     T6FURTHA                              
060730,000096: 17,2012           53465                           DXCH     T6NEXT                                
060731,000097: 17,2013           23463                           LXCH     NXT6ADR                               
060732,000098: 17,2014           54031                           TS       TIME6                                 
060733,000099: 
060734,000100: 17,2015           67724                           AD       PRIO37                                
060735,000101: 17,2016           54000                           TS       A                                     
060736,000102: 17,2017           12023                           TCF      ENABLET6                              
060737,000103: 17,2020           34733                           CA       POSMAX                                
060738,000104: 17,2021           54031                           TS       TIME6                                 
060739,000105: 17,2022           12034                           TCF      GOCH56                                
060740,000106: 17,2023           34735        ENABLET6           CA       BIT15                                 
060741,000107: 17,2024           00006                           EXTEND                                         
060742,000108: 17,2025           05013                           WOR      CHAN13                                
060743,000109: 17,2026           31464                           CA       T6NEXT                                
060744,000110: 17,2027           67724                           AD       PRIO37                                
060745,000111: 17,2030           54000                           TS       A                                     
060746,000112: 17,2031           12034                           TCF      GOCH56                                
060747,000113: 17,2032           34733                           CA       POSMAX                                
060748,000114: 17,2033           55464                           TS       T6NEXT                                
060749,000115: 17,2034           50001        GOCH56             INDEX    L                                     
060750,000116: 17,2035           15744                           TCF      WRITEP     -1                         
060751,000117: 
060752,000118:    5744                                           BLOCK    02                                    
060753,000119:    4000                                           SETLOC   FFTAG9                                
060754,000120:    4000                                           BANK                                           
060755,000121:    5744  E6,1633                                  EBANK=   CDUXD                                 
060756,000122:    5744                                           COUNT*   $$/DAPT6                              
060757,000123: 
060758,000124:    5744           31470                           CA       NEXTP                                 
060759,000125:    5745           00006        WRITEP             EXTEND                                         
060760,000126:    5746           01006                           WRITE    CHAN6                                 

Page 1400

060762,000128:    5747           00002                           TC       Q                                     
060763,000129: 
060764,000130:    5750           31471                           CA       NEXTU                                 
060765,000131:    5751           54001        WRITEU             TS       L                                     
060766,000132:    5752           45765                           CS       00314OCT                              
060767,000133:    5753           00006                           EXTEND                                         
060768,000134:    5754           02005                           RAND     CHAN5                                 
060769,000135:    5755           60001                           AD       L                                     
060770,000136:    5756           00006                           EXTEND                                         
060771,000137:    5757           01005                           WRITE    CHAN5                                 
060772,000138:    5760           00002                           TC       Q                                     
060773,000139: 
060774,000140:    5761           31472                           CA       NEXTV                                 
060775,000141:    5762           54001        WRITEV             TS       L                                     
060776,000142:    5763           35765                           CA       00314OCT                              
060777,000143:    5764           15753                           TCF      -9D                                   
060778,000144:    5765           00314        00314OCT           OCT      00314                                 
060779,000145: 
060780,000146: 17,2036                                           BANK     17                                    
060781,000147: 17,2000                                           SETLOC   DAPS2                                 
060782,000148: 17,2000                                           BANK                                           
060783,000149: 
060784,000150: 17,2036  E6,1464                                  EBANK=   T6NEXT                                
060785,000151: 17,2036                                           COUNT*   $$/DAPT6                              
060786,000152: 
060787,000153: 17,2036           22016        DOT6RUPT           LXCH     BANKRUPT                              #  (INTERRUPT LEAD INS CONTINUED)
060788,000154: 17,2037           00006                           EXTEND                                         
060789,000155: 17,2040           22012                           QXCH     QRUPT                                 
060790,000156: 
060791,000157: 17,2041           02000                           TC       T6JOBCHK                              #  CALL T6JOBCHK.
060792,000158: 
060793,000159: 17,2042           15270                           TCF      RESUME                                #  END TIME6 INTERRUPT PROCESSOR.
060794,000160: 

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