Source Code
These source-code files are part of a reconstructed copy of Comanche 72, the
first release of the Apollo Guidance Computer (AGC) Command Module (CM) software
for Apollo 13.
They have been adapted from sources files created from a listing of Comanche 55. These source files were updated to match binary dumps of a set of Comanche 67 rope modules. They were then further modified by applying known changes between Comanche 67 and Comanche 72. A binary dump of module B2 of Comanche 72, part number 2010802-021, was also used to validate changes made to banks 05-13. The resulting code assembles to have identical memory-bank checksums as those specified in NASA drawing 2021153G; this gives reasonably high confidence that the changes that have been made are correct. In places where ambiguity exists, this ambiguity is discussed in "## Reconstruction:" comments. Since no contemporary listings of Comanche 72 are available as source material, all comments and labels are approximate. They have been taken from other AGC programs where possible, or, in some places, written from scratch to match what we believe would have been in the original listing. |
051079,000002: ## Copyright: Public domain.
051080,000003: ## Filename: WAITLIST.agc
051081,000004: ## Purpose: A section of Comanche revision 072.
051082,000005: ## It is part of the reconstructed source code for the first
051083,000006: ## release of the software for the Command Module's (CM) Apollo
051084,000007: ## Guidance Computer (AGC) for Apollo 13. No original listings
051085,000008: ## of this program are available; instead, this file was recreated
051086,000009: ## from a printout of Comanche 055, binary dumps of a set of
051087,000010: ## Comanche 067 rope modules, and changelogs between Comanche 067
051088,000011: ## and 072. It has been adapted such that the resulting bugger words
051089,000012: ## exactly match those specified for Comanche 072 in NASA drawing
051090,000013: ## 2021153G, which gives relatively high confidence that the
051091,000014: ## reconstruction is correct.
051092,000015: ## Assembler: yaYUL
051093,000016: ## Contact: Ron Burkey <info@sandroid.org>.
051094,000017: ## Website: www.ibiblio.org/apollo/index.html
051095,000018: ## Mod history: 2024-05-13 MAS Created from Comanche 067.
051096,000019:
051097,000020: # PROGRAM DESCRIPTION DATE - 10 OCTOBER 1966
051098,000021: # MOD NO - 2 LOG SECTION - WAITLIST
051099,000022: # MOD BY - MILLER (DTMAX INCREASED TO 162.5 SEC) ASSEMBLY SUNBURST REV 5
051100,000023: # MOD 3 BY KERNAN (INHINT INSERTED AT WAITLIST) 2/28/68 SKIPPER REV 4
051101,000024: # MOD 4 BY KERNAN (TWIDDLE IN 54) 3/28/68 SKIPPER REV 13.
051102,000025:
051103,000026: # FUNCTIONAL DESCRIPTION -
051104,000027: # PART OF A SECTION OF PROGRAMS,- WAITLIST, TASKOVER, T3RUPT, USED TO CALL A PROGRAM, (CALLED A TASK),
051105,000028: # WHICH IS TO BEGIN IN C(A) CENTISECONDS. WAITLIST UPDATES TIME3, LST1 AND LST2. THE MEANING OF THESE LISTS
051106,000029: # FOLLOW.
051107,000030:
051108,000031: # C(TIME3) = 16384 -(T1-T) CENTISECONDS, (T=PRESENT TIME, T1-TIME FOR TASK1)
051109,000032:
051110,000033: # C(LST1) = -(T2-T1)+1
051111,000034: # C(LST1 +1) = -(T3-T2)+1
051112,000035: # C(LST1 +2) = -(T4-T3)+1
051113,000036: # .
051114,000037: # .
051115,000038: # C(LST1 +6) = -(T8-T7)+1
051116,000039: # C(LST1 +7) = -(T9-T8)+1
051117,000040:
051118,000041: # C(LST2) = 2CADR OF TASK1
051119,000042: # C(LST2 +2) = 2CADR OF TASK2
051120,000043: # .
051121,000044: # .
051122,000045: # C(LST2 +14) = 2CADR OF TASK8
051123,000046: # C(LST2 +16) = 2CADR OF TASK9
051124,000047:
051125,000048: # WARNINGS-
051126,000049: # --------
051127,000050: # 1) 1 <= C(A) <= 16250D (1 CENTISECOND TO 162.5 SEC)
051128,000051: # 2) 9 TASKS MAXIMUM
051129,000052: # 3) TASKS CALLED UNDER INTERRUPT INHIBITED
051130,000053: # 4) TASKS END BY TC TASKOVER
051131,000054:
051132,000055: # CALLING SEQUENCE -
051133,000056: # L-1 CA DELTAT (TIME IN CENTISECONDS TO TASK START)
051134,000057: # L TC WAITLIST
051135,000058: # L+1 2CADR DESIRED TASK
051136,000059: # L+2 (MINOR OF 2CADR)
051137,000060: # L+3 RELINT (RETURNS HERE)
051138,000061:
051139,000062: # TWIDDLE-
051140,000063: # -------
051141,000064: # TWIDDLE IS FOR USE WHEN THE TASK BEING SET UP IS IN THE SAME EBANK AND FBANK AS THE USER. IN
051142,000065: # SUCH CASES, IT IMPROVES UPON WAITLIST BY ELIMINATING THE NEED FOR THE BBCON HALF OF THE 2CADR,
051143,000066: # SAVING A WORD. TWIDDLE IS LIKE WAITLIST IN EVERY RESPECT EXCEPT CALLING SEQUENCE, TO WIT-
051144,000067: # L-1 CA DELTAT
051145,000068: # L TC TWIDDLE
051146,000069: # L+1 ADRES DESIRED TASK
051147,000070: # L+2 RELINT (RETURNS HERE)
051148,000071:
051149,000072: # NORMAL EXIT MODES -
051150,000073: # AT L+3 OF CALLING SEQUENCE
051151,000074:
051152,000075: # ALARM OR ABORT EXIT MODES -
051153,000076: # TC ABORT
051154,000077: # OCT 1203 (WAITLIST OVERFLOW - TOO MANY TASKS)
051155,000078:
051156,000079: # ERASABLE INITIALIZATION REQUIRED -
051157,000080: # ACCOMPLISHED BY FRESH START,-- LST2, ..., LST2 +16 = ENDTASK
051158,000081: # LST1, ..., LST1 +7 = NEG1/2
051159,000082:
051160,000083: # OUTPUT --
051161,000084: # LST1 AND LST2 UPDATED WITH NEW TASK AND ASSOCIATED TIME.
051162,000085:
051163,000086: # DEBRIS -
051164,000087: # CENTRALS - A,Q,L
051165,000088: # OTHER - WAITEXIT, WAITADR, WAITTEMP, WAITBANK
051166,000089:
051167,000090: # DETAILED ANALYSIS OF TIMING -
051168,000091: # CONTROL WILL NOT BE RETURNED TO THE SPECIFIED ADDRESS (2CADR) IN EXACTLY DELTA T CENTISECONDS.
051169,000092: # THE APPROXIMATE TIME MAY BE CALCULATED AS FOLLOWS
051170,000093: # LET TO = THE TIME OF THE TC WAITLIST
051171,000094: # LET TS = TO +147U + COUNTER INCREMENTS (SET UP TIME)
051172,000095: # LET X = TS -(100TS)/100 (VARIANCE FROM COUNTERS)
051173,000096: # LET Y = LENGTH OF TIME OF INHIBIT INTERRUPT AFTER T3RUPT
051174,000097: # LET Z = LENGTH OF TIME TO PROCESS TASKS WHICH ARE DUE THIS T3RUPT BUT DISPATCHED EARLIER.
051175,000098: # (Z=0, USUALLY)
051176,000099: # LET DELTD = THE ACTUAL TIME TAKEN TO GIVE CONTROL TO 2CADR
051177,000100: # THEN DELTD = TS+DELTA T -X +Y +Z +1.05MS* +COUNTERS*
051178,000101: # *-THE TIME TAKEN BY WAITLIST ITSELF AND THE COUNTER TICKING DURING THIS WAITLIST TIME.
051179,000102: # IN SHORT, THE ACTUAL TIME TO RETURN CONTROL TO A 2CADR IS AUGMENTED BY THE TIME TO SET UP THE TASK:S
051180,000103: # INTERRUPT, ALL COUNTERS TICKING, THE T3RUPT PROCESSING TIME, THE WAITLIST PROCESSING TIME AND THE POSSIBILITY
051181,000104: # OF OTHER TASKS INHIBITING THE INTERRUPT.
051182,000105:
051183,000106: 5251 BLOCK 02
051184,000107: 5251 E3,1400 EBANK= LST1 # TASK LISTS IN SWITCHED E BANK.
051185,000108:
051186,000109: 5251 COUNT 02/WAIT
051187,000110:
051188,000111: 5251 00004 TWIDDLE INHINT
051189,000112: 5252 54001 TS L # SAVE DELAY TIME IN L
051190,000113: 5253 35013 CA POSMAX
051191,000114: 5254 26002 ADS Q # CREATING OVERFLOW AND Q-1 IN Q
051192,000115: 5255 30006 CA BBANK
051193,000116: 5256 00006 EXTEND
051194,000117: 5257 04007 ROR SUPERBNK
051195,000118: 5260 56001 XCH L
051196,000119:
051197,000120: 5261 00004 WAITLIST INHINT
051198,000121: 5262 00006 EXTEND
051199,000122: 5263 65275 BZMF WATLST0-
051200,000123: 5264 56002 XCH Q # SAVE DELTA T IN Q AND RETURN IN
051201,000124: 5265 54061 TS WAITEXIT # WAITEXIT.
051202,000125: 5266 00006 EXTEND
051203,000126: 5267 50061 INDEX WAITEXIT # IF TWIDDLING, THE TS SKIPS TO HERE
051204,000127: 5270 30001 DCA 0 # PICK UP 2CADR OF TASK.
051205,000128: 5271 54063 -1 TS WAITADR # BBCON WILL REMAIN IN L
051206,000129: 5272 35302 DLY2 CAF WAITBB # ENTRY FROM FIXDELAY AND VARDELAY.
051207,000130: 5273 56006 XCH BBANK
051208,000131: 5274 13246 TCF WAIT2
051209,000132:
051210,000133: 5275 05725 WATLST0- TC POODOO
051211,000134: 5276 21204 OCT 21204
051212,000135:
051213,000136: # RETURN TO CALLER AFTER TASK INSERTION:
051214,000137:
051215,000138: 5277 52062 LVWTLIST DXCH WAITEXIT
051216,000139: 5300 65032 AD TWO
051217,000140: 5301 52006 DTCB
051218,000141:
051219,000142: 5302 E3,1400 EBANK= LST1
051220,000143: 5302 02063 WAITBB BBCON WAIT2
051221,000144:
051222,000145: # RETURN TO CALLER +2 AFTER WAITING DT SPECIFIED AT CALLER +1.
051223,000146:
051224,000147: 5303 50002 FIXDELAY INDEX Q # BOTH ROUTINES MUST BE CALLED UNDER
051225,000148: 5304 30000 CAF 0 # WAITLIST CONTROL AND TERMINATE THE TASK
051226,000149: 5305 24002 INCR Q # IN WHICH THEY WERE CALLED.
051227,000150:
051228,000151: # RETURN TO CALLER +1 AFTER WAITING THE DT AS ARRIVING IN A.
051229,000152:
051230,000153: 5306 56002 VARDELAY XCH Q # DT TO Q. TASK ADRES TO WAITADR.
051231,000154: 5307 54063 TS WAITADR
051232,000155: 5310 30006 CA BBANK # BBANK IS SAVED DURING DELAY.
051233,000156: 5311 00006 EXTEND
051234,000157: 5312 04007 ROR SUPERBNK # ADD SBANK TO BBCON.
051235,000158: 5313 54001 TS L
051236,000159: 5314 35317 CAF DELAYEX
051237,000160: 5315 54061 TS WAITEXIT # GO TO TASKOVER AFTER TASK ENTRY.
051238,000161: 5316 15272 TCF DLY2
051239,000162:
051240,000163: 5317 15336 DELAYEX TCF TASKOVER -2 # RETURNS TO TASKOVER
051241,000164:
051242,000165: # ENDTASK MUST BE ENTERED IN FIXED-FIXED SO IT IS DISTINGUISHABLE BY ITS ADRES ALONE.
051243,000166:
051244,000167: 5320 E3,1400 EBANK= LST1
051245,000168: 5320 72455 73714 ENDTASK -2CADR SVCT3
051246,000169:
051247,000170: 5322 10076 SVCT3 CCS FLAGWRD2 # DRIFT FLAG
051248,000171: 5323 15340 TCF TASKOVER
051249,000172: 5324 15340 TCF TASKOVER
051250,000173: 5325 15326 TCF +1
051251,000174:
051252,000175: 5326 11322 CCS IMUCADR # DON'T DO NBDONLY IF SOMEONE ELSE IS IN
051253,000176: 5327 17717 TCF SVCT3X
051254,000177: 5330 15333 TCF +3
051255,000178: 5331 17717 TCF SVCT3X
051256,000179: 5332 17717 TCF SVCT3X
051257,000180: 5333 37672 +3 CAF PRIO35 # COMPENSATE FOR NBD COEFFICIENTS ONLY.
051258,000181: 5334 05150 TC NOVAC # ENABLE EVERY 81.93 SECONDS
051259,000182: 5335 E3,1460 EBANK= NBDX
051260,000183: 5335 03542 14063 2CADR NBDONLY
051261,000184:
051262,000185: 5337 15340 TCF TASKOVER
051263,000186:
051264,000187: 6000 SETLOC FFTAG6
051265,000188: 6000 BANK
051266,000189:
051267,000190: 7717 05303 SVCT3X TC FIXDELAY # DELAY MAX OF 2 TIMES FOR IMU ZERO
051268,000191: 7720 00764 DEC 500 B-14
051269,000192: 7721 05322 TC SVCT3 # CHECK DRIFT FLAG AGAIN
051270,000193:
051271,000194: # BEGIN TASK INSERTION.
051272,000195:
051273,000196: 01,3246 BANK 01
051274,000197: 01,3246 COUNT 01/WAIT
051275,000198:
051276,000199: 01,3246 54062 WAIT2 TS WAITBANK # BBANK OF CALLING PROGRAM.
051277,000200: 01,3247 40026 CS TIME3
051278,000201: 01,3250 65024 AD BIT8 # BIT 8 = OCT 200
051279,000202: 01,3251 10000 CCS A # TEST 200 - C(TIME3). IF POSITIVE,
051280,000203: # IT MEANS THAT TIME3 OVERFLOW HAS OCCURRED PRIOR TO CS TIME3 AND THAT
051281,000204: # C(TIME3) = T - T1, INSTEAD OF 1.0 - (T1 - T). THE FOLLOWING FOUR
051282,000205: # ORDERS SET C(A) = TD - T1 + 1 IN EITHER CASE.
051283,000206:
051284,000207: 01,3252 66056 AD OCT40001 # OVERFLOW HAS OCCURRED. SET C(A) =
051285,000208: 01,3253 40000 CS A # T - T1 + 1.0 - 201
051286,000209:
051287,000210: # NORMAL CASE (C(A) NNZ) YIELDS SAME C(A): -( -(1.0-(T1-T)) + 200) - 1
051288,000211:
051289,000212: 01,3254 63402 AD OCT40201
051290,000213: 01,3255 60002 AD Q # RESULT = TD - T1 + 1.
051291,000214:
051292,000215: 01,3256 10000 CCS A # TEST TD - T1 +1
051293,000216:
051294,000217: 01,3257 61400 AD LST1 # IF TD - T1 POS, GO TO WTLST5 WITH
051295,000218: 01,3260 13322 TCF WTLST5 # C(A) = (TD - T1) + C(LST1) = TD-T2+1
051296,000219:
051297,000220: 01,3261 13262 NOOP
051298,000221: 01,3262 40002 CS Q
051299,000222:
051300,000223: # NOTE THAT THIS PROGRAM SECTION IS NEVER ENTERED WHEN T-T1 G/E -1,
051301,000224: # SINCE TD-T1+1 = (TD-T) + (T-T1+1), AND DELTA T = TD-T G/E +1. (G/E
051302,000225: # SYMBOL MEANS GREATER THAN OR EQUAL TO). THUS THERE NEED BE NO CON-
051303,000226: # CERN OVER A PREVIOUS OR IMMINENT OVERFLOW OF TIME3 HERE.
051304,000227:
051305,000228: 01,3263 65016 AD POS1/2 # WHEN TD IS NEXT, FORM QUANTITY
051306,000229: 01,3264 65016 AD POS1/2 # 1.0 - DELTA T = 1.0 - (TD - T)
051307,000230: 01,3265 56026 XCH TIME3
051308,000231: 01,3266 65015 AD NEGMAX
051309,000232: 01,3267 60002 AD Q # 1.0 - DELTAT T NOW COMPLETE.
051310,000233: 01,3270 00006 EXTEND # ZERO INDEX Q.
051311,000234: 01,3271 22007 QXCH 7 # (ZQ)
051312,000235:
051313,000236: 01,3272 57400 WTLST4 XCH LST1
051314,000237: 01,3273 57401 XCH LST1 +1
051315,000238: 01,3274 57402 XCH LST1 +2
051316,000239: 01,3275 57403 XCH LST1 +3
051317,000240: 01,3276 57404 XCH LST1 +4
051318,000241: 01,3277 57405 XCH LST1 +5
051319,000242: 01,3300 57406 XCH LST1 +6
051320,000243: 01,3301 57407 XCH LST1 +7
051321,000244:
051322,000245: 01,3302 30063 CA WAITADR # (MINOR PART OF TASK CADR HAS BEEN IN L.)
051323,000246: 01,3303 50002 INDEX Q
051324,000247: 01,3304 13305 TCF +1
051325,000248:
051326,000249: 01,3305 53411 DXCH LST2
051327,000250: 01,3306 53413 DXCH LST2 +2
051328,000251: 01,3307 53415 DXCH LST2 +4
051329,000252: 01,3310 53417 DXCH LST2 +6
051330,000253: 01,3311 53421 DXCH LST2 +8D
051331,000254: 01,3312 53423 DXCH LST2 +10D # AT END, CHECK THAT C(LST2 +10) IS STD
051332,000255: 01,3313 53425 DXCH LST2 +12D
051333,000256: 01,3314 53427 DXCH LST2 +14D
051334,000257: 01,3315 53431 DXCH LST2 +16D
051335,000258: 01,3316 65320 AD ENDTASK # END ITEM, AS CHECK FOR EXCEEDING
051336,000259: # THE LENGTH OF THE LIST.
051337,000260: 01,3317 00006 EXTEND # DUMMY TASK ADRES SHOULD BE IN FIXED-
051338,000261: 01,3320 15277 BZF LVWTLIST # FIXED SO ITS ADRES ALONE DISTINGUISHES
051339,000262: 01,3321 13375 TCF WTABORT # IT.
051340,000263:
051341,000264: 01,3322 10000 WTLST5 CCS A # TEST TD - T2 + 1
051342,000265: 01,3323 61401 AD LST1 +1
051343,000266: 01,3324 13330 TCF +4
051344,000267: 01,3325 65033 AD ONE
051345,000268: 01,3326 03403 TC WTLST2
051346,000269: 01,3327 00001 OCT 1
051347,000270:
051348,000271: 01,3330 10000 +4 CCS A # TEST TD - T3 + 1
051349,000272: 01,3331 61402 AD LST1 +2
051350,000273: 01,3332 13336 TCF +4
051351,000274: 01,3333 65033 AD ONE
051352,000275: 01,3334 03403 TC WTLST2
051353,000276: 01,3335 00002 OCT 2
051354,000277:
051355,000278: 01,3336 10000 +4 CCS A # TEST TD - T4 + 1
051356,000279: 01,3337 61403 AD LST1 +3
051357,000280: 01,3340 13344 TCF +4
051358,000281: 01,3341 65033 AD ONE
051359,000282: 01,3342 03403 TC WTLST2
051360,000283: 01,3343 00003 OCT 3
051361,000284:
051362,000285: 01,3344 10000 +4 CCS A # TEST TD - T5 + 1
051363,000286: 01,3345 61404 AD LST1 +4
051364,000287: 01,3346 13352 TCF +4
051365,000288: 01,3347 65033 AD ONE
051366,000289: 01,3350 03403 TC WTLST2
051367,000290: 01,3351 00004 OCT 4
051368,000291:
051369,000292: 01,3352 10000 +4 CCS A # TEST TD - T6 + 1
051370,000293: 01,3353 61405 AD LST1 +5
051371,000294: 01,3354 13360 TCF +4
051372,000295: 01,3355 65033 AD ONE
051373,000296: 01,3356 03403 TC WTLST2
051374,000297: 01,3357 00005 OCT 5
051375,000298:
051376,000299: 01,3360 10000 +4 CCS A # TEST TD - T7 + 1
051377,000300: 01,3361 61406 AD LST1 +6
051378,000301: 01,3362 13366 TCF +4
051379,000302: 01,3363 65033 AD ONE
051380,000303: 01,3364 03403 TC WTLST2
051381,000304: 01,3365 00006 OCT 6
051382,000305:
051383,000306: 01,3366 10000 +4 CCS A
051384,000307: 01,3367 61407 AD LST1 +7
051385,000308: 01,3370 13374 TCF +4
051386,000309: 01,3371 65033 AD ONE
051387,000310: 01,3372 03403 TC WTLST2
051388,000311: 01,3373 00007 OCT 7
051389,000312:
051390,000313: 01,3374 10000 +4 CCS A
051391,000314: 01,3375 07755 WTABORT TC BAILOUT # NO ROOM IN THE INN.
051392,000315: 01,3376 31203 OCT 31203
051393,000316:
051394,000317: 01,3377 65033 AD ONE
051395,000318: 01,3400 03403 TC WTLST2
051396,000319: 01,3401 00010 OCT 10
051397,000320:
051398,000321: 01,3402 40201 OCT40201 OCT 40201
051399,000322:
051400,000323: # THE ENTRY TO WTLST2 JUST PRECEDING OCT N IS FOR T LE TD LE T -1.
051401,000324: # N N+1
051402,000325:
051403,000326: # (LE MEANS LESS THAN OR EQUAL TO). AT ENTRY, C(A) = -(TD - T + 1)
051404,000327: # N+1
051405,000328:
051406,000329: # THE LST1 ENTRY-(T -T +1) IS TO BE REPLACED BY -(TD - T + 1), AND
051407,000330: # N+1 N N
051408,000331:
051409,000332: # THE ENTRY-(T - TD + 1) IS TO BE INSERTED IMMEDIATELY FOLLOWING.
051410,000333: # N+1
051411,000334:
051412,000335: 01,3403 54064 WTLST2 TS WAITTEMP # C(A) = -(TD - T + 1)
051413,000336: 01,3404 50002 INDEX Q
051414,000337: 01,3405 30000 CAF 0
051415,000338: 01,3406 54002 TS Q # INDEX VALUE INTO Q.
051416,000339:
051417,000340: 01,3407 35033 CAF ONE
051418,000341: 01,3410 60064 AD WAITTEMP
051419,000342: 01,3411 50002 INDEX Q # C(A) = -(TD - T ) + 1.
051420,000343: 01,3412 27377 ADS LST1 -1 # N
051421,000344:
051422,000345: 01,3413 40064 CS WAITTEMP
051423,000346: 01,3414 50002 INDEX Q
051424,000347: 01,3415 13272 TCF WTLST4
051425,000348:
051426,000349: # C(TIME3) = 1.0 - (T1 - T)
051427,000350:
051428,000351: # C(LST1 ) = - (T2 - T1) + 1
051429,000352: # C(LST1+1) = - (T3 - T2) + 1
051430,000353: # C(LST1+2) = - (T4 - T3) + 1
051431,000354: # C(LST1+3) = - (T5 - T4) + 1
051432,000355: # C(LST1+4) = - (T6 - T5) + 1
051433,000356:
051434,000357: # C(LST2 ) = 2CADR TASK1
051435,000358: # C(LST2+2 ) = 2CADR TASK2
051436,000359: # C(LST2+4 ) = 2CADR TASK3
051437,000360: # C(LST2+6 ) = 2CADR TASK4
051438,000361: # C(LST2+8 ) = 2CADR TASK5
051439,000362: # C(LST2+10) = 2CADR TASK6
051440,000363:
051441,000364: # ENTERS HERE ON T3 RUPT TO DISPATCH WAITLISTED TASK.
051442,000365:
051443,000366: 01,3416 00006 T3RUPT EXTEND
051444,000367: 01,3417 04007 ROR SUPERBNK # READ CURRENT SUPERBANK VALUE AND
051445,000368: 01,3420 54016 TS BANKRUPT # SAVE WITH E AND F BANK VALUES.
051446,000369: 01,3421 00006 EXTEND
051447,000370: 01,3422 22012 QXCH QRUPT
051448,000371:
051449,000372: 01,3423 35014 T3RUPT2 CAF NEG1/2 # DISPATCH WAITLIST TASK.
051450,000373: 01,3424 57407 XCH LST1 +7
051451,000374: 01,3425 57406 XCH LST1 +6
051452,000375: 01,3426 57405 XCH LST1 +5
051453,000376: 01,3427 57404 XCH LST1 +4 # 1. MOVE UP LST1 CONTENTS, ENTERING
051454,000377: 01,3430 57403 XCH LST1 +3 # A VALUE OF 1/2 +1 AT THE BOTTOM
051455,000378: 01,3431 57402 XCH LST1 +2 # FOR T6-T5, CORRESPONDING TO THE
051456,000379: 01,3432 57401 XCH LST1 +1 # INTERVAL 81.91 SEC FOR ENDTASK.
051457,000380: 01,3433 57400 XCH LST1
051458,000381: 01,3434 65013 AD POSMAX # 2. SET T3 = 1.0 - T2 - T USING LIST 1.
051459,000382: 01,3435 26026 ADS TIME3 # SO T3 WONT TICK DURING UPDATE.
051460,000383: 01,3436 54734 TS RUPTAGN
051461,000384: 01,3437 45035 CS ZERO
051462,000385: 01,3440 54734 TS RUPTAGN # SETS RUPTAGN TO +1 ON OVERFLOW.
051463,000386:
051464,000387: 01,3441 00006 EXTEND # DISPATCH TASK.
051465,000388: 01,3442 45321 DCS ENDTASK
051466,000389: 01,3443 53431 DXCH LST2 +16D
051467,000390: 01,3444 53427 DXCH LST2 +14D
051468,000391: 01,3445 53425 DXCH LST2 +12D
051469,000392: 01,3446 53423 DXCH LST2 +10D
051470,000393: 01,3447 53421 DXCH LST2 +8D
051471,000394: 01,3450 53417 DXCH LST2 +6
051472,000395: 01,3451 53415 DXCH LST2 +4
051473,000396: 01,3452 53413 DXCH LST2 +2
051474,000397: 01,3453 53411 DXCH LST2
051475,000398:
051476,000399: 01,3454 56001 XCH L
051477,000400: 01,3455 00006 EXTEND
051478,000401: 01,3456 01007 WRITE SUPERBNK # SET SUPERBANK FROM BBCON OF 2CADR
051479,000402: 01,3457 56001 XCH L # RESTORE TO L FOR DXCH Z.
051480,000403: 01,3460 52006 DTCB
051481,000404:
051482,000405: # RETURN, AFTER EXECUTION OF T3 OVERFLOW TASK:
051483,000406:
051484,000407: 5340 BLOCK 02
051485,000408: 5340 COUNT 02/WAIT
051486,000409:
051487,000410: 5340 10734 TASKOVER CCS RUPTAGN # IF +1 RETURN TO T3RUPT, IF -0 RESUME.
051488,000411: 5341 35302 CAF WAITBB
051489,000412: 5342 54006 TS BBANK
051490,000413: 5343 13423 TCF T3RUPT2 # DISPATCH NEXT TASK IF IT WAS DUE.
051491,000414:
051492,000415: 5344 30016 CA BANKRUPT
051493,000416: 5345 00006 EXTEND
051494,000417: 5346 01007 WRITE SUPERBNK # RESTORE SUPERBANK BEFORE RESUME IS DONE
051495,000418:
051496,000419: 5347 00006 RESUME EXTEND
051497,000420: 5350 22012 QXCH QRUPT
051498,000421: 5351 30016 NOQRSM CA BANKRUPT
051499,000422: 5352 56006 XCH BBANK
051500,000423: 5353 52011 NOQBRSM DXCH ARUPT
051501,000424: 5354 00003 RELINT
051502,000425: 5355 50017 RESUME
051503,000426:
051504,000427: # LONGCALL
051505,000428: # PROGRAM DESCRIPTION DATE - 17 MARCH 1967
051506,000429: # PROGRAM WRITTEN BY W.H.VANDEVER LOG SECTION WAITLIST
051507,000430: # MOD BY - R. MELANSON TO ADD DOCUMENTATION ASSEMBLY SUNDISK REV. 100
051508,000431:
051509,000432: # FUNCTIONAL DESCRIPTION -
051510,000433: # LONGCALL IS CALLED WITH THE DELTA TIME ARRIVING IN A,L SCALED AS TIME2,TIME1 WITH THE 2CADR OF THE TASK
051511,000434: # IMMEDIATELY FOLLOWING THE TC LONGCALL. FOR EXAMPLE, IT MIGHT BE DONE AS FOLLOWS WHERE TIMELOC IS THE NAME OF
051512,000435: # A DP REGISTER CONTAINING A DELTA TIME AND WHERE TASKTODO IS THE NAME OF THE LOCATION AT WHICH LONGCALL IS TO
051513,000436: # START
051514,000437:
051515,000438: # CALLING SEQUENCE -
051516,000439: # EXTEND
051517,000440: # DCA TIMELOC
051518,000441: # TC LONGCALL
051519,000442: # 2CADR TASKTODO
051520,000443:
051521,000444: # NORMAL EXIT MODE -
051522,000445: # 1). TC WAITLIST
051523,000446: # 2). DTCB (TO L+3 OF CALLING ROUTINE 1ST PASS THRU LONGCYCL)
051524,000447: # 3). DTCB (TO TASKOVER ON SUBSEQUENT PASSES THRU LONGCYCL)
051525,000448:
051526,000449: # ALARM OR ABORT EXIT MODE -
051527,000450: # NONE
051528,000451:
051529,000452: # OUTPUT -
051530,000453: # LONGTIME AND LONGTIME+1 = DELTA TIME
051531,000454: # LONGEXIT AND LONGEXIT+1 = RETURN 2CADR
051532,000455: # LONGCADR AND LONGCADR+1 = TASK 2CADR
051533,000456: # A = SINGLE PRECISION TIME FOR WAITLIST
051534,000457:
051535,000458: # ERASABLE INITIALIZATION -
051536,000459: # A = MOST SIGNIFICANT PART OF DELTA TIME
051537,000460: # L = LEAST SIGNIFICANT PART OF DELTA TIME
051538,000461: # Q = ADDRESS OF 2CADR TASK VALUE
051539,000462:
051540,000463: # DEBRIS -
051541,000464: # A,Q,L
051542,000465: # LONGCADR AND LONGCADR+1
051543,000466: # LONGEXIT AND LONGEXIT+1
051544,000467: # LONGTIME AND LONGTIME+1
051545,000468:
051546,000469: # *** THE FOLLOWING IS TO BE IN FIXED-FIXED AND UNSWITCHED ERRASIBLE ***
051547,000470:
051548,000471: 5356 BLOCK 02
051549,000472: 5356 E3,1400 EBANK= LST1
051550,000473: 5356 53140 LONGCALL DXCH LONGTIME # OBTAIN THE DELTA TIME
051551,000474:
051552,000475: 5357 00006 EXTEND # OBTAIN THE 2CADR
051553,000476: 5360 50002 NDX Q
051554,000477: 5361 30001 DCA 0
051555,000478: 5362 53134 DXCH LONGCADR
051556,000479:
051557,000480: 5363 00006 EXTEND # NOW GO TO THE APPROPRIATE SWITCHED BANK
051558,000481: 5364 35367 DCA LGCL2CDR # FOR THE REST OF LONGCALL
051559,000482: 5365 52006 DTCB
051560,000483:
051561,000484: 5366 E3,1400 EBANK= LST1
051562,000485: 5366 03461 02063 LGCL2CDR 2CADR LNGCALL2
051563,000486:
051564,000487: # *** THE FOLLOWING MAY BE IN A SWITCHED BANK, INCLUDING ITS ERASABLE ***
051565,000488:
051566,000489: 01,3461 BANK 01
051567,000490: 01,3461 COUNT 01/WAIT
051568,000491:
051569,000492: 01,3461 23435 LNGCALL2 LXCH LONGEXIT +1 # SAVE THE CORRECT BB FOR RETURN
051570,000493: 01,3462 35032 CA TWO # OBTAIN THE RETURN ADDRESS
051571,000494: 01,3463 26002 ADS Q
051572,000495: 01,3464 55434 TS LONGEXIT
051573,000496:
051574,000497: # *** WAITLIST TASK LONGCYCL ***
051575,000498:
051576,000499: 01,3465 00006 LONGCYCL EXTEND # CAN WE SUCCESFULLY TAKE ABOUT 1.25
051577,000500: 01,3466 43477 DCS DPBIT14 # MINUTES OFF OF LONGTIME
051578,000501: 01,3467 21140 DAS LONGTIME
051579,000502:
051580,000503: 01,3470 11140 CCS LONGTIME +1 # THE REASONIBG BEHIND THIS PART IS
051581,000504: 01,3471 13510 TCF MUCHTIME # INVOLVED, TAKING INTO ACCOUNT THAT THE
051582,000505: # WORDS MAY NOT BE SIGNED CORRECTED (DP
051583,000506: # BASIC INSTRUCTIONS
051584,000507: # DO NOT SIGN CORRECT) AND THAT WE SUBTRAC
051585,000508: # TED BIT14 (1 OVER HALF THE POS. VALUE
051586,000509: # REPRESENTIBLE IN SINGLE WORD)
051587,000510: 01,3472 13473 NOOP # CAN:T GET HERE **********
051588,000511: 01,3473 13474 TCF +1
051589,000512: 01,3474 11137 CCS LONGTIME
051590,000513: 01,3475 13510 TCF MUCHTIME
051591,000514: 01,3476 00000 DPBIT14 OCT 00000
051592,000515: 01,3477 20000 OCT 20000
051593,000516:
051594,000517: # LONGCALL
051595,000518: 01,3500 35016 LASTTIME CA BIT14 # GET BACK THE CORRECT DELTA TFOR WAITLIST
051596,000519: 01,3501 27140 ADS LONGTIME +1
051597,000520: 01,3502 05261 TC WAITLIST
051598,000521: 01,3503 E3,1400 EBANK= LST1
051599,000522: 01,3503 03515 02063 2CADR GETCADR # THE ENTRY TO OUR LONGCADR
051600,000523:
051601,000524: 01,3505 33517 LONGRTRN CA TSKOVCDR # SET IT UP SO THAT ONLY THE FIRST EXIT IS
051602,000525: 01,3506 53435 DXCH LONGEXIT # TO THE CALLER OF LONGCALL
051603,000526: 01,3507 52006 DTCB # THE REST ARE TO TASKOVER
051604,000527:
051605,000528: 01,3510 35016 MUCHTIME CA BIT14 # WE HAVE OVER OUR ABOUT 1.25 MINUTES
051606,000529: 01,3511 05261 TC WAITLIST # SO SET UP FOR ANOTHER CYCLE THROUGH HERE
051607,000530: 01,3512 E3,1400 EBANK= LST1
051608,000531: 01,3512 03465 02063 2CADR LONGCYCL
051609,000532:
051610,000533: 01,3514 13505 TCF LONGRTRN # NOW EXIT PROPERLY
051611,000534:
051612,000535: # *** WAITLIST TASK GETCADR ***
051613,000536:
051614,000537: 01,3515 53134 GETCADR DXCH LONGCADR # GET THE LONGCALL THAT WE WISHED TO START
051615,000538: 01,3516 52006 DTCB # AND TRANSFER CONTROL TO IT
051616,000539:
051617,000540: 01,3517 05340 TSKOVCDR GENADR TASKOVER
051618,000541:
051619,000542:
End of include-file WAITLIST.agc. Parent file is MAIN.agc