Source Code

These source-code files derive from a printout of Luminary 210 (Apollo 15-17 Lunar Module guidance computer program), from the personal library of original AGC developer Don Eyles, digitally photographed at archive.org, financially sponsored by Jim Lawton, and transcribed to source code by a team of volunteers. This colorized, syntax-highlighted form was created by assembling that transcribed source code. Note that the full page images are available on the Virtual AGC project page at archive.org, while reduced-size images are presented at the VirtualAGC project website. Report or fix any transcription errors at the Virtual AGC project code repository.

Notations on the program listing read, in part:

	GAP: ASSEMBLE REVISION 210 OF AGC PROGRAM LUMINARY 
	BY NASA 2021112-161 17:11 MAR. 19,1971
Note that the date is the date of the printout, not the date of the program revision.

040838,000002:                                                                                                  ## Copyright:   Public domain.
040839,000003:                                                                                                  ## Filename:    P51-P53.agc
040840,000004:                                                                                                  ## Purpose:     A section of Luminary revision 210.
040841,000005:                                                                                                  ##              It is part of the source code for the Lunar Module's (LM)
040842,000006:                                                                                                  ##              Apollo Guidance Computer (AGC) for Apollo 15-17.
040843,000007:                                                                                                  ##              This file is intended to be a faithful transcription, except
040844,000008:                                                                                                  ##              that the code format has been changed to conform to the
040845,000009:                                                                                                  ##              requirements of the yaYUL assembler rather than the
040846,000010:                                                                                                  ##              original YUL assembler.
040847,000011:                                                                                                  ## Reference:   pp. 923-981
040848,000012:                                                                                                  ## Assembler:   yaYUL
040849,000013:                                                                                                  ## Contact:     Ron Burkey <info@sandroid.org>.
040850,000014:                                                                                                  ## Website:     www.ibiblio.org/apollo/index.html
040851,000015:                                                                                                  ## Mod history: 2016-11-17 JL   Created from Luminary131 version.
040852,000016:                                                                                                  ##              2016-12-07 MAS  Began transcription.
040853,000017:                                                                                                  ##              2016-12-08 MAS  Finished updates for Luminary 210.
040854,000018:                                                                                                  ##              2016-12-11 HG   Fix operand FLT69FLG -> FLT59FLG
040855,000019:                                                                                                  ##                                  Operator TCF GOTOPOOH -> TC GOTOPOOH   
040856,000020:                                                                                                  ##                                           TC  CHKOUT   -> TCF CHKOUT   
040857,000021:                                                                                                  ##              2016-12-26 RSB  Comment-text proofed using ProoferComments
040858,000022:                                                                                                  ##                              and corrected errors found.
040859,000023:                                                                                                  ##              2017-03-16 RSB  Comment-text fixes identified in 5-way
040860,000024:                                                                                                  ##                              side-by-side diff of Luminary 69/99/116/131/210.
040861,000025: 

Page 923

040863,000027:                                                                                                  #  PROGRAM NAME- PROG52                                                                   DATE- JAN 9, 1967
040864,000028:                                                                                                  #  MOD NO- 0                                                                              LOG SECTION- P51-P53
040865,000029:                                                                                                  #  MODIFICATION BY- LONSKE                                                                ASSEMBLY- SUNDANCE REV 46
040866,000030: 
040867,000031:                                                                                                  #  FUNCTIONAL DESCRIPTION-
040868,000032: 
040869,000033:                                                                                                  #       ALIGNS THE IMU TO ONE OF THREE ORIENTATIONS SELECTED BY THE ASTRONAUT. THE PRESENT IMU ORIENTATION IS KNOWN
040870,000034:                                                                                                  #  AND IS STORED IN REFSMMAT. THE THREE POSSIBLE ORIENTATIONS MAY BE_
040871,000035: 
040872,000036:                                                                                                  #       (A) PREFERRED ORIENTATION
040873,000037: 
040874,000038:                                                                                                  #        AN OPTIMUM ORIENTATION FOR A PREVIOUSLY CALCULATED MANUEVER. THIS ORIENTATION MUST BE CALCULATED AND
040875,000039:                                                                                                  #       STORED BY A PREVIOUSLY SELECTED PROGRAM.
040876,000040: 
040877,000041:                                                                                                  #       (B) NOMINAL ORIENTATION
040878,000042: 
040879,000043:                                                                                                  #           X   =  UNIT ( R )
040880,000044:                                                                                                  #           -SM
040881,000045: 
040882,000046:                                                                                                  #           Y  =  UNIT (V X R)
040883,000047:                                                                                                  #            SM
040884,000048: 
040885,000049:                                                                                                  #           Z   =  UNIT (X   X  Y  )
040886,000050:                                                                                                  #            SM           SM     SM
040887,000051: 
040888,000052:                                                                                                  #           WHERE_
040889,000053:                                                                                                  #            R = THE GEOCENTRIC RADIUS VECTOR AT TIME T(ALIGN) SELECTED BY THE ASTRONAUT
040890,000054:                                                                                                  #            -
040891,000055: 
040892,000056:                                                                                                  #            V = THE INERTIAL VELOCITY VECTOR AT TIME T(ALIGN) SELECTED BY THE ASTRONAUT
040893,000057:                                                                                                  #            -
040894,000058: 
040895,000059:                                                                                                  #       (C) REFSMMAT ORIENTATION
040896,000060: 
040897,000061:                                                                                                  #           (D)  LANDING SITE - THIS IS NOT AVAILIBLE IN SUNDANCE
040898,000062: 
040899,000063:                                                                                                  #        THIS SELECTION CORRECTS THE PRESENT IMU ORIENTATION. THE PRESENT ORIENTATION DIFFERS FROM THAT TO WHICH IT
040900,000064:                                                                                                  #       WAS LAST ALIGNED ONLY DUE TO GYRO DRIFT(I.E. NEITHER GIMBAL LOCK NOR IMU POWER INTERRUPTION HAS OCCURED
040901,000065:                                                                                                  #       SINCE THE LAST ALIGNMENT).
040902,000066: 
040903,000067:                                                                                                  #       AFTER A IMU ORIENTATION HAS BEEN SELECTED ROUTINE S52.2 IS OPERATED TO COMPUTE THE GIMBAL ANGLES USING THE
040904,000068:                                                                                                  #  NEW ORIENTATION AND THE PRESENT VEHICLE ATTITUDE. CAL52A THEN USES THESE ANGLES, STORED IN THETAD,+1,+2, TO
040905,000069:                                                                                                  #  COARSE ALIGN THE IMU. THE STAR SELECTION ROUTINE, R56, IS THEN OPERATED. IF 2 STARS ARE NOT AVAILABLE AN ALARM
040906,000070:                                                                                                  #  IS FLASHED TO NOTIFY THE ASTRONAUT. AT THIS POINT THE ASTRONAUT WILL MANUEVER THE VEHICLE AND SELECT 2 STARS
040907,000071:                                                                                                  #  EITHER MANUALLY OR AUTOMATICALLY. AFTER 2 STARS HAVE BEEN SELECTED THE IMU IS FINE ALIGNED USING ROUTINE R51. IF
040908,000072:                                                                                                  #  THE RENDEZVOUS NAVIGATION PROCESS IS OPERATING(INDICATED BY RNDVZFLG) P20 IS DISPLAYED. OTHERWISE P00 IS
040909,000073:                                                                                                  #  REQUESTED.
040910,000074: 
040911,000075:                                                                                                  #  CALLING SEQUENCE-

Page 924

040913,000077:                                                                                                  #       THE PROGRAM IS CALLED BY THE ASTRONAUT BY DSKY ENTRY.
040914,000078: 
040915,000079:                                                                                                  #  SUBROUTINES CALLED-
040916,000080: 
040917,000081:                                                                                                  #      1. FLAGDOWN      7. S52.2           13. NEWMODEX
040918,000082:                                                                                                  #      2. R02BOTH       8. CAL53A          14. PRIOLARM
040919,000083:                                                                                                  #      3. GOPERF4       9. FLAGUP
040920,000084:                                                                                                  #      4. MATMOVE      10. R56
040921,000085:                                                                                                  #      5. GOFLASH      11. R51
040922,000086:                                                                                                  #      6. S52.3        12. GOPERF3
040923,000087: 
040924,000088:                                                                                                  #  NORMAL EXIT MODES-
040925,000089: 
040926,000090:                                                                                                  #      EXITS TO ENDOFJOB
040927,000091: 
040928,000092:                                                                                                  #  ALARM OR ABORT EXIT MODES-
040929,000093: 
040930,000094:                                                                                                  #      NONE
040931,000095: 
040932,000096:                                                                                                  #  OUTPUT-
040933,000097: 
040934,000098:                                                                                                  #      THE FOLLOWING MAY BE FLASHED ON THE DSKY
040935,000099:                                                                                                  #         1. IMU ORIENTATION CODE
040936,000100:                                                                                                  #         2. ALARM CODE 215 -PREFERRED IMU ORIENTATION NOT SPECIFIED
040937,000101:                                                                                                  #         3. TIME OF NEXT IGNITION
040938,000102:                                                                                                  #         4. GIMBAL ANGLES
040939,000103:                                                                                                  #         5. ALARM CODE 405 -TWO STARS NOT AVAILABLE
040940,000104:                                                                                                  #         6. PLEASE PERFORM P00
040941,000105:                                                                                                  #      THE MODE DISPLAY MAY BE CHANGED TO 20
040942,000106: 
040943,000107:                                                                                                  #  ERASABLE INITIALIZATION REQUIRED-
040944,000108: 
040945,000109:                                                                                                  #      PFRATFLG SHOULD BE SET IF A PREFERRED ORIENTATION HAS BEEN COMPUTED.IF IT HAS BEEN COMPUTED IT IS STORED IN
040946,000110:                                                                                                  #      XSMD,YSMD,ZSMD.
040947,000111:                                                                                                  #      RNDVZFLG INDICATES WHETHER THE RENDEZVOUS NAVIGATION PROCESS IS OPERATING.
040948,000112: 
040949,000113:                                                                                                  #  DEBRIS-
040950,000114: 
040951,000115:                                                                                                  #      WORK AREA
040952,000116: 15,2000                                           SETLOC   P50S                                  
040953,000117: 15,2000                                           BANK                                           
040954,000118: 
040955,000119: 15,2201  E5,1755                                  EBANK=   BESTI                                 
040956,000120: 15,2201                                           COUNT*   $$/P52                                
040957,000121: 15,2201           04607        PROG52             TC       BANKCALL                              
040958,000122: 15,2202           33757                           CADR     R02BOTH                               #  IMU STATUS CHECK
040959,000123: 15,2203           34741                           CAF      PFRATBIT                              
040960,000124: 15,2204           70076                           MASK     FLAGWRD2                              #  IS PFRATFLG SET?
040961,000125: 15,2205           10000                           CCS      A                                     
040962,000126: 15,2206           02211                           TC       P52A                                  #  YES

Page 925

040964,000128: 15,2207           36266                           CAF      THREE                                 #  DISPLAY REFSMMAT OPTION 3
040965,000129: 15,2210           02212                           TC       P52A       +1                         
040966,000130: 15,2211           34744        P52A               CAF      BIT1                                  
040967,000131: 15,2212           55144                           TS       OPTION2                               
040968,000132: 15,2213           34744        P52B               CAF      BIT1                                  
040969,000133: 15,2214           04607                           TC       BANKCALL                              #  FLASH OPTION CODE AND ORIENTATION CODE
040970,000134: 15,2215           20725                           CADR     GOPERF4R                              #  FLASH V04N06
040971,000135: 15,2216           06001                           TC       GOTOPOOH                              
040972,000136: 15,2217           12224                           TCF      +5                                    #  V33-PROCEED
040973,000137: 15,2220           02213                           TC       P52B                                  #  NEW CODE - NEW ORIENTATION CODE INPUT
040974,000138: 15,2221           05355                           TC       PHASCHNG                              #  DISPLAY RETURN
040975,000139: 15,2222           00014                           OCT      00014                                 
040976,000140: 15,2223           05146                           TC       ENDOFJOB                              
040977,000141: 
040978,000142: 15,2224           31144                           CA       OPTION2                               
040979,000143: 15,2225           76266                           MASK     THREE                                 
040980,000144: 15,2226           50000                           INDEX    A                                     
040981,000145: 15,2227           02230                           TC       +1                                    
040982,000146: 15,2230           12236                           TCF      OPT4                                  #  OPTION 4 LANDING SITE
040983,000147: 15,2231           12310                           TCF      P52H                                  #  OPTION 1 PREFERRED
040984,000148: 15,2232           12243                           TCF      P52T                                  #  OPTION 2 NOMINAL
040985,000149: 15,2233           06060        P52E               TC       INTPRET                               #  OPTION 3 REFSMMAT
040986,000150: 15,2234           77650                           GOTO                                           
040987,000151: 15,2235           32321                                    P52F                                  #  GO DO R51
040988,000152: 
040989,000153: 15,2236           34732        OPT4               CAF      EBANK4                                #  SET EBANK TO USE TLAND
040990,000154: 15,2237           54003                           TS       EBANK                                 
040991,000155: 15,2240  E4,1426                                  EBANK=   TLAND                                 
040992,000156: 15,2240           00006                           EXTEND                                         
040993,000157: 15,2241           31427                           DCA      TLAND                                 #  IF OPTION 4 DISPLAY TLAND
040994,000158: 15,2242           12245                           TCF      P52T       +2                         
040995,000159: 
040996,000160: 15,2243           00006        P52T               EXTEND                                         
040997,000161: 15,2244           34746                           DCA      NEG0                                  
040998,000162: 15,2245           53045                           DXCH     DSPTEM1                               
040999,000163: 15,2246           35005                           CAF      EBANK5                                #  RESTORE EBANK AFTER USE OF TLAND
041000,000164: 15,2247           54003                           TS       EBANK                                 
041001,000165: 15,2250  E5,1774                                  EBANK=   TALIGN                                
041002,000166: 15,2250           32325                           CAF      V06N34*                               
041003,000167: 15,2251           04607                           TC       BANKCALL                              
041004,000168: 15,2252           20471                           CADR     GOFLASH                               
041005,000169: 15,2253           06001                           TC       GOTOPOOH                              
041006,000170: 15,2254           02256                           TC       +2                                    
041007,000171: 15,2255           02250                           TC       -5                                    
041008,000172: 15,2256           53045                           DXCH     DSPTEM1                               
041009,000173: 15,2257           00006                           EXTEND                                         
041010,000174: 15,2260           62262                           BZMF     +2                                    #  IF TIME ZERO OR NEG USE TIME2
041011,000175: 15,2261           12264                           TCF      +3                                    
041012,000176: 15,2262           00006                           EXTEND                                         
041013,000177: 15,2263           30025                           DCA      TIME2                                 

Page 926

041015,000179: 15,2264           53775                           DXCH     TALIGN                                
041016,000180: 15,2265           31144        P52V               CA       OPTION2                               
041017,000181: 15,2266           74743                           MASK     BIT2                                  
041018,000182: 15,2267           10000                           CCS      A                                     
041019,000183: 15,2270           02274                           TC       P52W                                  
041020,000184: 15,2271           06060                           TC       INTPRET                               #  OPTION 4 - GET LS ORIENTATION
041021,000185: 15,2272           77650                           GOTO                                           
041022,000186: 15,2273           32355                                    P52LS                                 
041023,000187: 

Page 927

041025,000189:                                                                                                  #  START ALIGNMENT 
041026,000190: 
041027,000191: 15,2274           06060        P52W               TC       INTPRET                               
041028,000192: 15,2275           45145                           DLOAD    CALL                                  #  PICK UP ALIGN TIME
041029,000193: 15,2276           02775                                    TALIGN                                #  COMPUTE NOMINAL IMU
041030,000194: 15,2277           42740                                    S52.3                                 #   ORIENTATION
041031,000195: 15,2300           77624        P52D               CALL                                           #  READ VEHICLE ATTITUDE AND
041032,000196: 15,2301           42707                                    S52.2                                 #   COMPUTE GIMBAL ANGLES
041033,000197: 15,2302           77776                           EXIT                                           
041034,000198: 15,2303           35001                           CAF      V06N22                                
041035,000199: 15,2304           04607                           TC       BANKCALL                              #  DISPLAY GIMBAL ANGLES
041036,000200: 15,2305           20471                           CADR     GOFLASH                               
041037,000201: 15,2306           06001                           TC       GOTOPOOH                              
041038,000202: 15,2307           12326                           TCF      COARSTYP                              #  V33-PROCEED, SEE IF GYRO TORQUE COARSE
041039,000203: 15,2310           06060        P52H               TC       INTPRET                               
041040,000204: 15,2311           77650                           GOTO                                           
041041,000205: 15,2312           32300                                    P52D                                  
041042,000206: 15,2313           06060        REGCOARS           TC       INTPRET                               
041043,000207: 15,2314           77624                           CALL                                           #  DO COARSE ALIGN
041044,000208: 15,2315           31316                                    CAL53A                                #   ROUTINE
041045,000209: 15,2316           43014        COARSRET           SET      CLEAR                                 
041046,000210: 15,2317           01462                                    REFSMFLG                              
041047,000211: 15,2320           01273                                    PFRATFLG                              
041048,000212: 15,2321           77624        P52F               CALL                                           
041049,000213: 15,2322           31023                                    R51                                   
041050,000214: 15,2323           77776        P52OUT             EXIT                                           
041051,000215: 15,2324           06001                           TC       GOTOPOOH                              
041052,000216: 15,2325     4777               VB05N09            =        V05N09                                
041053,000217: 15,2325           01442        V06N34*            VN       634                                   
041054,000218: 

Page 928

041056,000220:                                                                                                  #  CHECK FOR GRRO TORQUE COARSE ALIGNMENT
041057,000221: 15,2326           32354        COARSTYP           CAF      OCT13                                 
041058,000222: 15,2327           04607                           TC       BANKCALL                              #  DISPLAY V 50N25 WITH COARSE ALIGN OPTION
041059,000223: 15,2330           20635                           CADR     GOPERF1                               
041060,000224: 15,2331           16001                           TCF      GOTOPOOH                              #  V34-TERMIN&OE
041061,000225: 15,2332           12313                           TCF      REGCOARS                              #  V33-NORMAL COARSE
041062,000226: 15,2333           06060                           TC       INTPRET                               #  V32-GYRO TORQUE COARSE
041063,000227: 15,2334           64375                           VLOAD    MXV                                   
041064,000228: 15,2335           03607                                    XSMD                                  #  GET SM(DESIRED) WRT SM(PRESENT)
041065,000229: 15,2336           01732                                    REFSMMAT                              
041066,000230: 15,2337           77656                           UNIT                                           
041067,000231: 15,2340           26665                           STOVL    XDC                                   
041068,000232: 15,2341           03615                                    YSMD                                  
041069,000233: 15,2342           53521                           MXV      UNIT                                  
041070,000234: 15,2343           01732                                    REFSMMAT                              
041071,000235: 15,2344           26673                           STOVL    YDC                                   
041072,000236: 15,2345           03623                                    ZSMD                                  
041073,000237: 15,2346           53521                           MXV      UNIT                                  
041074,000238: 15,2347           01732                                    REFSMMAT                              
041075,000239: 15,2350           36701                           STCALL   ZDC                                   
041076,000240: 15,2351           31174                                    GYCOARS                               
041077,000241: 15,2352           77650                           GOTO                                           
041078,000242: 15,2353           32323                                    P52OUT                                
041079,000243: 15,2354           00013        OCT13              OCT      13                                    
041080,000244: 

Page 929

