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.

063870,000002:                                                                                                  ## Copyright:   Public domain.
063871,000003:                                                                                                  ## Filename:    KALMAN_FILTER.agc
063872,000004:                                                                                                  ## Purpose:     The main source file for Luminary revision 069.
063873,000005:                                                                                                  ##              It is part of the source code for the original release
063874,000006:                                                                                                  ##              of the flight software for the Lunar Module's (LM) Apollo
063875,000007:                                                                                                  ##              Guidance Computer (AGC) for Apollo 10. The actual flown
063876,000008:                                                                                                  ##              version was Luminary 69 revision 2, which included a
063877,000009:                                                                                                  ##              newer lunar gravity model and only affected module 2.
063878,000010:                                                                                                  ##              This file is intended to be a faithful transcription, except
063879,000011:                                                                                                  ##              that the code format has been changed to conform to the
063880,000012:                                                                                                  ##              requirements of the yaYUL assembler rather than the
063881,000013:                                                                                                  ##              original YUL assembler.
063882,000014:                                                                                                  ## Reference:   pp. 1465-1466
063883,000015:                                                                                                  ## Assembler:   yaYUL
063884,000016:                                                                                                  ## Contact:     Ron Burkey <info@sandroid.org>.
063885,000017:                                                                                                  ## Website:     www.ibiblio.org/apollo/index.html
063886,000018:                                                                                                  ## Mod history: 2016-12-13 MAS  Created from Luminary 99.
063887,000019:                                                                                                  ##              2016-12-18 MAS  Updated from comment-proofed Luminary 99 version.
063888,000020:                                                                                                  ##              2016-12-22 IJK  Updated for Luminary 69.
063889,000021:                                                                                                  ##              2017-01-28 RSB  Proofed comment text using octopus/prooferComments
063890,000022:                                                                                                  ##                              but no errors found.
063891,000023: 

Page 1465

063893,000025: 17,3700  E6,1522                                  EBANK=   NO.UJETS                              
063894,000026: 16,3624                                           BANK     16                                    
063895,000027: 16,2000                                           SETLOC   DAPS1                                 
063896,000028: 16,2000                                           BANK                                           
063897,000029: 
063898,000030: 16,3624                                           COUNT*   $$/DAP                                
063899,000031: 
063900,000032: 16,3624           34752        RATELOOP           CA       TWO                                   
063901,000033: 16,3625           55742                           TS       DAPTEMP6                              
063902,000034: 16,3626           60000                           DOUBLE                                         
063903,000035: 16,3627           54002                           TS       Q                                     
063904,000036: 16,3630           51742                           INDEX    DAPTEMP6                              
063905,000037: 16,3631           11524                           CCS      TJP                                   
063906,000038: 16,3632           13634                           TCF      +2                                    
063907,000039: 16,3633           13653                           TCF      LOOPRATE                              
063908,000040: 16,3634           63714                           AD       -100MST6                              
063909,000041: 16,3635           00006                           EXTEND                                         
063910,000042: 16,3636           63672                           BZMF     SMALLTJU                              
063911,000043: 16,3637           51742                           INDEX    DAPTEMP6                              
063912,000044: 16,3640           11524                           CCS      TJP                                   
063913,000045: 16,3641           33714                           CA       -100MST6                              
063914,000046: 16,3642           13644                           TCF      +2                                    
063915,000047: 16,3643           43714                           CS       -100MST6                              
063916,000048: 16,3644           51742                           INDEX    DAPTEMP6                              
063917,000049: 16,3645           27524                           ADS      TJP                                   
063918,000050: 16,3646           51742                           INDEX    DAPTEMP6                              
063919,000051: 16,3647           11524                           CCS      TJP                                   
063920,000052: 16,3650           43600                           CS       -100MS                                #  0.1 AT 1
063921,000053: 16,3651           13653                           TCF      +2                                    
063922,000054: 16,3652           33600                           CA       -100MS                                
063923,000055: 16,3653           00006        LOOPRATE           EXTEND                                         
063924,000056: 16,3654           51742                           INDEX    DAPTEMP6                              
063925,000057: 16,3655           71521                           MP       NO.PJETS                              
063926,000058: 16,3656           30001                           CA       L                                     
063927,000059: 16,3657           51742                           INDEX    DAPTEMP6                              
063928,000060: 16,3660           55735                           TS       DAPTEMP1                              #  SIGNED TORQUE AT 1 JET-SEC FOR FILTER
063929,000061: 16,3661           00006                           EXTEND                                         
063930,000062: 16,3662           74742                           MP       BIT10                                 #  RESCALE TO 32; ONE BIT ABOUT 2 JET-MSEC
063931,000063: 16,3663           00006                           EXTEND                                         
063932,000064: 16,3664           63715                           BZMF     NEGTORK                               
063933,000065: 16,3665           50002        STORTORK           INDEX    Q                                     #  INCREMENT DOWNLIST REGISTER.
063934,000066: 16,3666           27513                           ADS      DOWNTORK                              #    NOTE: NOT INITIALIZED; OVERFLOWS.
063935,000067: 
063936,000068: 16,3667           11742                           CCS      DAPTEMP6                              
063937,000069: 16,3670           13625                           TCF      RATELOOP   +1                         
063938,000070: 16,3671           13701                           TCF      ROTORQUE                              
063939,000071: 16,3672           34755        SMALLTJU           CA       ZERO                                  
063940,000072: 16,3673           51742                           INDEX    DAPTEMP6                              
063941,000073: 16,3674           57524                           XCH      TJP                                   
063942,000074: 16,3675           00006                           EXTEND                                         

Page 1466

063944,000076: 16,3676           74760                           MP       ELEVEN                                #  10.24 PLUS
063945,000077: 16,3677           30001                           CA       L                                     
063946,000078: 16,3700           13653                           TCF      LOOPRATE                              
063947,000079: 16,3701           31736        ROTORQUE           CA       DAPTEMP2                              
063948,000080: 16,3702           61737                           AD       DAPTEMP3                              
063949,000081: 16,3703           00006                           EXTEND                                         
063950,000082: 16,3704           71532                           MP       1JACCR                                
063951,000083: 16,3705           55745                           TS       JETRATER                              
063952,000084: 16,3706           41737                           CS       DAPTEMP3                              
063953,000085: 16,3707           61736                           AD       DAPTEMP2                              
063954,000086: 16,3710           00006                           EXTEND                                         
063955,000087: 16,3711           71531                           MP       1JACCQ                                
063956,000088: 16,3712           55744                           TS       JETRATEQ                              
063957,000089: 16,3713           12305                           TCF      BACKP                                 
063958,000090: 16,3714           77537        -100MST6           DEC      -160       B-14                       
063959,000091: 
063960,000092: 16,3715           40000        NEGTORK            COM                                            
063961,000093: 16,3716           24002                           INCR     Q                                     
063962,000094: 16,3717           13665                           TCF      STORTORK                              
063963,000095: 
063964,000096: 

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