Source Code

This is a reconstructed version of Luminary 130, the initial AGC program released in November 1969 for the Apollo 13 LM. Three more releases followed before the flown revision was finally manufactured in February 1970.

This reconstruction was created from a previous transcription of the original listing of Luminary 131, combined with Luminary memo #129 which describes the small difference between the Luminary 130 and 131. The reconstructed source code was verified by matching memory-bank checksums to those listed for Luminary 130 in drawing 2021152G.

In this source code, program comments from the original (Luminary 131) code are prefixed with '#', while those added later by the Virtual AGC project are prefixed with '##'.

062494,000002:                                                                                                  ## Copyright:   Public domain.
062495,000003:                                                                                                  ## Filename:    KALMAN_FILTER.agc
062496,000004:                                                                                                  ## Purpose:     A section of the reconstructed source code for Luminary 130.
062497,000005:                                                                                                  ##              This was the original program released for the Apollo 13 LM,
062498,000006:                                                                                                  ##              although several more revisions would follow. It has been
062499,000007:                                                                                                  ##              reconstructed from a listing of Luminary 131, from which it
062500,000008:                                                                                                  ##              differs on only two lines in P70-P71. The difference is
062501,000009:                                                                                                  ##              described in detail in Luminary memo #129, which was used
062502,000010:                                                                                                  ##              to perform the reconstruction. This file is intended to be a
062503,000011:                                                                                                  ##              faithful reconstruction, except that the code format has been
062504,000012:                                                                                                  ##              changed to conform to the requirements of the yaYUL assembler
062505,000013:                                                                                                  ##              rather than the original YUL assembler.
062506,000014:                                                                                                  ## Reference:   pp. 1462-1463
062507,000015:                                                                                                  ## Contact:     Ron Burkey <info@sandroid.org>.
062508,000016:                                                                                                  ## Website:     www.ibiblio.org/apollo/index.html
062509,000017:                                                                                                  ## Mod history: 06/08/03 RSB.   Began transcribing.
062510,000018:                                                                                                  ##              05/14/05 RSB    Corrected website reference above
062511,000019:                                                                                                  ##              2017-01-06 RSB  Page numbers now agree with those on the
062512,000020:                                                                                                  ##                              original hardcopy, as opposed to the PDF page
062513,000021:                                                                                                  ##                              numbers in 1701.pdf.
062514,000022:                                                                                                  ##              2017-02-28 RSB  Proofed comment text using octopus/ProoferComments.
062515,000023:                                                                                                  ##              2018-09-04 MAS  Copied from Luminary 131 for Luminary 130.
062516,000024: 

Page 1462

