Source Code

These source-code files were transcribed from a printout in Don Eyles's personal collection, scanned by archive.org, and financially sponsored by Peter McDermott. A team of volunteers performed the transcription and proof-reading. The scanned page images are available at the Virtual AGC Project website, as well as higher-quality (but much larger) images at the Virtual AGC Project's collection in the Internet Archive. Report any problems by creating "issues" at the Virtual AGC Project's GitHub Repository.

Notations on the program listing read, in part:

	YUL SYSTEM FOR AGC: NEW PROGRAM SHEPATIN BY EYLES
	DEC 13, 1966

	THIS PROGRAM WAS ASSEMBLED AS A VERSION OF REVISION 37 
        OF PROGRAM SUNBURST BY LEM GROUP
Note that the date is the date of the printout, not the date of the program revision.

033704,000002:                                                                                                  ## Copyright:   Public domain.
033705,000003:                                                                                                  ## Filename:    AS206_MISSION_SCHEDULING_PACKAGE.agc
033706,000004:                                                                                                  ## Purpose:     A section of Sunburst revision 37, or Shepatin revision 0.
033707,000005:                                                                                                  ##              It is part of an early development version of the software
033708,000006:                                                                                                  ##              for Apollo Guidance Computer (AGC) on the unmanned Lunar
033709,000007:                                                                                                  ##              Module (LM) flight Apollo 5. Sunburst 37 was the program
033710,000008:                                                                                                  ##              upon which Don Eyles's offline development program Shepatin
033711,000009:                                                                                                  ##              was based; the listing herein transcribed was actually for
033712,000010:                                                                                                  ##              the equivalent revision 0 of Shepatin.
033713,000011:                                                                                                  ##              This file is intended to be a faithful transcription, except
033714,000012:                                                                                                  ##              that the code format has been changed to conform to the
033715,000013:                                                                                                  ##              requirements of the yaYUL assembler rather than the
033716,000014:                                                                                                  ##              original YUL assembler.
033717,000015:                                                                                                  ## Reference:   pp. 748-762
033718,000016:                                                                                                  ## Assembler:   yaYUL
033719,000017:                                                                                                  ## Contact:     Ron Burkey <info@sandroid.org>.
033720,000018:                                                                                                  ## Website:     www.ibiblio.org/apollo/index.html
033721,000019:                                                                                                  ## Mod history: 2017-05-24 MAS  Created from Sunburst 120.
033722,000020:                                                                                                  ##              2017-06-07 MAS  Updated for Sunburst 37. There's a decent number
033723,000021:                                                                                                  ##                              of differences.
033724,000022:                                                                                                  ##              2017-06-15 HG   Fix page number 814 -> 762
033725,000023:                                                                                                  ##                              Add missing instruction TCF ENDUP
033726,000024:                                                                                                  ##                              remove operand modifier CHKUPDEX +1 -> CHKUPDEX
033727,000025:                                                                                                  ##              2017-06-23 RSB  Proofed comment text with
033728,000026:                                                                                                  ##                              octopus/ProoferComments.
033729,000027: 

Page 748

033731,000029:                                                                                                  #           THE FOLLOWING ROUTINES IMPLEMENT THE MISSION SCHEDULING LOGIC AS DESCRIBED IN CHAPTER 4 OF THE
033732,000030:                                                                                                  #  AS206 OPERATIONS PLAN. THE FOLLOWING ROUTINE IS ENTERED ONCE EACH SECOND FOR MOST OF THE DURATION OF THE
033733,000031: 
033734,000032:                                                                                                  #  FLIGHT, ONCE LIFT-OFF HAS OCCURRED. AN EXCEPTION TO THIS IS THE TIME-CRI
033735,000033: 
033736,000034:                                                                                                  #  RESTART  GROUP  FOR MISSION SCHEDULING PACKAGE IS GROUP 3.
033737,000035: 
033738,000036: 31,2000                                           BANK     31                                    
033739,000037: 31,2000     1167                                  EBANK=   MTIMER4                               
033740,000038: 
033741,000039: 31,2000           36301        MMAINT             CAF      THREE                                 #  LOOP TO PROCESS ALL FOUR TIMERS.
033742,000040: 31,2001           55212                           TS       MINH                                  #  AT END OF TIMER UPDATE, THIS REGISTER
033743,000041:                                                                                                  #  WILL NOT BE EQUAL TO 3 IF MAINTENANCE IS
033744,000042: 
033745,000043:                                                                                                  #  TO CEASE.
033746,000044: 31,2002           54070        MLOOP              TS       RUPTREG1                              
033747,000045: 
033748,000046: 31,2003           50000                           INDEX    A                                     #  LOOK AT TIMER.
033749,000047: 31,2004           11167                           CCS      MTIMER4                               
033750,000048: 31,2005           12011                           TCF      MCOUNT                                #  PNZ - ACTIVE AND COUNTING DOWN.
033751,000049: 31,2006           12107                           TCF      MDUE                                  #  +0 - MISSION PHASE DUE.
033752,000050: 31,2007           67755                           AD       ONE                                   #  NNZ - FREE BUT LOADED BY GROUND.
033753,000051: 31,2010           40000                           COM                                            #  -0 - FREE.
033754,000052: 31,2011           50070        MCOUNT             INDEX    RUPTREG1                              #  PLACE UPDATED TIMERS AND PHASE REGISTERS
033755,000053: 31,2012           55177                           TS       MTIMER4T                              #  INTO COPY BUFFER FOR RESTART PROTECTION.
033756,000054: 
033757,000055: 
033758,000056: 31,2013           50070                           INDEX    RUPTREG1                              
033759,000057: 31,2014           31173                           CA       MPHASE4                               
033760,000058: 31,2015           50070        MENTERED           INDEX    RUPTREG1                              
033761,000059: 31,2016           55203                           TS       MPHASE4T                              
033762,000060: 
033763,000061: 31,2017           10070                           CCS      RUPTREG1                              
033764,000062: 31,2020           12002                           TCF      MLOOP                                 
033765,000063: 
033766,000064: 31,2021           11213        MCHKST             CCS      STATECTR                              #  SEE IF POSSIBLY TIME FOR INTERNAL STATE
033767,000065: 31,2022           12041                           TCF      MSTATEOK                              #  VECTOR EXTRAPOLATION.
033768,000066: 
033769,000067: 31,2023           36301                           CAF      THREE                                 #  IF SO, DO UPDATE UNLESS WE ARE WITHIN 16
033770,000068: 31,2024           54070        MSTATECK           TS       RUPTREG1                              #  SECONDS OF THE INITIATION OF ANY MISSION
033771,000069: 31,2025           45361                           CS       LOW4                                  #  PHASE.
033772,000070: 31,2026           50070                           INDEX    RUPTREG1                              
033773,000071: 31,2027           71167                           MASK     MTIMER4                               
033774,000072: 31,2030           00006                           EXTEND                                         
033775,000073: 31,2031           12040                           BZF      MSTATEOK   -1                         #  BRANCH IF PHASE DUE WITHIN 16 SECS.
033776,000074: 
033777,000075: 31,2032           10070                           CCS      RUPTREG1                              
033778,000076: 31,2033           12024                           TCF      MSTATECK                              
033779,000077: 
033780,000078: 31,2034           35651                           CAF      PRIO5                                 
033781,000079: 
033782,000080: 31,2035           05534                           TC       FINDVAC                               #  TO DO THE INTEGRATION.
033783,000081: 31,2036  E4,1566                                  EBANK=   TDEC                                  
033784,000082: 31,2036           02216 16004                     2CADR    STATEINT                              
033785,000083: 