041082,000246:                                                                                                  #  COMPUTE LANDING ORIENTATION FOR OPTION 4
041083,000247: 15,2355           43014        P52LS              SET      CLEAR                                 #  GET LANDING SITE ORIENTATION
041084,000248: 15,2356           01463                                    LUNAFLAG                              
041085,000249: 15,2357           00662                                    ERADFLAG                              #  TO PICK UP RLS
041086,000250: 15,2360           77201                           SETPD    VLOAD                                 
041087,000251: 15,2361           00001                                    0                                     
041088,000252: 15,2362           02021                                    RLS                                   #  PICK UP LANDING SITE VEC IN MF
041089,000253: 15,2363           41525                           PDDL     PUSH                                  #  RLS PD 0-5
041090,000254: 15,2364           02775                                    TALIGN                                
041091,000255: 15,2365           36027                           STCALL   TLAND                                 #  JAM ALIGN TIME IN TLAND FOR OPTION 4
041092,000256: 
041093,000257: 15,2366           55716                                    RP-TO-R                               #  TRANS RLS TO REF
041094,000258: 15,2367           77742                           VSR2                                           
041095,000259: 15,2370           16032                           STODL    ALPHAV                                #  INPUT TO LAT-LONG
041096,000260: 15,2371           02775                                    TALIGN                                
041097,000261: 15,2372           77624                           CALL                                           
041098,000262: 15,2373           30455                                    N89DISP                               
041099,000263: 15,2374           53575                           VLOAD    UNIT                                  #  COMPUTE LANDING SITE ORIENT (XSMD)
041100,000264: 15,2375           02032                                    ALPHAV                                
041101,000265: 15,2376           37607                           STCALL   XSMD                                  
041102,000266: 15,2377           11014                                    LSORIENT                              
041103,000267: 15,2400           77650                           GOTO                                           
041104,000268: 15,2401           32300                                    P52D                                  #  NOW GO COMPUTE GIMBAL ANGLES
041105,000269: 
041106,000270: 13,2000                                           SETLOC   P50S2                                 
041107,000271: 13,2000                                           BANK                                           
041108,000272: 
041109,000273: 13,2374           77773        MATMOVE            VLOAD*                                         
041110,000274: 13,2375           00001                                    0,1                                   
041111,000275: 13,2376           10001                           STORE    0,2                                   
041112,000276: 13,2377           77773                           VLOAD*                                         
041113,000277: 13,2400           00007                                    6D,1                                  
041114,000278: 13,2401           10007                           STORE    6D,2                                  
041115,000279: 13,2402           77773                           VLOAD*                                         
041116,000280: 13,2403           00015                                    12D,1                                 
041117,000281: 13,2404           10015                           STORE    12D,2                                 
041118,000282: 13,2405           77616                           RVQ                                            
041119,000283: 

Page 930

041121,000285:                                                                                                  #  SUBROUTINE TO CALCULATE AND DISPLAY THE LUNAR LANDING SITE
041122,000286: 
041123,000287: 14,2000                                           SETLOC   P50S1                                 
041124,000288: 14,2000                                           BANK                                           
041125,000289: 14,2455  E5,1642                                  EBANK=   XSM                                   
041126,000290: 
041127,000291: 14,2455           77620        N89DISP            STQ                                            
041128,000292: 14,2456           02746                                    QMAJ                                  
041129,000293: 14,2457           35242                           STCALL   SITIME                                #  STORE TIME
041130,000294: 14,2460           26406                                    LAT-LONG                              
041131,000295: 14,2461           70545                           DLOAD    SR1                                   
041132,000296: 14,2462           01122                                    LONG                                  
041133,000297: 14,2463           16711                           STODL    LANDLONG                              
041134,000298: 14,2464           01124                                    ALT                                   
041135,000299: 14,2465           16713                           STODL    LANDALT                               
041136,000300: 14,2466           01120                                    LAT                                   
041137,000301: 14,2467           02707                           STORE    LANDLAT                               
041138,000302: 14,2470           77776                           EXIT                                           
041139,000303: 
041140,000304: 14,2471           32514        LSDISP             CAF      V06N89*                               #  DISPLAY LAT,LONG/2,ALT
041141,000305: 14,2472           04607                           TC       BANKCALL                              
041142,000306: 14,2473           20471                           CADR     GOFLASH                               
041143,000307: 14,2474           16001                           TCF      GOTOPOOH                              #  V34-TERMINATE-EXIT P57
041144,000308: 14,2475           12477                           TCF      +2                                    #  V33-PROCEED- ACCEPT LS DATA
041145,000309: 14,2476           12471                           TCF      LSDISP                                #  V32 OR E- LOOK AGAIN AND/OR LOAD NEW LS
041146,000310: 
041147,000311: 14,2477           06060                           TC       INTPRET                               
041148,000312: 14,2500           72545                           DLOAD    SL1                                   
041149,000313: 14,2501           02711                                    LANDLONG                              
041150,000314: 14,2502           15122                           STODL    LONG                                  
041151,000315: 14,2503           02713                                    LANDALT                               
041152,000316: 14,2504           15124                           STODL    ALT                                   
041153,000317: 14,2505           02707                                    LANDLAT                               
041154,000318: 14,2506           15120                           STODL    LAT                                   
041155,000319: 14,2507           01242                                    SITIME                                #  PICK UP TIME
041156,000320: 14,2510           77624                           CALL                                           #  GET RLS BACK FROM LAT,LONG, ALT
041157,000321: 14,2511           26457                                    LALOTORV                              #  RLS B-29 IN MPAC AND ALPHAV
041158,000322: 14,2512           77650                           GOTO                                           
041159,000323: 14,2513           02746                                    QMAJ                                  
041160,000324: 14,2514           01531        V06N89*            VN       689                                   
041161,000325: 

Page 931

041163,000327:                                                                                                  #  NAME -S50 ALIAS  LOCSAM
041164,000328:                                                                                                  #  BY
041165,000329:                                                                                                  #  VINCENT
041166,000330:                                                                                                  #  FUNCTION - COMPUTE INPUTS FOR PICAPAR  AND PLANET
041167,000331: 
041168,000332:                                                                                                  #           DEFINE
041169,000333: 
041170,000334: 
041171,000335:                                                                                                  #           U    = UNIT( SUN WRT EARTH)
041172,000336:                                                                                                  #            ES
041173,000337: 
041174,000338:                                                                                                  #           U    =UNIT( MOON WRT EARTH)
041175,000339:                                                                                                  #            EM
041176,000340: 
041177,000341:                                                                                                  #           R    =POSITION VECTOR OF LEM
041178,000342:                                                                                                  #            L
041179,000343: 
041180,000344:                                                                                                  #           R    =MEAN DISTANCE (384402KM) BETWEEN EARTH AND MOON
041181,000345:                                                                                                  #            EM
041182,000346: 
041183,000347:                                                                                                  #           P    =RATIO   R   /(DISTANCE SUN TO EARTH)    >.00257125
041184,000348:                                                                                                  #                           EM
041185,000349: 
041186,000350:                                                                                                  #           R    =EQUATORIAL RADIUSS (6378.166KM) OF EARTH
041187,000351:                                                                                                  #            E
041188,000352: 
041189,000353:                                                                                                  #           LOCSAM  COMPUTES IN EARTH INFLUENCE
041190,000354: 
041191,000355:                                                                                                  #       VSUN   =   U
041192,000356:                                                                                                  #                   ES
041193,000357: 
041194,000358:                                                                                                  #      VEARTH  =   -UNIT( R  )
041195,000359:                                                                                                  #                          L
041196,000360: 
041197,000361:                                                                                                  #      VMOON   =    UNIT(R  .U   - R  )
041198,000362:                                                                                                  #                         EM  EM    L
041199,000363: 
041200,000364:                                                                                                  #      CSUN    =   COS 90
041201,000365: 
041202,000366:                                                                                                  #      CEARTH  =    COS(5 + ARCSIN(R /MAG(R )))
041203,000367:                                                                                                  #                                   E      L
041204,000368: 
041205,000369:                                                                                                  #      CMOON   =    COS 5
041206,000370: 
041207,000371: 
041208,000372:                                                                                                  #  INPUT -  TIME IN MPAC
041209,000373:                                                                                                  #  OUTPUT - LISTED ABOVE
041210,000374:                                                                                                  #  SUBROUTINES -LSPOS,LEMPREC
041211,000375:                                                                                                  #  DEBRIS - VAC AREA ,TSIGHT
041212,000376: 

Page 932

041214,000378: 14,2515                                           COUNT*   $$/LOSAM                              
041215,000379: 
041216,000380: 14,2515  14,2515               S50                =        LOCSAM                                
041217,000381: 14,2515           77620        LOCSAM             STQ                                            
041218,000382: 14,2516           02745                                    QMIN                                  
041219,000383: 14,2517           37562                           STCALL   TSIGHT                                
041220,000384: 14,2520           33646                                    LSPOS                                 
041221,000385: 14,2521           77745                           DLOAD                                          
041222,000386: 14,2522           03562                                    TSIGHT                                
041223,000387: 14,2523           34041                           STCALL   TDEC1                                 
041224,000388: 14,2524           27115                                    LEMPREC                               
041225,000389: 14,2525           61131                           SSP      TIX,2                                 
041226,000390: 14,2526           00052                                    S2                                    
041227,000391: 14,2527           00000                                    0                                     
041228,000392: 14,2530           30552                                    MOONCNTR                              
041229,000393: 14,2531           74375        EARTCNTR           VLOAD    VXSC                                  
041230,000394: 14,2532           02723                                    VMOON                                 
041231,000395: 14,2533           30001                                    RSUBEM                                
041232,000396: 14,2534           52372                           VSL1     VSU                                   
041233,000397: 14,2535           00001                                    RATT                                  
041234,000398: 14,2536           77656                           UNIT                                           
041235,000399: 14,2537           26723                           STOVL    VMOON                                 
041236,000400: 14,2540           00001                                    RATT                                  
041237,000401: 14,2541           57456                           UNIT     VCOMP                                 
041238,000402: 14,2542           16707                           STODL    VEARTH                                
041239,000403: 14,2543           30005                                    RSUBE                                 
041240,000404: 14,2544           77624                           CALL                                           
041241,000405: 14,2545           30604                                    OCCOS                                 
041242,000406: 14,2546           14017                           STODL    CEARTH                                
041243,000407: 14,2547           30613                                    CSS5                                  
041244,000408: 14,2550           34023                           STCALL   CMOON                                 
041245,000409: 14,2551           30577                                    ENDSAM                                
041246,000410: 14,2552           74375        MOONCNTR           VLOAD    VXSC                                  
041247,000411: 14,2553           02723                                    VMOON                                 
041248,000412: 14,2554           30007                                    ROE                                   
041249,000413: 14,2555           53445                           BVSU     UNIT                                  
041250,000414: 14,2556           02715                                    VSUN                                  
041251,000415: 14,2557           26715                           STOVL    VSUN                                  
041252,000416: 14,2560           02723                                    VMOON                                 
041253,000417: 14,2561           53361                           VXSC     VAD                                   
041254,000418: 14,2562           30001                                    RSUBEM                                
041255,000419: 14,2563           00001                                    RATT                                  
041256,000420: 14,2564           57456                           UNIT     VCOMP                                 
041257,000421: 14,2565           26707                           STOVL    VEARTH                                
041258,000422: 14,2566           00001                                    RATT                                  
041259,000423: 14,2567           57456                           UNIT     VCOMP                                 
041260,000424: 14,2570           16723                           STODL    VMOON                                 
041261,000425: 14,2571           30003                                    RSUBM                                 
041262,000426: 14,2572           77624                           CALL                                           
041263,000427: 14,2573           30604                                    OCCOS                                 

Page 933

041265,000429: 14,2574           14023                           STODL    CMOON                                 
041266,000430: 14,2575           30613                                    CSS5                                  
041267,000431: 14,2576           00017                           STORE    CEARTH                                
041268,000432: 14,2577           77745        ENDSAM             DLOAD                                          
041269,000433: 14,2600           30615                                    CSSUN                                 
041270,000434: 14,2601           00021                           STORE    CSUN                                  
041271,000435: 14,2602           77650                           GOTO                                           
041272,000436: 14,2603           02745                                    QMIN                                  
041273,000437: 14,2604           70471        OCCOS              DDV      SR1                                   
041274,000438: 14,2605           00045                                    36D                                   
041275,000439: 14,2606           43336                           ASIN     DAD                                   
041276,000440: 14,2607           30617                                    5DEGREES                              
041277,000441: 14,2610           70546                           COS      SR1                                   
041278,000442: 14,2611           77616                           RVQ                                            
041279,000443: 14,2612                        CEARTH             =        14D                                   
041280,000444: 14,2612                        CSUN               =        16D                                   
041281,000445: 14,2612                        CMOON              =        18D                                   
041282,000446: 14,2612           07760 14473  CSS5               2DEC     .2490475                              #  (COS 5)/4
041283,000447: 
041284,000448: 14,2614           04000 00000  CSSUN              2DEC     .125                                  #  (COS60)/4
041285,000449: 
041286,000450: 14,2616           00343 21616  5DEGREES           2DEC     .013888889                            #     SCALED IN REVS
041287,000451: 

Page 934

041289,000453:                                                                                                  #  PROGRAM NAME - R56              DATE  DEC 20 66
041290,000454:                                                                                                  #  MOD 1                           LOG SECTION P51-P53
041291,000455:                                                                                                  #                                  ASSEMBLY  SUNDISK  REV40
041292,000456:                                                                                                  #  BY KEN VINCENT
041293,000457: 
041294,000458:                                                                                                  #  FUNCTION
041295,000459:                                                                                                  #    THIS PROGRAM READ THE IMU-CDUS AND COMPUTES THE VEHICLE ORIENTATION
041296,000460:                                                                                                  #  WITH RESPECT TO INERTIAL SPACE. IT THEN COMPUTES THE SHAFT AXIS (SAX)
041297,000461:                                                                                                  #  WITH RESPECT TO REFERENCE INERTIAL. EACH STAR IN THE CATALOG IS TESTED
041298,000462:                                                                                                  #  TO DETERMINE IF IT IS OCCULTED BY EITHER THE EARTH,SUN OR MOON. IF A
041299,000463:                                                                                                  #  STAR IS NOT OCCULTED  THEN IT IS PAIRED WITH ALL STAR OF LOWER INDEX.
041300,000464:                                                                                                  #  THE PAIRED STAR  IS TESTED FOR OCCULTATION. PAIRS OF STARS THAT PASS
041301,000465:                                                                                                  #  THE OCCULTATION TESTS ARE TESTED FOR GOOD SEPARATION.A PAIR OF STARS
041302,000466:                                                                                                  #  HAVE GOOD SEPERATION IF THE ANGLE BETWEEN THEM IS LESS THAN 100 DEGREES
041303,000467:                                                                                                  #  AND MORE THAN 50 DEGREES. THOSE PAIRS WITH GOOD SEPARATION
041304,000468:                                                                                                  #  ARE THEN TESTED TO SEE IF THEY LIE IN CURRENT FIELD OF VIEW.(WITHIN
041305,000469:                                                                                                  #  50 DEGREESOF SAX).THE PAIR WITH MAX SEPARATION IS CHOSEN FROM
041306,000470:                                                                                                  #  THOSE WITH GOOD SEPARATION,AND     IN FIELD OF VIEW.
041307,000471: 
041308,000472:                                                                                                  #  CALLING SEQUENCE
041309,000473:                                                                                                  #  L        TC     BANKCALL
041310,000474:                                                                                                  #  L+1      CADR   R56
041311,000475:                                                                                                  #  L+2      ERROR RETURN - NO STARS IN FIELD OF VIEW
041312,000476:                                                                                                  #  L+3      NORMAL RETURN
041313,000477: 
041314,000478:                                                                                                  #  OUTPUT
041315,000479:                                                                                                  #  BESTI,BESTJ -SINGLE PREC,INTEGERS,STAR NUMBERS TIMES 6
041316,000480:                                                                                                  #  VFLAG - FLAG BIT  SET IMPLIES NO STARS IN FIELD OF VIEW
041317,000481: 
041318,000482:                                                                                                  #  INITIALIZATION
041319,000483:                                                                                                  #  1)A CALL TO LOCSAM MUST BE MADE
041320,000484: 
041321,000485:                                                                                                  #  DEBRIS
041322,000486:                                                                                                  #  WORK AREA
041323,000487:                                                                                                  #  X,Y,ZNB
041324,000488:                                                                                                  #  SINCDU,COSCDU
041325,000489:                                                                                                  #  STARAD - STAR +5
041326,000490: 
041327,000491: 14,2620  14,2620               R56                =        PICAPAR                               
041328,000492: 14,2620                                           COUNT*   $$/R56                                
041329,000493: 14,2620           04636        PICAPAR            TC       MAKECADR                              
041330,000494: 14,2621           55745                           TS       QMIN                                  
041331,000495: 14,2622           06060                           TC       INTPRET                               
041332,000496: 14,2623           45014                           SET      CALL                                  
041333,000497: 14,2624           01465                                    VFLAG                                 
041334,000498: 14,2625           47522                                    CDUTRIG                               
041335,000499: 14,2626           77624                           CALL                                           
041336,000500: 14,2627           20030                                    CALCSMSC                              
041337,000501: 14,2630           71201                           SETPD    DLOAD                                 
041338,000502: 14,2631           00001                                    0                                     
041339,000503: 14,2632           24007                                    DPZERO                                

Page 935

041341,000505: 14,2633           26756                           STOVL    BESTI                                 
041342,000506: 14,2634           02665                                    XNB                                   
041343,000507: 14,2635           63361                           VXSC     PDVL                                  
041344,000508: 14,2636           24005                                    HALFDP                                
041345,000509: 14,2637           02701                                    ZNB                                   
041346,000510: 14,2640           74370                           AXT,1    VXSC                                  
041347,000511: 14,2641           00344                                    228D                                  #  X1 = 37 X 6 +6
041348,000512: 14,2642           24005                                    HALFDP                                
041349,000513: 14,2643           77655                           VAD                                            
041350,000514: 14,2644           53505                           VXM      UNIT                                  
041351,000515: 14,2645           01732                                    REFSMMAT                              
041352,000516: 14,2646           02731                           STORE    SAX                                   #  SAX = SHAFT AXIS
041353,000517: 14,2647           66331                           SSP      SSP                                   #  S1=S2=6
041354,000518: 14,2650           00051                                    S1                                    
041355,000519: 14,2651           00006                                    6                                     
041356,000520: 14,2652           00052                                    S2                                    
041357,000521: 14,2653           00006                                    6                                     
041358,000522: 14,2654           52100        PIC1               TIX,1    GOTO                                  #  MAJOR STAR
041359,000523: 14,2655           30657                                    PIC2                                  
041360,000524: 14,2656           30774                                    PICEND                                
041361,000525: 14,2657           50373        PIC2               VLOAD*   DOT                                   
041362,000526: 14,2660           30347                                    CATLOG,1                              
041363,000527: 14,2661           02731                                    SAX                                   
041364,000528: 14,2662           50025                           DSU      BMN                                   
041365,000529: 14,2663           30773                                    CSS33                                 
041366,000530: 14,2664           30654                                    PIC1                                  
041367,000531: 14,2665           77754                           LXA,2                                          
041368,000532: 14,2666           00046                                    X1                                    
041369,000533: 14,2667           52104        PIC3               TIX,2    GOTO                                  
041370,000534: 14,2670           30672                                    PIC4                                  
041371,000535: 14,2671           30654                                    PIC1                                  
041372,000536: 14,2672           50373        PIC4               VLOAD*   DOT                                   
041373,000537: 14,2673           47430                                    CATLOG,2                              
041374,000538: 14,2674           02731                                    SAX                                   
041375,000539: 14,2675           50025                           DSU      BMN                                   
041376,000540: 14,2676           30773                                    CSS33                                 
041377,000541: 14,2677           30667                                    PIC3                                  
041378,000542: 14,2700           47773                           VLOAD*   DOT*                                  
041379,000543: 14,2701           30347                                    CATLOG,1                              
041380,000544: 14,2702           47430                                    CATLOG,2                              
041381,000545: 14,2703           51025                           DSU      BPL                                   
041382,000546: 14,2704           30771                                    CSS40                                 
041383,000547: 14,2705           30667                                    PIC3                                  
041384,000548: 14,2706           45173                           VLOAD*   CALL                                  
041385,000549: 14,2707           30347                                    CATLOG,1                              
041386,000550: 14,2710           30746                                    OCCULT                                
041387,000551: 14,2711           77614                           BON                                            
041388,000552: 14,2712           01710                                    CULTFLAG                              
041389,000553: 14,2713           30654                                    PIC1                                  
041390,000554: 14,2714           45173                           VLOAD*   CALL                                  

Page 936