062518,000026: 17,3777  E6,1522                                  EBANK=   NO.UJETS                              
062519,000027: 16,3645                                           BANK     16                                    
062520,000028: 16,2000                                           SETLOC   DAPS1                                 
062521,000029: 16,2000                                           BANK                                           
062522,000030: 
062523,000031: 16,3645                                           COUNT*   $$/DAP                                
062524,000032: 
062525,000033: 16,3645           34752        RATELOOP           CA       TWO                                   
062526,000034: 16,3646           55743                           TS       DAPTEMP6                              
062527,000035: 16,3647           60000                           DOUBLE                                         
062528,000036: 16,3650           54002                           TS       Q                                     
062529,000037: 16,3651           51743                           INDEX    DAPTEMP6                              
062530,000038: 16,3652           11524                           CCS      TJP                                   
062531,000039: 16,3653           13655                           TCF      +2                                    
062532,000040: 16,3654           13674                           TCF      LOOPRATE                              
062533,000041: 16,3655           63735                           AD       -100MST6                              
062534,000042: 16,3656           00006                           EXTEND                                         
062535,000043: 16,3657           63713                           BZMF     SMALLTJU                              
062536,000044: 16,3660           51743                           INDEX    DAPTEMP6                              
062537,000045: 16,3661           11524                           CCS      TJP                                   
062538,000046: 16,3662           33735                           CA       -100MST6                              
062539,000047: 16,3663           13665                           TCF      +2                                    
062540,000048: 16,3664           43735                           CS       -100MST6                              
062541,000049: 16,3665           51743                           INDEX    DAPTEMP6                              
062542,000050: 16,3666           27524                           ADS      TJP                                   
062543,000051: 16,3667           51743                           INDEX    DAPTEMP6                              
062544,000052: 16,3670           11524                           CCS      TJP                                   
062545,000053: 16,3671           43621                           CS       -100MS                                #  0.1 AT 1
062546,000054: 16,3672           13674                           TCF      +2                                    
062547,000055: 16,3673           33621                           CA       -100MS                                
062548,000056: 16,3674           00006        LOOPRATE           EXTEND                                         
062549,000057: 16,3675           51743                           INDEX    DAPTEMP6                              
062550,000058: 16,3676           71521                           MP       NO.PJETS                              
062551,000059: 16,3677           30001                           CA       L                                     
062552,000060: 16,3700           51743                           INDEX    DAPTEMP6                              
062553,000061: 16,3701           55736                           TS       DAPTEMP1                              #  SIGNED TORQUE AT 1 JET-SEC FOR FILTER
062554,000062: 16,3702           00006                           EXTEND                                         
062555,000063: 16,3703           74742                           MP       BIT10                                 #  RESCALE TO 32; ONE BIT ABOUT 2 JET-MSEC
062556,000064: 16,3704           00006                           EXTEND                                         
062557,000065: 16,3705           63736                           BZMF     NEGTORK                               
062558,000066: 16,3706           50002        STORTORK           INDEX    Q                                     #  INCREMENT DOWNLIST REGISTER.
062559,000067: 16,3707           27513                           ADS      DOWNTORK                              #        NOTE:  NOT INITIALIZED; OVERFLOWS.
062560,000068: 
062561,000069: 16,3710           11743                           CCS      DAPTEMP6                              
062562,000070: 16,3711           13646                           TCF      RATELOOP   +1                         
062563,000071: 16,3712           13722                           TCF      ROTORQUE                              
062564,000072: 16,3713           34755        SMALLTJU           CA       ZERO                                  
062565,000073: 16,3714           51743                           INDEX    DAPTEMP6                              
062566,000074: 16,3715           57524                           XCH      TJP                                   
062567,000075: 16,3716           00006                           EXTEND                                         

Page 1463

062569,000077: 16,3717           74760                           MP       ELEVEN                                #  10.24 PLUS
062570,000078: 16,3720           30001                           CA       L                                     
062571,000079: 16,3721           13674                           TCF      LOOPRATE                              
062572,000080: 16,3722           31737        ROTORQUE           CA       DAPTEMP2                              
062573,000081: 16,3723           61740                           AD       DAPTEMP3                              
062574,000082: 16,3724           00006                           EXTEND                                         
062575,000083: 16,3725           71532                           MP       1JACCR                                
062576,000084: 16,3726           55746                           TS       JETRATER                              
062577,000085: 16,3727           41740                           CS       DAPTEMP3                              
062578,000086: 16,3730           61737                           AD       DAPTEMP2                              
062579,000087: 16,3731           00006                           EXTEND                                         
062580,000088: 16,3732           71531                           MP       1JACCQ                                
062581,000089: 16,3733           55745                           TS       JETRATEQ                              
062582,000090: 16,3734           12316                           TCF      BACKP                                 
062583,000091: 16,3735           77537        -100MST6           DEC      -160       B-14                       
062584,000092: 
062585,000093: 16,3736           40000        NEGTORK            COM                                            
062586,000094: 16,3737           24002                           INCR     Q                                     
062587,000095: 16,3740           13706                           TCF      STORTORK                              
062588,000096: 
062589,000097: 

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