Page 749

033787,000085: 31,2040           35222                 -1        CAF      STATECRI                              
033788,000086: 31,2041           55213        MSTATEOK           TS       STATECTR                              
033789,000087: 
033790,000088: 31,2042           31210                           CA       NEWMTIME                              #  COPY FOR RESTART PROTECTION
033791,000089: 31,2043           55211                           TS       NEWTIMET                              
033792,000090: 
033793,000091: 31,2044           04147                           TC       PHASCHNG                              #  UPDATE RESTART
033794,000092: 31,2045           04013                           OCT      04013                                 
033795,000093: 
033796,000094: 31,2046           37757        REDO3.3            CAF      SEVEN                                 #  COPY NEW TIMERS AND PHASE REGISTERS.
033797,000095: 31,2047           54070        MCOPY              TS       RUPTREG1                              
033798,000096: 31,2050           50000                           INDEX    A                                     
033799,000097: 31,2051           31177                           CA       MTIMER4T                              
033800,000098: 31,2052           50070                           INDEX    RUPTREG1                              
033801,000099: 31,2053           55167                           TS       MTIMER4                               
033802,000100: 31,2054           10070                           CCS      RUPTREG1                              
033803,000101: 31,2055           12047                           TCF      MCOPY                                 
033804,000102: 
033805,000103: 31,2056           46301                           CS       THREE                                 #  SEE IF FURTHER MAINTENCE HAS BEEN
033806,000104: 
033807,000105: 31,2057           71212                           MASK     MINH                                  #  INHIBITED BY THE INITIATION OF A TIME-
033808,000106: 31,2060           10000                           CCS      A                                     #  CRITICAL MISSION PHASE.
033809,000107: 31,2061           12101                           TCF      MINHIBIT                              
033810,000108: 
033811,000109: 31,2062           32106                           CAF      1SEC                                  #  UPDATE T1 SETTING FOR NEXT UPDATE
033812,000110: 31,2063           27210                           ADS      NEWMTIME                              
033813,000111: 
033814,000112: 31,2064           04147                           TC       PHASCHNG                              
033815,000113: 31,2065           04013                           OCT      04013                                 #  IMMECIATE RESTART AT NEXT LOCATION
033816,000114: 
033817,000115: 31,2066           40025                           CS       TIME1                                 #  GET DT FOR NEXT SCHEDULING REQUEST.
033818,000116: 31,2067           61211                           AD       NEWTIMET                              
033819,000117: 
033820,000118: 31,2070           00006                           EXTEND                                         
033821,000119: 31,2071           62073                           BZMF     +2                                    #  CORRECT FOR CLOCK OVERFLOW.
033822,000120: 31,2072           12075                           TCF      +3                                    
033823,000121: 
033824,000122: 31,2073           67740                           AD       HALF                                  
033825,000123: 31,2074           67740                           AD       HALF                                  
033826,000124: 31,2075           05701                 +3        TC       WAITLIST                              
033827,000125: 31,2076     1167                                  EBANK=   MTIMER4                               
033828,000126: 31,2076           02000 62062                     2CADR    MMAINT                                
033829,000127: 
033830,000128: 
033831,000129: 31,2100           05745                           TC       TASKOVER                              
033832,000130: 
033833,000131: 31,2101           06045        MINHIBIT           TC       FLAG2DWN                              #  RESET TIMERS ENABLED FLAG.
033834,000132: 31,2102           00020                           OCT      20                                    
033835,000133: 
033836,000134: 31,2103           04147                           TC       PHASCHNG                              
033837,000135: 31,2104           00003                           OCT      00003                                 
033838,000136: 
033839,000137: 31,2105           15745                           TCF      TASKOVER                              
033840,000138: 

