Source Code
These source-code files are part of a reconstructed copy of Luminary 69/2,
the flown, final release of the Apollo 10 Lunar Module (LM) Apollo Guidance Computer (AGC) software.
The reconstruction is based on the source code of Luminary 69 — i.e., the initial, unflown version, "revision 0" — of which a contemporary listing was available. The code was then updated by incorporating the differences between Luminary 69 and Luminary 69/2, known from other contemporary documentation. The only such difference is the implementation in Luminary 69/2 of the "R-2 Lunar Potential Model", the source code for which was taken from program Luminary 99/1 (Apollo 11 LM), of which a contemporary listing was also available. Finally, the now-reconstructed Luminary 69/2 was then validated by assembling it to executable form and verifying that its memory banks had the correct checksums, known from still other contemporary documentation. Note that page numbers in the reconstructed code match those in the original Luminary 69 program listing, or in the ORBITAL INTEGRATION log section, in Luminary 99/1. Page numbers would certainly differ somewhat in a contemporary Luminary 69/2 listing. Moreover, annotations that were not present in the contemporary source code have been added to the reconstructed code to justify each change in Luminary 69/2 relative to Luminary 69. Here's a guide to the Apollo documentation referenced in those annotations:
|
028930,000002: ## Copyright: Public domain.
028931,000003: ## Filename: GROUND_TRACKING_DETERMINATION_PROGRAM_-_P21.agc
028932,000004: ## Purpose: A section of LUM69 revision 2.
028933,000005: ## It is part of the reconstructed source code for the flown
028934,000006: ## version of the flight software for the Lunar Module's (LM)
028935,000007: ## Apollo Guidance Computer (AGC) for Apollo 10. The code has
028936,000008: ## been recreated from a copy of Luminary revsion 069, using
028937,000009: ## changes present in Luminary 099 which were described in
028938,000010: ## Luminary memos 75 and 78. The code has been adapted such
028939,000011: ## that the resulting bugger words exactly match those specified
028940,000012: ## for LUM69 revision 2 in NASA drawing 2021152B, which gives
028941,000013: ## relatively high confidence that the reconstruction is correct.
028942,000014: ## Reference: pp. 664-666
028943,000015: ## Assembler: yaYUL
028944,000016: ## Contact: Ron Burkey <info@sandroid.org>.
028945,000017: ## Website: www.ibiblio.org/apollo/index.html
028946,000018: ## Mod history: 2019-07-27 MAS Created from Luminary 69.
028947,000019:
Page 664 |
028949,000021: # GROUND TRACKING DETERMINATION PROGRAM P21
028950,000022: # PROGRAM DESCRIPTION
028951,000023: # MOD NO - 1
028952,000024: # MOD BY - N. M. NEVILLE
028953,000025:
028954,000026: # FUNCTIONAL DECRIPTION -
028955,000027:
028956,000028: # TO PROVIDE THE ASTRONAUT DETAILS OF THE LM OR CSM GROUND TRACK WITHOUT
028957,000029: # THE NEED FOR GROUND COMMUNICATION (REQUESTED BY DSKY).
028958,000030: # CALLING SEQUENCE -
028959,000031:
028960,000032: # ASTRONAUT REQUEST THROUGH DSKY V37E21E
028961,000033: # SUBROUTINES CALLED -
028962,000034:
028963,000035: # GOPERF4
028964,000036: # GOFLASH
028965,000037: # THISPREC
028966,000038: # OTHPREC
028967,000039: # LAT-LONG
028968,000040:
028969,000041: # NORMAL EXIT MODES -
028970,000042:
028971,000043: # ASTRONAUT REQUEST TROUGH DSKY TO TERMINATE PROGRAM V34E
028972,000044: # ALARM OR ABORT EXIT MODES -
028973,000045:
028974,000046: # NONE
028975,000047: # OUTPUT -
028976,000048:
028977,000049: # OCTAL DISPLAY OF OPTION CODE AND VEHICLE WHOSE GROUND TRACK IS TO BE
028978,000050: # COMPUTED
028979,000051: # OPTION CODE 00002
028980,000052: # THIS 00001
028981,000053: # OTHER 00002
028982,000054: # DECIMAL DISPLAY OF TIME TO BE INTEGRATED TO HOURS , MINUTES , SECONDS
028983,000055: # DECIMAL DISPLAY OF LAT,LONG,ALT
028984,000056:
028985,000057: # ERASABLE INITIALIZATION REQUIRED
028986,000058:
028987,000059: # AX0 2DEC 4.652459653 E-5 RADIANS %68-69 CONSTANTS"
028988,000060:
028989,000061: # -AY0 2DEC 2.147535898 E-5 RADIANS
028990,000062:
028991,000063: # AZ0 2DEC .7753206164 REVOLUTIONS
028992,000064: # FOR LUNAR ORBITS 504LM VECTOR IS NEEDED
028993,000065:
028994,000066: # 504LM 2DEC -2.700340600 E-5 RADIANS
028995,000067:
028996,000068: # 504LM _2 2DEC -7.514128400 E-4 RADIANS
028997,000069:
028998,000070: # 504LM _4 2DEC _2.553198641 E-4 RADIANS
028999,000071:
029000,000072: # NONE
029001,000073: # DEBRIS
Page 665 |
029003,000075:
029004,000076: # CENTRALS-A,Q,L
029005,000077: # OTHER - THOSE USED BY THE ABOVE LISTED SUBROUTINES
029006,000078: # SEE LEMPREC, LAT-LONG
029007,000079:
029008,000080: 35,2511 30,2000 SBANK= LOWSUPER # FOR LOW 2CADR'S.
029009,000081:
029010,000082: 33,2200 BANK 33
029011,000083: 24,2000 SETLOC P20S
029012,000084: 24,2000 BANK
029013,000085:
029014,000086: 24,3402 E7,1756 EBANK= P21TIME
029015,000087: 24,3402 COUNT* $$/P21
029016,000088: 24,3402 34753 PROG21 CAF ONE
029017,000089: 24,3403 55145 TS OPTION2 # ASSUMED VEHICLE IS LM, R2 = 00001
029018,000090: 24,3404 34752 CAF BIT2 # OPTION 2
029019,000091: 24,3405 04616 TC BANKCALL
029020,000092: 24,3406 20506 CADR GOPERF4
029021,000093: 24,3407 06001 TC GOTOPOOH # TERMINATE
029022,000094: 24,3410 03412 TC +2 # PROCEED VALUE OF ASSUMED VEHICLE OK
029023,000095: 24,3411 03404 TC -5 # R2 LOADED THROUGH DSKY
029024,000096: 24,3412 33503 P21PROG1 CAF V6N34 # LOAD DESIRED TIME OF LAT-LONG.
029025,000097: 24,3413 04616 TC BANKCALL
029026,000098: 24,3414 20351 CADR GOFLASH
029027,000099: 24,3415 06001 TC GOTOPOOH # TERM
029028,000100: 24,3416 03420 TC +2 # PROCEED VALUES OK
029029,000101: 24,3417 03412 TC -5 # TIME LOADED THROUGH DSKY
029030,000102: 24,3420 06036 TC INTPRET
029031,000103: 24,3421 77745 DLOAD
029032,000104: 24,3422 01046 DSPTEM1
029033,000105: 24,3423 03757 STORE P21TIME
029034,000106: 24,3424 45335 SLOAD DSU
029035,000107: 24,3425 01146 OPTION2
029036,000108: 24,3426 11501 P21ONENN
029037,000109: 24,3427 71230 BHIZ DLOAD
029038,000110: 24,3430 51443 P21PROG2 # VEHICLE TO BE INTEGRATED IS LEM
029039,000111: 24,3431 03757 P21TIME # VEHICLE TO BE INTEGRATED IS CSM
029040,000112: 24,3432 34041 STCALL TDEC1 # INTEGRATE TO TIME SPECIFIED IN TDEC
029041,000113: 24,3433 27043 OTHPREC # ADJUST UNITS FOR LAT-LONG ROUTINE
029042,000114: 24,3434 46135 P21PROGA SLOAD BHIZ
029043,000115: 24,3435 00050 X2
029044,000116: 24,3436 51451 P21PROG3
029045,000117: 24,3437 43175 VLOAD SETGO
029046,000118: 24,3440 00001 RATT
029047,000119: 24,3441 01423 LUNAFLAG
029048,000120: 24,3442 51454 P21PROG4
029049,000121: 24,3443 77745 P21PROG2 DLOAD
029050,000122: 24,3444 03757 P21TIME
029051,000123: 24,3445 34041 STCALL TDEC1
029052,000124: 24,3446 27057 THISPREC
029053,000125: 24,3447 77650 GOTO
Page 666 |
029055,000127: 24,3450 51434 P21PROGA
029056,000128: 24,3451 43175 P21PROG3 VLOAD CLEAR
029057,000129: 24,3452 00001 RATT
029058,000130: 24,3453 01663 LUNAFLAG
029059,000131: 24,3454 16032 P21PROG4 STODL ALPHAV
029060,000132: 24,3455 00015 TAT
029061,000133: 24,3456 45014 CLEAR CALL
029062,000134: 24,3457 00662 ERADFLAG
029063,000135: 24,3460 26351 LAT-LONG
029064,000136: 24,3461 77776 EXIT
029065,000137: 24,3462 33502 CAF V06N43 # DISPLAY LAT,LONG,ALT
029066,000138: 24,3463 04616 TC BANKCALL # LAT,LONG = 1/2 REVS B0
029067,000139: 24,3464 20351 CADR GOFLASH # ALT = KM B14
029068,000140: 24,3465 06001 TC GOTOPOOH # TERM
029069,000141: 24,3466 06001 TC GOTOPOOH
029070,000142: 24,3467 06036 TC INTPRET # V32E RECYCLE
029071,000143: 24,3470 43345 DLOAD DAD
029072,000144: 24,3471 03757 P21TIME
029073,000145: 24,3472 11477 600SEC # 600 SECONDS OR 10 MIN
029074,000146: 24,3473 01046 STORE DSPTEM1
029075,000147: 24,3474 77634 RTB
029076,000148: 24,3475 51412 P21PROG1
029077,000149: 24,3476 00003 25140 600SEC 2DEC 60000 B-28 # 10 MIN
029078,000150:
029079,000151: 24,3500 00001 P21ONENN OCT 00001 # NEEDED TO DETERMINE VEHICLE
029080,000152: 24,3501 00000 OCT 00000 # TO BE INTEGRATED
029081,000153: 24,3502 01453 V06N43 VN 00643
029082,000154: 24,3503 01442 V6N34 VN 00634
029083,000155:
029084,000156:
End of include-file GROUND_TRACKING_DETERMINATION_PROGRAM_-_P21.agc. Parent file is MAIN.agc