041392,000556: 14,2715           47430                                    CATLOG,2                              
041393,000557: 14,2716           30746                                    OCCULT                                
041394,000558: 14,2717           77614                           BON                                            
041395,000559: 14,2720           01710                                    CULTFLAG                              
041396,000560: 14,2721           30667                                    PIC3                                  
041397,000561: 14,2722           77614        STRATGY            BONCLR                                         
041398,000562: 14,2723           01605                                    VFLAG                                 
041399,000563: 14,2724           30741                                    NEWPAR                                
041400,000564: 14,2725           65120                           XCHX,1   XCHX,2                                
041401,000565: 14,2726           02755                                    BESTI                                 
041402,000566: 14,2727           02756                                    BESTJ                                 
041403,000567: 14,2730           47773        STRAT              VLOAD*   DOT*                                  
041404,000568: 14,2731           30347                                    CATLOG,1                              
041405,000569: 14,2732           47430                                    CATLOG,2                              
041406,000570: 14,2733           43006                           PUSH     BOFINV                                
041407,000571: 14,2734           01545                                    VFLAG                                 
041408,000572: 14,2735           30725                                    STRAT      -3                         
041409,000573: 14,2736           45345                           DLOAD    DSU                                   
041410,000574: 14,2737           77644                           BPL                                            
041411,000575: 14,2740           30667                                    PIC3                                  
041412,000576: 14,2741           67130        NEWPAR             SXA,1    SXA,2                                 
041413,000577: 14,2742           02755                                    BESTI                                 
041414,000578: 14,2743           02756                                    BESTJ                                 
041415,000579: 14,2744           77650                           GOTO                                           
041416,000580: 14,2745           30667                                    PIC3                                  
041417,000581: 14,2746           51321        OCCULT             MXV      BVSU                                  
041418,000582: 14,2747           02707                                    CULTRIX                               
041419,000583: 14,2750           00017                                    CSS                                   
041420,000584: 14,2751           77654                           BZE                                            
041421,000585: 14,2752           30765                                    CULTED                                
041422,000586: 14,2753           75240                           BMN      SIGN                                  
041423,000587: 14,2754           30765                                    CULTED                                
041424,000588: 14,2755           00160                                    MPAC       +3                         
041425,000589: 14,2756           75240                           BMN      SIGN                                  
041426,000590: 14,2757           30765                                    CULTED                                
041427,000591: 14,2760           00162                                    MPAC       +5                         
041428,000592: 14,2761           43040                           BMN      CLRGO                                 
041429,000593: 14,2762           30765                                    CULTED                                
041430,000594: 14,2763           01630                                    CULTFLAG                              
041431,000595: 14,2764           00052                                    QPRET                                 
041432,000596: 14,2765           77614        CULTED             SETGO                                          
041433,000597: 14,2766           01430                                    CULTFLAG                              
041434,000598: 14,2767           00052                                    QPRET                                 
041435,000599: 14,2770  0000016               CSS                =        CEARTH                                
041436,000600: 14,2770           05110 35052  CSS40              2DEC     .16070                                #  COS 50 /4
041437,000601: 
041438,000602: 14,2772           05110 35052  CSS33              2DEC     .16070                                #   COS 50 /4
041439,000603: 
041440,000604: 14,2774           77414        PICEND             BOFF     EXIT                                  
041441,000605: 14,2775           01745                                    VFLAG                                 

Page 937

041443,000607: 14,2776           31000                                    PICGXT                                
041444,000608: 14,2777           03021                           TC       PICBXT                                
041445,000609: 14,3000           73150        PICGXT             LXA,1    LXA,2                                 
041446,000610: 14,3001           02755                                    BESTI                                 
041447,000611: 14,3002           02756                                    BESTJ                                 
041448,000612: 14,3003           47775                           VLOAD    DOT*                                  
041449,000613: 14,3004           02731                                    SAX                                   
041450,000614: 14,3005           30347                                    CATLOG,1                              
041451,000615: 14,3006           47715                           PDVL     DOT*                                  
041452,000616: 14,3007           02731                                    SAX                                   
041453,000617: 14,3010           47430                                    CATLOG,2                              
041454,000618: 14,3011           77625                           DSU                                            
041455,000619: 14,3012           66044                           BPL      SXA,1                                 
041456,000620: 14,3013           31017                                    PICNSWP                               
041457,000621: 14,3014           02756                                    BESTJ                                 
041458,000622: 14,3015           77734                           SXA,2                                          
041459,000623: 14,3016           02755                                    BESTI                                 
041460,000624: 14,3017           77776        PICNSWP            EXIT                                           
041461,000625: 14,3020           25745                           INCR     QMIN                                  
041462,000626: 14,3021           31745        PICBXT             CA       QMIN                                  
041463,000627: 14,3022           04613                           TC       SWCALL                                
041464,000628: 14,3023                        VPD                =        0D                                    
041465,000629: 14,3023                        V0                 =        6D                                    
041466,000630: 14,3023                        V1                 =        12D                                   
041467,000631: 14,3023                        V2                 =        18D                                   
041468,000632: 14,3023                        V3                 =        24D                                   
041469,000633: 14,3023                        DP0                =        30D                                   
041470,000634: 14,3023                        DP1                =        32D                                   
041471,000635: 

Page 938

041473,000637:                                                                                                  #  NAME-R51  FINE ALIGN
041474,000638:                                                                                                  #  FUNCTION-TO ALIGN THE STABLE MEMBER TO REFSMMAT
041475,000639:                                                                                                  #  CALLING SEQ- CALL  R51
041476,000640:                                                                                                  #  INPUT -  REFSMMAT
041477,000641:                                                                                                  #  OUTPUT- GYRO TORQUE PULSES
041478,000642:                                                                                                  #  SUBROUTINES -LOCSAM,PICAPAR,R52,R53,R54,R55
041479,000643: 
041480,000644: 14,3023                                           COUNT*   $$/R51                                
041481,000645: 14,3023           77620        R51                STQ                                            
041482,000646: 14,3024           02746                                    QMAJ                                  
041483,000647: 14,3025           77776        R51.1              EXIT                                           
041484,000648: 14,3026           05355                           TC       PHASCHNG                              
041485,000649: 14,3027           04024                           OCT      04024                                 
041486,000650: 
041487,000651: 14,3030           05520        R51C               TC       DOWNFLAG                              
041488,000652: 14,3031           00222                           ADRES    FLT59FLG                              
041489,000653: 
041490,000654: 14,3032           34752                           CAF      OCT15                                 
041491,000655: 14,3033           04607                           TC       BANKCALL                              
041492,000656: 14,3034           20635                           CADR     GOPERF1                               
041493,000657: 14,3035           06001                           TC       GOTOPOOH                              
041494,000658: 14,3036           03046                           TC       DOSAM                                 
041495,000659: 14,3037           44737                           CS       BIT6                                  
041496,000660: 14,3040           70154                           MASK     MPAC                                  
041497,000661: 14,3041           10000                           CCS      A                                     
041498,000662: 14,3042           13071                           TCF      R51E                                  #  ENTER
041499,000663: 14,3043           05506                           TC       UPFLAG                                #  V32-SET FLT59FLG
041500,000664: 14,3044           00222                           ADRES    FLT59FLG                              
041501,000665: 14,3045           13071                           TCF      R51E                                  
041502,000666: 
041503,000667: 14,3046           06060        DOSAM              TC       INTPRET                               
041504,000668: 14,3047           43234                           RTB      DAD                                   
041505,000669: 14,3050           21603                                    LOADTIME                              
041506,000670: 14,3051           31173                                    TSIGHT1                               
041507,000671: 14,3052           77624                           CALL                                           
041508,000672: 14,3053           30515                                    LOCSAM                                
041509,000673: 14,3054           77776                           EXIT                                           
041510,000674: 14,3055           04607                           TC       BANKCALL                              
041511,000675: 14,3056           30620                           CADR     R56                                   
041512,000676: 14,3057           03061                           TC       R51I                                  
041513,000677: 14,3060           03071        R51F               TC       R51E                                  
041514,000678: 14,3061           05571        R51I               TC       ALARM                                 
041515,000679: 14,3062           00405                           OCT      405                                   
041516,000680: 14,3063           34777                           CAF      VB05N09                               
041517,000681: 14,3064           04607                           TC       BANKCALL                              
041518,000682: 14,3065           20471                           CADR     GOFLASH                               
041519,000683: 14,3066           06001                           TC       GOTOPOOH                              
041520,000684: 14,3067           03071                           TC       R51E                                  
041521,000685: 14,3070           03030                           TC       R51C                                  
041522,000686: 14,3071           34746        R51E               CAF      ZERO                                  
041523,000687: 14,3072           55757                           TS       STARIND                               

Page 939

041525,000689: 14,3073           06060        R51.2              TC       INTPRET                               
041526,000690: 14,3074           77776        R51.3              EXIT                                           
041527,000691: 14,3075           05355                           TC       PHASCHNG                              
041528,000692: 14,3076           04024                           OCT      04024                                 
041529,000693: 
041530,000694: 14,3077           06060                           TC       INTPRET                               
041531,000695: 14,3100           77624                           CALL                                           
041532,000696: 14,3101           31603                                    R52                                   #  AOP WILL MAKE CALLS TO SIGHTING
041533,000697: 14,3102           77776                           EXIT                                           
041534,000698: 14,3103           04607                           TC       BANKCALL                              
041535,000699: 14,3104           16000                           CADR     AOTMARK                               
041536,000700: 14,3105           04607                           TC       BANKCALL                              
041537,000701: 14,3106           17731                           CADR     OPTSTALL                              
041538,000702: 14,3107           05705                           TC       CURTAINS                              
041539,000703: 14,3110           11757                           CCS      STARIND                               
041540,000704: 14,3111           13113                           TCF      +2                                    
041541,000705: 14,3112           03156                           TC       R51.4                                 
041542,000706: 14,3113           05355                           TC       PHASCHNG                              
041543,000707: 14,3114           04024                           OCT      04024                                 
041544,000708: 
041545,000709: 14,3115           06060                           TC       INTPRET                               
041546,000710: 14,3116           45145                           DLOAD    CALL                                  
041547,000711: 14,3117           03562                                    TSIGHT                                
041548,000712: 14,3120           16607                                    PLANET                                
041549,000713: 14,3121           53521                           MXV      UNIT                                  
041550,000714: 14,3122           01732                                    REFSMMAT                              
041551,000715: 14,3123           26715                           STOVL    STARAD     +6                         
041552,000716: 14,3124           03554                                    PLANVEC                               
041553,000717: 14,3125           53521                           MXV      UNIT                                  
041554,000718: 14,3126           01732                                    REFSMMAT                              
041555,000719: 14,3127           26707                           STOVL    STARAD                                
041556,000720: 14,3130           02761                                    STARSAV1                              
041557,000721: 14,3131           24007                           STOVL    6D                                    
041558,000722: 14,3132           02767                                    STARSAV2                              
041559,000723: 14,3133           34015                           STCALL   12D                                   
041560,000724: 14,3134           31265                                    R54                                   #  STAR DATA TEST
041561,000725: 14,3135           45014                           BOFF     CALL                                  
041562,000726: 14,3136           00354                                    FREEFLAG                              
041563,000727: 14,3137           31145                                    R51K                                  
041564,000728: 14,3140           47424                                    AXISGEN                               
041565,000729: 14,3141           77624                           CALL                                           
041566,000730: 14,3142           31234                                    R55                                   #  GYRO TORQUE
041567,000731: 14,3143           77614                           CLEAR                                          
041568,000732: 14,3144           01273                                    PFRATFLG                              
041569,000733: 14,3145           77776        R51K               EXIT                                           
041570,000734: 14,3146           35745        R51P63             CAF      OCT14                                 
041571,000735: 14,3147           04607                           TC       BANKCALL                              
041572,000736: 14,3150           20635                           CADR     GOPERF1                               
041573,000737: 14,3151           06001                           TC       GOTOPOOH                              
041574,000738: 14,3152           03030                           TC       R51C                                  

Page 940

041576,000740: 14,3153           06060                           TC       INTPRET                               
041577,000741: 14,3154           77650                           GOTO                                           
041578,000742: 14,3155           02746                                    QMAJ                                  
041579,000743: 14,3156           06060        R51.4              TC       INTPRET                               
041580,000744: 14,3157           77775                           VLOAD                                          
041581,000745: 14,3160           02767                                    STARSAV2                              
041582,000746: 14,3161           02761                           STORE    STARSAV1                              
041583,000747: 14,3162           45145                           DLOAD    CALL                                  
041584,000748: 14,3163           03562                                    TSIGHT                                
041585,000749: 14,3164           16607                                    PLANET                                
041586,000750: 14,3165           03554                           STORE    PLANVEC                               
041587,000751: 14,3166           52131                           SSP      GOTO                                  
041588,000752: 14,3167           02760                                    STARIND                               
041589,000753: 14,3170           00001                                    1                                     
041590,000754: 14,3171           31074                                    R51.3                                 
041591,000755: 
041592,000756: 14,3172           00002 06240  TSIGHT1            2DEC     36000      B-28                       #  6  MIN  TO  MARKING
041593,000757: 

Page 941

041595,000759:                                                                                                  #  GYRO TORQUE COARSE ALIGNMENT
041596,000760: 14,3174           45020        GYCOARS            STQ      CALL                                  
041597,000761: 14,3175           02746                                    QMAJ                                  
041598,000762: 14,3176           47232                                    CALCGTA                               

The first CLEAR and DRIFTFLG below are circled.

041600,000764: 14,3177           43014                           CLEAR    CLEAR                                 
041601,000765: 14,3200           01260                                    DRIFTFLG                              
041602,000766: 14,3201           01662                                    REFSMFLG                              
041603,000767: 14,3202           77776                           EXIT                                           
041604,000768: 14,3203           33233                           CAF      V16N20                                #  MONITOR GIMBALS
041605,000769: 14,3204           04607                           TC       BANKCALL                              
041606,000770: 14,3205           20444                           CADR     GODSPR                                
041607,000771: 14,3206           33264                           CA       R55CDR                                
041608,000772: 14,3207           04607                           TC       BANKCALL                              
041609,000773: 14,3210           17310                           CADR     IMUPULSE                              
041610,000774: 14,3211           04607                           TC       BANKCALL                              
041611,000775: 14,3212           17735                           CADR     IMUSTALL                              
041612,000776: 14,3213           05705                           TC       CURTAINS                              
041613,000777: 14,3214           05355                           TC       PHASCHNG                              
041614,000778: 14,3215           04024                           OCT      04024                                 
041615,000779: 
041616,000780: 14,3216           06060                           TC       INTPRET                               
041617,000781: 14,3217           75160                           AXC,1    AXC,2                                 
041618,000782: 14,3220           03606                                    XSMD                                  
041619,000783: 14,3221           01731                                    REFSMMAT                              
041620,000784: 14,3222           77624                           CALL                                           #  STORE DESIRED REFSMMAT
041621,000785: 14,3223           26374                                    MATMOVE                               
041622,000786: 14,3224           43014                           CLEAR    SET                                   
041623,000787: 14,3225           01273                                    PFRATFLG                              
041624,000788: 14,3226           01462                                    REFSMFLG                              
041625,000789: 14,3227           77624                           CALL                                           
041626,000790: 14,3230           31566                                    NCOARSE                               #  SET DRIFT AND INITIALIZE 1/PIPADT
041627,000791: 14,3231           77650                           GOTO                                           
041628,000792: 14,3232           31145                                    R51K                                  
041629,000793: 14,3233           04024        V16N20             VN       1620                                  
041630,000794: 

Page 942

041632,000796:                                                                                                  #  R55  GYRO TORQUE
041633,000797:                                                                                                  #  FUNCTION-COMPUTE AND SEND GYRO PULSES
041634,000798:                                                                                                  #  CALLING SEQ- CALL R55
041635,000799:                                                                                                  #  INPUT- X,Y,ZDC- REFSMMAT WRT PRESENT STABLE MEMBER
041636,000800:                                                                                                  #  OUTPUT- GYRO PULSES
041637,000801:                                                                                                  #  SUBROUTINES- CALCGTA,GOFLASH,GODSPR,IMUFINE,IMUPULSE,GOPERF1
041638,000802: 14,3234                                           COUNT*   $$/R55                                
041639,000803: 14,3234           45020        R55                STQ      CALL                                  
041640,000804: 14,3235           02745                                    QMIN                                  
041641,000805: 14,3236           47232                                    CALCGTA                               
041642,000806: 14,3237           77776        PULSEM             EXIT                                           
041643,000807: 14,3240           33263        R55.1              CAF      V06N93                                
041644,000808: 14,3241           04607                           TC       BANKCALL                              
041645,000809: 14,3242           20471                           CADR     GOFLASH                               
041646,000810: 14,3243           06001                           TC       GOTOPOOH                              
041647,000811: 14,3244           03246                           TC       R55.2                                 
041648,000812: 14,3245           03260                           TC       R55RET                                
041649,000813: 14,3246           05355        R55.2              TC       PHASCHNG                              
041650,000814: 14,3247           00214                           OCT      00214                                 
041651,000815: 14,3250           33264                           CA       R55CDR                                
041652,000816: 14,3251           04607                           TC       BANKCALL                              
041653,000817: 14,3252           17310                           CADR     IMUPULSE                              
041654,000818: 14,3253           04607                           TC       BANKCALL                              
041655,000819: 14,3254           17735                           CADR     IMUSTALL                              
041656,000820: 14,3255           05705                           TC       CURTAINS                              
041657,000821: 14,3256           05355                           TC       PHASCHNG                              
041658,000822: 14,3257           04024                           OCT      04024                                 
041659,000823: 
041660,000824: 14,3260           06060        R55RET             TC       INTPRET                               
041661,000825: 14,3261           77650                           GOTO                                           
041662,000826: 14,3262           02745                                    QMIN                                  
041663,000827: 14,3263           01535        V06N93             VN       0693                                  
041664,000828: 14,3264           02737        R55CDR             ECADR    OGC                                   
041665,000829: 14,3265  14,3265               R54                =        CHKSDATA                              
041666,000830: 

Page 943

041668,000832:                                                                                                  #  CHKSDATA                                                                               DATE- JAN 9, 1967
041669,000833:                                                                                                  #  THE ANGULAR DIFFERENCE IS DISPLAYED FOR ASTRONAUT ACCEPTENCE
041670,000834:                                                                                                  #  EXIT MODE 1. FREEFLAG SET  IMPLIES  ASTRONAUT WANTS TO PROCEED
041671,000835:                                                                                                  #            2. FREEFLAG RESET IMPLIES ASTRONAUT WANTS TO RECYCLE          ERANCE)
041672,000836:                                                                                                  #  OUTPUT - 1.VERB 6,NOUN 3- DISPLAYS ANGULAR DIFFERENCE BETWEEN 2 SETS OF STARS.
041673,000837:                                                                                                  #           2.STAR VECTORS FROM STAR CATALOG ARE LEFT IN 6D AND 12D.
041674,000838: 
041675,000839:                                                                                                  #  ERASABLE INITIALIZATION REQUIRED -
041676,000840:                                                                                                  #           1.MARK VECTORS ARE STORED IN STARAD AND STARAD +6.
041677,000841:                                                                                                  #           2.CATALOG VECTORS ARE STORED IN 6D AND 12D.
041678,000842:                                                                                                  #  DEBRIS -
041679,000843: 14,3265                                           COUNT*   $$/R54                                
041680,000844: 14,3265           50375        CHKSDATA           VLOAD    DOT                                   
041681,000845: 14,3266           02707                                    STARAD                                #  1ST CATALOG STAR
041682,000846: 14,3267           02715                                    STARAD     +6                         #  2ND CATALOG STAR
041683,000847: 14,3270           65552                           SL1      ACOS                                  
041684,000848: 14,3271           24025                           STOVL    THETA                                 
041685,000849: 14,3272           00007                                    6                                     #  1ST OBSERVED STAR
041686,000850: 14,3273           72441                           DOT      SL1                                   
041687,000851: 14,3274           00015                                    12D                                   #  2ND OBSERVED STAR
041688,000852: 14,3275           45326                           ACOS     DSU                                   
041689,000853: 14,3276           00025                                    THETA                                 
041690,000854: 14,3277           77634                           RTB                                            
041691,000855: 14,3300           21622                                    SGNAGREE                              
041692,000856: 14,3301           01045                           STORE    NORMTEM1                              #  OBSERVED DIF - CATALOG DIF
041693,000857: 14,3302           77414                           SET      EXIT                                  
041694,000858: 14,3303           00074                                    FREEFLAG                              
041695,000859: 14,3304           33315                           CAF      VB6N5                                 
041696,000860: 14,3305           04607                           TC       BANKCALL                              
041697,000861: 14,3306           20471                           CADR     GOFLASH                               
041698,000862: 14,3307           06001                           TC       GOTOPOOH                              #  V34
041699,000863: 14,3310           13313                           TCF      CHKOUT                                #  V33-PROCEED
041700,000864: 14,3311           05520                           TC       DOWNFLAG                              #  V32-REJECT DATA-CLEAR FLAG
041701,000865: 14,3312           00014                           ADRES    FREEFLAG                              
041702,000866: 14,3313           06060        CHKOUT             TC       INTPRET                               
041703,000867: 14,3314           77616                           RVQ                                            
041704,000868: 
041705,000869: 14,3315           01405        VB6N5              VN       605                                   
041706,000870: 

Page 944