Page 750

033842,000140: 31,2106           00144        1SEC               DEC      100        B-14                       
033843,000141: 

Page 751

033845,000143:                                                                                                  #           THE FOLLOWING CODING DISPATCHES DUE MISSION PHASES VIA A TABLE OF EXECUTIVE PRIORITIES AND 2CADRS.
033846,000144: 
033847,000145: 31,2107           30070        MDUE               CA       RUPTREG1                              
033848,000146: 31,2110           55207                           TS       MDUETEMP                              #  COPY FOR RESTART PROTECTION
033849,000147: 
033850,000148: 31,2111           50070                           INDEX    RUPTREG1                              #  GET NUMBER OF NEW PHASE AND MP BY NUMBER
033851,000149: 
033852,000150: 31,2112           31173                           CA       MPHASE4                               #  OF TABLE ENTRIES PER PHASE TO GET ADDRES
033853,000151: 31,2113           00006                           EXTEND                                         #  OF TABLE ENTRY FOR THIS PHASE.
033854,000152: 31,2114           12431                           BZF      BADPHASE                              #  INACTIVE MPHASE HERE IS VERY BAD.
033855,000153: 31,2115           54765                           TS       PHASENUM                              #  HOLDS CURRENT MP NUMBER FOR DOWNLINK
033856,000154: 31,2116           00006                           EXTEND                                         
033857,000155: 31,2117           76301                           MP       THREE                                 
033858,000156: 31,2120           50001                           INDEX    L                                     
033859,000157: 31,2121           32354                           CA       MTABLE                                #  PRIO, INHIBIT/ENABLE INFO., ETC.
033860,000158: 31,2122           54071                           TS       RUPTREG2                              
033861,000159: 31,2123           77757                           MASK     SEVEN                                 #  HONOR INHIBIT/ENABLE FUNCTION.
033862,000160: 31,2124           70076                           MASK     FLAGWRD2                              
033863,000161: 31,2125           10000                           CCS      A                                     
033864,000162: 
033865,000163: 31,2126           12152                           TCF      MBYPASS                               
033866,000164: 
033867,000165: 31,2127           37752                           CAF      BIT4                                  #  SET MRETURN  IF COUNTERS ARE TO STOP.
033868,000166: 31,2130           70071                           MASK     RUPTREG2                              
033869,000167: 31,2131           27212                           ADS      MINH                                  
033870,000168: 
033871,000169: 31,2132           35676                           CAF      PRIO37                                
033872,000170: 31,2133           70071                           MASK     RUPTREG2                              
033873,000171: 31,2134           54063                           TS       NEWPRIO                               
033874,000172: 31,2135           00006                           EXTEND                                         
033875,000173: 
033876,000174: 31,2136           50001                           INDEX    L                                     #  PICK UP 2CADR AND DO FINDVAC.
033877,000175: 31,2137           32356                           DCA      MTABLE     +1                         
033878,000176: 31,2140           05544                           TC       SPVAC                                 
033879,000177: 
033880,000178: 31,2141           04127                           TC       2PHSCHNG                              
033881,000179: 31,2142           00032                           OCT      00032                                 #  2.3SPOT TO RESTART MISSION PHASE NOW DUE
033882,000180: 31,2143           04013                           OCT      04013                                 #  GROUP 3 RESTART FOR MISSIN SCHEDULER
033883,000181: 
033884,000182: 31,2144           31207                           CA       MDUETEMP                              
033885,000183: 31,2145           54070                           TS       RUPTREG1                              #  RUPTREG1 WAS DESTROYED BY 2PHSCHNG
033886,000184: 
033887,000185: 31,2146           35226                           CAF      PRIO30                                #  SET UP JOB TO TERMINATE ANY UPDATE
033888,000186: 
033889,000187: 31,2147           05523                           TC       NOVAC                                 #  POSSIBLY IN PROGRESS & RELEASE DISPLAY.
033890,000188: 31,2150     1167                                  EBANK=   MTIMER4                               #  PINBALL USES UNSWITCHED ERASABLE
033891,000189: 31,2150           02173 62062                     2CADR    UPDATKIL                              
033892,000190: 
033893,000191: 31,2152           47761        MBYPASS            CS       ZERO                                  
033894,000192: 31,2153           50070                           INDEX    RUPTREG1                              #  MAKE THIS TIMER/PHASE PAIR AVAILABLE.
033895,000193: 31,2154           55177                           TS       MTIMER4T                              
033896,000194: 31,2155           12015                           TCF      MENTERED                              #  JOINS MAIN CODING.
033897,000195: 

Page 752

