Source Code
This is a reconstruction of the AGC program Luminary 99 Rev 0. It was the third release
of the Lunar Module flight software targeted for use in Apollo 11, after Luminary 96 and 97.
A bug (which had been around since at least Apollo 10, Luminary 69) was
discovered in Rev 0 shortly before the Apollo 11 flight, resulting in a last minute
revision into Rev 1,
which is what actually flew rather than
the Rev 0 presented here. A hardcopy of Rev 0 is known to
exist — it belonged to AGC developer Allan Klumpp for many years — but
unfortunately the Virtual AGC Project has not had access to that hardcopy. Thus
the code you see here had been reconstructed (we believe accurately) rather than
transcribed. The first step of the reconstruction of the Rev 0 source code was
the transcription of the Rev 1 source code from a hardcopy in the MIT Museum collection.
The process of reverting the active portion of the source code (i.e., other than
program comments) from Rev 1 to Rev 0 was very minor, consisting
only of moving the position of the STARTSB1 label in
FRESH START AND RESTART. Allan had previously given
us the checksums of the memory banks of Rev 0, and we have verified the program presented here has checksums
identical to all banks of Allan's listing of Rev 0. The notations on Allan's Rev 0 program listing read,
in part:GAP: ASSEMBLE REVISION 099 OF AGC PROGRAM LUMINARY BY NASA 2021112-051 A single program comment is known to differ between Rev 0 and Rev 1, but these are harder to reconstruct and verify than changes to the active portion of the code. Thus it is possible that there are additional differences between the program comments in Rev 0 and Rev 1 that are unknown to us, and therefore are not reflected in the code presented here. |
043852,000002: ## Copyright: Public domain.
043853,000003: ## Filename: DOWN-TELEMETRY_PROGRAM.agc
043854,000004: ## Purpose: Part of the reconstructed source code for LMY99 Rev 0,
043855,000005: ## otherwise known as Luminary Rev 99, the third release
043856,000006: ## of the Apollo Guidance Computer (AGC) software for Apollo 11.
043857,000007: ## It differs from LMY99 Rev 1 (the flown version) only in the
043858,000008: ## placement of a single label. The corrections shown here have
043859,000009: ## been verified to have the same bank checksums as AGC developer
043860,000010: ## Allan Klumpp's copy of Luminary Rev 99, and so are believed
043861,000011: ## to be accurate. This file is intended to be a faithful
043862,000012: ## recreation, except that the code format has been changed to
043863,000013: ## conform to the requirements of the yaYUL assembler rather than
043864,000014: ## the original YUL assembler.
043865,000015: ##
043866,000016: ## Assembler: yaYUL
043867,000017: ## Contact: Ron Burkey <info@sandroid.org>.
043868,000018: ## Website: www.ibiblio.org/apollo.
043869,000019: ## Pages: 988-997
043870,000020: ## Mod history: 2009-05-24 RSB Adapted from the corresponding
043871,000021: ## Luminary131 file, using page
043872,000022: ## images from Luminary 1A.
043873,000023: ## 2011-01-06 JL Fixed pseudo-label indentation.
043874,000024: ## 2016-12-17 RSB Proofed text comments with octopus/ProoferComments
043875,000025: ## and corrected the errors found.
043876,000026: ## 2017-01-28 RSB Back-ported some comment-text fixes
043877,000027: ## identified from Luminary 69.
043878,000028: ## 2017-03-13 RSB Comment-text fixes noted in proofing Luminary 116.
043879,000029: ## 2017-03-15 RSB Comment-text fixes identified in 5-way
043880,000030: ## side-by-side diff of Luminary 69/99/116/131/210.
043881,000031: ## 2017-08-01 MAS Created from LMY99 Rev 1.
043882,000032:
043883,000033: ## This source code has been transcribed or otherwise adapted from
043884,000034: ## digitized images of a hardcopy from the MIT Museum. The digitization
043885,000035: ## was performed by Paul Fjeld, and arranged for by Deborah Douglas of
043886,000036: ## the Museum. Many thanks to both. The images (with suitable reduction
043887,000037: ## in storage size and consequent reduction in image quality as well) are
043888,000038: ## available online at www.ibiblio.org/apollo. If for some reason you
043889,000039: ## find that the images are illegible, contact me at info@sandroid.org
043890,000040: ## about getting access to the (much) higher-quality images which Paul
043891,000041: ## actually created.
043892,000042: ##
043893,000043: ## The code has been modified to match LMY99 Revision 0, otherwise
043894,000044: ## known as Luminary Revision 99, the Apollo 11 software release preceeding
043895,000045: ## the listing from which it was transcribed. It has been verified to
043896,000046: ## contain the same bank checksums as AGC developer Allan Klumpp's listing
043897,000047: ## of Luminary Revision 99 (for which we do not have scans).
043898,000048: ##
043899,000049: ## Notations on Allan Klumpp's listing read, in part:
043900,000050: ##
043901,000051: ## ASSEMBLE REVISION 099 OF AGC PROGRAM LUMINARY BY NASA 2021112-51
043902,000052:
Page 988 |
043904,000054: # PROGRAM NAME - DOWN TELEMETRY PROGRAM
043905,000055: # MOD NO. - 0 TO COMPLETELY REWRITE THE DOWN TELEMETRY PROGRAM AND DOWNLINK ERASABLE DUMP PROGRAM FOR THE
043906,000056: # PURPOSE OF SAVING APPROXIMATELY 150 WORDS OF CORE STORAGE.
043907,000057: # THIS CHANGE REQUIRES AN ENTIRELY NEW METHOD OF SPECIFYING DOWNLINK LISTS. REFER TO DOWNLINK
043908,000058: # LISTS LOG SECTION FOR MORE DETAILS. HOWEVER THIS CHANGE WILL NOT AFFECT THE GROUND PROCESSING
043909,000059: # OF DOWN TELEMETRY DATA.
043910,000060: # MOD BY - KILROY, SMITH, DEWITT
043911,000061: # DATE - 02 OCT 67
043912,000062: # AUTHORS - KILROY, SMITH, DEWITT, DEWOLF, FAGIN
043913,000063: # LOG SECTION - DOWN-TELEMETRY PROGRAM
043914,000064:
043915,000065: # FUNCTIONAL DESCRIPTION - THIS ROUTINE IS INITIATED BY TELEMETRY END
043916,000066: # PULSE FROM THE DOWNLINK TELEMETRY CONVERTER. THIS PULSE OCCURS
043917,000067: # AT 50 TIMES PER SEC (EVERY 20 MS) THEREFORE DODOWNTM IS
043918,000068: # EXECUTED AT THESE RATES. THIS ROUTINE SELECTS THE APPROPRIATE
043919,000069: # AGC DATA TO BE TRANSMITTED DOWNLINK AND LOADS IT INTO OUTPUT
043920,000070: # CHANNELS 34 AND 35. THE INFORMATION IS THEN GATED OUT FROM THE
043921,000071: # LGC IN SERIAL FASHION.
043922,000072:
043923,000073: # THIS PROGRAM IS CODED FOR A 2 SECOND DOWNLIST. SINCE DOWNRUPTS
043924,000074: # OCCUR EVERY 20 MS AND 2 AGC COMPUTER WORDS CAN BE PLACED IN
043925,000075: # CHANNELS 34 AND 35 DURING EACH DOWNRUPT THE PROGRAM IS CAPABLE
043926,000076: # OF SENDING 200 AGC WORDS EVERY 2 SECONDS.
043927,000077:
043928,000078: # CALLING SEQUENCE - NONE
043929,000079: # PROGRAM IS ENTERED VIA TCF DODOWNTM WHICH IS EXECUTED AS A
043930,000080: # RESULT OF A DOWNRUPT. CONTROL IS RETURNED VIA TCF RESUME WHICH
043931,000081: # IN EFFECT IS A RESUME.
043932,000082:
043933,000083: # SUBROUTINES CALLED - NONE
043934,000084:
043935,000085: # NORMAL EXIT MODE - TCF RESUME
043936,000086:
043937,000087: # ALARM OR ABORT EXIT MODE - NONE
043938,000088:
043939,000089: # RESTART PROTECTION:
043940,000090: # ON A FRESH START AND RESTART THE 'STARTSUB' SUBROUTINE WILL INITIALIZE THE DOWNLIST POINTER (ACTUALLY
043941,000091: # DNTMGOTO) TO THE BEGINNING OF THE CURRENT DOWNLIST (I.E. CURRENT CONTENTS OF DNLSTADR). THIS HAS THE
043942,000092: # EFFECT OF IGNORING THE REMAINDER OF THE DOWNLIST WHICH THE DOWN-TELEMETRY PROGRAM WAS WORKING ON WHEN
043943,000093: # THE RESTART (OR FRESH START) OCCURRED AND RESUME DOWN TELEMETRY FROM THE BEGINNING OF THE CURRENT
043944,000094: # DOWNLIST.
043945,000095:
043946,000096: # ALSO OF INTEREST IS THE FACT THAT ON A RESTART THE AGC WILL ZERO DOWNLINK CHANNELS 13, 34 AND 35.
043947,000097:
043948,000098: # DOWNLINK LIST SELECTION:
043949,000099: # THE APPROPRIATE DOWNLINK LISTS ARE SELECTED BY THE FOLLOWING:
043950,000100: # 1. FRESH START
043951,000101: # 2. V37EXXE WHERE XX = THE MAJOR MODE BEING SELECTED.
043952,000102: # 3. UPDATE PROGRAM (P27)
043953,000103: # 4. NON-V37 SELECTABLE TYPE PROGRAMS (E.G. AGS INITIALIZATION (SUNDANCE, LUMINARY) AND P61-P62
043954,000104: # TRANSITION (COLOSSUS) ETC.).
043955,000105:
043956,000106: # DOWNLINK LIST RULES AND LIMITATIONS:
043957,000107: # READ SECTION(S) WHICH FOLLOW 'DEBRIS' WRITEUP.
043958,000108:
043959,000109: # OUTPUT - EVERY 2 SECONDS 100 DOUBLE PRECISION WORDS (I.E. 200 LGC
043960,000110: # COMPUTER WORDS) ARE TRANSMITTED VIA DOWNLINK.
043961,000111:
043962,000112: # ERASABLE INITIALIZATION REQUIRED - NONE
043963,000113: # 'DNTMGOTO' AND 'DNLSTADR' ARE INITIALIZED BY THE FRESH START PROGRAM.
043964,000114:
043965,000115: # DEBRIS (ERASABLE LOCATIONS DESTROYED BY THIS PROGRAM) -
043966,000116: # LDATALST, DNTMBUFF TO DNTMBUFF +21D, TMINDEX, DNQ.
043967,000117:
Page 989
This page is empty |
043970,000120:
Page 990 |
043972,000122: # DODOWNTM IS ENTERED EVERY 20 MS BY AN INTERRUPT TRIGGERED BY THE
043973,000123: # RECEIPT OF AN ENDPULSE FROM THE SPACECRAFT TELEMETRY PROGRAMMER.
043974,000124:
043975,000125: # NOTES REGARDING DOWNLINK LISTS ASSOCIATED WITH THIS PROGRAM:
043976,000126: # 1. DOWNLISTS. - DOWNLISTS MUST BE COMPILED IN THE SAME BANK AS THE
043977,000127: # DOWN-TELEMETRY PROGRAM. THIS IS DONE FOR EASE OF CODING, FASTER
043978,000128: # EXECUTION.
043979,000129: # 2. EACH DOWNLINK LIST CONSISTS OF A CONTROL LIST AND A NUMBER OF
043980,000130: # SUBLISTS.
043981,000131: # 3. A SUBLIST REFERS TO A SNAPSHOT OR DATA COMMON TO THE SAME OR OTHER
043982,000132: # DOWNLINK LISTS. ANY SUBLIST CONTAINING COMMON DATA NEEDS TO BE
043983,000133: # CODED ONLY ONCE FOR THE APPLICABLE DOWNLINK LISTS.
043984,000134: # 4. SNAPSHOT SUBLISTS REFER SPECIFICALLY TO HOMOGENOUS DATA WHICH MUST BE
043985,000135: # SAVED IN A BUFFER DURING ONE DOWNRUPT.
043986,000136: # 5. THE 1DNADR FOR THE 1ST WORD OF SNAPSHOT DATA IS FOUND AT THE END
043987,000137: # OF EACH SNAPSHOT SUBLIST, SINCE THE PROGRAM CODING SENDS THIS DP WORD
043988,000138: # IMMEDIATELY AFTER STORING THE OTHERS IN THE SNAPSHOT BUFFER.
043989,000139: # 6. ALL LISTS ARE COMBINATIONS OF CODED ERASABLE ADDRESS CONSTANTS
043990,000140: # CREATED FOR THE DOWNLIST PROGRAM.
043991,000141: # A. 1DNADR 1-WORD DOWNLIST ADDRESS.
043992,000142: # SAME AS ECADR, BUT USED WHEN THE WORD ADDRESSED IS THE LEFT
043993,000143: # HALF OF A DOUBLE-PRECISION WORD FOR DOWN TELEMETRY.
043994,000144: # B. 2DNADR - 6DNADR N-WORD DOWNLIST ADDRESS, N = 2 - 6.
043995,000145: # SAME AS 1DNADR, BUT WITH THE 4 UNUSED BITS OF THE ECADR FORMAT
043996,000146: # FILLED IN WITH 0001-0101. USED TO POINT TO A LIST OF N DOUBLE-
043997,000147: # PRECISION WORDS, STORED CONSECUTIVELY, FOR DOWN TELEMETRY.
043998,000148: # C. DNCHAN DOWNLIST CHANNEL ADDRESS.
043999,000149: # SAME AS 1DNADR, BUT WITH PREFIX BITS 0111. USED TO POINT TO
044000,000150: # A PAIR OF CHANNELS FOR DOWN TELEMETRY.
044001,000151: # D. DNPTR DOWN TELEMETRY SUBLIST POINTER.
044002,000152: # SAME AS CAF BUT TAGGED AS A CONSTANT. USED IN CONTROL LIST TO POINT TO A SUBLIST.
044003,000153: # CAUTION --- A DNPTR CANNOT BE USED IN A SUBLIST.
044004,000154: # 7. THE WORD ORDER CODE IS SET TO ZERO AT THE BEGINNING OF EACH DOWNLIST (I.E. CONTROL LIST) AND WHEN
044005,000155: # A '1DNADR TIME2' IS DETECTED IN THE CONTROL LIST (ONLY).
044006,000156: # 8. IN THE SNAPSHOT SUBLIST ONLY, THE DNADR'S CANNOT POINT TO THE FIRST WORD OF ANY EBANK.
044007,000157:
044008,000158: # DOWNLINK LIST RESTRICTIONS:
044009,000159: # (THE FOLLOWING POINTS MAY BE LISTED ELSEWHERE BUT ARE LISTED HERE SO IT IS CLEAR THAT THESE THINGS CANNOT BE
044010,000160: # DONE)
044011,000161: # 1. SNAPSHOT DOWNLIST:
044012,000162: # (A) CANNOT CONTAIN THE FOLLOWING ECADRS (I.E. 1DNADR'S): 0, 400, 1000, 1400, 2000, 2400, 3000, 3400.
044013,000163: # (B) CAN CONTAIN ONLY 1DNADR'S
044014,000164: # 2. ALL DOWNLINKED DATA (EXCEPT CHANNELS) IS PICKED UP BY A <DCA<SO DOWNLINK LISTS CANNOT CONTAIN THE
044015,000165: # EQUIVALENT OF THE FOLLOWING ECADRS (I.E. IDNADRS): 377, 777, 1377, 1777, 2377, 27777, 3377, 3777.
044016,000166: # (NOTE: THE TERM EQUIVALENT ' MEANT THAT THE IDNADR TO 6DNADR WILL BE PROCESSED LIKE 1 TO 6 ECADRS)
044017,000167: # 3. CONTROL LISTS AND SUBLISTS CANNOT HAVE ENTRIES = OCTAL 00000 OR OCTAL 77777
Page 991 |
044019,000169: # 4. THE '1DNADR TIME2' WHICH WILL CAUSE THE DOWNLINK PROGRAM TO SET THE WORDER CODE TO 3 MUST APPEAR IN THE
044020,000170: # CONTROL SECTION OF THE DOWNLIST.
044021,000171: # 5. 'DNCHAN 0' CANNOT BE USED.
044022,000172: # 6. 'DNPTR 0' CANNOT BE USED.
044023,000173: # 7. DNPTR CANNOT APPEAR IN A SUBLIST.
044024,000174:
044025,000175: # EBANK SETTINGS
044026,000176: # IN THE PROCESS OF SETTING THE EBANK (WHEN PICKING UP DOWNLINK DATA) THE DOWN TELEMETRY PROGRAM PUTS
044027,000177: # 'GARBAGE' INTO BITS15-12 OF EBANK. HUGH BLAIR-SMITH WARNS US THAT BITS15-12 OF EBANK MAY BECOME
044028,000178: # SIGNIFICANT SOMEDAY IN THE FUTURE. IF/WHEN THAT HAPPENS, THE PROGRAM SHOULD INSURE (BY MASKING ETC.)
044029,000179: # THAT BITS 15-12 OF EBANK ARE ZERO.
044030,000180:
044031,000181: # INITIALIZATION REQUIRED - TO INTERRUPT CURRENT LIST AND START A NEW ONE..
044032,000182: # 1. ADRES OF DOWNLINK LIST INTO DNLSTADR
044033,000183: # 2. NEGONE INTO SUBLIST
044034,000184: # 3. NEGONE INTO DNECADR
044035,000185:
044036,000186: 22,3711 BANK 22
044037,000187: 05,2000 SETLOC DOWNTELM
044038,000188: 05,2000 BANK
044039,000189:
044040,000190: 05,3506 0340 EBANK= DNTMBUFF
044041,000191:
044042,000192: 05,3506 COUNT* $$/DPROG
044043,000193: 05,3506 54016 DODOWNTM TS BANKRUPT
044044,000194: 05,3507 00006 EXTEND
044045,000195: 05,3510 22012 QXCH QRUPT # SAVE Q
044046,000196: 05,3511 13763 TCF WOTEST
044047,000197: 05,3512 00006 WO1 EXTEND # SET WORD ORDER BIT TO 1 ONLY IF IT
044048,000198: 05,3513 05013 WOR CHAN13 # ALREADY ISN'T.
044049,000199: 05,3514 00335 TC DNTMGOTO # GOTO APPROPRIATE PHASE OF PROGRAM
044050,000200:
044051,000201: 05,3515 37747 DNPHASE1 CA NEGONE # INITIALIZE ALL CONTROL WORDS
044052,000202: 05,3516 54337 TS SUBLIST # WORDS TO MINUS ONE
044053,000203: 05,3517 54336 TS DNECADR
044054,000204: 05,3520 33640 CA LDNPHAS2 # SET DNTMGOTO =O ALL SUBSEQUENT DOWNRUPTS
044055,000205: 05,3521 54335 TS DNTMGOTO # GO TO DNPHASE2
044056,000206: 05,3522 13536 TCF NEWLIST
044057,000207: 05,3523 10336 DNPHASE2 CCS DNECADR # SENDING OF DATA IN PROGRESS
044058,000208: 05,3524 03653 DODNADR TC FETCH2WD # YES - THEN FETCH THE NEXT 2 SP WORDS
044059,000209: 05,3525 77753 MINTIME2 -1DNADR TIME2 # NEGATIVE OF TIME2 1DNADR
044060,000210: 05,3526 13527 TCF +1 # (ECADR OF 3776 + 74001 = 77777)
044061,000211:
044062,000212: 05,3527 10337 CCS SUBLIST # IS THE SUBLIST IN CONTROL
044063,000213: 05,3530 13666 TCF NEXTINSL # YES
Page 992 |
044065,000215: 05,3531 74001 DNADRDCR OCT 74001 # DNADR COUNT AND ECADR DECREMENTER
044066,000216:
044067,000217: 05,3532 30334 CHKLIST CA CTLIST
044068,000218: 05,3533 00006 EXTEND
044069,000219: 05,3534 63536 BZMF NEWLIST # IT WILL BE NEGATIVE AT END OF LIST
044070,000220: 05,3535 13543 TCF NEXTINCL
044071,000221: 05,3536 50332 NEWLIST INDEX DNLSTCOD
044072,000222: 05,3537 32441 CA DNTABLE # INITIALIZE CTLIST WITH
044073,000223: 05,3540 54334 TS CTLIST # STARTING ADDRESS OF NEW LIST
044074,000224: 05,3541 40332 CS DNLSTCOD
044075,000225: 05,3542 13756 TCF SENDID +3
044076,000226: 05,3543 50334 NEXTINCL INDEX CTLIST
044077,000227: 05,3544 30000 CA 0
044078,000228: 05,3545 10000 CCS A
044079,000229: 05,3546 24334 INCR CTLIST # SET POINTER TO PICK UP NEXT CTLIST WORD
044080,000230: 05,3547 13553 TCF +4 # ON NEXT ENTRY TO PROG. (A SHOULD NOT =0)
044081,000231: 05,3550 56334 XCH CTLIST # SET CTLIST TO NEGATIVE AND PLACE(CODING)
044082,000232: 05,3551 40000 COM # UNCOMPLEMENTED DNADR INTO A. (FOR LA)
044083,000233: 05,3552 56334 XCH CTLIST # (ST IN )
044084,000234: 05,3553 24000 +4 INCR A # (CTLIST)
044085,000235: 05,3554 54336 TS DNECADR # SAVE DNADR
044086,000236: 05,3555 63525 AD MINTIME2 # TEST FOR TIME2 (NEG. OF ECADR)
044087,000237: 05,3556 10000 CCS A
044088,000238: 05,3557 13563 TCF SETWO +1 # DON'T SET WORD ORDER CODE
044089,000239: 05,3560 47777 MINB1314 OCT 47777 # MINUS BIT 13 AND 14 (CAN'T GET HERE)
044090,000240: 05,3561 13563 TCF SETWO +1 # DON'T SET WORD ORDER CODE
044091,000241: 05,3562 03605 SETWO TC WOZERO # GO SET WORD ORDER CODE TO ZERO.
044092,000242: 05,3563 30336 +1 CA DNECADR # RELOAD A WITH THE DNADR.
044093,000243: 05,3564 63560 +2 AD MINB1314 # IS THIS A REGULAR DNADR?
044094,000244: 05,3565 00006 EXTEND
044095,000245: 05,3566 63653 BZMF FETCH2WD # YES. (A MUST NEVER BE ZERO)
044096,000246: 05,3567 67741 AD MINB12 # NO- IS IT A POINTER (DNPTR) OR A
044097,000247: 05,3570 00006 EXTEND # CHANNEL(DNCHAN)
044098,000248: 05,3571 63611 BZMF DODNPTR # IT'S A POINTER. (A MUST NEVER BE ZERO)
044099,000249:
044100,000250: 05,3572 00006 DODNCHAN TC 6 # (EXECUTED AS EXTEND) IT S A CHANNEL
044101,000251: 05,3573 50336 INDEX DNECADR
044102,000252: 05,3574 44000 INDEX 0 -4000 # (EXECUTED AS READ)
044103,000253: 05,3575 54001 TS L
044104,000254: 05,3576 00006 TC 6 # (EXECUTED AS EXTEND)
044105,000255: 05,3577 50336 INDEX DNECADR
044106,000256: 05,3600 43777 INDEX 0 -4001 # (EXECUTED AS READ)
044107,000257: 05,3601 54336 TS DNECADR # SET DNECADR
044108,000258: 05,3602 37747 CA NEGONE # TO MINUS
044109,000259: 05,3603 56336 XCH DNECADR # WHILE PRESERVING A.
044110,000260: 05,3604 13701 TCF DNTMEXIT # GO SEND CHANNELS
044111,000261:
044112,000262: 05,3605 44745 WOZERO CS BIT7
044113,000263: 05,3606 00006 EXTEND
044114,000264: 05,3607 03013 WAND CHAN13 # SET WORD ORDER CODE TO ZERO
Page 993 |
044116,000266: 05,3610 00002 TC Q # RETURN TO CALLER
044117,000267:
044118,000268: 05,3611 50336 DODNPTR INDEX DNECADR # DNECADR CONTAINS ADRES OF SUBLIST
044119,000269: 05,3612 00000 0 0 # CLEAR AND ADD LIST ENTRY INTO A.
044120,000270: 05,3613 10000 CCS A # IS THIS A SNAPSHOT SUBLIST
044121,000271: 05,3614 30336 CA DNECADR # NO, IT IS A REGULAR SUBLIST.
044122,000272: 05,3615 13665 TCF DOSUBLST # A MUST NOT BE ZERO.
044123,000273:
044124,000274: 05,3616 56336 XCH DNECADR # YES, IT IS A SNAPSHOT SUBLIST.
044125,000275: 05,3617 54337 TS SUBLIST # C(DNECADR) INTO SUBLIST
044126,000276: 05,3620 34755 CAF ZERO # A INTO A
044127,000277: 05,3621 56336 XCH TMINDEX # (NOTE.. TMINDEX = DNECADR)
044128,000278:
044129,000279: # THE FOLLOWING CODING (FROM SNAPLOOP TO SNAPEND) IS FOR THE PURPOSE OF TAKING A SNAPSHOT OF 12 DP REGISTERS.
044130,000280: # THIS IS DONE BY SAVING 11 DP REGISTERS IN DNTMBUFF AND SENDING THE FIRST DP WORD IMMEDIATELY.
044131,000281: # THE SNAPSHOT PROCESSING IS THE MOST TIME CONSUMING AND THEREFORE THE CODING AND LIST STRUCTURE WERE DESIGNED
044132,000282: # TO MINIMIZE TIME. THE TIME OPTIMIZATION RESULTS IN RULES UNIQUE TO THE SNAPSHOT PORTION OF THE DOWNLIST.
044133,000283: # THESE RULES ARE ......
044134,000284: # 1. ONLY 1DNADR'S CAN APPEAR IN THE SNAPSHOT SUBLIST
044135,000285: # 2. THE 1DNADR'S CANNOT REFER TO THE FIRST LOCATION IN ANY BANK.
044136,000286:
044137,000287: 05,3622 54003 SNAPLOOP TS EBANK # SET EBANK
044138,000288: 05,3623 74357 MASK LOW8 # ISOLATE RELATIVE ADDRESS
044139,000289: 05,3624 00006 EXTEND
044140,000290: 05,3625 50000 INDEX A
044141,000291: 05,3626 E3,1401 EBANK= 1401
044142,000292: 05,3626 31402 DCA 1401 # PICK UP 2 SNAPSHOT WORDS.
044143,000293: 05,3627 0340 EBANK= DNTMBUFF
044144,000294: 05,3627 50336 INDEX TMINDEX
044145,000295: 05,3630 52341 DXCH DNTMBUFF # STORE 2 SNAPSHOT WORDS IN BUFFER
044146,000296: 05,3631 24336 INCR TMINDEX # SET BUFFER INDEX FOR NEXT 2 WORDS.
044147,000297: 05,3632 24336 INCR TMINDEX
044148,000298: 05,3633 24337 SNAPAGN INCR SUBLIST # SET POINTER TO NEXT 2 WORDS OF SNAPSHOT
044149,000299: 05,3634 50337 INDEX SUBLIST
044150,000300: 05,3635 00000 0 0 # = CA SSSS (SSSS = NEXT ENTRY IN SUBLIST)
044151,000301: 05,3636 10000 CCS A # TEST FOR LAST TWO WORDS OF SNAPSHOT.
044152,000302: 05,3637 13622 TCF SNAPLOOP # NOT LAST TWO.
044153,000303: 05,3640 03523 LDNPHAS2 GENADR DNPHASE2
044154,000304: 05,3641 54337 TS SUBLIST # YES, LAST. SAVE A.
044155,000305: 05,3642 37747 CA NEGONE # SET DNECADR AND
044156,000306: 05,3643 54336 TS DNECADR # SUBLIST POINTERS
044157,000307: 05,3644 56337 XCH SUBLIST # TO NEGATIVE VALUES.
044158,000308: 05,3645 54003 TS EBANK
044159,000309: 05,3646 74357 MASK LOW8
044160,000310: 05,3647 00006 EXTEND
044161,000311: 05,3650 50000 INDEX A
044162,000312: 05,3651 E3,1401 EBANK= 1401
044163,000313: 05,3651 31402 DCA 1401 # PICK UP FIRST 2 WORDS OF SNAPSHOT.
Page 994 |
044165,000315: 05,3652 0340 EBANK= DNTMBUFF
044166,000316: 05,3652 13701 SNAPEND TCF DNTMEXIT # NOW GO SEND THEM.
044167,000317:
044168,000318: 05,3653 30336 FETCH2WD CA DNECADR
044169,000319: 05,3654 54003 TS EBANK # SET EBANK
044170,000320: 05,3655 74357 MASK LOW8 # ISOLATE RELATIVE ADDRESS
044171,000321: 05,3656 54001 TS L
044172,000322: 05,3657 33531 CA DNADRDCR # DECREMENT COUNT AND ECADR
044173,000323: 05,3660 26336 ADS DNECADR
044174,000324: 05,3661 00006 EXTEND
044175,000325: 05,3662 50001 INDEX L
044176,000326: 05,3663 E3,1400 EBANK= 1400
044177,000327: 05,3663 31401 DCA 1400 # PICK UP 2 DATA WORDS
044178,000328: 05,3664 0340 EBANK= DNTMBUFF
044179,000329: 05,3664 13701 TCF DNTMEXIT # NOW GO SEND THEM.
044180,000330:
044181,000331: 05,3665 54337 DOSUBLST TS SUBLIST # SET SUBLIST POINTER
044182,000332: 05,3666 50337 NEXTINSL INDEX SUBLIST
044183,000333: 05,3667 00000 0 0 # = CA SSSS (SSSS = NEXT ENTRY IN SUBLIST)
044184,000334: 05,3670 10000 CCS A # IS IT THE END OF THE SUBLIST
044185,000335: 05,3671 24337 INCR SUBLIST # NO -
044186,000336: 05,3672 13676 TCF +4
044187,000337: 05,3673 54337 TS SUBLIST # SAVE A.
044188,000338: 05,3674 37747 CA NEGONE # SET SUBLIST TO MINUS
044189,000339: 05,3675 56337 XCH SUBLIST # RETRIEVE A.
044190,000340: 05,3676 24000 +4 INCR A
044191,000341: 05,3677 54336 TS DNECADR # SAVE DNADR
044192,000342: 05,3700 13564 TCF SETWO +2 # GO USE COMMON CODING (PROBLEMS WOULD
044193,000343: # OCCUR IF THE PROGRAM ENCOUNTERED A
044194,000344: # DNPTR NOW)
044195,000345:
044196,000346: 05,3701 00006 DNTMEXIT EXTEND # DOWN-TELEMETRY EXIT
044197,000347: 05,3702 01034 WRITE DNTM1 # TO SEND A + L TO CHANNELS 34 + 35
044198,000348: 05,3703 30001 CA L # RESPECTIVELY
044199,000349: 05,3704 00006 TMEXITL EXTEND
044200,000350: 05,3705 01035 WRITE DNTM2
044201,000351: 05,3706 15270 TMRESUME TCF RESUME # EXIT TELEMETRY PROGRAM VIA RESUME.
044202,000352:
044203,000353: 05,3707 7741 MINB12 EQUALS -1/8
044204,000354: 05,3707 0336 DNECADR EQUALS TMINDEX
044205,000355: 05,3707 0334 CTLIST EQUALS LDATALST
044206,000356: 05,3707 0337 SUBLIST EQUALS DNQ
044207,000357:
Page 995 |
044209,000359: # SUBROUTINE NAME - DNDUMP
044210,000360:
044211,000361: # FUNCTIONAL DESCRIPTION - TO SEND (DUMP) ALL ERASABLE STORAGE 'N' TIMES. (N=1 TO 4). BANKS ARE SENT ONE AT A TIME
044212,000362: # EACH BANK IS PRECEEDED BY AN ID WORD, SYNCH BITS, ECADR AND TIME1 FOLLOWED BY THE 256D WORDS OF EACH
044213,000363: # EBANK. EBANKS ARE DUMPED IN ORDER (I.E. EBANK 0 FIRST, THEN EBANK1 ETC.)
044214,000364:
044215,000365: # CALLING SEQUENCE - THE GROUND OR ASTRONAUT BY KEYING V74E CAN INITIALIZE THE DUMP.
044216,000366: # AFTER KEYING IN V74E THE CURRENT DOWNLIST WILL BE IMMEDIATELY TERMINATED AND THE DOWNLINK ERASABLE DUMP
044217,000367: # WILL BEGIN.
044218,000368:
044219,000369: # ONCE INITIATED THE DOWNLINK ERASABLE DUMP CAN BE TERMINATED (AND INTERRUPTED DOWNLIST REINSTATED) ONLY
044220,000370: # BY THE FOLLOWING:
044221,000371:
044222,000372: # 1. A FRESH START
044223,000373: # 2. COMPLETION OF ALL DOWNLINK DUMPS REQUESTED (ACCORDING TO BITS SET IN DUMPCNT). NOTE THAT DUMPCNT
044224,000374: # CAN BE ALTERED BY A V21N01.
044225,000375: # 3. AND INVOLUNTARILY BY A RESTART.
044226,000376:
044227,000377: # NORMAL EXIT MODE - TCF DNPHASE1
044228,000378:
044229,000379: # ALARM OR ABORT MODE - NONE
044230,000380:
044231,000381: # *SUBROUTINES CALLED - NONE.
044232,000382:
044233,000383: # ERASABLE INITIALIZATION REQUIRED -
044234,000384: # DUMPCNT OCT 20000 IF 4 COMPLETE ERASABLE DUMPS ARE DESIRED
044235,000385: # DUMPCNT OCT 10000 IF 2 COMPLETE ERASABLE DUMPS ARE DESIRED
044236,000386: # DUMPCNT OCT 04000 IF 1 COMPLETE ERASABLE DUMP IS DESIRED
044237,000387:
044238,000388: # DEBRIS - DUMPLOC, DUMPSW, DNTMGOTO, EBANK AND CENTRAL REGISTERS
044239,000389:
044240,000390: # TIMING - TIME (IN SECS) = ((NO.DUMPS)*(NO.EBANKS)*(WDSPEREBANK + NO.IDWDS)) / NO.WDSPERSEC
044241,000391: # TIME (IN SECS) = ( 4 )*( 8 )*( 256 + 4 ) / 100
044242,000392: # THUS TIME (IN SECS TO SEND DUMP OF ERASABLE 4 TIMES VIA DOWNLINK) = 83.2 SECONDS
044243,000393:
044244,000394: # STRUCTURE OF ONE EBANK AS IT IS SENT BY DOWNLINK PROGRAM -
044245,000395: # (REMINDER - THIS ONLY DESCRIBES ONE OF THE 8 EBANKS X 4 (DUMPS) = 32 EBANKS WHICH WILL BE SENT BY DNDUMP)
044246,000396: # DOWNLIST W
044247,000397: # WORD TAKEN FROM CONTENTS OF EXAMPLE O COMMENTS
044248,000398: # 1 ERASID 0177X 0 DOWNLIST I.D. FOR DOWNLINK ERASABLE DUMP (X=7 CSM, 6 LM)
044249,000399: # 2 LOWIDCOD 77340 1 DOWNLINK SYNCH BITS. (SAME ONE USED IN ALL OTHER DOWNLISTS)
044250,000400: # 3 DUMPLOC 13400 1 (SEE NOTES ON DUMPLOC) 1 = 3RD ERAS DUMP, 3400=ECADR OF 5TH WD
044251,000401: # 4 TIME1 14120 1 TIME IN CENTISECONDS
044252,000402: # 5 FIRST WORD OF EBANK X 03400 1 IN THIS EXAMPLE THIS WORD = CONTENTS OF E7,1400 (ECADR 3400)
044253,000403: # 6 2ND WORD OF EBANK X 00142 1 IN THIS EXAMPLE THIS WORD = CONTENTS OF E7,1401 (ECADR 3401)
044254,000404: # 7 3RD WORD OF EBANK X 00142 1 IN THIS EXAMPLE THIS WORD = CONTENTS OF E7,1402 (ECADR 3402)
044255,000405: # . 1
044256,000406: # . 1
044257,000407: # . 1
044258,000408: # 260D 256TH WORD OF EBANK X 03777 1 IN THIS EXAMPLE THIS WORD = CONTENTS OF E7,1777 (ECADR 3777)
044259,000409:
044260,000410: # NOTE - DUMPLOC CONTAINS THE COUNTER AND ECADR FOR EACH WORD BEING SENT.
044261,000411: # THE BIT STRUCTURE OF DUMPLOC IS FOLLOWS---
044262,000412: # X = NOT USED
044263,000413: # X ABC EEE RRRRRRRR ABC = ERASABLE DUMP COUNTER (I.E. ABC = 0,1,2 OR 3 WHICH MEANS THAT
044264,000414: # COMPLETE ERASABLE DUMP NUMBER 1,2,3 OR 4 RESPECTIVELY IS IN PROGRESS)
044265,000415: # EEE = EBANK BITS
044266,000416: # RRRRRRRR = RELATIVE ADDRESS WITHIN AN EBANK.
044267,000417:
Page 996 |
044269,000419: 05,3707 34755 DNDUMPI CA ZERO # INITIALIZE DOWNLINK
044270,000420: 05,3710 54336 TS DUMPLOC # ERASABLE DUMP
044271,000421: 05,3711 03753 +2 TC SENDID # GO SEND ID AND SYNCH BITS
044272,000422: 05,3712 33721 CA LDNDUMP1 # SET DNTMGOTO
044273,000423: 05,3713 54335 TS DNTMGOTO # TO LOCATION FOR NEXT PASS
044274,000424: 05,3714 30025 CA TIME1 # PLACE TIME1
044275,000425: 05,3715 56001 XCH L # INTO L
044276,000426: 05,3716 30336 CA DUMPLOC # AND ECADR OF THIS EBANK INTO A
044277,000427: 05,3717 13701 TCF DNTMEXIT # SEND DUMPLOC AND TIME1
044278,000428:
044279,000429: 05,3720 03722 LDNDUMP ADRES DNDUMP
044280,000430: 05,3721 03735 LDNDUMP1 ADRES DNDUMP1
044281,000431:
044282,000432: 05,3722 34752 DNDUMP CA TWO # INCREMENT ECADR IN DUMPLOC
044283,000433: 05,3723 26336 ADS DUMPLOC # TO NEXT DP WORD TO BE
044284,000434: 05,3724 74357 MASK LOW8 # DUMPED AND SAVE IT.
044285,000435: 05,3725 10000 CCS A # IS THIS THE BEGINNING OF A NEW EBANK
044286,000436: 05,3726 13737 TCF DNDUMP2 # NO - THEN CONTINUE DUMPING
044287,000437: 05,3727 30336 CA DUMPLOC # YES - IS THIS THE END OF THE
044288,000438: 05,3730 70333 MASK DUMPCNT # N TH (N = 1 TO 4) COMPLETE ERASABLE
044289,000439: 05,3731 77722 MASK PRIO34 # DUMP (BIT14 FOR 4, BIT13 FOR 2 OR BIT12
044290,000440: 05,3732 10000 CCS A # FOR 1 COMPLETE ERASABLE DUMP(S)).
044291,000441: 05,3733 13515 TCF DNPHASE1 # YES - START SENDING INTERRUPTED DOWNLIST
044292,000442: # AGAIN
044293,000443: 05,3734 13711 TCF DNDUMPI +2 # NO - GO BACK AND INITIALIZE NEXT BANK
044294,000444:
044295,000445: 05,3735 33720 DNDUMP1 CA LDNDUMP # SET DNTMGOTO
044296,000446: 05,3736 54335 TS DNTMGOTO # FOR WORDS 3 TO 256D OF CURRENT EBANK
044297,000447:
044298,000448: 05,3737 30336 DNDUMP2 CA DUMPLOC
044299,000449: 05,3740 54003 TS EBANK # SET EBANK
044300,000450: 05,3741 74357 MASK LOW8 # ISOLATE RELATIVE ADDRESS.
044301,000451: 05,3742 54002 TS Q # (NOTE: MASK INSTRUCTION IS USED TO PICK
044302,000452: 05,3743 34754 CA NEG0 # UP ERASABLE REGISTERS SO THAT EDITING
044303,000453: 05,3744 54001 TS L # REGISTERS 20-23 WILL NOT BE ALTERED.)
044304,000454: 05,3745 50002 INDEX Q
044305,000455: 05,3746 E3,1400 EBANK= 1400 # PICK UP LOW ORDER REGISTER OF PAIR
044306,000456: 05,3746 71401 MASK 1401 # OF ERASABLE REGISTERS.
044307,000457: 05,3747 56001 XCH L
044308,000458: 05,3750 50002 INDEX Q # PICK UP HIGH ORDER REGISTER OF PAIR
044309,000459: 05,3751 71400 MASK 1400 # OF ERASABLE REGISTERS.
044310,000460: 05,3752 0340 EBANK= DNTMBUFF
044311,000461: 05,3752 13701 TCF DNTMEXIT # GO SEND THEM
044312,000462:
044313,000463: 05,3753 00006 SENDID EXTEND # ** ENTRANCE USED BY ERASABLE DUMP PROG.**
044314,000464: 05,3754 22335 QXCH DNTMGOTO # SET DNTMGOTO SO NEXT TIME PROG WILL GO
044315,000465: 05,3755 35011 CAF ERASID # TO LOCATION FOLLOWING :TC SENDID:
044316,000466:
044317,000467: 05,3756 54001 TS L # ** ENTRANCE USED BY REGULAR DOWNLINK PG **
Page 997 |
044319,000469: 05,3757 03605 TC WOZERO # GO SET WORD ORDER CODE TO ZERO
044320,000470: 05,3760 32065 CAF LOWIDCOD # PLACE SPECIAL ID CODE INTO L
044321,000471: 05,3761 56001 XCH L # AND ID BACK INTO A
044322,000472: 05,3762 13701 TCF DNTMEXIT # SEND DOWNLIST ID CODE(S).
044323,000473:
044324,000474: 05,3763 34745 WOTEST CA BIT7 # AT THE BEGINNING OF THE LIST THE WORD
044325,000475: 05,3764 00006 EXTEND # ORDER BIT WILL BE SET BACK TO ZERO
044326,000476: 05,3765 02013 RAND CHAN13
044327,000477: 05,3766 10000 CCS A
044328,000478: 05,3767 00335 TC DNTMGOTO
044329,000479: 05,3770 34745 CA BIT7
044330,000480: 05,3771 13512 TCF WO1
044331,000481:
End of include-file DOWN-TELEMETRY_PROGRAM.agc. Parent file is MAIN.agc