041708,000872:                                                                                                  #  CAL53A
041709,000873:                                                                                                  #  FUNCTION -COMPUTE DESIRED GIMBAL ANGLES AND COARSE ALIGN IF NECESSARY
041710,000874:                                                                                                  #  CALLING SEQUENCE - CALL CAL53A
041711,000875:                                                                                                  #  INPUT - X,Y,ZSMD ,CDUX,Y,Z
041712,000876:                                                                                                  #          DESIRED GIMBAL ANGLES - THETAD,+1,+2
041713,000877:                                                                                                  #  OUTPUT - THE IMU COORDINATES ARE STORED IN REFSMMAT
041714,000878:                                                                                                  #  SUBROUTINES - S52.2, IMUCOARSE , IMUFINE
041715,000879: 14,3316                                           COUNT*   $$/R50                                
041716,000880: 14,3316           77624        CAL53A             CALL                                           
041717,000881: 14,3317           42707                                    S52.2                                 #  MAKE ONE FINAL COMP OF GIMBALE ANGLES
041718,000882: 14,3320           66234                           RTB      SSP                                   
041719,000883: 14,3321           31370                                    RDCDUS                                #  READ CDUS
041720,000884: 14,3322           00051                                    S1                                    
041721,000885: 14,3323           00001                                    1                                     
041722,000886: 14,3324           40370                           AXT,1    SETPD                                 
041723,000887: 14,3325           00003                                    3                                     
041724,000888: 14,3326           00005                                    4                                     
041725,000889: 14,3327           70543        CALOOP             DLOAD*   SR1                                   
041726,000890: 14,3330           00325                                    THETAD     +3D,1                      
041727,000891: 14,3331           70523                           PDDL*    SR1                                   
041728,000892: 14,3332           00005                                    4,1                                   
041729,000893: 14,3333           51425                           DSU      ABS                                   
041730,000894: 14,3334           45206                           PUSH     DSU                                   
041731,000895: 14,3335           31367                                    DEGREE1                               
041732,000896: 14,3336           71240                           BMN      DLOAD                                 
041733,000897: 14,3337           31355                                    CALOOP1                               
041734,000898: 14,3340           51025                           DSU      BPL                                   
041735,000899: 14,3341           31370                                    DEG359                                
041736,000900: 14,3342           31355                                    CALOOP1                               
041737,000901: 14,3343           77776                           EXIT                                           
041738,000902: 14,3344           05355                           TC       PHASCHNG                              
041739,000903: 14,3345           04024                           OCT      04024                                 
041740,000904: 
041741,000905: 14,3346           06060                           TC       INTPRET                               
041742,000906: 14,3347           77624        COARFINE           CALL                                           
041743,000907: 14,3350           31542                                    COARSE                                
041744,000908: 14,3351           77624                           CALL                                           
041745,000909: 14,3352           31566                                    NCOARSE                               
041746,000910: 14,3353           77650                           GOTO                                           
041747,000911: 14,3354           31357                                    FINEONLY                              
041748,000912: 14,3355           77700        CALOOP1            TIX,1                                          
041749,000913: 14,3356           31327                                    CALOOP                                
041750,000914: 14,3357           75160        FINEONLY           AXC,1    AXC,2                                 
041751,000915: 14,3360           02642                                    XSM                                   
041752,000916: 14,3361           01731                                    REFSMMAT                              
041753,000917: 14,3362           77624                           CALL                                           
041754,000918: 14,3363           26374                                    MATMOVE                               
041755,000919: 14,3364           77650                           GOTO                                           
041756,000920: 14,3365           32316                                    COARSRET                              
041757,000921: 14,3366           00056        DEGREE1            DEC      46         B-14                       #  1 DEG SCALED CDU/2

Page 945

041759,000923: 14,3367           37722        DEG359             DEC      16338      B-14                       #  359 DEG SCALED CDU/2
041760,000924: 14,3370           00004        RDCDUS             INHINT                                         #  READ CDUS
041761,000925: 14,3371           30032                           CA       CDUX                                  
041762,000926: 14,3372           50120                           INDEX    FIXLOC                                
041763,000927: 14,3373           54001                           TS       1                                     
041764,000928: 14,3374           30033                           CA       CDUY                                  
041765,000929: 14,3375           50120                           INDEX    FIXLOC                                
041766,000930: 14,3376           54002                           TS       2                                     
041767,000931: 14,3377           30034                           CA       CDUZ                                  
041768,000932: 14,3400           50120                           INDEX    FIXLOC                                
041769,000933: 14,3401           54003                           TS       3                                     
041770,000934: 14,3402           00003                           RELINT                                         
041771,000935: 14,3403           06102                           TC       DANZIG                                #                                +
041772,000936: 14,3404                                           COUNT*   $$/INFLT                              
041773,000937: 

Page 946

041775,000939:                                                                                                  #  NAME - P51 - IMU ORIENTATION DETERMINATION
041776,000940:                                                                                                  #           MOD.NO.1  23 JAN 67                                                             LOG SECTION - P51-P53
041777,000941:                                                                                                  #  MOD BY STURLAUGSON                                                                      ASSEMBLY SUNDANCE REV56
041778,000942: 
041779,000943:                                                                                                  #  FUNCTIONAL DESCRIPTION
041780,000944: 
041781,000945:                                                                                                  #       DETERMINES THE INERTIAL ORIENTATION OF THE IMU. THE PROGRAM IS SELECTED BY DSKY ENTRY. THE SIGHTING
041782,000946:                                                                                                  #  (AOTMARK)ROUTINE IS CALLED TO COLLECT AND PROCESS MARKED-STAR DATA. AOTMARK(R53) RETURNS THE STAR NUMBER AND THE
041783,000947:                                                                                                  #  STAR LOS VECTOR IN STARAD+6. TWO STARS ARE THUS SIGHTED. THE ANGLE BETWEEN THE TWO STARS IS THEN CHECKED AT
041784,000948:                                                                                                  #  CHKSDATA(R54). REFSMMAT IS THEN COMPUTED AT AXISGEN.
041785,000949: 
041786,000950:                                                                                                  #  CALLING SEQUENCE
041787,000951: 
041788,000952:                                                                                                  #    THE PROGRAM IS CALLED BY THE ASTRONAUT BY DSKY ENTRY.
041789,000953: 
041790,000954:                                                                                                  #  SUBROUTINES CALLED.
041791,000955: 
041792,000956:                                                                                                  #       GOPERF3
041793,000957:                                                                                                  #       GOPERF1
041794,000958:                                                                                                  #       GODSPR
041795,000959:                                                                                                  #       IMUCOARS
041796,000960:                                                                                                  #       IMUFIN20
041797,000961:                                                                                                  #       AOTMARK(R53)
041798,000962:                                                                                                  #       CHKSDATA(R54)
041799,000963:                                                                                                  #       MKRELEAS
041800,000964:                                                                                                  #       AXISGEN
041801,000965:                                                                                                  #       MATMOVE
041802,000966: 
041803,000967:                                                                                                  #  ALARMS
041804,000968: 
041805,000969:                                                                                                  #       NONE.
041806,000970: 
041807,000971:                                                                                                  #  ERASABLE INITIALIZATION
041808,000972: 
041809,000973:                                                                                                  #       IMU ZERO FLAG SHOULD BE SET.
041810,000974: 
041811,000975:                                                                                                  #  OUTPUT
041812,000976: 
041813,000977:                                                                                                  #       REFSMMAT
041814,000978:                                                                                                  #       REFSMFLG
041815,000979: 
041816,000980:                                                                                                  #  DEBRIS
041817,000981: 
041818,000982:                                                                                                  #       WORK AREA
041819,000983:                                                                                                  #       STARAD
041820,000984:                                                                                                  #       STARIND
041821,000985:                                                                                                  #       BESTI
041822,000986:                                                                                                  #       BESTJ
041823,000987: 
041824,000988: 14,3404                                           COUNT*   $$/P51                                

Page 947

041826,000990: 14,3404           04607        P51                TC       BANKCALL                              #  IS ISS ON - IF NOT, IMUCHK WILL SEND
041827,000991: 14,3405           33634                           CADR     IMUCHK                                #  ALARM CODE 210 AND EXIT VIA GOTOPOOH.
041828,000992: 
041829,000993: 14,3406           34752                           CAF      OCT15                                 
041830,000994: 14,3407           04607                           TC       BANKCALL                              
041831,000995: 14,3410           20635                           CADR     GOPERF1                               
041832,000996: 14,3411           06001                           TC       GOTOPOOH                              #  TERM.
041833,000997: 14,3412           13436                           TCF      P51B                                  #  V33
041834,000998: 14,3413           05355                           TC       PHASCHNG                              
041835,000999: 14,3414           04024                           OCT      04024                                 
041836,001000: 
041837,001001: 14,3415           34746                           CAF      ZERO                                  
041838,001002: 14,3416           54321                           TS       THETAD                                #  ZERO THE GIMBALS
041839,001003: 14,3417           54322                           TS       THETAD     +1                         
041840,001004: 14,3420           54323                           TS       THETAD     +2                         
041841,001005: 14,3421           35001                           CAF      V06N22                                
041842,001006: 14,3422           04607                           TC       BANKCALL                              
041843,001007: 14,3423           20441                           CADR     GODSPRET                              
041844,001008: 14,3424           33541                           CAF      V41K                                  #  NOW DISPLAY COARSE ALIGN VERB 41
041845,001009: 14,3425           04607                           TC       BANKCALL                              
041846,001010: 14,3426           20441                           CADR     GODSPRET                              
041847,001011: 14,3427           06060                           TC       INTPRET                               
041848,001012: 14,3430           77624                           CALL                                           
041849,001013: 14,3431           31542                                    COARSE                                
041850,001014: 14,3432           77776                           EXIT                                           
041851,001015: 14,3433           05355                           TC       PHASCHNG                              
041852,001016: 14,3434           04024                           OCT      04024                                 
041853,001017: 14,3435           13406                           TCF      P51        +2                         
041854,001018: 
041855,001019: 14,3436           05355        P51B               TC       PHASCHNG                              
041856,001020: 14,3437           00014                           OCT      00014                                 
041857,001021: 14,3440           06060                           TC       INTPRET                               
041858,001022: 14,3441           77624                           CALL                                           
041859,001023: 14,3442           31566                                    NCOARSE                               
041860,001024: 14,3443           40331                           SSP      SETPD                                 
041861,001025: 14,3444           02760                                    STARIND                               #  INDEX-STAR 1 OR 2
041862,001026: 14,3445           00000                                    0                                     
041863,001027: 14,3446           00001                                    0                                     
041864,001028: 14,3447           77776        P51C               EXIT                                           
041865,001029: 14,3450           05355                           TC       PHASCHNG                              
041866,001030: 14,3451           04024                           OCT      04024                                 
041867,001031: 
041868,001032: 14,3452           04607                           TC       BANKCALL                              
041869,001033: 14,3453           16000                           CADR     AOTMARK                               #  R53
041870,001034: 14,3454           04607                           TC       BANKCALL                              
041871,001035: 14,3455           17731                           CADR     AOTSTALL                              
041872,001036: 14,3456           05705                           TC       CURTAINS                              
041873,001037: 14,3457           11757                           CCS      STARIND                               
041874,001038: 14,3460           13466                           TCF      P51D       +1                         
041875,001039: 14,3461           06060                           TC       INTPRET                               

Page 948

041877,001041: 14,3462           77775                           VLOAD                                          
041878,001042: 14,3463           02767                                    STARSAV2                              
041879,001043: 14,3464           02761                           STORE    STARSAV1                              
041880,001044: 14,3465           77776        P51D               EXIT                                           
041881,001045: 14,3466           05355                           TC       PHASCHNG                              
041882,001046: 14,3467           04024                           OCT      04024                                 
041883,001047: 
041884,001048: 14,3470           11757                           CCS      STARIND                               
041885,001049: 14,3471           13505                           TCF      P51E                                  
041886,001050: 14,3472           05355                           TC       PHASCHNG                              
041887,001051: 14,3473           04024                           OCT      04024                                 
041888,001052: 
041889,001053: 14,3474           06060                           TC       INTPRET                               
041890,001054: 14,3475           45145                           DLOAD    CALL                                  
041891,001055: 14,3476           03562                                    TSIGHT                                
041892,001056: 14,3477           16607                                    PLANET                                
041893,001057: 14,3500           03554                           STORE    PLANVEC                               
041894,001058: 14,3501           77776                           EXIT                                           
041895,001059: 14,3502           34744                           CAF      BIT1                                  
041896,001060: 14,3503           55757                           TS       STARIND                               
041897,001061: 14,3504           13450                           TCF      P51C       +1                         #  DO SECOND STAR
041898,001062: 14,3505           05355        P51E               TC       PHASCHNG                              
041899,001063: 14,3506           04024                           OCT      04024                                 
041900,001064: 
041901,001065: 14,3507           06060                           TC       INTPRET                               
041902,001066: 14,3510           45145                           DLOAD    CALL                                  
041903,001067: 14,3511           03562                                    TSIGHT                                
041904,001068: 14,3512           16607                                    PLANET                                
041905,001069: 14,3513           24015                           STOVL    12D                                   
041906,001070: 14,3514           03554                                    PLANVEC                               
041907,001071: 14,3515           24007                           STOVL    6D                                    
041908,001072: 14,3516           02761                                    STARSAV1                              
041909,001073: 14,3517           26707                           STOVL    STARAD                                
041910,001074: 14,3520           02767                                    STARSAV2                              
041911,001075: 14,3521           36715                           STCALL   STARAD     +6                         
041912,001076: 14,3522           31265                                    CHKSDATA                              #  CHECK STAR ANGLES IN STARAD AND
041913,001077: 14,3523           77414                           BON      EXIT                                  
041914,001078: 14,3524           00314                                    FREEFLAG                              
041915,001079: 14,3525           31527                                    P51G                                  
041916,001080: 14,3526           03406                           TC       P51        +2                         
041917,001081: 14,3527           77624        P51G               CALL                                           
041918,001082: 14,3530           47424                                    AXISGEN                               #  COME BACK WITH REFSMMAT IN XDC
041919,001083: 14,3531           75160                           AXC,1    AXC,2                                 
041920,001084: 14,3532           02664                                    XDC                                   
041921,001085: 14,3533           01731                                    REFSMMAT                              
041922,001086: 14,3534           77624                           CALL                                           
041923,001087: 14,3535           26374                                    MATMOVE                               
041924,001088: 14,3536           77414                           SET      EXIT                                  
041925,001089: 14,3537           01462                                    REFSMFLG                              
041926,001090: 14,3540           06001                           TC       GOTOPOOH                              #  FINIS

Page 949

041928,001092: 14,3541           12200        V41K               VN       4100                                  
041929,001093: 14,3542           77776        COARSE             EXIT                                           
041930,001094: 14,3543           31301                 +1        CA       MODECADR                              #  SEE IF IMU DEVICE IS IN USE.
041931,001095: 14,3544           00006                           EXTEND                                         
041932,001096: 14,3545           13552                           BZF      DOCORS                                #  NOT IN USE, DO COARSE ALIGN
041933,001097: 14,3546           34770                           CAF      1SEC                                  #  IN USE, DELAY ONE SEC
041934,001098: 14,3547           04607                           TC       BANKCALL                              
041935,001099: 14,3550           01736                           CADR     DELAYJOB                              
041936,001100: 14,3551           13543                           TCF      COARSE     +1                         
041937,001101: 14,3552           04607        DOCORS             TC       BANKCALL                              
041938,001102: 14,3553           16765                           CADR     IMUCOARS                              
041939,001103: 14,3554           04607                           TC       BANKCALL                              
041940,001104: 14,3555           17735                           CADR     IMUSTALL                              
041941,001105: 14,3556           05705                           TC       CURTAINS                              
041942,001106: 14,3557           04607                           TC       BANKCALL                              
041943,001107: 14,3560           17175                           CADR     IMUFINE                               
041944,001108: 14,3561           04607                           TC       BANKCALL                              
041945,001109: 14,3562           17735                           CADR     IMUSTALL                              
041946,001110: 14,3563           05705                           TC       CURTAINS                              
041947,001111: 14,3564           06060                           TC       INTPRET                               
041948,001112: 14,3565           77616                           RVQ                                            
041949,001113: 14,3566           77776        NCOARSE            EXIT                                           
041950,001114: 14,3567           30025                           CA       TIME1                                 
041951,001115: 14,3570           55074                           TS       1/PIPADT                              
041952,001116: 14,3571           44746                           CS       ZERO                                  
041953,001117: 14,3572           54037                           TS       PIPAX                                 
041954,001118: 14,3573           54040                           TS       PIPAY                                 
041955,001119: 14,3574           54041                           TS       PIPAZ                                 
041956,001120: 14,3575           06060                           TC       INTPRET                               
041957,001121: 14,3576           77775                           VLOAD                                          
041958,001122: 14,3577           24007                                    ZEROVEC                               
041959,001123: 14,3600           01472                           STORE    GCOMP                                 

SET and DRIFTFLG below are circled.

041961,001125: 14,3601           43414                           SET      RVQ                                   
041962,001126: 14,3602           01060                                    DRIFTFLG                              
041963,001127: 

Page 950

041965,001129:                                                                                                  #  NAME-S52.2
041966,001130:                                                                                                  #  FUNCTION-COMPUTE GIMBAL ANGLES FOR DESIRED SM AND PRESENT VEHICLE
041967,001131:                                                                                                  #  CALL-  CALL  S52.2
041968,001132:                                                                                                  #  INPUT- X,Y,ZSMD
041969,001133:                                                                                                  #  OUTPUT- OGC,IGC,MGC,THETAD,+1,+2
041970,001134:                                                                                                  #  SUBROUTINES-CDUTRIG,CALCSMSC,MATMOVE,CALCGA
041971,001135: 21,2000                                           SETLOC   P50S3                                 
041972,001136: 21,2000                                           BANK                                           
041973,001137: 
041974,001138: 21,2707                                           COUNT*   $$/S52.1                              
041975,001139: 21,2707           45020        S52.2              STQ      CALL                                  
041976,001140: 21,2710           02746                                    QMAJ                                  
041977,001141: 21,2711           47522                                    CDUTRIG                               
041978,001142: 21,2712           77624                           CALL                                           
041979,001143: 21,2713           20030                                    CALCSMSC                              
041980,001144: 21,2714           66370                           AXT,1    SSP                                   
041981,001145: 21,2715           00022                                    18D                                   
041982,001146: 21,2716           00051                                    S1                                    
041983,001147: 21,2717           00006                                    6D                                    
041984,001148: 21,2720           61373        S52.2A             VLOAD*   VXM                                   
041985,001149: 21,2721           02707                                    XNB        +18D,1                     
041986,001150: 21,2722           01732                                    REFSMMAT                              
041987,001151: 21,2723           77656                           UNIT                                           
041988,001152: 21,2724           06707                           STORE    XNB        +18D,1                     
041989,001153: 21,2725           77700                           TIX,1                                          
041990,001154: 21,2726           42720                                    S52.2A                                
041991,001155: 21,2727           75160        S52.2.1            AXC,1    AXC,2                                 
041992,001156: 21,2730           03606                                    XSMD                                  
041993,001157: 21,2731           02642                                    XSM                                   
041994,001158: 21,2732           77624                           CALL                                           
041995,001159: 21,2733           26374                                    MATMOVE                               
041996,001160: 21,2734           77624                           CALL                                           
041997,001161: 21,2735           47336                                    CALCGA                                
041998,001162: 21,2736           77650                           GOTO                                           
041999,001163: 21,2737           02746                                    QMAJ                                  
042000,001164: 

Page 951

042002,001166:                                                                                                  #  NAME-S52.3
042003,001167:                                                                                                  #  FUNCTION  XSMD= UNIT R
042004,001168:                                                                                                  #            YSMD= UNIT(V X R)
042005,001169:                                                                                                  #            ZSMD= UNIT(XSMD X YSMD)
042006,001170:                                                                                                  #  CALL     DLOAD  CALL
042007,001171:                                                                                                  #                  TALIGN
042008,001172:                                                                                                  #                  S52.3
042009,001173:                                                                                                  #  INPUT-   TIME OF ALIGNMENT IN MPAC
042010,001174:                                                                                                  #  OUTPUT-  X,Y,ZSMD
042011,001175:                                                                                                  #  SUBROUTINES- CSMCONIC
042012,001176: 21,2740                                           COUNT*   $$/S52.3                              
042013,001177: 21,2740           77620        S52.3              STQ                                            
042014,001178: 21,2741           02746                                    QMAJ                                  
042015,001179: 21,2742           34041                           STCALL   TDEC1                                 
042016,001180: 21,2743           27136                                    LEMCONIC                              
042017,001181: 21,2744           53575                           VLOAD    UNIT                                  
042018,001182: 21,2745           00001                                    RATT                                  
042019,001183: 21,2746           27607                           STOVL    XSMD                                  
042020,001184: 21,2747           00007                                    VATT                                  
042021,001185: 21,2750           53435                           VXV      UNIT                                  
042022,001186: 21,2751           00001                                    RATT                                  
042023,001187: 21,2752           27615                           STOVL    YSMD                                  
042024,001188: 21,2753           03607                                    XSMD                                  
042025,001189: 21,2754           53435                           VXV      UNIT                                  
042026,001190: 21,2755           03615                                    YSMD                                  
042027,001191: 21,2756           37623                           STCALL   ZSMD                                  
042028,001192: 21,2757           02746                                    QMAJ                                  
042029,001193: 