033899,000197:                                                                                                  #  RESTART  ROUTIN E TO RESCHEDULE MISSION PHASE
033900,000198: 
033901,000199: 31,2156           51207        REDOMDUE           INDEX    MDUETEMP                              #  FIND PRIO AND 2CADR OF NEW MP
033902,000200: 31,2157           31173                           CA       MPHASE4                               #  IN TABLE.  MDUETEMP CONTAINS
033903,000201: 31,2160           00006                           EXTEND                                         #  THE PHASE REGISTER NUMBER OF THE
033904,000202: 31,2161           76301                           MP       THREE                                 #  MISSION PHASE DUE AT THIS TIME
033905,000203: 31,2162           50001                           INDEX    L                                     
033906,000204: 31,2163           32354                           CA       MTABLE                                
033907,000205: 31,2164           75676                           MASK     PRIO37                                
033908,000206: 31,2165           54063                           TS       NEWPRIO                               
033909,000207: 31,2166           00006                           EXTEND                                         
033910,000208: 31,2167           50001                           INDEX    L                                     
033911,000209: 
033912,000210: 31,2170           32356                           DCA      MTABLE     +1                         
033913,000211: 31,2171           05544                           TC       SPVAC                                 #  DO FINDVAC WITH 2CADR IN A +  L
033914,000212: 31,2172           15745                           TCF      TASKOVER                              
033915,000213: 
033916,000214: 
033917,000215: 
033918,000216:                                                                                                  #  DO A PSEUDO VERB 34 ENTER TO KILL AN UPDATE IN PROGRESS, AND TO RELEASE THE DSKY.
033919,000217: 
033920,000218: 31,2173           32414        UPDATKIL           CAF      34OCT                                 
033921,000219: 31,2174           54304                           TS       REQRET                                
033922,000220: 31,2175           05224                           TC       BANKCALL                              
033923,000221: 31,2176           12314                           CADR     UPDATVB    -1                         
033924,000222: 
033925,000223: 31,2177           05243                           TC       POSTJUMP                              
033926,000224: 31,2200           11333                           CADR     VBTERM                                #  GOES TO ENDOFJOB WHEN DONE
033927,000225: 

Page 753

033929,000227:                                                                                                  #           THE FOLLOWING SUBROUTINE MAY BE USED BY MISSION PROGRAMS TO SET MISSION PHASE/TIMER PAIRS TO INITIATE
033930,000228:                                                                                                  #  THE VARIOUS MISSION PHASES (SEE CHAPTER 4 OF THE GSOP).
033931,000229: 
033932,000230:                                                                                                  #           CALLING SEQUENCE IS AS FOLLOWS:
033933,000231: 
033934,000232:                                                                                                  #                                                   TC     MPENTRY         UNDER CONTROL OF EXEC OR RUPT.
033935,000233:                                                                                                  #                                                   DEC    INDEX           INDEX OF TIMER (1 TO 4).
033936,000234:                                                                                                  #                                                   DEC    PHASE           MISSION PHASE NUMBER.
033937,000235: 
033938,000236:                                                                                                  #                                                   ADRES  DT              DT = TIME (SECONDS) TO INITIATION.
033939,000237:                                                                                                  #                                                                          (EBANK MUST ALREADY BE SET.)
033940,000238: 
033941,000239:    5141                                           BLOCK    02                                    
033942,000240:    5141           00004        MPENTRY            INHINT                                         
033943,000241:    5142           50002                           INDEX    Q                                     #  MAKE INTERNAL INDEX.
033944,000242:    5143           40000                           CS       0                                     
033945,000243:    5144           67753                           AD       FOUR                                  
033946,000244:    5145           54070                           TS       RUPTREG1                              
033947,000245: 
033948,000246:    5146           50000                           INDEX    A                                     #  IF THIS MISSION PHASE REGISTER IS NOT
033949,000247:    5147           11173                           CCS      MPHASE4                               #  -0, IT HAS BEEN CHANGED BY THE GROUND,
033950,000248:    5150           15157                           TCF      MENTRYT                               #  SO LEAVE IT ALONE.
033951,000249:    5151           15157                           TCF      MENTRYT                               
033952,000250:    5152           15157                           TCF      MENTRYT                               
033953,000251: 
033954,000252:    5153           50002                           INDEX    Q                                     
033955,000253:    5154           30001                           CAF      1                                     
033956,000254:    5155           50070                           INDEX    RUPTREG1                              
033957,000255:    5156           55173                           TS       MPHASE4                               
033958,000256: 
033959,000257:    5157           50070        MENTRYT            INDEX    RUPTREG1                              #  IF THE TIMER IS -0, SET IT TO THE INPUT
033960,000258:    5160           11167                           CCS      MTIMER4                               #  VALUE, OTHERWISE, ASSUME IT HAS BEEN
033961,000259: 
033962,000260:    5161           67755                           AD       ONE                                   #  SET BY THE GROUND AND JUST FORCE IT POS.
033963,000261:    5162           15170                           TCF      MENTABS                               
033964,000262:    5163           15161                           TCF      -2                                    
033965,000263: 
033966,000264:    5164           50002                           INDEX    Q                                     
033967,000265:    5165           30002                           CAF      2                                     
033968,000266:    5166           50000                           INDEX    A                                     
033969,000267:    5167           30000                           CA       0                                     
033970,000268:    5170           50070        MENTABS            INDEX    RUPTREG1                              
033971,000269:    5171           55167                           TS       MTIMER4                               
033972,000270: 
033973,000271:    5172           36301                           CAF      THREE                                 #  MAKE UP RETURN SO COMMON ROUTINE CAN BE
033974,000272:    5173           60002                           AD       Q                                     #  USED TO INITATE TIMER COUNTING.
033975,000273:    5174           55221                 -1        TS       MRETURN                               
033976,000274: 

Page 754

033978,000276:                                                                                                  #  SUBROUTINE TO START MISSION TIMERS IF THEY ARE NOT GOING ALREADY.
033979,000277: 
033980,000278:    5175           30076        MSTART             CA       FLAGWRD2                              #  SEE IF TIMERS ENABLED ALREADY.
033981,000279:    5176           77751                           MASK     BIT5                                  
033982,000280:    5177           10000                           CCS      A                                     
033983,000281:    5200           15220                           TCF      MDONE                                 #  YES - RETURN.
033984,000282: 
033985,000283:    5201           04147                           TC       PHASCHNG                              #  UPDATE RESTART BEFORE SETTING FLAG.
033986,000284:    5202           05013                           OCT      05013                                 
033987,000285:    5203           77777                           OCT      77777                                 
033988,000286: 
033989,000287:    5204           06027                           TC       FLAG2UP                               #  SHOW TIMERS ENABLED.
033990,000288:    5205           00020                           OCT      20                                    
033991,000289: 
033992,000290: 
033993,000291:    5206           00004                           INHINT                                         
033994,000292: 
033995,000293:    5207           35223                           CAF      1SEC+1                                
033996,000294:    5210           60025                           AD       TIME1                                 
033997,000295:    5211           57210                           XCH      NEWMTIME                              
033998,000296: 
033999,000297:    5212           35222                           CAF      STATECRI                              #  INITIALIZE STATE VECTOR EXTRAPOLATION
034000,000298:    5213           55213                           TS       STATECTR                              #  TIMER.
034001,000299: 
034002,000300:    5214           37755                           CAF      ONE                                   
034003,000301: 
034004,000302:    5215           05701                           TC       WAITLIST                              
034005,000303:    5216     1167                                  EBANK=   MTIMER4                               
034006,000304:    5216           02000 62062                     2CADR    MMAINT                                #  START COUNTER MAINTENANCE.
034007,000305: 
034008,000306:    5220           00003        MDONE              RELINT                                         
034009,000307:    5221           01221                           TC       MRETURN                               
034010,000308: 
034011,000309:    5222           01033        STATECRI           DEC      539        B-14                       #  CALLS FOR INTEGRATION EVERY 539 SEC.
034012,000310:    5223           00145        1SEC+1             DEC      101        B-14                       
034013,000311: 

Page 755

034015,000313:                                                                                                  #  SUBROUTINE CALLS FOR VARIOUS UPDATE OPTIONS (SEE GSOP).  ENTER UNDER EXEC WITH INTERRUPT INHIBITED.
034016,000314: 
034017,000315: 31,2201                                           BANK     31                                    
034018,000316: 31,2201           02314        DOV70              TC       MTIMERUP                              #  VERB 70
034019,000317: 31,2202           12373                           TCF      ENDUP                                 
034020,000318: 
034021,000319: 31,2203           02314        DOV72              TC       MTIMERUP                              #  VERB 72
034022,000320: 31,2204           02245        DOV71              TC       MPHASEUP                              #  VERB 71
034023,000321: 31,2205           12373                           TCF      ENDUP                                 
034024,000322: 
034025,000323:                                                                                                  #     *** C ODING  TO BE INSERTED HERE TO CLEAR OUT ALL TIMER/PHASE PAIRS
034026,000324:                                                                                                  #         W HICH H AVE BEEN SET BY LGC, SINCE GROUND REQUEST WILL SUPERSEDE
034027,000325:                                                                                                  #           ALL PR EVIOUSLY SCHEDULED MPS EXCEPT THOSE SET BY GROUND ITSELF
034028,000326: 
034029,000327:                                                                                                  #  DOV74         EQUALS          FORGETIT
034030,000328: 31,2206           00003        ENDV73             RELINT                                         
034031,000329: 31,2207           12373        TCFENDUP           TCF      ENDUP                                 
034032,000330: 

Page 756

034034,000332:                                                                                                  #  INVERT INHIBIT/ENABLE SWITCH WHOSE INDEX IS IN UPINDEX (1 TO 3).  ENTER UNDER EXEC WITH INTERRUPT INHIBITED.
034035,000333: 
034036,000334: 
034037,000335: 31,2210           47754        DOV73              CS       TWO                                   
034038,000336: 31,2211           61216                           AD       UPINDEX                               
034039,000337: 31,2212           04312                           TC       MAGSUB                                #  SEE IF INDEX LEGIT.
034040,000338: 31,2213           77776                           DEC      -1         B-14                       
034041,000339: 31,2214           12375                           TCF      UPERROR                               
034042,000340: 
034043,000341: 31,2215           51216                           INDEX    UPINDEX                               
034044,000342: 31,2216           37752                           CAF      BIT3       -1                         #  BITS IN POSITIONS 3, 2, AND 1 OF
034045,000343: 31,2217           54001                           TS       L                                     #  FLAGWRD2 (SEE SWITCH ASSIGNMENTS).
034046,000344: 31,2220           00004                           INHINT                                         
034047,000345: 
034048,000346: 31,2221           30076                           CA       FLAGWRD2                              
034049,000347: 31,2222           00006                           EXTEND                                         
034050,000348: 31,2223           06001                           RXOR     L                                     
034051,000349: 31,2224           54076                           TS       FLAGWRD2                              
034052,000350: 31,2225           12206                           TCF      ENDV73                                
034053,000351: 
034054,000352:                                                                                                  #           THE FOLLOWING CODING ISSUES THE SINGLE LMP COMMAND FOUND IN UPINDEX PROVIDED THE TIMERS ARE ENABLED
034055,000353:                                                                                                  #  (NON TIME CRITICAL PHASE OF MISSION).
034056,000354: 
034057,000355: 31,2226           40076        DOV67              CS       FLAGWRD2                              
034058,000356: 31,2227           77751                           MASK     BIT5                                  
034059,000357: 31,2230           10000                           CCS      A                                     
034060,000358: 
034061,000359: 31,2231           12375                           TCF      UPERROR                               
034062,000360: 
034063,000361: 31,2232           47746                           CS       BIT8                                  #  COMMAND MUST BE BETWEEN 1 AND 255.
034064,000362: 31,2233           61216                           AD       UPINDEX                               
034065,000363: 31,2234           04312                           TC       MAGSUB                                
034066,000364: 31,2235           77600                           DEC      -127       B-14                       
034067,000365: 31,2236           12375                           TCF      UPERROR                               
034068,000366: 
034069,000367: 31,2237           32244                           CAF      TC1LMP                                
034070,000368: 31,2240           55215                           TS       UPINDEX    -1                         
034071,000369: 
034072,000370: 31,2241           32207                           CAF      TCFENDUP                              
034073,000371: 31,2242           55217                           TS       UPINDEX    +1                         
034074,000372: 31,2243           01215                           TC       UPINDEX    -1                         
034075,000373: 
034076,000374: 31,2244           05073        TC1LMP             TC       1LMP                                  #  FOR ERASABLE CALL.
034077,000375: 