Page 952

042031,001195:                                                                                                  #  NAME    -R52 (AUTOMATIC OPTICS POSITIONING ROUTINE)
042032,001196: 
042033,001197:                                                                                                  #  FUNCTION-POINT THE AOT OPTIC AXIS BY MANEUVERING THE LEM TO A NAVIGATION
042034,001198:                                                                                                  #           STAR SELECTED BY ALIGNMENT PROGRAMS OR DSKY INPUT
042035,001199: 
042036,001200:                                                                                                  #  CALLING -CALL R52
042037,001201: 
042038,001202:                                                                                                  #  INPUT   -BESTI AND BESTJ (STAR CODES TIMES 6)
042039,001203:                                                                                                  #  OUTPUT  -STAR CODE IN BITS1-6, DETENT CODE IN BITS 7-9
042040,001204:                                                                                                  #           (NO CHECK IS MADE TO INSURE THE DETENT  CODE TO BE VALID)
042041,001205:                                                                                                  #           POINTVSM-1/2 UNIT NAV STAR VEC IN SM
042042,001206:                                                                                                  #           SCAXIS-AOT OPTIC AXIS VEC IN NB X-Z PLANE
042043,001207: 
042044,001208:                                                                                                  #  SUBROUT -R60LEM
042045,001209: 
042046,001210: 14,2000                                           SETLOC   P50S1                                 
042047,001211: 14,2000                                           BANK                                           
042048,001212: 
042049,001213: 14,3603                                           COUNT*   $$/R52                                
042050,001214: 14,3603           77420        R52                STQ      EXIT                                  
042051,001215: 14,3604           03665                                    SAVQR52                               
042052,001216: 14,3605           34741                           CAF      BIT4                                  
042053,001217: 14,3606           70105                           MASK     FLAGWRD9                              
042054,001218: 14,3607           00006                           EXTEND                                         
042055,001219: 14,3610           13613                           BZF      DOR52                                 
042056,001220: 14,3611           04607                           TC       BANKCALL                              
042057,001221: 14,3612           32402                           CADR     R59                                   
042058,001222: 
042059,001223: 14,3613           51757        DOR52              INDEX    STARIND                               
042060,001224: 14,3614           31755                           CA       BESTI                                 #  PICK UP STARCODE DETERMINED BY R56
042061,001225: 14,3615           00006                           EXTEND                                         
042062,001226: 14,3616           73712                           MP       1/6TH                                 
042063,001227: 14,3617           64735                           AD       BIT8                                  #  SET DETENT POSITION 2
042064,001228: 14,3620           55235                           TS       STARCODE                              #  SCALE AND STORE IN STARCODE
042065,001229: 
042066,001230: 14,3621           33713        R52A               CAF      V01N70                                
042067,001231: 14,3622           04607                           TC       BANKCALL                              
042068,001232: 14,3623           20471                           CADR     GOFLASH                               #  DISPLAY STARCODE AND WAIT FOR RESPONSE
042069,001233: 14,3624           06001                           TC       GOTOPOOH                              #  V34-TERMINATE
042070,001234: 14,3625           13627                           TCF      R52B                                  #  V33-PROCEED TO ORIENT LEM
042071,001235: 14,3626           13621                           TCF      R52A                                  #  ENTER-SELECT NEW STARCODE-RECYCLE
042072,001236: 
042073,001237: 14,3627           05520        R52B               TC       DOWNFLAG                              
042074,001238: 14,3630           00124                           ADRES    3AXISFLG                              #  BIT6 OF FLAGWRD5 ZERO TO ALLOW VECPOINT
042075,001239: 14,3631           31235                           CA       STARCODE                              #  GRAB DETENT CODE
042076,001240: 14,3632           77765                           MASK     HIGH9                                 
042077,001241: 14,3633           00006                           EXTEND                                         
042078,001242: 14,3634           74734                           MP       BIT9                                  
042079,001243: 14,3635           54001                           TS       L                                     #  TEMP STORE DETENT
042080,001244: 

Page 953

042082,001246: 14,3636           00006                           EXTEND                                         
042083,001247: 14,3637           63655                           BZMF     GETAZEL                               #  CODE 0, COAS CALIBRATION
042084,001248: 
042085,001249: 14,3640           65652                           AD       NEG7                                  
042086,001250: 14,3641           00006                           EXTEND                                         
042087,001251: 14,3642           13655                           BZF      GETAZEL                               #  CODE 7, COAS SIGHTING
042088,001252: 
042089,001253: 14,3643  E7,1551                                  EBANK=   XYMARK                                
042090,001254: 14,3643           35007                           CA       EBANK7                                
042091,001255: 14,3644           54003                           TS       EBANK                                 
042092,001256: 
042093,001257: 14,3645           50001                           INDEX    L                                     
042094,001258: 14,3646           31403                           CA       AOTAZ      -1                         #  PICK UP AZ CORRESPONDING TO DETENT
042095,001259: 14,3647           54001                           TS       L                                     
042096,001260: 14,3650  E5,1642                                  EBANK=   XSM                                   
042097,001261: 14,3650           35005                           CA       EBANK5                                #  CHANGE TO EBANK5 BUT DONT DISTURB L
042098,001262: 14,3651           54003                           TS       EBANK                                 
042099,001263: 14,3652           34730                           CA       BIT13                                 #  SET ELV TO 45 DEG
042100,001264: 14,3653           56001                           XCH      L                                     #  SET C(A)=AZ, C(L)=45 DEG
042101,001265: 14,3654           13665                           TCF      AZEL                                  #  GO COMP OPTIC AXIS
042102,001266: 
042103,001267: 14,3655           33714        GETAZEL            CAF      V06N87                                #  CODE 0 OR 7, GET AZ AND EL KEY IN
042104,001268: 14,3656           04607                           TC       BANKCALL                              
042105,001269: 14,3657           20471                           CADR     GOFLASH                               
042106,001270: 14,3660           06001                           TC       GOTOPOOH                              #  V34-TERMINATE
042107,001271: 14,3661           13663                           TCF      +2                                    #  PROCEED-CALC OPTIC AXIS
042108,001272: 14,3662           13655                           TCF      GETAZEL                               #  ENTER-RECYCLE
042109,001273: 
042110,001274: 14,3663           00006                           EXTEND                                         
042111,001275: 14,3664           31345                           DCA      AZ                                    #  PICK UP AZ AND EL IN SP 2S COMP
042112,001276: 14,3665           50120        AZEL               INDEX    FIXLOC                                #  JAM AZ AND EL IN 8 AND 9 OF VAC
042113,001277: 14,3666           52011                           DXCH     8D                                    
042114,001278: 14,3667           06060                           TC       INTPRET                               
042115,001279: 14,3670           77624                           CALL                                           #  GO COMPUTE OPTIC AXIS AND STORE IN
042116,001280: 14,3671           10557                                    OANB                                  #  SCAXIS IN NB COORDS
042117,001281: 14,3672           45034                           RTB      CALL                                  
042118,001282: 14,3673           21603                                    LOADTIME                              
042119,001283: 14,3674           16607                                    PLANET                                
042120,001284: 14,3675           53521                           MXV      UNIT                                  
042121,001285: 14,3676           01732                                    REFSMMAT                              
042122,001286: 14,3677           03773                           STORE    POINTVSM                              #  STORE FOR VECPOINT
042123,001287: 
042124,001288: 14,3700           77776                           EXIT                                           
042125,001289: 14,3701           04607                           TC       BANKCALL                              
042126,001290: 14,3702           54125                           CADR     R60LEM                                #  GO TORQUE LEM OPTIC AXIS TO STAR LOS
042127,001291: 
042128,001292: 14,3703           37765                           CAF      HIGH9                                 #  IF COAS CALIBRATION CODE 0, RECYCLE
042129,001293: 14,3704           71235                           MASK     STARCODE                              
042130,001294: 14,3705           00006                           EXTEND                                         
042131,001295: 14,3706           13621                           BZF      R52A                                  
042132,001296: 

Page 954

042134,001298: 14,3707           06060                           TC       INTPRET                               #  RETURN FROM KALCMANU
042135,001299: 14,3710           77650                           GOTO                                           
042136,001300: 14,3711           03665                                    SAVQR52                               #  RETURN TO CALLER
042137,001301: 
042138,001302: 14,3712           05253        1/6TH              DEC      .1666667                              
042139,001303: 14,3713           00306        V01N70             VN       0170                                  
042140,001304: 14,3714           01527        V06N87             VN       687                                   
042141,001305: 

Page 955

042143,001307:                                                                                                  #  LUNAR SURFACE STAR AQUISITION
042144,001308: 
042145,001309: 15,2000                                           SETLOC   P50S                                  
042146,001310: 15,2000                                           BANK                                           
042147,001311: 15,2402                                           COUNT*   $$/R59                                
042148,001312: 
042149,001313: 15,2402           40077        R59                CS       FLAGWRD3                              
042150,001314: 15,2403           74730                           MASK     REFSMBIT                              #  IF REFSMMAT FLAG CLEAR BYPASS STAR AQUIR
042151,001315: 15,2404           10000                           CCS      A                                     
042152,001316: 15,2405           12574                           TCF      R59OUT                                #  NO REFSMMAT GO TO AOTMARK
042153,001317: 
042154,001318: 15,2406           32606                           CAF      V01N70*                               #  SELECT STAR CODE FOR ACQUISITION
042155,001319: 15,2407           04607                           TC       BANKCALL                              
042156,001320: 15,2410           20471                           CADR     GOFLASH                               
042157,001321: 15,2411           06001                           TC       GOTOPOOH                              #  V34-TERMINATE
042158,001322: 15,2412           12414                           TCF      R59A                                  #  V33-PROCEED
042159,001323: 15,2413           12402                           TCF      R59                                   #  V32-RECYCLE
042160,001324: 
042161,001325: 15,2414           06060        R59A               TC       INTPRET                               
042162,001326: 15,2415           45034                           RTB      CALL                                  
042163,001327: 15,2416           21603                                    LOADTIME                              
042164,001328: 15,2417           16607                                    PLANET                                #  GO GET CELESTRIAL BODY IN REF COORDS.
042165,001329: 15,2420           53521                           MXV      UNIT                                  
042166,001330: 15,2421           01732                                    REFSMMAT                              #  TRANSFORM TO NB COORDS.
042167,001331: 15,2422           77624                           CALL                                           
042168,001332: 15,2423           47640                                    CDU*SMNB                              
042169,001333: 15,2424           02731                           STORE    STAR                                  #  TEMP STORE STAR VEC(NB)
042170,001334: 15,2425           77776                           EXIT                                           
042171,001335: 
042172,001336: 15,2426           34744                           CAF      BIT1                                  #  INITIALIZE AZ POSITION CODE TO 1 (-60)
042173,001337: 15,2427           54734                           TS       POSCODE                               
042174,001338: 
042175,001339: 15,2430  E7,1551                                  EBANK=   XYMARK                                
042176,001340: 15,2430           35007        INCAZ              CA       EBANK7                                
042177,001341: 15,2431           54003                           TS       EBANK                                 
042178,001342: 
042179,001343: 15,2432           50734                           INDEX    POSCODE                               
042180,001344: 15,2433           31403                           CA       AOTAZ      -1                         #  PICK UP AZ CORRESPONDING TO POSCODE
042181,001345: 15,2434           54001                           TS       L                                     
042182,001346: 
042183,001347: 15,2435  E5,1642                                  EBANK=   XSM                                   
042184,001348: 15,2435           35005                           CA       EBANK5                                
042185,001349: 15,2436           54003                           TS       EBANK                                 
042186,001350: 
042187,001351: 15,2437           34730                           CA       BIT13                                 #  SET ELV TO 45 DEG
042188,001352: 15,2440           56001                           XCH      L                                     #  SET C(A)=AZ, C(L)=45 DEG
042189,001353: 15,2441           55745                           TS       QMIN                                  #  STORE QMIN=AZ FOR LATER
042190,001354: 15,2442           50120                           INDEX    FIXLOC                                
042191,001355: 15,2443           52011                           DXCH     8D                                    #  JAM AZ IN 8D, 45 DEG IN 9D FOR OANB
042192,001356: 

Page 956

042194,001358: 15,2444           06060                           TC       INTPRET                               
042195,001359: 15,2445           77624                           CALL                                           
042196,001360: 15,2446           10557                                    OANB                                  #  GO CALC OPTIC AXIS WRT NB
042197,001361: 15,2447           50375                           VLOAD    DOT                                   
042198,001362: 15,2450           02731                                    STAR                                  #  DOT STAR WITH OA
042199,001363: 15,2451           03765                                    SCAXIS                                
042200,001364: 15,2452           65552                           SL1      ARCCOS                                
042201,001365: 15,2453           00031                           STORE    24D                                   #  TEMP STORE ARCCOS(STAR.OPTAXIS)
042202,001366: 
042203,001367: 15,2454           51025                           DSU      BPL                                   
042204,001368: 15,2455           32611                                    DEG30                                 #  SEE IF STAR IN AOT FIELD-OF-VIEW
042205,001369: 15,2456           32533                                    NXAX                                  #  NOT IN FIELD - TRY NEXT POSITION
042206,001370: 15,2457           45345                           DLOAD    DSU                                   #  SEE IF STAR AT FIELD CENTER
042207,001371: 15,2460           00031                                    24D                                   
042208,001372: 15,2461           32613                                    DEG.5                                 
042209,001373: 15,2462           71240                           BMN      DLOAD                                 #  CALC SPIRAL AND CURSOR
042210,001374: 15,2463           32552                                    ZSPCR                                 #  GO ZERO CURSOR AND SPIRAL
042211,001375: 15,2464           00031                                    24D                                   #  GET SPIRAL
042212,001376: 15,2465           42405                           DMP      SL4                                   
042213,001377: 15,2466           23773                                    3/4                                   #  12 SCALED AT 16
042214,001378: 15,2467           24031                           STOVL    24D                                   #  12(ARCCOS(AO.STAR)) SCALED IN REVS
042215,001379: 
042216,001380: 15,2470           03765                                    SCAXIS                                #  OA
042217,001381: 15,2471           53435                           VXV      UNIT                                  
042218,001382: 15,2472           24005                                    XUNIT                                 
042219,001383: 15,2473           47206                           PUSH     VXV                                   #   OA X UNITX   PD 0-5
042220,001384: 15,2474           03765                                    SCAXIS                                
042221,001385: 15,2475           77676                           VCOMP                                          
042222,001386: 15,2476           63256                           UNIT     PDVL                                  #  UNIT(OA X(OA X UNITX))  PD 6-11
042223,001387: 15,2477           03765                                    SCAXIS                                
042224,001388: 15,2500           53435                           VXV      UNIT                                  
042225,001389: 15,2501           02731                                    STAR                                  
042226,001390: 15,2502           50206                           PUSH     DOT                                   #  1/2(OA X STAR)   PD 12-17
042227,001391: 15,2503           00001                                    0                                     #  DOT WITH 1/2(OA X UNITX)  FOR YROT
042228,001392: 15,2504           65552                           SL1      ARCCOS                                
042229,001393: 15,2505           24033                           STOVL    26D                                   #  STORE THET SCALED IN REVS
042230,001394: 
042231,001395: 15,2506           77641                           DOT                                            #  UP 12-17, UP 6-11 FOR C2
042232,001396: 15,2507           71244                           BPL      DLOAD                                 #  IF THET NEG-GET 360-THET
042233,001397: 15,2510           32515                                    R59D                                  
042234,001398: 15,2511           32157                                    ABOUTONE                              
042235,001399: 15,2512           77625                           DSU                                            
042236,001400: 15,2513           00033                                    26D                                   
042237,001401: 15,2514           00033                           STORE    26D                                   #  360-THET SCALED IN REVS
042238,001402: 
042239,001403: 15,2515           70535        R59D               SLOAD    SR1                                   
042240,001404: 15,2516           02746                                    QMIN                                  #  RESCALE AZ(N) TO REVS
042241,001405: 15,2517           41415                           DAD      PUSH                                  #  PUSH YROT + AZ(N) REVS
042242,001406: 15,2520           00033                                    26D                                   
042243,001407: 15,2521           77634                           RTB                                            

Page 957

042245,001409: 15,2522           21624                                    1STO2S                                
042246,001410: 15,2523           15241                           STODL    CURSOR                                #  YROT IN 1/2 REVS
042247,001411: 15,2524           00031                                    24D                                   #  LOAD SROT IN REVS
042248,001412: 15,2525           77615                           DAD                                            #  12(SEP) + YROT
042249,001413: 15,2526           77634                           RTB                                            
042250,001414: 15,2527           21624                                    1STO2S                                
042251,001415: 15,2530           01242                           STORE    SPIRAL                                #  SROT IN 1/2 REVS
042252,001416: 15,2531           77776                           EXIT                                           
042253,001417: 15,2532           12556                           TCF      79DISP                                #  GO DISPLAY CURSOR-SPIRAL-POS CODE
042254,001418: 
042255,001419: 15,2533           77776        NXAX               EXIT                                           
042256,001420: 15,2534           24734                           INCR     POSCODE                               
042257,001421: 15,2535           40734                           CS       POSCODE                               
042258,001422: 15,2536           64750                           AD       SEVEN                                 
042259,001423: 15,2537           00006                           EXTEND                                         
042260,001424: 15,2540           62542                           BZMF     R59ALM                                #  THIS STAR NOT AT ANY POSITION
042261,001425: 15,2541           12430                           TCF      INCAZ                                 
042262,001426: 
042263,001427: 15,2542           05571        R59ALM             TC       ALARM                                 #  THIS STAR CANT BE LOCATED IN AOT FIELD
042264,001428: 15,2543           00404                           OCT      404                                   
042265,001429: 15,2544           34777                           CAF      VB05N09                               #  DISPLAY ALARM
042266,001430: 15,2545           04607                           TC       BANKCALL                              
042267,001431: 15,2546           20471                           CADR     GOFLASH                               
042268,001432: 15,2547           16001                           TCF      GOTOPOOH                              #  VB34-TERMINATE
042269,001433: 15,2550           12574                           TCF      R59OUT                                #  VB33-PROCEED, GO WITHOUT AQUIRE
042270,001434: 15,2551           12402                           TCF      R59                                   #  VB32-RECYCLE AND TRY ANOTHER STAR
042271,001435: 
042272,001436: 15,2552           77776        ZSPCR              EXIT                                           
042273,001437: 15,2553           34746                           CAF      ZERO                                  
042274,001438: 15,2554           55240                           TS       CURSOR                                
042275,001439: 15,2555           55241                           TS       SPIRAL                                
042276,001440: 
042277,001441: 15,2556           32607        79DISP             CAF      V06N79                                #  DISPLAY CURSOR, SPIRAL AND POS CODE
042278,001442: 15,2557           04607                           TC       BANKCALL                              
042279,001443: 15,2560           20471                           CADR     GOFLASH                               
042280,001444: 15,2561           16001                           TCF      GOTOPOOH                              #  V34-TERMINATE
042281,001445: 15,2562           12564                           TCF      R59E                                  #  V33-PROCEED TO MARK ROUTINE
042282,001446: 15,2563           12402                           TCF      R59                                   #  V32-RECYCLE TO TOP OF R59 AGAIN
042283,001447: 
042284,001448: 15,2564           34750        R59E               CAF      SEVEN                                 #  GET DETENT CODE CORRESPONDING TO POSCODE
042285,001449: 15,2565           70734                           MASK     POSCODE                               
042286,001450: 15,2566           00006                           EXTEND                                         
042287,001451: 15,2567           74736                           MP       BIT7                                  #  DETENT CODE NOW IN L
042288,001452: 15,2570           47765                           CS       HIGH9                                 
042289,001453: 15,2571           71235                           MASK     AOTCODE                               #  ISOLATE STAR NO IN BIT 1-6
042290,001454: 15,2572           60001                           AD       L                                     
042291,001455: 15,2573           55235                           TS       AOTCODE                               #  STORE DETENT 7-9
042292,001456: 
042293,001457: 15,2574           06060        R59OUT             TC       INTPRET                               
042294,001458: 15,2575           77414                           BON      EXIT                                  

Page 958