Page 757

034079,000377:                                                                                                  #           THE FOLLOWING CODING UPDATES A MISSION PHASE NUMBER WHOSE INDEX IS IN UPINDEX TO THE VALUE FOUND
034080,000378:                                                                                                  #  IN UPPHASE. RETURN IS TO CALLER IF DATA OK, OR TO UPERROR IF DATA OUT OF RANGE.
034081,000379: 
034082,000380: 31,2245           30002        MPHASEUP           CA       Q                                     
034083,000381: 31,2246           02277                           TC       CHKUPDEX                              #  CHECK INDEX VALUE AND MAKE INTERNAL NDX.
034084,000382: 
034085,000383: 31,2247           11214                           CCS      UPPHASE                               #  CHECK ON SIZE OF PHASE.
034086,000384: 31,2250           12254                           TCF      +4                                    
034087,000385: 
034088,000386: 31,2251           12375                           TCF      UPERROR                               
034089,000387: 31,2252           12375                           TCF      UPERROR                               
034090,000388: 31,2253           12375                           TCF      UPERROR                               
034091,000389: 
034092,000390: 31,2254           04312                 +4        TC       MAGSUB                                
034093,000391: 31,2255           77756                           OCT      -21                                   #  ALLOW PHASES 1 - 18D ONLY.
034094,000392: 31,2256           12375                           TCF      UPERROR                               #  FOR BAD RETURN FROM MAGSUB
034095,000393: 31,2257           41214                           CS       UPPHASE                               #  CHECK LEGALITY OF UPPHASE
034096,000394: 31,2260           66276                           AD       SIX                                   
034097,000395: 31,2261           10000                           CCS      A                                     
034098,000396: 
034099,000397: 31,2262           12375                           TCF      UPERROR                               
034100,000398: 31,2263           72400        MPLEGAL            OCT      72400                                 #  BITS 15 - 1 = 1 FOR MP 7 - 21 LEGAL
034101,000399: 31,2264           12266                           TCF      +2                                    
034102,000400: 31,2265           12375                           TCF      UPERROR                               
034103,000401: 
034104,000402: 31,2266           50000                           INDEX    A                                     
034105,000403: 31,2267           37737                           CA       BIT15                                 
034106,000404: 31,2270           72263                           MASK     MPLEGAL                               
034107,000405: 31,2271           00006                           EXTEND                                         
034108,000406: 31,2272           12375                           BZF      UPERROR                               
034109,000407: 
034110,000408: 31,2273           31214                           CA       UPPHASE                               
034111,000409: 
034112,000410: 31,2274           50070                           INDEX    RUPTREG1                              
034113,000411: 31,2275           55173                           TS       MPHASE4                               
034114,000412: 31,2276           15220                           TCF      MDONE                                 #  RELINT & RETURN VIA MRETURN.
034115,000413: 
034116,000414:                                                                                                  #  MINOR SUBROUTINE TO CHECK MISSION TIMER/PHASE UPDATE INDEX AND LEAVE CORRESPONDING VALUE IN RUPTREG1.
034117,000415: 
034118,000416:                                                                                                  #  TO BE ENTERED WITH INTERRUPT INHIBITED:
034119,000417: 
034120,000418: 31,2277           55221        CHKUPDEX           TS       MRETURN                               #  CALLER'S RETURN ARRIVES IN A.
034121,000419: 31,2300           11216                           CCS      UPINDEX                               
034122,000420: 
034123,000421: 31,2301           12305                           TCF      +4                                    
034124,000422: 31,2302           12375                           TCF      UPERROR                               
034125,000423: 31,2303           12375                           TCF      UPERROR                               
034126,000424: 31,2304           12375                           TCF      UPERROR                               
034127,000425: 
034128,000426: 31,2305           75357                 +4        MASK     NEG3                                  
034129,000427: 31,2306           10000                           CCS      A                                     
034130,000428: 31,2307           12375                           TCF      UPERROR                               
034131,000429: 
034132,000430: 31,2310           41216                           CS       UPINDEX                               #  MAKE INTERNAL VALUE.

Page 758

034134,000432: 31,2311           67753                           AD       FOUR                                  
034135,000433: 31,2312           54070                           TS       RUPTREG1                              
034136,000434: 31,2313           00002                           TC       Q                                     
034137,000435: 

Page 759

034139,000437:                                                                                                  #           THE FOLLOWING CODING UPDATES THE MISSION TIMER WHOSE INDEX IS IN UPINDEX BY ADDING THE CONTENTS OF UPDT
034140,000438:                                                                                                  #  TO IT. OUTCOMES DEPEND ON WHETHER THE TIMER WAS COUNTING AT THE TIME, AND THE SIGN OF THE RESULT (SEE GSOP).
034141,000439: 
034142,000440: 31,2314           30002        MTIMERUP           CA       Q                                     #  GO TO COMMON SUBROUTINE TO SAVE RETURN
034143,000441: 31,2315           02277                           TC       CHKUPDEX                              #  AND CHECK INDEX.
034144,000442: 31,2316           50070                           INDEX    RUPTREG1                              #  SEE IF TIMER IS COUNTING NOW.
034145,000443: 
034146,000444: 31,2317           11167                           CCS      MTIMER4                               
034147,000445: 31,2320           12327                           TCF      TUPBUSY                               #  POS INDICATES IT IS.
034148,000446: 31,2321           12327                           TCF      TUPBUSY                               
034149,000447: 31,2322           12323                           NOOP                                           
034150,000448: 
034151,000449: 31,2323           31215                           CA       UPDT                                  #  IF NOT BUSY, DO ADD, MAKING NO CHANGE
034152,000450: 31,2324           50070                           INDEX    RUPTREG1                              #  IN THE ENABLE FLAG.
034153,000451: 31,2325           27167                           ADS      MTIMER4                               
034154,000452: 31,2326           15220                           TCF      MDONE                                 
034155,000453: 
034156,000454: 31,2327           11215        TUPBUSY            CCS      UPDT                                  #  IF TIMER COUNTING, SEE IF DT ZERO.
034157,000455: 31,2330           12337                           TCF      CTRAD                                 #  NZ - DO ADD.
034158,000456: 
034159,000457: 31,2331           12334                           TCF      CTRABS                                #  +0 - PHASE DUE NEXT MAINTENANCE CYCLE.
034160,000458: 31,2332           12337                           TCF      CTRAD                                 
034161,000459: 
034162,000460: 31,2333           47761                           CS       ZERO                                  #  IF -0, DISABLE TIMER.
034163,000461: 31,2334           50070        CTRABS             INDEX    RUPTREG1                              
034164,000462: 31,2335           55167                           TS       MTIMER4                               
034165,000463: 31,2336           15220                           TCF      MDONE                                 
034166,000464: 
034167,000465: 31,2337           31215        CTRAD              CA       UPDT                                  
034168,000466: 31,2340           50070                           INDEX    RUPTREG1                              
034169,000467: 
034170,000468: 31,2341           27167                           ADS      MTIMER4                               
034171,000469: 31,2342           10000                           CCS      A                                     #  IF RESULT NEGATIVE OR ZERO, PHASE DUE
034172,000470: 31,2343           15220                           TCF      MDONE                                 #  NEXT MAINTENANCE CYCLE.
034173,000471: 31,2344           15220                           TCF      MDONE                                 
034174,000472: 31,2345           37761                           CAF      ZERO                                  
034175,000473: 31,2346           12334                           TCF      CTRABS                                #  (THIS ALONE REVERTS -0 TO +0.)
034176,000474: 

Page 760

034178,000476:                                                                                                  #           THE FOLLOWING CODING IS THE SAME AS MTIMERUP BUT ACCEPTS DP GET IN UPGET (SEE GSOP).
034179,000477: 
034180,000478: 31,2347           06103        MGETUP             TC       INTPRET                               #  MAKE SURE THIS ENTERED WITH VAC AREA.
034181,000479: 
034182,000480: 31,2350           44234                           RTB      BDSU                                  #  TIME IN CS.
034183,000481: 31,2351           33521                                    LOADTIME                              
034184,000482: 31,2352           01220                                    UPGET                                 
034185,000483: 31,2353           54205                           DMP      SL                                    #  CONVERT TO SEC & MOVE TO MAJOR PART.
034186,000484: 31,2354           22400                                    1/100                                 
034187,000485: 31,2355           20217                                    14D                                   
034188,000486: 31,2356           50004                           BOVB     BMN                                   
034189,000487: 31,2357           62375                                    UPERROR                               
034190,000488: 
034191,000489: 31,2360           62374                                    UPERROR    -1                         #  (DOES AN EXIT.)
034192,000490: 
034193,000491: 31,2361           77776                           EXIT                                           
034194,000492: 
034195,000493: 31,2362           00004                           INHINT                                         
034196,000494: 31,2363           37751                           CA       BIT5                                  #  INSURE THAT MAINTENANCE IS STILL ENABLED
034197,000495: 31,2364           70076                           MASK     FLAGWRD2                              
034198,000496: 31,2365           00006                           EXTEND                                         
034199,000497: 31,2366           12375                           BZF      UPERROR                               
034200,000498: 
034201,000499: 31,2367           02277                           TC       CHKUPDEX                              
034202,000500: 31,2370           30144                           CA       MPAC                                  #  CONTAINS DT IN SECONDS.
034203,000501: 
034204,000502: 31,2371           50070                           INDEX    RUPTREG1                              
034205,000503: 31,2372           55167                           TS       MTIMER4                               #  INSERT DT DIRECTLY INTO TIMER.
034206,000504: 
034207,000505:                                                                                                  #           GENERAL EXIT LOCATION FOR SUCCESSFULLY COMPLETED UPDATE:
034208,000506: 
034209,000507: 31,2373           15605        ENDUP              TCF      ENDOFJOB                              #  (MORE TO BE ADDED?)
034210,000508: 
034211,000509:                                                                                                  #           EXIT FOR GENERAL UPDATE ERRORS (RANGE OF DATA, ETC.)
034212,000510: 
034213,000511: 31,2374           77776                 -1        EXIT                                           
034214,000512: 
034215,000513: 31,2375           04560        UPERROR            TC       FALTON                                
034216,000514: 31,2376           15605                           TCF      ENDOFJOB                              
034217,000515: 