042296,001460: 15,2576           04713                                    FLT59FLG                              #  IF FLT59FLG SET GO BACK TO R51 TO
042297,001461: 15,2577           03665                                    SAVQR52                               #  DO AOTMARK
042298,001462: 15,2600           04607                           TC       BANKCALL                              
042299,001463: 15,2601           16000                           CADR     AOTMARK                               
042300,001464: 15,2602           04607                           TC       BANKCALL                              
042301,001465: 15,2603           17731                           CADR     AOTSTALL                              #  SLEEP TILL SIGHTING DONE
042302,001466: 15,2604           05705                           TC       CURTAINS                              #  BADEND RETURN FROM AOTMARK
042303,001467: 15,2605           13073                           TCF      R59RET                                #  RETURN TO 1 STAR OR 2STAR
042304,001468: 
042305,001469: 15,2606           00306        V01N70*            VN       170                                   
042306,001470: 15,2607           01517        V06N79             VN       679                                   
042307,001471: 15,2610           02525 12525  DEG30              2DEC     .083333333                            #  30 DEGRESS
042308,001472: 
042309,001473: 15,2612           00026 30131  DEG.5              2DEC     .00138888                             #  .5 DEGRESS SCALED IN REVS
042310,001474: 
042311,001475: 15,2614           12525        DEG60              OCT      12525                                 #  60 DEG CDU SCALING
042312,001476: 

Page 959

042314,001478:                                                                                                  #  NAME -    PLANET
042315,001479:                                                                                                  #  FUNCTION -TO PROVIDE THE REFERENCE VECTOR FOR THE SIGHTED CELESTIAL
042316,001480:                                                                                                  #            BODY. STARS ARE FETCHED FROM THE CATALOG,SUN,EARTH AND
042317,001481:                                                                                                  #            MOON ARE COMPUTED BY LOCSAM,PLANET VECTORS ARE ENTERED
042318,001482:                                                                                                  #            BY DSDY INPUT
042319,001483:                                                                                                  #  CALL  -  CALL
042320,001484:                                                                                                  #                  PLANET
042321,001485:                                                                                                  #  INPUT -  TIME IN MPAC
042322,001486:                                                                                                  #  OUTPUT - VECTOR  IN MPAC
042323,001487:                                                                                                  #  SUBROUTINES - LOCSAM
042324,001488:                                                                                                  #  DEBRIS - VAC ,STARAD - STARAD +17
042325,001489: 
042326,001490: 07,2000                                           SETLOC   AOTMARK1                              
042327,001491: 07,2000                                           BANK                                           
042328,001492: 07,2607                                           COUNT*   $$/R58                                
042329,001493: 
042330,001494: 07,2607           03562        PLANET             STORE    TSIGHT                                
042331,001495: 07,2610           77420                           STQ      EXIT                                  
042332,001496: 07,2611           02736                                    GCTR                                  
042333,001497: 07,2612           47765                           CS       HIGH9                                 
042334,001498: 07,2613           71235                           MASK     AOTCODE                               
042335,001499: 07,2614           00006                           EXTEND                                         
042336,001500: 07,2615           76263                           MP       REVCNT                                
042337,001501: 07,2616           56001                           XCH      L                                     
042338,001502: 07,2617           51757                           INDEX    STARIND                               
042339,001503: 07,2620           55755                           TS       BESTI                                 
042340,001504: 07,2621           10000                           CCS      A                                     
042341,001505: 07,2622           12637                           TCF      NOTPLAN                               
042342,001506: 07,2623           32676                           CAF      VNPLANV                               
042343,001507: 07,2624           04607                           TC       BANKCALL                              
042344,001508: 07,2625           20471                           CADR     GOFLASH                               
042345,001509: 07,2626           02623                           TC       -3                                    
042346,001510: 07,2627           02631                           TC       +2                                    
042347,001511: 07,2630           02623                           TC       -5                                    
042348,001512: 07,2631           06060                           TC       INTPRET                               
042349,001513: 07,2632           74375                           VLOAD    VXSC                                  
042350,001514: 07,2633           02707                                    STARAD                                
042351,001515: 07,2634           16700                                    1/SQR3                                
042352,001516: 07,2635           52056                           UNIT     GOTO                                  
042353,001517: 07,2636           02736                                    GCTR                                  
042354,001518: 
042355,001519: 07,2637           40000        NOTPLAN            CS       A                                     
042356,001520: 07,2640           62675                           AD       DEC227                                
042357,001521: 07,2641           00006                           EXTEND                                         
042358,001522: 07,2642           62653                           BZMF     CALSAM1                               
042359,001523: 07,2643           51757                           INDEX    STARIND                               
042360,001524: 07,2644           31755                           CA       BESTI                                 
042361,001525: 07,2645           50120                           INDEX    FIXLOC                                
042362,001526: 07,2646           54046                           TS       X1                                    
042363,001527: 07,2647           06060                           TC       INTPRET                               

Page 960

042365,001529: 07,2650           52173                           VLOAD*   GOTO                                  
042366,001530: 07,2651           30347                                    CATLOG,1                              
042367,001531: 07,2652           02736                                    GCTR                                  
042368,001532: 07,2653           06060        CALSAM1            TC       INTPRET                               
042369,001533: 07,2654           45145        CALSAM             DLOAD    CALL                                  
042370,001534: 07,2655           03562                                    TSIGHT                                
042371,001535: 07,2656           30515                                    LOCSAM                                
042372,001536: 07,2657           77340                           LXC,1    VLOAD                                 
042373,001537: 07,2660           02757                                    STARIND                               
042374,001538: 07,2661           02707                                    VEARTH                                
042375,001539: 07,2662           24001                           STOVL    0D                                    
042376,001540: 07,2663           02715                                    VSUN                                  
042377,001541: 07,2664           26707                           STOVL    VEARTH                                
042378,001542: 07,2665           00001                                    0D                                    
042379,001543: 07,2666           02715                           STORE    VSUN                                  
042380,001544: 07,2667           70143                           DLOAD*   LXC,1                                 
042381,001545: 07,2670           02756                                    BESTI,1                               
042382,001546: 07,2671           00154                                    MPAC                                  
042383,001547: 07,2672           52173                           VLOAD*   GOTO                                  
042384,001548: 07,2673           02343                                    STARAD     -228D,1                    
042385,001549: 07,2674           02736                                    GCTR                                  
042386,001550: 07,2675           00343        DEC227             DEC      227        B-14                       
042387,001551: 07,2676           01530        VNPLANV            VN       0688                                  
042388,001552: 07,2677  37,3543               PIPSRINE           =        PIPASR     +3                         #  EBANK NOT 4 SO DONT LOAD PIPTIME1
042389,001553: 07,2677           22363 11623  1/SQR3             2DEC     .57735021                             
042390,001554: 

Page 961

042392,001556:                                                                                                  #  GRAVITY VECTOR DETERMINATION ROUTINE
042393,001557:                                                                                                  #  BY KEN VINCENT
042394,001558:                                                                                                  #  FOR DETAILED DESCRIPTION SEE 504GSOP 5.6.3.2.5
042395,001559:                                                                                                  #  THIS PROGRAM FINDS THE DIRECTION OF THE MOONS GRAVITY
042396,001560:                                                                                                  #  WHILE THE LM IS ON THE MOONS SURFACE. IT WILL BE USED
042397,001561:                                                                                                  #  FOR LUNAR SURFACE ALIGNMENT. THE GRAVITY VECTOR IS
042398,001562:                                                                                                  #  DETERMINED BY READING THE PIPAS WITH THE IMU AT TWO
042399,001563:                                                                                                  #  PARTICULAR ORIONTATIONS. THE TWO READINGS ARE AVERAGED
042400,001564:                                                                                                  #  AND UNITIZED AND TRANSFORMED TO NB COORDINATES. THE TWO
042401,001565:                                                                                                  #  ORIENTATION WERE CHOSEN TO REDUCE BIAS ERRORS IN THE
042402,001566:                                                                                                  #  READINGS.
042403,001567: 
042404,001568:                                                                                                  #  CALL-
042405,001569:                                                                                                  #           TC     BANKCALL
042406,001570:                                                                                                  #           CADR   GVDETER
042407,001571:                                                                                                  #  INPUTS-
042408,001572:                                                                                                  #           PIPAS,CDUS
042409,001573:                                                                                                  #  OUTPUTS-
042410,001574:                                                                                                  #           STARSAV1 = UNIT GRAVITY
042411,001575:                                                                                                  #           GSAV     =   DITTO
042412,001576:                                                                                                  #           GRAVBIT  = 1
042413,001577:                                                                                                  #  SUBROUTINES-
042414,001578:                                                                                                  #           PIPASR,IMUCOARS,IMUFINE,IMUSTALL,1/PIPA,DELAYJOB,CDUTRIG,
042415,001579:                                                                                                  #           *NBSM* ,*SNMB*, CALCGA,FOFLASH
042416,001580:                                                                                                  #  DEBRIS-
042417,001581:                                                                                                  #           VAC,SAC,STARAD,XSM,XNB,THETAD,DELV,COSCDU,SINCDU
042418,001582: 15,2000                                           SETLOC   P50S                                  
042419,001583: 15,2000                                           BANK                                           
042420,001584: 15,2615                                           COUNT*   $$/P57                                
042421,001585: 
042422,001586: 15,2615           33016        GVDETER            CAF      42DEG                                 
042423,001587: 15,2616           54321                           TS       THETAD                                
042424,001588: 15,2617           40000                           COM                                            
042425,001589: 15,2620           54322                           TS       THETAD     +1                         
042426,001590: 15,2621           33017                           CAF      35DEG                                 
042427,001591: 15,2622           54323                           TS       THETAD     +2                         
042428,001592: 15,2623           06060                           TC       INTPRET                               
042429,001593: 15,2624           45014                           CLEAR    CALL                                  
042430,001594: 15,2625           01662                                    REFSMFLG                              
042431,001595: 15,2626           32722                                    LUNG                                  
042432,001596:                                                                                                  #  FIND  GIMBAL ANGLES WHICH ROTATE SM 180DEG  ABOUT  G VEC
042433,001597: 
042434,001598:                                                                                                  #   DEFINE G COOR SYS
042435,001599:                                                                                                  #                       -
042436,001600:                                                                                                  #                       X    UNIT G    
042437,001601:                                                                                                  #                   *   -               -
042438,001602:                                                                                                  #                   M=  Y =  UNITEZSM * X )
042439,001603:                                                                                                  #                       -         -     -
042440,001604:                                                                                                  #                       Z    UNIT(X   * Y )
042441,001605:                                                                                                  #   THEN   ROTATED  SM WRT  PRESENT IS

Page 962

042443,001607:                                                                                                  #                      1,  0 , 0  
042444,001608:                                                                                                  #            *      *T            *            *         *
042445,001609:                                                                                                  #           XSM =   M  0, -1 , 0  M   =  2  (X X ) - 1/2 I  *
042446,001610:                                                                                                  #                                             I J
042447,001611:                                                                                                  #                      0,  0 ,-1
042448,001612: 
042449,001613:                                                                                                  #   ALSO   NB WRT PRES SM  IS
042450,001614: 
042451,001615:                                                                                                  #                 *      *   *
042452,001616:                                                                                                  #                XNB = NBSM  I
042453,001617:                                                                                                  #                             *     *
042454,001618:                                                                                                  #   GIMBAL ANGLES  = CALCGA( XSM , XNB )
042455,001619: 
042456,001620: 15,2000                                           SETLOC   P50S                                  
042457,001621: 15,2000                                           BANK                                           
042458,001622: 15,2627                                           COUNT*   $$/P57                                
042459,001623: 15,2627           66370                           AXT,1    SSP                                   #  X1=18
042460,001624: 15,2630           00022                                    18D                                   #  S1= 6
042461,001625: 15,2631           00051                                    S1                                    #  X2, -2
042462,001626: 15,2632           00006                                    6D                                    
042463,001627: 15,2633           77744                           LXC,2                                          
042464,001628: 15,2634           00050                                    S1                                    
042465,001629: 15,2635           45173        GRAVEL             VLOAD*   CALL                                  
042466,001630: 15,2636           54000                                    XUNIT      -6,2                       
042467,001631: 15,2637           47665                                    *NBSM*                                #  SIN AND COS COMPUTED IN LUNG
042468,001632: 15,2640           06707                           STORE    XNB        +18D,1                     
042469,001633: 15,2641           77775                           VLOAD                                          
042470,001634: 15,2642           02731                                    STAR                                  
042471,001635: 15,2643           73744                           LXC,2    VXSC*                                 #  COMPLEMENT- UNITX  ARE BACKWARD -
042472,001636: 15,2644           00047                                    X2                                    
042473,001637: 15,2645           75040                                    STAR       +6,2                       #  OUTER PRODUCT
042474,001638: 15,2646           71152                           VSL2     LXC,2                                 
042475,001639: 15,2647           00047                                    X2                                    
042476,001640: 15,2650           63047                           VSU*     INCR,2                                
042477,001641: 15,2651           54000                                    XUNIT      -6,2                       
042478,001642: 15,2652           00002                                    2D                                    
042479,001643: 15,2653           06665                           STORE    XSM        +18D,1                     
042480,001644: 15,2654           45100                           TIX,1    CALL                                  
042481,001645: 15,2655           32635                                    GRAVEL                                
042482,001646: 15,2656           47336                                    CALCGA                                
042483,001647: 15,2657           74575                           VLOAD    VSR1                                  
042484,001648: 15,2660           02715                                    GOUT                                  
042485,001649: 15,2661           36723                           STCALL   STARAD     +12D                       
042486,001650: 15,2662           32722                                    LUNG                                  
042487,001651: 15,2663           74575                           VLOAD    VSR1                                  
042488,001652: 15,2664           02715                                    GOUT                                  
042489,001653: 15,2665           53455                           VAD      UNIT                                  
042490,001654: 15,2666           02723                                    STARAD     +12D                       

Page 963

042492,001656: 15,2667           02761                           STORE    STARSAV1                              
042493,001657: 15,2670           77641                           DOT                                            
042494,001658: 15,2671           02222                                    GSAV                                  
042495,001659: 15,2672           65552                           SL1      ACOS                                  
042496,001660: 15,2673           01045                           STORE    DSPTEM1                               
042497,001661: 15,2674           77776                           EXIT                                           
042498,001662: 15,2675           05520                           TC       DOWNFLAG                              #  CLEAR FREEFLAG IN CASE OF RECYCLE
042499,001663: 15,2676           00014                           ADRES    FREEFLAG                              
042500,001664: 
042501,001665: 15,2677           33015                           CA       DISGRVER                              
042502,001666: 15,2700           04607                           TC       BANKCALL                              
042503,001667: 15,2701           20471                           CADR     GOFLASH                               
042504,001668: 15,2702           06001                           TC       GOTOPOOH                              
042505,001669: 15,2703           12706                           TCF      PROGRAV                               #  VB33-PROCEED
042506,001670: 15,2704           05506                           TC       UPFLAG                                #  VB32-RECYCLE-STORE GRAV AND DO IT AGAIN
042507,001671: 15,2705           00014                           ADRES    FREEFLAG                              #  AND SET FREEFLAG TO SHOW RECYCLE
042508,001672: 
042509,001673: 15,2706           05355        PROGRAV            TC       PHASCHNG                              
042510,001674: 15,2707           04024                           OCT      04024                                 
042511,001675: 
042512,001676: 15,2710           06060                           TC       INTPRET                               
042513,001677: 15,2711           77775                           VLOAD                                          
042514,001678: 15,2712           02761                                    STARSAV1                              
042515,001679: 15,2713           02222                           STORE    GSAV                                  
042516,001680: 15,2714           77776                           EXIT                                           
042517,001681: 15,2715           34742                           CAF      FREEFBIT                              #  IF FREEFLAG SET, RE-COMPUTE GRAVITY.
042518,001682: 15,2716           70074                           MASK     FLAGWRD0                              
042519,001683: 15,2717           10000                           CCS      A                                     
042520,001684: 15,2720           12615                           TCF      GVDETER                               #  SET
042521,001685: 15,2721           13535                           TCF      ATTCHK                                #  EXIT FROM GVDETER
042522,001686: 
042523,001687: 15,2722           77220        LUNG               STQ      VLOAD                                 
042524,001688: 15,2723           02745                                    QMIN                                  
042525,001689: 15,2724           24007                                    ZEROVEC                               
042526,001690: 15,2725           02707                           STORE    GACC                                  
042527,001691: 15,2726           77776                           EXIT                                           
042528,001692: 15,2727           05355                           TC       PHASCHNG                              
042529,001693: 15,2730           04024                           OCT      04024                                 
042530,001694: 
042531,001695: 15,2731           06060                           TC       INTPRET                               
042532,001696: 15,2732           77624                           CALL                                           
042533,001697: 15,2733           31542                                    COARSE                                
042534,001698: 15,2734           77776                           EXIT                                           
042535,001699: 15,2735           33014                           CA       T/2SEC                                
042536,001700: 15,2736           55736                           TS       GCTR                                  
042537,001701: 15,2737           37737                           CA       PRIO31                                
042538,001702: 15,2740           55074                           TS       1/PIPADT                              
042539,001703: 15,2741           04607                           TC       BANKCALL                              
042540,001704: 15,2742           15751                           CADR     GCOMPZER                              #  INITIALIZE  COMPENSATION
042541,001705: 15,2743           05355                           TC       PHASCHNG                              

Page 964

042543,001707: 15,2744           04024                           OCT      04024                                 
042544,001708: 
042545,001709: 15,2745           04607                           TC       BANKCALL                              #   DONT NEED TO INHINY  THIS USED TO
042546,001710: 15,2746           77543                           CADR     PIPSRINE                              #  INITIALIZE PIPAS  DONT USE DATA
042547,001711: 15,2747           06060                           TC       INTPRET                               
042548,001712: 15,2750           77776        GREED              EXIT                                           #  = MASK 7776 IN BASIC SO DONT CARE
042549,001713: 15,2751           34771                           CAF      2SECS                                 
042550,001714: 15,2752           05175                           TC       TWIDDLE                               #  SET UP 2 SEC TASK TO READ PIPAS
042551,001715: 15,2753           02755                           ADRES    GRABGRAV                              
042552,001716: 
042553,001717: 15,2754           05146                           TC       ENDOFJOB                              
042554,001718: 
042555,001719: 15,2755           04665        GRABGRAV           TC       IBNKCALL                              
042556,001720: 15,2756           77543                           CADR     PIPSRINE                              
042557,001721: 15,2757           35014                           CAF      PRIO13                                #  RE-ESTABLISH MAINLINE JOB
042558,001722: 15,2760           05076                           TC       FINDVAC                               
042559,001723: 15,2761  E5,1706                                  EBANK=   STARAD                                
042560,001724: 15,2761           02764 32065                     2CADR    ADDGRAV                               
042561,001725: 
042562,001726: 
042563,001727: 15,2763           05263                           TC       TASKOVER                              
042564,001728: 
042565,001729: 15,2764           04607        ADDGRAV            TC       BANKCALL                              
042566,001730: 15,2765           15333                           CADR     1/PIPA                                
042567,001731: 15,2766           25736                           INCR     GCTR                                  
042568,001732: 15,2767           06060                           TC       INTPRET                               
042569,001733: 15,2770           53375                           VLOAD    VAD                                   
042570,001734: 15,2771           00325                                    DELV                                  
042571,001735: 15,2772           02707                                    GACC                                  
042572,001736: 15,2773           02707                           STORE    GACC                                  #  ACCUMULATE G VECTOR
042573,001737: 15,2774           50135                           SLOAD    BMN                                   
042574,001738: 15,2775           02737                                    GCTR                                  
042575,001739: 15,2776           32750                                    GREED                                 
042576,001740: 15,2777           53575                           VLOAD    UNIT                                  
042577,001741: 15,3000           02707                                    GACC                                  
042578,001742: 15,3001           36731                           STCALL   STAR                                  
042579,001743: 15,3002           47522                                    CDUTRIG                               #  TRANSFORM  IN NB COOR  AND  STORE
042580,001744: 15,3003           77624                           CALL                                           #   IN OUTPUT
042581,001745: 15,3004           47663                                    *SMNB*                                
042582,001746: 15,3005           02715                           STORE    GOUT                                  
042583,001747: 15,3006           77776                           EXIT                                           
042584,001748: 15,3007           05355                           TC       PHASCHNG                              
042585,001749: 15,3010           04024                           OCT      04024                                 
042586,001750: 
042587,001751: 15,3011           06060        QMINEXIT           TC       INTPRET                               
042588,001752: 15,3012           77650                           GOTO                                           
042589,001753: 15,3013           02745                                    QMIN                                  
042590,001754: 15,3014           77753        T/2SEC             DEC      -20        B-14                       
042591,001755: 15,3015           01404        DISGRVER           VN       0604                                  
042592,001756: 15,3016           07357        42DEG              OCT      07357                                 

Page 965

042594,001758: 15,3017           06211        35DEG              OCT      06211                                 
042595,001759: 

Page 966