The original listing reads simplye "E-2" here. A 1 has been added to conform to yaYUL's requirements.

034219,000517: 31,2377           00243 32703  1/100              2DEC     1          E-2                        
034220,000518: 

Page 761

034222,000520:                                                                                                  #           THE FOLLOWING TABLE SPECIFIES STARTING LOCATIONS AND PRIORITIES OF ALL 206 MISSION PHASES INITIATED BY
034223,000521:                                                                                                  #  THE MISSION TIMERS (S4B-LEM SEP AND BEYOND). IT ALSO CONTAINS INHIBIT/ENABLE INFORMATION, ETC. EACH ENTRY
034224,000522:                                                                                                  #  CONSISTS OF THREE WORDS. THE FIRST IS PACKED WITH SEVERAL PIECES OF INFORMATION, AND THE SECOND TWO CONTAIN THE
034225,000523:                                                                                                  #  2CADR OF THE LOCATION AT WHICH THE PHASE IS TO BEGIN. THE INTERPRETATION OF WORD 1 IS AS FOLLOWS:
034226,000524: 
034227,000525:                                                                                                  #           BIT15:         SPARE
034228,000526:                                                                                                  #           BITS 14-10:    JOB PRIORITY.
034229,000527:                                                                                                  #           BITS 9-5:      SPARE
034230,000528: 
034231,000529:                                                                                                  #           BIT4:          1 IF TIMERS TO BE DISABLED ON PHASE INITIATION.
034232,000530:                                                                                                  #           BIT3:          1 IF RCS TESTS (INHIBIT/ENABLE INFO).
034233,000531:                                                                                                  #           BIT2:                  1 IF DPS COLD SOAK
034234,000532:                                                                                                  #           BIT1:                  1 IF RCS COLD SOAK
034235,000533: 
034236,000534:                                                                                                  #  NOTE SPARES COULD BE USED FOR SWITCHING DOWNLISTS, ETC.
034237,000535: 
034238,000536:                                                                                                  #           PHASES 1 - 6 ARE NOT INCLUDED SINCE THEY ARE NOT INITIATED BY THE MISSION SCHEDULING ROUTINES.
034239,000537: 31,2401           20010        MTABLE1            OCT      20010                                 #  MP7
034240,000538: 31,2402  E4,1566                                  EBANK=   TDEC                                  
034241,000539: 
034242,000540: 31,2402           02467 52004                     2CADR    MP07JOB                               
034243,000541: 
034244,000542: 31,2404           20012                           OCT      20012                                 #  MP8
034245,000543: 
034246,000544: 31,2405  E3,1652                                  EBANK=   RATEINDX                              
034247,000545: 31,2405           02555 56003                     2CADR    MP8JOB                                
034248,000546: 
034249,000547: 31,2407           20010                           OCT      20010                                 #  MP9
034250,000548: 31,2410  E4,1566                                  EBANK=   TDEC                                  
034251,000549: 31,2410           02614 66064                     2CADR    MP9JOB                                
034252,000550: 
034253,000551: 31,2412           04725                           TC       CCSHOLE                               #  MP 10.  UNUSED SLOT.
034254,000552: 
034255,000553: 31,2413           04725                           TC       CCSHOLE                               
034256,000554: 31,2414           00034        34OCT              OCT      00034                                 
034257,000555: 
034258,000556: 31,2415           20010                           OCT      20010                                 #  MP11
034259,000557: 31,2416  E4,1566                                  EBANK=   TDEC                                  
034260,000558: 31,2416           02000 74064                     2CADR    MP11JOB                               
034261,000559: 
034262,000560: 31,2420           04725                           TC       CCSHOLE                               #  MP 12.  UNUSED SLOT.
034263,000561: 31,2421           04725                           TC       CCSHOLE                               
034264,000562: 31,2422           04725                           TC       CCSHOLE                               
034265,000563: 
034266,000564: 31,2423           20010                           OCT      20010                                 #  MP13
034267,000565: 31,2424  E4,1566                                  EBANK=   TDEC                                  
034268,000566: 31,2424           03071 56004                     2CADR    MP13JOB                               
034269,000567: 
034270,000568: 31,2426           04725                           TC       CCSHOLE                               #  MP 14.  UNUSED SLOT.
034271,000569: 31,2427           04725                           TC       CCSHOLE                               
034272,000570: 31,2430           04725                           TC       CCSHOLE                               
034273,000571: 
034274,000572: 31,2431  31,2354               MTABLE             EQUALS   MTABLE1    -21D                       #  MP 1-6 NOT ACTUALLY INCLUDED IN TABLE.
034275,000573: 

Page 762

034277,000575: 31,2431           04744        BADPHASE           TC       ALARM                                 #  ALARM WHEN MPHASE COMES DUE BUT MPHASE
034278,000576: 
034279,000577: 31,2432           00601                           OCT      00601                                 #  REGISTER IS ZERO (-0 MEANS INACTIVE).
034280,000578: 
034281,000579: 31,2433           35676                           CAF      PRIO37                                
034282,000580: 31,2434           05523                           TC       NOVAC                                 
034283,000581: 31,2435  E3,1400                                  EBANK=   LST1                                  
034284,000582: 31,2435           02000 16003                     2CADR    FORGETIT                              
034285,000583: 
034286,000584: 31,2437           05745                           TC       TASKOVER                              

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