042597,001761:                                                                                                  #  NAME  GYROTRIM
042598,001762: 
042599,001763:                                                                                                  #  THIS PROGRAM COMPUTES AND SENDS GYRO COMMANDS WHICH CAUSE THE CDUS
042600,001764:                                                                                                  #    TO ATTAIN A PRESCRIBED SET OF ANGLES. THIS ROUTINE ASSUMES THE
042601,001765:                                                                                                  #    VEHICLES ATTITUDE REMAINS STATIONARY DURING ITS OPERATION.
042602,001766: 
042603,001767:                                                                                                  #  CALL     CALL
042604,001768:                                                                                                  #                  GYROTRIM
042605,001769: 
042606,001770:                                                                                                  #  INPUT    THETAD,+1,+2 = DESIRED CDU ANGLES
042607,001771:                                                                                                  #           CDUX,CDUY,CDUZ
042608,001772: 
042609,001773:                                                                                                  #  OUTPUT - GYRO TORQUE PULSES
042610,001774: 
042611,001775:                                                                                                  #  SUBROUTINES- TRG*NBSM,*NBSM*,CDUTRIG,AXISGEN,CALCGTA,IMUFINE
042612,001776:                                                                                                  #               IMPULSE,IMUSTALL
042613,001777:                                                                                                  #             -         -        -        *           *     -
042614,001778:                                                                                                  #  DEBRIS -  CDUSPOT ,SINCDU ,COSCDU , STARAD ,VAC , XDC , OGC
042615,001779: 15,3020                                           COUNT*   $$/P57                                
042616,001780: 15,3020           71220        GYROTRIM           STQ      DLOAD                                 
042617,001781: 15,3021           02745                                    QMIN                                  
042618,001782: 15,3022           00322                                    THETAD                                
042619,001783: 15,3023           65325                           PDDL     PDDL                                  
042620,001784: 15,3024           00324                                    THETAD     +2                         
042621,001785: 15,3025           00323                                    THETAD     +1                         
042622,001786: 15,3026           77666                           VDEF                                           
042623,001787: 15,3027           24766                           STOVL    CDUSPOT                               
042624,001788: 15,3030           24005                                    XUNIT                                 
042625,001789: 15,3031           77624                           CALL                                           
042626,001790: 15,3032           47656                                    TRG*NBSM                              
042627,001791: 15,3033           26707                           STOVL    STARAD                                
042628,001792: 15,3034           24003                                    YUNIT                                 
042629,001793: 15,3035           77624                           CALL                                           
042630,001794: 15,3036           47665                                    *NBSM*                                
042631,001795: 15,3037           36715                           STCALL   STARAD     +6                         
042632,001796: 15,3040           47522                                    CDUTRIG                               
042633,001797: 15,3041           77624                           CALL                                           
042634,001798: 15,3042           20030                                    CALCSMSC                              
042635,001799: 15,3043           77775                           VLOAD                                          
042636,001800: 15,3044           02665                                    XNB                                   
042637,001801: 15,3045           24007                           STOVL    6D                                    
042638,001802: 15,3046           02673                                    YNB                                   
042639,001803: 15,3047           34015                           STCALL   12D                                   
042640,001804: 15,3050           47424                                    AXISGEN                               
042641,001805: 15,3051           77624                           CALL                                           
042642,001806: 15,3052           47232                                    CALCGTA                               
042643,001807: 15,3053           77776        JUSTTRIM           EXIT                                           
042644,001808: 15,3054           33063                           CA       GYRCDR                                
042645,001809: 15,3055           04607                           TC       BANKCALL                              
042646,001810: 15,3056           17310                           CADR     IMUPULSE                              

Page 967

042648,001812: 15,3057           04607                           TC       BANKCALL                              
042649,001813: 15,3060           17735                           CADR     IMUSTALL                              
042650,001814: 15,3061           05705                           TC       CURTAINS                              
042651,001815: 15,3062           13011                           TCF      QMINEXIT                              
042652,001816: 
042653,001817: 15,3063           02737        GYRCDR             ECADR    OGC                                   
042654,001818: 

Page 968

042656,001820:                                                                                                  #  PERFORM STAR AQUISITION AND STAR SIGHTINGS
042657,001821: 
042658,001822: 15,3064           34746        2STARS             CAF      ZERO                                  #  INITALIZE STARIND
042659,001823: 15,3065           13067                           TCF      +2                                    #  ZERO FOR 1ST STAR, ONE FOR 2ND STAR
042660,001824: 15,3066           34744        1STAR              CAF      BIT1                                  
042661,001825: 15,3067           55757                           TS       STARIND                               
042662,001826: 
042663,001827: 15,3070           05355                           TC       PHASCHNG                              
042664,001828: 15,3071           04024                           OCT      04024                                 
042665,001829: 
042666,001830: 15,3072           12402                           TCF      R59                                   #  GO DO STAR AQUIRE AND AOTMARK
042667,001831: 
042668,001832: 15,3073           31757        R59RET             CA       STARIND                               #  BACK FROM SURFACE MARKING
042669,001833: 15,3074           00006                           EXTEND                                         
042670,001834: 15,3075           13106                           BZF      ASTAR                                 #  1ST STAR MARKED
042671,001835: 
042672,001836: 15,3076           05355                           TC       PHASCHNG                              
042673,001837: 15,3077           04024                           OCT      04024                                 
042674,001838: 
042675,001839: 15,3100           06060                           TC       INTPRET                               
042676,001840: 15,3101           45145                           DLOAD    CALL                                  
042677,001841: 15,3102           03562                                    TSIGHT                                #  TIME OF 2ND MARK
042678,001842: 15,3103           16607                                    PLANET                                
042679,001843: 15,3104           37254                           STCALL   VEC2                                  #  STORE 2ND CATALOG VEC (REF)
042680,001844: 15,3105           33120                                    SURFLINE                              
042681,001845: 
042682,001846: 15,3106           06060        ASTAR              TC       INTPRET                               
042683,001847: 15,3107           77775                           VLOAD                                          
042684,001848: 15,3110           02767                                    STARSAV2                              
042685,001849: 15,3111           02761                           STORE    STARSAV1                              #  1ST OBSERVED STAR (SM)
042686,001850: 15,3112           45145                           DLOAD    CALL                                  
042687,001851: 15,3113           03562                                    TSIGHT                                #  TIME OF 1ST MARK
042688,001852: 15,3114           16607                                    PLANET                                
042689,001853: 15,3115           03246                           STORE    VEC1                                  #  STORE 1ST CATALOG VEC (REF)
042690,001854: 15,3116           77776                           EXIT                                           
042691,001855: 15,3117           13066                           TCF      1STAR                                 #  GO GET 2ND STAR SIGHTING
042692,001856: 

Page 969

042694,001858:                                                                                                  #  DO FINE OR COARSE ALIGNMENT OF IMU
042695,001859: 
042696,001860: 15,3120           77131        SURFLINE           SSP      AXT,2                                 
042697,001861: 15,3121           00052                                    S2                                    
042698,001862: 15,3122           00006                                    6                                     
042699,001863: 15,3123           00014                                    12D                                   
042700,001864: 15,3124           64373        WRTDESIR           VLOAD*   MXV                                   
042701,001865: 15,3125           74515                                    VEC1       +12D,2                     #  PICK UP VEC IN REF, TRANS TO DESIRED SH
042702,001866: 15,3126           03607                                    XSMD                                  
042703,001867: 15,3127           77656                           UNIT                                           
042704,001868: 15,3130           12723                           STORE    STARAD     +12D,2                     #  VEC IN SM
042705,001869: 15,3131           77773                           VLOAD*                                         
042706,001870: 15,3132           75002                                    STARSAV1   +12D,2                     #  PICK UP VEC IN PRESENT SM
042707,001871: 15,3133           10023                           STORE    18D,2                                 
042708,001872: 15,3134           43104                           TIX,2    BON                                   
042709,001873: 15,3135           33124                                    WRTDESIR                              
042710,001874: 15,3136           04315                                    INITALGN                              #  IF INITIAL PASS (OPTION 0) BYPASS R54
042711,001875: 15,3137           33145                                    INITBY                                
042712,001876: 15,3140           77624        DOALIGN            CALL                                           
042713,001877: 15,3141           31265                                    R54                                   #  DO CHKSDATA
042714,001878: 15,3142           77614                           BOFF                                           
042715,001879: 15,3143           00354                                    FREEFLAG                              
042716,001880: 15,3144           33225                                    P57POST                               #  ASTRO DOES NOT LIKE DATA TEST RESULTS
042717,001881: 15,3145           77624        INITBY             CALL                                           
042718,001882: 15,3146           47424                                    AXISGEN                               #  GET DESIRED ORIENT WRT PRES.XDC,YDC,ZDC
042719,001883: 15,3147           77624                           CALL                                           
042720,001884: 15,3150           47232                                    CALCGTA                               #  GET GYRO TORQ ANGLES, OGC,IGC,MGC
042721,001885: 15,3151           77776                           EXIT                                           
042722,001886: 15,3152           34743                           CAF      INITABIT                              #  IF INITIAL PASS BYPASS NOUN 93 DISPLAY
042723,001887: 15,3153           70104                           MASK     FLAGWRD8                              
042724,001888: 15,3154           10000                           CCS      A                                     
042725,001889: 15,3155           13164                           TCF      5DEGTEST                              
042726,001890: 15,3156           33273                           CAF      DISPGYRO                              #  DISPLAY GYRO TORQ ANGLES V 06N93
042727,001891: 15,3157           04607                           TC       BANKCALL                              
042728,001892: 15,3160           20471                           CADR     GOFLASH                               
042729,001893: 15,3161           06001                           TC       GOTOPOOH                              #  V34-TERMINATE
042730,001894: 15,3162           13164                           TCF      5DEGTEST                              #  VB33-PROCEED TO COARSE OR FINE
042731,001895: 15,3163           13226                           TCF      P57POST    +1                         #  VB32-RECYCLE, MAYBE RE-ALIGN
042732,001896: 
042733,001897: 15,3164           06060        5DEGTEST           TC       INTPRET                               #  IF ANGLES GREATER THAN 5 DEGS, DO COARSE
042734,001898: 15,3165           40175                           VLOAD    BOV                                   
042735,001899: 15,3166           02740                                    OGC                                   
042736,001900: 15,3167           33170                                    SURFSUP                               
042737,001901: 15,3170           02750        SURFSUP            STORE    OGCT                                  
042738,001902: 15,3171           40141                           V/SC     BOV                                   
042739,001903: 15,3172           30617                                    5DEGREES                              
042740,001904: 15,3173           31715                                    COATRIM                               
042741,001905: 15,3174           52131                           SSP      GOTO                                  
042742,001906: 15,3175           02746                                    QMIN                                  
042743,001907: 15,3176           33200                                    SURFDISP                              

Page 970

042745,001909: 15,3177           33053                                    JUSTTRIM                              #  ANGLES LESS THAN 5DEG, DO GYRO TORQ
042746,001910: 
042747,001911: 15,3200           77776        SURFDISP           EXIT                                           
042748,001912: 15,3201           05355                           TC       PHASCHNG                              
042749,001913: 15,3202           04024                           OCT      04024                                 
042750,001914: 
042751,001915: 15,3203           06060                           TC       INTPRET                               
042752,001916: 15,3204           75160                           AXC,1    AXC,2                                 
042753,001917: 15,3205           03606                                    XSMD                                  
042754,001918: 15,3206           01731                                    REFSMMAT                              
042755,001919: 15,3207           45014                           SET      CALL                                  
042756,001920: 15,3210           01462                                    REFSMFLG                              
042757,001921: 15,3211           26374                                    MATMOVE                               
042758,001922: 15,3212           77776                           EXIT                                           
042759,001923: 15,3213           11144                           CCS      OPTION2                               #  IF OPTION ZERO DO FINISH
042760,001924: 15,3214           13216                           TCF      B2F8                                  
042761,001925: 15,3215           13226                           TCF      P57POST    +1                         
042762,001926: 
042763,001927: 15,3216           34743        B2F8               CAF      INITABIT                              #  IF INITIAL FLAG SET, RE-CYCLE.
042764,001928: 15,3217           70104                           MASK     FLAGWRD8                              
042765,001929: 15,3220           10000                           CCS      A                                     
042766,001930: 15,3221           13543                           TCF      P57JUMP                               #  ITS SET
042767,001931: 15,3222           06060                           TC       INTPRET                               
042768,001932: 15,3223           77624                           CALL                                           
042769,001933: 15,3224           33470                                    REFMF                                 #  GO GET ATTITUDE VEC IN MF(YNBSAV,XNBSAV)
042770,001934: 15,3225           77776        P57POST            EXIT                                           
042771,001935: 15,3226           35745                           CAF      OCT14                                 #  DISPLAY V50N25 CHK CODE 14
042772,001936: 15,3227           04607                           TC       BANKCALL                              
042773,001937: 15,3230           20635                           CADR     GOPERF1                               
042774,001938: 15,3231           16001                           TCF      GOTOPOOH                              #  VB34-TERMINATE
042775,001939: 15,3232           13543                           TCF      P57JUMP                               #  VB33-PROCEED TO RE-ALIGN
042776,001940: 15,3233           44743                           CS       BIT2                                  #  TEST TO SE IF ALIGNED BY OPTION 2
042777,001941: 15,3234           61144                           AD       OPTION2                               
042778,001942: 15,3235           00006                           EXTEND                                         
042779,001943: 15,3236           13240                           BZF      +2                                    #  YES-GO CALCULATE LANDING SITE
042780,001944: 15,3237           16001                           TCF      GOTOPOOH                              #  NO-EXIT P57
042781,001945: 15,3240           05355                           TC       PHASCHNG                              #  RESTART PLACE
042782,001946: 15,3241           04024                           OCT      04024                                 
042783,001947: 15,3242           06060                           TC       INTPRET                               
042784,001948: 15,3243           45175                           VLOAD    CALL                                  #  USE GNB
042785,001949: 15,3244           02222                                    GSAV                                  
042786,001950: 15,3245           47653                                    CDU*NBSM                              #  GO TO SM COORDS
042787,001951: 15,3246           43105                           VXM      SET                                   #           ON MOON SO SET LUNAFLAG
042788,001952: 15,3247           01732                                    REFSMMAT                              #           G(REF) = (REFSMMAT)T (NBSM)GNB
042789,001953: 15,3250           01463                                    LUNAFLAG                              
042790,001954: 15,3251           51515                           PDVL     ABVAL                                 
042791,001955: 15,3252           02021                                    RLS                                   
042792,001956: 15,3253           45561                           VXSC     STADR                                 
042793,001957: 15,3254           75745                           STORE    ALPHAV                                #           ALPHAV =  RLSMAG * G(REF)
042794,001958: 15,3255           47014                           CLEAR    RTB                                   

Page 971

042796,001960: 15,3256           00662                                    ERADFLAG                              
042797,001961: 15,3257           21603                                    LOADTIME                              
042798,001962: 15,3260           77624                           CALL                                           
042799,001963: 15,3261           30455                                    N89DISP                               #  SUBROUTINE TO CALC LS AND GIVE RLS BACK
042800,001964: 15,3262           01220                           STORE    RN                                    #  RN=RLS B-29 = LM POSITION
042801,001965: 15,3263           65352                           VSL2     PDDL                                  #  R-TO-RP GETS RLS B-27 AT  0-5D IN PDLIST
042802,001966: 15,3264           01242                                    SITIME                                #  TIME STORED IN N89DISP
042803,001967: 15,3265           77606                           PUSH                                           #  TIME AT  6-7 IN PDLIST
042804,001968: 15,3266           35234                           STCALL   PIPTIME                               #  PIPTIME = LM STATE TIME
042805,001969: 15,3267           51644                                    R-TO-RP                               
042806,001970: 15,3270           02021                           STORE    RLS                                   #  RLS IN MOON-FIXED COORDS
042807,001971: 15,3271           77776                           EXIT                                           
042808,001972: 15,3272           16001                           TCF      GOTOPOOH                              #  EXIT P57
042809,001973: 

Page 972

042811,001975:                                                                                                  #  COARSE AND FINE ALIGN IMU
042812,001976: 14,2000                                           SETLOC   P50S1                                 
042813,001977: 14,2000                                           BANK                                           
042814,001978: 
042815,001979: 14,3715                                           COUNT*   $$/P57                                
042816,001980: 
042817,001981: 14,3715           75160        COATRIM            AXC,1    AXC,2                                 
042818,001982: 14,3716           02664                                    XDC                                   
042819,001983: 14,3717           02642                                    XSM                                   
042820,001984: 14,3720           77624                           CALL                                           
042821,001985: 14,3721           26374                                    MATMOVE                               
042822,001986: 14,3722           77624                           CALL                                           
042823,001987: 14,3723           47522                                    CDUTRIG                               
042824,001988: 14,3724           77624                           CALL                                           
042825,001989: 14,3725           20030                                    CALCSMSC                              
042826,001990: 14,3726           77624                           CALL                                           
042827,001991: 14,3727           47336                                    CALCGA                                
042828,001992: 14,3730           77414                           BOFF     EXIT                                  
042829,001993: 14,3731           04355                                    INITALGN                              #  IF INITIAL ALGNMENT DISPLAY FINAL
042830,001994: 14,3732           31744                                    CORSIT                                #  GIMBAL ANGLES IF COARSE ANGLES GREATER
042831,001995: 14,3733           35001                           CAF      V06N22                                #  THAN 5 DEGREES
042832,001996: 14,3734           04607                           TC       BANKCALL                              
042833,001997: 14,3735           20471                           CADR     GOFLASH                               
042834,001998: 14,3736           06001                           TC       GOTOPOOH                              
042835,001999: 14,3737           13741                           TCF      +2                                    
042836,002000: 14,3740           13733                           TCF      -5                                    
042837,002001: 14,3741           05355                           TC       PHASCHNG                              
042838,002002: 14,3742           04024                           OCT      04024                                 
042839,002003: 
042840,002004: 14,3743           06060                           TC       INTPRET                               
042841,002005: 14,3744           77624        CORSIT             CALL                                           
042842,002006: 14,3745           31542                                    COARSE                                
042843,002007: 14,3746           77624                           CALL                                           
042844,002008: 14,3747           31566                                    NCOARSE                               
042845,002009: 14,3750           77624                           CALL                                           
042846,002010: 14,3751           33020                                    GYROTRIM                              
042847,002011: 14,3752           77650                           GOTO                                           
042848,002012: 14,3753           33200                                    SURFDISP                              
042849,002013: 15,2000                                           SETLOC   P50S                                  
042850,002014: 15,2000                                           BANK                                           
042851,002015: 15,3273                                           COUNT*   $$/P57                                
042852,002016: 
042853,002017: 15,3273           01535        DISPGYRO           VN       0693                                  
042854,002018: 

Page 973

042856,002020:                                                                                                  #  LUNAR SURFACE IMU ALIGNMENT PROGRAM
042857,002021: 
042858,002022: 15,3274           04607        P57                TC       BANKCALL                              #  IS ISS ON - IF NOT, IMUCHK WILL SEND
042859,002023: 15,3275           33634                           CADR     IMUCHK                                #  ALARM CODE 210 AND EXIT VIA GOTOPOOH
042860,002024: 
042861,002025: 15,3276           05520                           TC       DOWNFLAG                              
042862,002026: 15,3277           00222                           ADRES    FLT59FLG                              
042863,002027: 
042864,002028: 15,3300           36266                           CAF      THREE                                 #  JAM REFSMMAT OPTION 3 FOR INITIAL DISP.
042865,002029: 15,3301           55144                           TS       OPTION2                               
042866,002030: 15,3302           34744        P57OPT             CAF      BIT1                                  
042867,002031: 15,3303           04607                           TC       BANKCALL                              
042868,002032: 15,3304           20725                           CADR     GOPERF4R                              #  FLASH V04N06 FOR ALIGNMENT CODE
042869,002033: 15,3305           06001                           TC       GOTOPOOH                              #  V34 TERMINATE
042870,002034: 15,3306           13313                           TCF      ALIGNOPT                              #  V33 PROCEED
042871,002035: 15,3307           13302                           TCF      P57OPT                                #  V32 RECYCLE
042872,002036: 
042873,002037: 15,3310           05355                           TC       PHASCHNG                              
042874,002038: 15,3311           00014                           OCT      00014                                 
042875,002039: 15,3312           05146                           TC       ENDOFJOB                              
042876,002040: 
042877,002041: 15,3313           31144        ALIGNOPT           CA       OPTION2                               
042878,002042: 15,3314           76266                           MASK     THREE                                 
042879,002043: 15,3315           50000                           INDEX    A                                     
042880,002044: 15,3316           13317                           TCF      +1                                    
042881,002045: 15,3317           13332                           TCF      TDISP                                 #  OPTION 4 LS ORIENTATION
042882,002046: 15,3320           13373                           TCF      PACKOPTN                              #  OPTION 1 PREFERRED
042883,002047: 15,3321           13302                           TCF      P57OPT                                #  OPTION 2 INVALID IN P57, RECYCLE
042884,002048: 15,3322           06060                           TC       INTPRET                               #  OPTION 3 REFSMMAT
042885,002049: 15,3323           75160                           AXC,1    AXC,2                                 #  JAM REFSMMAT IN XSMD LOC
042886,002050: 15,3324           01731                                    REFSMMAT                              
042887,002051: 15,3325           03606                                    XSMD                                  
042888,002052: 15,3326           77624                           CALL                                           
042889,002053: 15,3327           26374                                    MATMOVE                               
042890,002054: 15,3330           77650                           GOTO                                           
042891,002055: 15,3331           33372                                    PACKOPTN   -1                         
042892,002056: 
042893,002057: 15,3332           06060        TDISP              TC       INTPRET                               
042894,002058: 15,3333           77745                           DLOAD                                          
042895,002059: 15,3334           03442                                    TIG                                   #  LOAD ASCENT TIME FOR DISPLAY
042896,002060: 15,3335           01045        P57A               STORE    DSPTEM1                               
042897,002061: 15,3336           77776                           EXIT                                           
042898,002062: 15,3337           32325        P57AA              CAF      V06N34*                               #  DISPLAY TALIGN, TALIGN : DSPTEM1
042899,002063: 15,3340           04607                           TC       BANKCALL                              
042900,002064: 15,3341           20471                           CADR     GOFLASH                               
042901,002065: 15,3342           16001                           TCF      GOTOPOOH                              #  V34-TERMINATE
042902,002066: 15,3343           13345                           TCF      +2                                    
042903,002067: 15,3344           13337                           TCF      P57AA                                 #  VB32-RECYCLE
042904,002068: 
042905,002069: 15,3345           06060                           TC       INTPRET                               

Page 974

042907,002071: 15,3346           65234                           RTB      PDDL                                  
042908,002072: 15,3347           21603                                    LOADTIME                              #  PUSH CURRENT TIME AND PICK UP KEY IN
042909,002073: 15,3350           01045                                    DSPTEM1                               
042910,002074: 15,3351           65254                           BZE      PDDL                                  
042911,002075: 15,3352           33362                                    P57C                                  #  IF KEY IN TIME ZERO-TALIGN=CURRENT TIME
042912,002076: 15,3353           51025                           DSU      BPL                                   #  NOT ZERO SO EXCHANGE PD WITH DSPTEM1
042913,002077: 15,3354           01045                                    DSPTEM1                               
042914,002078: 15,3355           33362                                    P57C                                  
042915,002079: 15,3356           45545                           DLOAD    STADR                                 #  IF KEYIN TIME GREATER THAN CURRENT TIME
042916,002080: 15,3357           74335                           STORE    TIG                                   #  STORE IT IN TIG
042917,002081: 15,3360           36775                           STCALL   TALIGN                                
042918,002082: 15,3361           33364                                    P57D                                  
042919,002083: 15,3362           45545        P57C               DLOAD    STADR                                 
042920,002084: 15,3363           75002                           STORE    TALIGN                                
042921,002085: 15,3364           34041        P57D               STCALL   TDEC1                                 
042922,002086: 15,3365           27115                                    LEMPREC                               #  COMPUTE DESIRED IMU ORIENTATION STORE
042923,002087: 15,3366           53575                           VLOAD    UNIT                                  #  IN  X,Y,ZSMD
042924,002088: 15,3367           00001                                    RATT                                  
042925,002089: 15,3370           37607                           STCALL   XSMD                                  
042926,002090: 15,3371           11014                                    LSORIENT                              
042927,002091: 15,3372           77776                           EXIT                                           
042928,002092: 15,3373           34746        PACKOPTN           CAF      ZERO                                  #  PACK FLAG BITS FOR OPTION DISPLAY
042929,002093: 15,3374           55144                           TS       OPTION1    +1                         #  JAM ZERO IN ALIGNMENT OPTION
042930,002094: 15,3375           55145                           TS       OPTION1    +2                         #  INITIALIZE FLAG BIT CONFIGURATION
042931,002095: 15,3376           34730                           CAF      REFSMBIT                              
042932,002096: 15,3377           70077                           MASK     FLAGWRD3                              #  REFSMFLG
042933,002097: 15,3400           10000                           CCS      A                                     
042934,002098: 15,3401           34736                           CAF      BIT7                                  #  SET
042935,002099: 15,3402           27145                           ADS      OPTION1    +2                         #  CLEAR-JUST ZERO
042936,002100: 15,3403           34744                           CAF      ATTFLBIT                              
042937,002101: 15,3404           70102                           MASK     FLAGWRD6                              #  ATTFLG
042938,002102: 15,3405           10000                           CCS      A                                     
042939,002103: 15,3406           34741                           CAF      BIT4                                  #  SET
042940,002104: 15,3407           27145                           ADS      OPTION1    +2                         #  CLEAR-ZERO IN A
042941,002105: 15,3410           34741                           CAF      BIT4                                  
042942,002106: 15,3411           55143                           TS       OPTION1                               #  JAM 00010 IN OPTION1 FOR CHECK LIST
042943,002107: 
042944,002108: 15,3412           33633        DSPOPTN            CAF      VB05N06                               #  DISPLAY OPTION CODE AND FLAG BITS
042945,002109: 15,3413           04607                           TC       BANKCALL                              
042946,002110: 15,3414           20471                           CADR     GOFLASH                               
042947,002111: 15,3415           16001                           TCF      GOTOPOOH                              #  VB34-TERMINATE
042948,002112: 15,3416           13420                           TCF      +2                                    #  V33-PROCEED
042949,002113: 15,3417           13412                           TCF      DSPOPTN                               #  V32-RECYCLE
042950,002114: 
042951,002115: 15,3420           34730                           CAF      REFSMBIT                              
042952,002116: 15,3421           70077                           MASK     FLAGWRD3                              
042953,002117: 15,3422           10000                           CCS      A                                     
042954,002118: 15,3423           13523                           TCF      GETLMATT                              #  SET, GO COMPUTE LM ATTITUDE
042955,002119: 15,3424           34744                           CAF      ATTFLBIT                              #  CLEAR-CHECK ATTFLAG FOR STORED ATTITUDE.
042956,002120: 15,3425           70102                           MASK     FLAGWRD6                              

Page 975

042958,002122: 15,3426           10000                           CCS      A                                     
042959,002123: 15,3427           13527                           TCF      BYLMATT                               #  ALLFLG SET, CHK OPTION FOR GRAVITY COMP
042960,002124: 15,3430           34743                           CAF      BIT2                                  #  SEE IF OPTION 2 OR 3
042961,002125: 15,3431           71144                           MASK     OPTION2                               
042962,002126: 15,3432           10000                           CCS      A                                     
042963,002127: 15,3433           13527                           TCF      BYLMATT                               #  OPTION 2 OR 3 BUT DONT HAVE ATTITUDE
042964,002128: 15,3434           05571                           TC       ALARM                                 #  OPTION INCONSISTANT WITH FLAGS-ALARM 701
042965,002129: 15,3435           00701                           OCT      701                                   
042966,002130: 15,3436           34777                           CAF      VB05N09                               #  DISPLAY ALARM FOR ACTION
042967,002131: 15,3437           04607                           TC       BANKCALL                              
042968,002132: 15,3440           20471                           CADR     GOFLASH                               
042969,002133: 15,3441           16001                           TCF      GOTOPOOH                              #  VB34-TERMINATE
042970,002134: 15,3442           13412                           TCF      DSPOPTN                               #  V33-PROCEED   ********TEMPORARY
042971,002135: 15,3443           13412                           TCF      DSPOPTN                               #  VB32-RECYCLE TO OPTION DISPLAY V 05N06
042972,002136: 

Page 976

042974,002138:                                                                                                  #  TRANSFORM VEC1,2 FROM MOON FIXED TO REF AND JAM BACK IN VEC1,2
042975,002139: 
042976,002140: 15,3444           40220        MFREF              STQ      SETPD                                 
042977,002141: 15,3445           02746                                    QMAJ                                  
042978,002142: 15,3446           00001                                    0                                     
042979,002143: 15,3447           77634                           RTB                                            
042980,002144: 15,3450           21603                                    LOADTIME                              
042981,002145: 15,3451           27562                           STOVL    TSIGHT                                
042982,002146: 15,3452           03246                                    VEC1                                  
042983,002147: 15,3453           41525                           PDDL     PUSH                                  
042984,002148: 15,3454           03562                                    TSIGHT                                
042985,002149: 15,3455           77624                           CALL                                           
042986,002150: 15,3456           55716                                    RP-TO-R                               
042987,002151: 15,3457           27246                           STOVL    VEC1                                  
042988,002152: 15,3460           03254                                    VEC2                                  
042989,002153: 15,3461           65201                           SETPD    PDDL                                  
042990,002154: 15,3462           00001                                    0                                     
042991,002155: 15,3463           03562                                    TSIGHT                                
042992,002156: 15,3464           45006                           PUSH     CALL                                  
042993,002157: 15,3465           55716                                    RP-TO-R                               
042994,002158: 15,3466           37254                           STCALL   VEC2                                  
042995,002159: 15,3467           02746                                    QMAJ                                  
042996,002160: 

Page 977

042998,002162:                                                                                                  #  COMPUTE LM ATTITUDE IN MOON FIXED COORDINATES USING REFSMMAT AND
042999,002163:                                                                                                  #  STORE IN YNBSAV AND ZNBSAV
043000,002164: 
043001,002165: 15,3470           45020        REFMF              STQ      CALL                                  
043002,002166: 15,3471           02746                                    QMAJ                                  
043003,002167: 15,3472           47522                                    CDUTRIG                               #  GET SIN AND COS OF CDUS
043004,002168: 15,3473           40234                           RTB      SETPD                                 
043005,002169: 15,3474           21603                                    LOADTIME                              
043006,002170: 15,3475           00001                                    0                                     
043007,002171: 15,3476           37562                           STCALL   TSIGHT                                
043008,002172: 15,3477           20030                                    CALCSMSC                              #  GET YNB IN SM
043009,002173: 15,3500           61375                           VLOAD    VXM                                   
043010,002174: 15,3501           02673                                    YNB                                   
043011,002175: 15,3502           01732                                    REFSMMAT                              #   YNB TO REF
043012,002176: 15,3503           65256                           UNIT     PDDL                                  
043013,002177: 15,3504           03562                                    TSIGHT                                
043014,002178: 15,3505           45006                           PUSH     CALL                                  
043015,002179: 15,3506           51644                                    R-TO-RP                               
043016,002180: 15,3507           26230                           STOVL    YNBSAV                                #  YNB TO MF
043017,002181: 15,3510           02701                                    ZNB                                   
043018,002182: 15,3511           53505                           VXM      UNIT                                  
043019,002183: 15,3512           01732                                    REFSMMAT                              #  ZNB TO REF
043020,002184: 15,3513           41525                           PDDL     PUSH                                  
043021,002185: 15,3514           03562                                    TSIGHT                                
043022,002186: 15,3515           77624                           CALL                                           
043023,002187: 15,3516           51644                                    R-TO-RP                               #  ZNB TO MF
043024,002188: 15,3517           02236                           STORE    ZNBSAV                                
043025,002189: 15,3520           77614                           SETGO                                          
043026,002190: 15,3521           03036                                    ATTFLAG                               
043027,002191: 15,3522           02746                                    QMAJ                                  
043028,002192: 

Page 978

043030,002194:                                                                                                  #  BRANCH TO ALIGNMENT OPTION
043031,002195: 
043032,002196: 15,3523           06060        GETLMATT           TC       INTPRET                               
043033,002197: 15,3524           77624                           CALL                                           
043034,002198: 15,3525           33470                                    REFMF                                 #  GO TRANSFORM TO MF IN YNBSAV,ZNBSAV
043035,002199: 15,3526           77776                           EXIT                                           
043036,002200: 
043037,002201: 15,3527           05506        BYLMATT            TC       UPFLAG                                #  SET INITIAL ALIGN FLAG
043038,002202: 15,3530           00205                           ADRES    INITALGN                              
043039,002203: 15,3531           34744                           CAF      BIT1                                  
043040,002204: 15,3532           71144                           MASK     OPTION2                               #  SEE IF OPTION 1 OR 3
043041,002205: 15,3533           10000                           CCS      A                                     
043042,002206: 15,3534           12615                           TCF      GVDETER                               #  OPTION 1 OR 2, GET GRAVITY
043043,002207: 
043044,002208: 15,3535           05355        ATTCHK             TC       PHASCHNG                              
043045,002209: 15,3536           04024                           OCT      04024                                 
043046,002210: 
043047,002211: 15,3537           34744                           CAF      ATTFLBIT                              #  NOT 1 OR 3, CHECK ATTFLAG
043048,002212: 15,3540           70102                           MASK     FLAGWRD6                              
043049,002213: 15,3541           10000                           CCS      A                                     
043050,002214: 15,3542           13557                           TCF      P57OPT0                               #  GET ALIGNMENT VECS FOR OPTION 0
043051,002215: 15,3543           05355        P57JUMP            TC       PHASCHNG                              
043052,002216: 15,3544           04024                           OCT      04024                                 
043053,002217: 
043054,002218: 15,3545           05520                           TC       DOWNFLAG                              #  ATTFLG CLEAR-RESET INTALIGN FLAG
043055,002219: 15,3546           00205                           ADRES    INITALGN                              
043056,002220: 15,3547           36266                           CAF      THREE                                 
043057,002221: 15,3550           71144                           MASK     OPTION2                               #  BRANCH ON OPTION CODE
043058,002222: 15,3551           50000                           INDEX    A                                     
043059,002223: 15,3552           13553                           TCF      +1                                    
043060,002224: 15,3553           13557                           TCF      P57OPT0                               #  OPTION IS 0
043061,002225: 15,3554           13600                           TCF      P57OPT1                               #  OPTION IS 1
043062,002226: 15,3555           13616                           TCF      P57OPT2                               #  OPTION IS 2
043063,002227: 15,3556           13617                           TCF      P57OPT3                               #  OPTION IS 3
043064,002228: 

Page 979

043066,002230:                                                                                                  #  OPTION 0, GET TWO ATTITUDE VECS
043067,002231: 
043068,002232: 15,3557           06060        P57OPT0            TC       INTPRET                               
043069,002233: 15,3560           77775                           VLOAD                                          
043070,002234: 15,3561           02230                                    YNBSAV                                #  Y AND Z ATTITUDE WILL BE PUT IN REF
043071,002235: 15,3562           27246                           STOVL    VEC1                                  
043072,002236: 15,3563           02236                                    ZNBSAV                                
043073,002237: 15,3564           37254                           STCALL   VEC2                                  
043074,002238: 15,3565           47522                                    CDUTRIG                               
043075,002239: 15,3566           77624                           CALL                                           
043076,002240: 15,3567           20030                                    CALCSMSC                              #  COMPUTE SC AXIS WRT PRESENT SM
043077,002241: 15,3570           77775                           VLOAD                                          
043078,002242: 15,3571           02673                                    YNB                                   
043079,002243: 15,3572           26761        SAMETYP            STOVL    STARSAV1                              #  Y SC AXIS WRT PRESENT SM
043080,002244: 15,3573           02701                                    ZNB                                   
043081,002245: 15,3574           36767                           STCALL   STARSAV2                              #  Z SC AXIS WRT PRESENT SM
043082,002246: 15,3575           33444                                    MFREF                                 #  TRANSFORM VEC1,2 FROM MF TO REF
043083,002247: 15,3576           77650                           GOTO                                           
043084,002248: 15,3577           33120                                    SURFLINE                              
043085,002249: 
043086,002250:                                                                                                  #  OPTION 1, GET LANDING SITE AND Z-ATTITUDE VEC
043087,002251: 
043088,002252: 15,3600           06060        P57OPT1            TC       INTPRET                               
043089,002253: 15,3601           53575                           VLOAD    UNIT                                  
043090,002254: 15,3602           02021                                    RLS                                   #  LANDING SITE VEC
043091,002255: 15,3603           27246                           STOVL    VEC1                                  
043092,002256: 15,3604           02236                                    ZNBSAV                                #  Z ATTITUDE VEC
043093,002257: 15,3605           37254                           STCALL   VEC2                                  
043094,002258: 15,3606           47522                                    CDUTRIG                               
043095,002259: 15,3607           77624                           CALL                                           
043096,002260: 15,3610           20030                                    CALCSMSC                              #  GET ZNB AXIS WRT PRES SM FOR STARSAV2
043097,002261: 15,3611           45175                           VLOAD    CALL                                  
043098,002262: 15,3612           02222                                    GSAV                                  #  TRANS GSAV FROM NB TO SM FOR STARSAV1
043099,002263: 15,3613           47653                                    CDU*NBSM                              
043100,002264: 15,3614           77650                           GOTO                                           
043101,002265: 15,3615           33572                                    SAMETYP                               #  NOW DO SAME AS OPTION 0
043102,002266: 

Page 980

043104,002268:                                                                                                  #  OPTION 2, GET TWO STAR SIGHTINGS
043105,002269: 
043106,002270: 15,3616           13064        P57OPT2            TCF      2STARS                                #  DO SIGHTING ON 2 STARS
043107,002271: 
043108,002272:                                                                                                  #  OPTION 3, GET LANDING SITE VEC AND ONE STAR SIGHTING
043109,002273: 
043110,002274: 15,3617           06060        P57OPT3            TC       INTPRET                               
043111,002275: 15,3620           53575                           VLOAD    UNIT                                  
043112,002276: 15,3621           02021                                    RLS                                   #  LANDING SITE VEC
043113,002277: 15,3622           03246                           STORE    VEC1                                  
043114,002278: 15,3623           27254                           STOVL    VEC2                                  #  DUMMY VEC2 FOR 2ND CATALOG STAR
043115,002279: 15,3624           02222                                    GSAV                                  #  GRAVITY VEC NB
043116,002280: 15,3625           77624                           CALL                                           
043117,002281: 15,3626           47653                                    CDU*NBSM                              #  TRANS GSAV FROM NB TO SM FOR STARSAV1
043118,002282: 15,3627           36761                           STCALL   STARSAV1                              
043119,002283: 15,3630           33444                                    MFREF                                 #  STARSAV2 IS STORED AS 2ND OBSERVED STAR
043120,002284: 15,3631           77776                           EXIT                                           
043121,002285: 15,3632           13066                           TCF      1STAR                                 #  1STAR GET VEC2,STARSAV2,GOES TO SURFLINE
043122,002286: 
043123,002287: 15,3633           01206        VB05N06            VN       506                                   
043124,002288: 

Page 981

043126,002290:                                                                                                  #  CHECK IMODES30 TO VARIFY IMU IS ON
043127,002291: 
043128,002292: 15,3634           41277        IMUCHK             CS       IMODES30                              
043129,002293: 15,3635           74734                           MASK     BIT9                                  
043130,002294: 15,3636           10000                           CCS      A                                     #  IS IMU ON
043131,002295: 15,3637           13643                           TCF      +4                                    #  YES
043132,002296: 
043133,002297: 15,3640           05571                           TC       ALARM                                 #  NO, SEND ALARM AND EXIT
043134,002298: 15,3641           00210                           OCT      210                                   
043135,002299: 15,3642           06001                           TC       GOTOPOOH                              
043136,002300: 
043137,002301: 15,3643           05506                           TC       UPFLAG                                
043138,002302: 15,3644           00007                           ADRES    IMUSE                                 #  SET IMUSE FLAG
043139,002303: 
043140,002304: 15,3645           04622                           TC       SWRETURN                              
043141,002305: 
043142,002306: 04,2000                                           SETLOC   AOTMARK2                              
043143,002307: 04,2000                                           BANK                                           
043144,002308: 04,3014                                           COUNT*   $$/P57                                
043145,002309: 
043146,002310: 04,3014           77220        LSORIENT           STQ      VLOAD                                 
043147,002311: 04,3015           02746                                    QMAJ                                  
043148,002312: 04,3016           01555                                    RRECTCSM                              
043149,002313: 04,3017           47235                           VXV      VXV                                   
043150,002314: 04,3020           01563                                    VRECTCSM                              
043151,002315: 04,3021           03607                                    XSMD                                  
043152,002316: 04,3022           77656                           UNIT                                           
043153,002317: 04,3023           03623                           STORE    ZSMD                                  
043154,002318: 04,3024           53435                           VXV      UNIT                                  
043155,002319: 04,3025           03607                                    XSMD                                  
043156,002320: 04,3026           37615                           STCALL   YSMD                                  
043157,002321: 04,3027           02746                                    QMAJ                                  

End of include-file P51-P53.agc.  Parent file is MAIN.agc