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.

003485,000002:                                                                                                  ## Copyright:   Public domain.
003486,000003:                                                                                                  ## Filename:    FRESH_START_AND_RESTART.agc
003487,000004:                                                                                                  ## Purpose:     A section of Sunburst revision 37, or Shepatin revision 0.
003488,000005:                                                                                                  ##              It is part of an early development version of the software
003489,000006:                                                                                                  ##              for Apollo Guidance Computer (AGC) on the unmanned Lunar
003490,000007:                                                                                                  ##              Module (LM) flight Apollo 5. Sunburst 37 was the program
003491,000008:                                                                                                  ##              upon which Don Eyles's offline development program Shepatin
003492,000009:                                                                                                  ##              was based; the listing herein transcribed was actually for
003493,000010:                                                                                                  ##              the equivalent revision 0 of Shepatin.
003494,000011:                                                                                                  ##              This file is intended to be a faithful transcription, except
003495,000012:                                                                                                  ##              that the code format has been changed to conform to the
003496,000013:                                                                                                  ##              requirements of the yaYUL assembler rather than the
003497,000014:                                                                                                  ##              original YUL assembler.
003498,000015:                                                                                                  ## Reference:   pp. 78-89
003499,000016:                                                                                                  ## Assembler:   yaYUL
003500,000017:                                                                                                  ## Contact:     Ron Burkey <info@sandroid.org>.
003501,000018:                                                                                                  ## Website:     www.ibiblio.org/apollo/index.html
003502,000019:                                                                                                  ## Mod history: 2017-05-24 MAS  Created from Sunburst 120.
003503,000020:                                                                                                  ##              2017-05-29 HG   Transcribed
003504,000021:                                                                                                  ##              2017-06-15 HG   Fix operand  BIT14  -> BIT4
003505,000022:                                                                                                  ##                              Fix operator TC     -> TS  
003506,000023:                                                                                                  ##                                           TCF    -> TC 
003507,000024:                                                                                                  ##                              Fix statements CS    LMPCMD --> MASK LMPCMD
003508,000025:                                                                                                  ##                                             MASK  BIT15  --> AD   BIT15
003509,000026:                                                                                                  ##                                             ADS   LMPCMD --> TS   LMPCMD
003510,000027:                                                                                                  ##                              Fix value IM30INIR  OCT 37000 -> OCT 37400
003511,000028:                                                                                                  ##              2017-06-21 RSB  Various comment fixes found using 
003512,000029:                                                                                                  ##                              octopus/ProoferComments.
003513,000030: 

Page 78

003515,000032: 01,2000                                           BANK     01                                    
003516,000033: 01,2000  E3,1400                                  EBANK=   LST1                                  
003517,000034: 
003518,000035: 01,2000           00004        SLAP1              INHINT                                         #  FRESH START. COMES HERE FROM PINBALL.
003519,000036: 01,2001           02322                           TC       STARTSUB                              #  SUBROUTINE DOES MOST OF THE WORK.
003520,000037: 
003521,000038: 01,2002           12007        STARTSW            TCF      GOON                                  #  PATCH FOR SIMULATIONS
003522,000039: 
003523,000040: 01,2003           37740        STARTSIM           CAF      BIT14                                 
003524,000041: 
003525,000042: 01,2004           05534                           TC       FINDVAC                               
003526,000043: 01,2005     0061                                  EBANK=   ITEMP1                                
003527,000044: 01,2005           03524 72060                     2CADR    BEGIN206                              
003528,000045: 
003529,000046: 01,2007           37737        GOON               CAF      BIT15                                 #  TURN OFF ALL DSPTAB +11D LAMPS ONLY ON
003530,000047: 01,2010           54326                           TS       DSPTAB     +11D                       #  REQUESTED FRESH START.
003531,000048: 
003532,000049: 01,2011           37761                           CAF      ZERO                                  #  SAME STORY ON ZEROING FAILREG.
003533,000050: 01,2012           55360                           TS       REDOCTR                               
003534,000051: 01,2013           55363                           TS       FAILREG                               
003535,000052: 01,2014           55364                           TS       FAILREG    +1                         
003536,000053: 01,2015           55365                           TS       FAILREG    +2                         
003537,000054: 
003538,000055: 01,2016           00006                           EXTEND                                         #  INITIALIZE SPECIAL ENEMIZE REGISTER
003539,000056: 01,2017           32141                           DCA      ENJOBCAD                              
003540,000057: 01,2020           52376                           DXCH     FLUSHREG                              #  *** REMOVE IF FAKESTRT REMOVED
003541,000058: 
003542,000059: 01,2021           47761        DOFSTART           CS       ZERO                                  #  MAKE ALL MTIMER/PHASE PAIRS AVAILABLE.
003543,000060: 01,2022           55167                           TS       MTIMER4                               
003544,000061: 01,2023           55170                           TS       MTIMER3                               
003545,000062: 01,2024           55171                           TS       MTIMER2                               
003546,000063: 01,2025           55172                           TS       MTIMER1                               
003547,000064: 
003548,000065: 01,2026           55173                           TS       MPHASE4                               
003549,000066: 01,2027           55174                           TS       MPHASE3                               
003550,000067: 01,2030           55175                           TS       MPHASE2                               
003551,000068: 01,2031           55176                           TS       MPHASE1                               
003552,000069: 
003553,000070:                                                                                                  #  INITIALIZE SWITCH REGISTERS INCLUDING DAPBOOLS
003554,000071: 
003555,000072: 01,2032           47755                           CS       ONE                                   
003556,000073: 01,2033           55144                           TS       LMPOUTT                               
003557,000074: 
003558,000075: 01,2034           37757                           CA       SEVEN                                 
003559,000076: 01,2035           54001                 -6        TS       L                                     
003560,000077: 01,2036           50001                           INDEX    L                                     
003561,000078: 01,2037           32540                           CA       SWINIT                                
003562,000079: 01,2040           50001                           INDEX    L                                     
003563,000080: 01,2041           54074                           TS       STATE                                 
003564,000081: 01,2042           10001                           CCS      L                                     
003565,000082: 01,2043           12035                           TCF      -6                                    
003566,000083: 

Page 79

003568,000085: 
003569,000086: 01,2044           54032                           TS       CDUX                                  #  ZERO CDUS SO MATRIX COMPUTATION IN T4
003570,000087: 01,2045           54033                           TS       CDUY                                  #  WONT OVERFLOW.
003571,000088: 01,2046           54034                           TS       CDUZ                                  
003572,000089: 
003573,000090: 01,2047           55132                           TS       LMPCMD                                #  RESET LMP COMMAND AREA.
003574,000091: 01,2050           55133                           TS       LMPCMD     +1                         
003575,000092: 01,2051           55134                           TS       LMPCMD     +2                         
003576,000093: 01,2052           55135                           TS       LMPCMD     +3                         
003577,000094: 01,2053           55136                           TS       LMPCMD     +4                         
003578,000095: 01,2054           55137                           TS       LMPCMD     +5                         
003579,000096: 01,2055           55140                           TS       LMPCMD     +6                         
003580,000097: 01,2056           55141                           TS       LMPCMD     +7                         
003581,000098: 01,2057           55142                           TS       LMPIN                                 
003582,000099: 01,2060           55143                           TS       LMPOUT                                
003583,000100: 
003584,000101: 01,2061           37761        POOH3              CAF      ZERO                                  
003585,000102: 01,2062           55357                           TS       SMODE                                 
003586,000103: 01,2063           54302                           TS       MODREG                                
003587,000104: 01,2064           54412                           TS       AGSWORD                               #  ALLOW AGS INITIALIZATION.
003588,000105: 
003589,000106: 01,2065           55112                           TS       PHASE6                                #  INITIALIZE PHASE TABLES - NO MISSION
003590,000107: 01,2066           55100                           TS       PHASE1                                #  PROGRAMS RUNNING.
003591,000108: 01,2067           55102                           TS       PHASE2                                
003592,000109: 01,2070           55104                           TS       PHASE3                                
003593,000110: 01,2071           55106                           TS       PHASE4                                
003594,000111: 01,2072           55110                           TS       PHASE5                                
003595,000112: 
003596,000113: 01,2073           40000                           COM                                            
003597,000114: 01,2074           55111                           TS       -PHASE6                               
003598,000115: 01,2075           55077                           TS       -PHASE1                               
003599,000116: 01,2076           55101                           TS       -PHASE2                               
003600,000117: 01,2077           55103                           TS       -PHASE3                               
003601,000118: 01,2100           55105                           TS       -PHASE4                               
003602,000119: 01,2101           55107                           TS       -PHASE5                               
003603,000120: 
003604,000121: 01,2102           34265                           CAF      LNORMT4                               
003605,000122: 01,2103           54346                           TS       T4LOC                                 
003606,000123: 
003607,000124: 01,2104           32527                           CAF      IM30INIF                              #  FRESH START IMU INITIALIZATION.
003608,000125: 01,2105           54365                           TS       IMODES30                              
003609,000126: 
003610,000127: 01,2106           37744                           CAF      BIT10                                 #  REMOVE IMU FAIL INHIBIT IN 5 SECS.
003611,000128: 01,2107           05701                           TC       WAITLIST                              
003612,000129: 01,2110  E3,1400                                  EBANK=   LST1                                  
003613,000130: 01,2110           02272 26003                     2CADR    IFAILOK                               
003614,000131: 01,2112           00006                           EXTEND                                         #  SETTING T5RUPT FOR SETIDLER PROGRAM
003615,000132: 01,2113           32537                           DCA      SETADR                                #  THE SETIDLER PROGRAM ASSURES 1 SECOND
003616,000133: 01,2114           53001                           DXCH     T5ADR                                 #  DELAY BEFORE THE DAPIDLER BEGINS.
003617,000134: 

Page 80

003619,000136: 01,2115           37750        ENDRSTRT           CAF      BIT6                                  #  IF GIMBAL LOCK LAMP IS STILL ON,
003620,000137: 01,2116           70326                           MASK     DSPTAB     +11D                       #  IMU WAS FOUND IN GIMBAL LOCK IN RESTART
003621,000138: 01,2117           10000                           CCS      A                                     #  AND LEFT IN COARSE ALIGN. IN THIS CASE
003622,000139: 01,2120           47745                           CS       BIT9                                  #  SET ISS OPERATE BIT IN IMODES30 TO
003623,000140: 01,2121           26365                           ADS      IMODES30                              #  OPERATE SO T4 INBIT MONITOR WONT ZERO
003624,000141: 
003625,000142: 01,2122           00003                           RELINT                                         #  THE CDUS AS IT DOES IN FRESH START.
003626,000143: 01,2123           05224                           TC       BANKCALL                              #  DISPLAY MAJOR MODE.
003627,000144: 01,2124           12001                           CADR     DSPMM                                 
003628,000145: 
003629,000146: 01,2125           35226                           CAF      PRIO30                                #  THIS IS USED ONLY FOR SPECIAL ENEMIZE.
003630,000147: 01,2126           00004                           INHINT                                         #  $$$ REMOVE IF FULL RESTARTABILITY ***
003631,000148: 01,2127           05534                           TC       FINDVAC                               
003632,000149: 01,2130     0375                                  EBANK=   FLUSHREG                              
003633,000150: 01,2130           02134 02000                     2CADR    FLUSHLOC                              
003634,000151: 01,2132           00003                           RELINT                                         
003635,000152: 01,2133           15616                           TCF      DUMMYJOB   +2                         #  DONT ZERO NEWJOB
003636,000153: 
003637,000154: 
003638,000155: 
003639,000156: 01,2134           00006        FLUSHLOC           EXTEND                                         #  GO TO SPECIAL ENEMA LOC FOR ROM
003640,000157: 01,2135           30376                           DCA      FLUSHREG                              
003641,000158: 01,2136           52006                           DXCH     Z                                     #  USUALLY THIS WILL BE AN ENDOFJOB
003642,000159: 
003643,000160: 01,2137           00312        OCT312             OCT      312                                   
003644,000161: 01,2140  E3,1400                                  EBANK=   LST1                                  
003645,000162: 01,2140           05605 04003  ENJOBCAD           2CADR    ENDOFJOB                              
003646,000163: 

Page 81

003648,000165:                                                                                                  #           COMES HERE FROM LOCATION 4000, GOJAM. RESTART ANY PROGRAMS WHICH MAY HAVE BEEN RUNNING AT THE TIME.
003649,000166: 
003650,000167: 01,2142           05224        GOPROG             TC       BANKCALL                              #  * * * SUBJECT TO A HUGE CHANGE * * *
003651,000168: 01,2143           16055                           CADR     FAKESTRT                              
003652,000169: 01,2144           25360                           INCR     REDOCTR                               
003653,000170: 
003654,000171: 01,2145           31355                           CA       ERESTORE                              
003655,000172: 01,2146           00006                           EXTEND                                         
003656,000173: 01,2147           12161                           BZF      2STARTSB                              
003657,000174: 01,2150           31377                           CA       SKEEP7                                
003658,000175: 01,2151           74547                           MASK     HI5                                   
003659,000176: 01,2152           00006                           EXTEND                                         #  IF SKEEP7 CONTAINS NONSENSE, DO
003660,000177: 01,2153           12155                           BZF      +2                                    #  A FRESH START.  THIS ELIMINATES A CHANCE
003661,000178: 01,2154           12000                           TCF      SLAP1                                 #  OF POSSIBLE COMPUTER LOCKUP.
003662,000179: 
003663,000180: 01,2155           00006                           EXTEND                                         #  RESTORE B(X) AND B(X+1) IF RESTART
003664,000181: 01,2156           31376                           DCA      SKEEP5                                #  HAPPENED WHILE SELF-CHECK HAD REPLACED
003665,000182: 01,2157           51377                           NDX      SKEEP7                                #  THEM WITH CHECKING WORDS.
003666,000183: 01,2160           52001                           DXCH     0000                                  
003667,000184: 
003668,000185: 01,2161           02322        2STARTSB           TC       STARTSUB                              #  COMMON INITIALIZATION ROUTINE
003669,000186: 
003670,000187: 01,2162           32532                           CAF      9,6                                   #  LEAVE PROGRAM ALARM AND GIMBAL LOCK
003671,000188: 01,2163           70326                           MASK     DSPTAB     +11D                       #  LAMPS INTACT ON RESTART.
003672,000189: 01,2164           67737                           AD       BIT15                                 
003673,000190: 01,2165           56326                           XCH      DSPTAB     +11D                       
003674,000191: 
003675,000192: 01,2166           77750                           MASK     BIT6                                  
003676,000193: 01,2167           10000                           CCS      A                                     #  IF GIMBAL LOCK LAMP WAS ON, LEAVE ISS IN
003677,000194: 01,2170           37752                           CAF      BIT4                                  #  COARSE ALIGN.
003678,000195: 01,2171           00006                           EXTEND                                         
003679,000196: 01,2172           05012                           WOR      12                                    
003680,000197: 
003681,000198:                                                                                                  #  DAP ZEROES GODAPGO TO BYPASS STARTUP OF DAP AFTER JETABORT UNTIL GROUND
003682,000199: 01,2173           00006                           EXTEND                                         #  SETTING T5RUPT FOR DAPIDLER PROGRAM
003683,000200: 01,2174           32535                           DCA      IDLEADR                               
003684,000201: 01,2175           53001                           DXCH     T5ADR                                 
003685,000202:                                                                                                  #  RESETS GODAPGO.
003686,000203: 01,2176           35676                           CAF      PRIO37                                #  DISPLAY FAILREG AS INDICATION OF RESTART
003687,000204: 01,2177           05523                           TC       NOVAC                                 #  OR TO DISPLAY ABORT CODE AS ABOVE.
003688,000205: 01,2200  E3,1400                                  EBANK=   LST1                                  
003689,000206: 01,2200           02063 16003                     2CADR    DOALARM                               
003690,000207: 01,2202           00006        LIGHTSET           EXTEND                                         #  DONT TRY TO RESTART IF ERROR
003691,000208: 01,2203           00015                           READ     15                                    #  AND MARK REJECT BUTTONS DEPRESSED.
003692,000209: 01,2204           62525                           AD       -ELR                                  
003693,000210: 01,2205           00006                           EXTEND                                         
003694,000211: 01,2206           12210                           BZF      +2                                    
003695,000212: 01,2207           12216                           TCF      +7                                    
003696,000213: 
003697,000214: 01,2210           37751                           CAF      BIT5                                  
003698,000215: 

Page 82

003700,000217: 01,2211           00006                           EXTEND                                         
003701,000218: 01,2212           02016                           RAND     16                                    
003702,000219: 01,2213           62526                           AD       -MKREJ                                
003703,000220: 01,2214           00006                           EXTEND                                         
003704,000221: 01,2215           12021                           BZF      DOFSTART                              
003705,000222: 
003706,000223: 01,2216           40346                           CS       T4LOC                                 #  SEE IF LMP COMMAND WAS SITTING IN CH 10
003707,000224: 01,2217           62521                           AD       LLMPRS2                               #  WHEN RESTART OCCURRED. IF SO, SET BIT 15
003708,000225: 
003709,000226: 01,2220           00006                           EXTEND                                         #  BACK TO ZERO SO THE COMMAND WILL BE
003710,000227: 01,2221           12230                           BZF      LMPRUPT                               #  RESENT.
003711,000228: 
003712,000229: 01,2222           11144                           CCS      LMPOUTT                               #  IF NOT, SEE IF UPDATE OF REFERENCE
003713,000230: 01,2223           67755                           AD       ONE                                   #  POINTER (LMPOUT) WAS IN PROCESS. IF SO,
003714,000231: 01,2224           55143                           TS       LMPOUT                                #  LMPOUTT IS NON-NEGATIVE.
003715,000232: 01,2225           47755                           CS       ONE                                   #  SHOW LMPOUT UPDATED.
003716,000233: 01,2226           55144                           TS       LMPOUTT                               
003717,000234: 01,2227           12236                           TCF      T4LOCRST                              
003718,000235: 
003719,000236: 01,2230           47737        LMPRUPT            CS       BIT15                                 #  CANT USE ADS HERE SINCE CODING MUST BE
003720,000237: 01,2231           51143                           INDEX    LMPOUT                                #  REPEATABLE (RESTART DURING RESTART, ETC)
003721,000238: 01,2232           71132                           MASK     LMPCMD                                
003722,000239: 01,2233           67737                           AD       BIT15                                 
003723,000240: 01,2234           51143                           INDEX    LMPOUT                                
003724,000241: 01,2235           55132                           TS       LMPCMD                                
003725,000242: 
003726,000243: 01,2236           34265        T4LOCRST           CAF      LNORMT4                               
003727,000244: 01,2237           54346                           TS       T4LOC                                 
003728,000245: 
003729,000246: 01,2240           37760                 -1        CAF      NUMGRPS                               #  VERIFY PHASE TABLE AGREEMENT.
003730,000247: 01,2241           54151        PCLOOP             TS       MPAC       +5                         
003731,000248: 01,2242           60000                           DOUBLE                                         
003732,000249: 
003733,000250: 01,2243           00006                           EXTEND                                         
003734,000251: 01,2244           50000                           INDEX    A                                     
003735,000252: 01,2245           31100                           DCA      -PHASE1                               #  COMPLEMENT INTO A, DIRECT INTO L.
003736,000253: 01,2246           00006                           EXTEND                                         
003737,000254: 01,2247           06001                           RXOR     L                                     #  RESULT MUST BE -0 FOR AGREEMENT.
003738,000255: 01,2250           10000                           CCS      A                                     
003739,000256: 01,2251           12310                           TCF      PTBAD                                 #  RESTART FAILURE.
003740,000257: 01,2252           12310                           TCF      PTBAD                                 
003741,000258: 01,2253           12310                           TCF      PTBAD                                 
003742,000259: 
003743,000260: 01,2254           10151                           CCS      MPAC       +5                         #  PROCESS ALL RESTART GROUPS.
003744,000261: 01,2255           12241                           TCF      PCLOOP                                
003745,000262: 
003746,000263: 01,2256           54152                           TS       MPAC       +6                         #  SET TO +0.
003747,000264: 01,2257           02267                           TC       NXTRST     -1                         #  * * * BYPASS 77 CHECK FOR NOW
003748,000265: 01,2260           31111                           CA       -PHASE6                               #  TEST TO SEE IF IT IS A PLANNED NO RESTAR
003749,000266: 01,2261           62264                           AD       OCT77                                 #  T RESTART
003750,000267: 01,2262           10000                           CCS      A                                     
003751,000268: 01,2263           12267                           TCF      +4                                    #  A NORMAL RESTART
003752,000269: 

Page 83

003754,000271: 01,2264           00077        OCT77              OCT      77                                    #  CAN:T GET HERE
003755,000272: 01,2265           12267                           TCF      +2                                    #  A NORMAL RESTART
003756,000273: 01,2266           12267                           TCF      +1                                    #  THIS MAY GO TO FORGETIT IF EVER USED
003757,000274: 
003758,000275: 01,2267           37760                           CAF      NUMGRPS                               #  SEE IF ANY GROUPS RUNNING.
003759,000276: 01,2270           54151        NXTRST             TS       MPAC       +5                         
003760,000277: 01,2271           60000                           DOUBLE                                         
003761,000278: 01,2272           50000                           INDEX    A                                     
003762,000279: 01,2273           11100                           CCS      PHASE1                                
003763,000280: 01,2274           12276                           TCF      PACTIVE                               #  PNZ - GROUP ACTIVE.
003764,000281: 01,2275           12303                           TCF      PINACT                                #  +0 - GROUP NOT RUNNING.
003765,000282: 
003766,000283: 01,2276           54144        PACTIVE            TS       MPAC                                  
003767,000284: 01,2277           24144                           INCR     MPAC                                  #  ABS OF PHASE.
003768,000285: 
003769,000286: 01,2300           24152                           INCR     MPAC       +6                         #  INDICATE GROUP DEMANDS PRESENT.
003770,000287: 01,2301           32313                           CA       RACTCADR                              #  GO TO RESTARTS AND PROCESS PHASE INFO.
003771,000288: 01,2302           05230                           TC       SWCALL                                #  MUST RETURN TO SWRETURN.
003772,000289: 
003773,000290: 01,2303           10151        PINACT             CCS      MPAC       +5                         #  PROCESS ALL RESTART GROUPS.
003774,000291: 01,2304           12270                           TCF      NXTRST                                
003775,000292: 
003776,000293: 01,2305           10152        TSTMPAC6           CCS      MPAC       +6                         #  IF NO GROUPS ACTIVE THIS REQUEST, DO A
003777,000294: 01,2306           12315                           TCF      DORSTART                              
003778,000295: 01,2307           12021                           TCF      DOFSTART                              #  FRESH START
003779,000296: 
003780,000297: 01,2310           32314        PTBAD              CAF      OCT1107                               #  SET ADDITIONAL FAILURE TO SHOW PHASE
003781,000298: 01,2311           55361                           TS       SFAIL                                 #  TABLE DISAGREEMENT (WILL BE DISPLAYED
003782,000299: 01,2312           12021                           TCF      DOFSTART                              #  IN R2).
003783,000300: 
003784,000301: 01,2313           14132        RACTCADR           CADR     RESTARTS                              
003785,000302: 01,2314           01107        OCT1107            OCT      1107                                  #  ADDITIONAL ALARM CODE.
003786,000303: 
003787,000304: 01,2315           32514        DORSTART           CAF      IFAILINH                              #  LEAVE IMU FAILURE INHIBITS INTACT ON
003788,000305: 01,2316           70365                           MASK     IMODES30                              #  RESTART, RESETTING ALL FAILURE CODES.
003789,000306: 01,2317           62530                           AD       IM30INIR                              
003790,000307: 01,2320           54365                           TS       IMODES30                              
003791,000308: 
003792,000309: 01,2321           12115                           TCF      ENDRSTRT                              
003793,000310: 

Page 84

003795,000312:                                                                                                  #           INITIALIZATION COMMON TO BOTH FRESH START AND RESTART.
003796,000313: 01,2322  E7,1401                                  EBANK=   DNTMGOTO                              #  DO PORTION OF FRESH START NOT DONE
003797,000314: 01,2322           32516        STARTSUB           CAF      LDNTMGO                               #  BY POO.
003798,000315: 01,2323           54003                           TS       EBANK                                 #  SET UP TM PROGRAM.
003799,000316: 
003800,000317: 01,2324           32515                           CAF      LDNPHAS1                              
003801,000318: 01,2325           55401                           TS       DNTMGOTO                              
003802,000319: 
003803,000320: 01,2326           56002        STARTSB2           XCH      Q                                     #  ENTRY FROM POO.
003804,000321: 01,2327           54120                           TS       BUF                                   #  EXEC TEMPS ARE AVAILABLE TO US.
003805,000322: 
003806,000323: 01,2330           37761                           CAF      ZERO                                  #  ZERO OUTBITS WITHIN 3MS OF RESTART.
003807,000324: 01,2331           00006                           EXTEND                                         
003808,000325: 01,2332           01012                           WRITE    12                                    
003809,000326: 01,2333           00006                           EXTEND                                         
003810,000327: 01,2334           01014                           WRITE    14                                    
003811,000328: 01,2335           00006                           EXTEND                                         
003812,000329: 01,2336           01011                           WRITE    11                                    
003813,000330: 01,2337           55355                           TS       ERESTORE                              #       ERASCHK RESTORE FLAG
003814,000331: 
003815,000332: 01,2340           00006                           EXTEND                                         #  USE FIRST 8 OF 12 SUPER-BANKS (ADD PROG
003816,000333: 01,2341           01007                           WRITE    7                                     #  WHEN LAST FOUR ARE NEEDED). PROBABLY V37
003817,000334: 01,2342           35673                           CAF      PRIO34                                #  ENABLE INTERRUPTS.
003818,000335: 01,2343           00006                           EXTEND                                         
003819,000336: 01,2344           01013                           WRITE    13                                    
003820,000337: 
003821,000338: 01,2345           37735                           CAF      POSMAX                                #  T3 AND T4 OVERFLOW AS SOON AS POSSIBLE.
003822,000339: 01,2346           54030                           TS       TIME5                                 #  SO DOES T5.
003823,000340: 01,2347           54026                           TS       TIME3                                 #    (POSMAX IS PSEUDO INTERRUPT SIGNAL IN
003824,000341: 01,2350           54027                           TS       TIME4                                 #    CASE RUPT SIGNALLED BEFORE TS TIME3).
003825,000342: 
003826,000343: 01,2351  E3,1400                                  EBANK=   LST1                                  
003827,000344: 01,2351           32524                           CAF      STARTEB                               
003828,000345: 01,2352           54003                           TS       EBANK                                 #  SET FOR E3
003829,000346: 
003830,000347: 01,2353           37736                           CAF      NEG1/2                                #  INITIALIZE WAITLIST DELTA-TS.
003831,000348: 01,2354           55407                           TS       LST1       +7                         
003832,000349: 01,2355           55406                           TS       LST1       +6                         
003833,000350: 01,2356           55405                           TS       LST1       +5                         
003834,000351: 01,2357           55404                           TS       LST1       +4                         
003835,000352: 01,2360           55403                           TS       LST1       +3                         
003836,000353: 01,2361           55402                           TS       LST1       +2                         
003837,000354: 01,2362           55401                           TS       LST1       +1                         
003838,000355: 
003839,000356: 01,2363           55400                           TS       LST1                                  
003840,000357: 
003841,000358: 01,2364           45732                           CS       ENDTASK                               
003842,000359: 01,2365           55410                           TS       LST2                                  
003843,000360: 01,2366           55412                           TS       LST2       +2                         
003844,000361: 01,2367           55414                           TS       LST2       +4                         
003845,000362: 01,2370           55416                           TS       LST2       +6                         
003846,000363: 

Page 85

003848,000365: 01,2371           55420                           TS       LST2       +8D                        
003849,000366: 01,2372           55422                           TS       LST2       +10D                       
003850,000367: 
003851,000368: 01,2373           55424                           TS       LST2       +12D                       
003852,000369: 01,2374           55426                           TS       LST2       +14D                       
003853,000370: 01,2375           55430                           TS       LST2       +16D                       
003854,000371: 01,2376           45733                           CS       ENDTASK    +1                         
003855,000372: 01,2377           55411                           TS       LST2       +1                         
003856,000373: 01,2400           55413                           TS       LST2       +3                         
003857,000374: 01,2401           55415                           TS       LST2       +5                         
003858,000375: 01,2402           55417                           TS       LST2       +7                         
003859,000376: 01,2403           55421                           TS       LST2       +9D                        
003860,000377: 01,2404           55423                           TS       LST2       +11D                       
003861,000378: 01,2405           55425                           TS       LST2       +13D                       
003862,000379: 01,2406           55427                           TS       LST2       +15D                       
003863,000380: 01,2407           55431                           TS       LST2       +17D                       
003864,000381: 
003865,000382: 01,2410           47761                           CS       ZERO                                  #  MAKE ALL EXECUTIVE REGISTER SETS
003866,000383: 01,2411           54157                           TS       PRIORITY                              #  AVAILABLE.
003867,000384: 01,2412           54173                           TS       PRIORITY   +12D                       
003868,000385: 01,2413           54207                           TS       PRIORITY   +24D                       
003869,000386: 01,2414           54223                           TS       PRIORITY   +36D                       
003870,000387: 01,2415           54237                           TS       PRIORITY   +48D                       
003871,000388: 01,2416           54253                           TS       PRIORITY   +60D                       
003872,000389: 01,2417           54267                           TS       PRIORITY   +72D                       
003873,000390: 
003874,000391: 01,2420           54067                           TS       NEWJOB                                #  SHOWS NO ACTIVE JOBS.
003875,000392: 
003876,000393: 01,2421           32522                           CAF      VAC1ADRC                              #  MAKE ALL VAC AREAS AVAILABLE.
003877,000394: 01,2422           54431                           TS       VAC1USE                               
003878,000395: 01,2423           62523                           AD       LTHVACA                               
003879,000396: 01,2424           54505                           TS       VAC2USE                               
003880,000397: 01,2425           62523                           AD       LTHVACA                               
003881,000398: 01,2426           54561                           TS       VAC3USE                               
003882,000399: 01,2427           62523                           AD       LTHVACA                               
003883,000400: 01,2430           54635                           TS       VAC4USE                               
003884,000401: 01,2431           62523                           AD       LTHVACA                               
003885,000402: 01,2432           54711                           TS       VAC5USE                               
003886,000403: 
003887,000404: 01,2433           34557                           CAF      TEN                                   #  TURN OFF ALL DISPLAY SYSTEM RELAYS.
003888,000405: 01,2434           54350                           TS       DIDFLG                                #  DISPLAY INERTIAL DATA FLAG.
003889,000406: 01,2435           54144        DSPOFF             TS       MPAC                                  
003890,000407: 01,2436           47742                           CS       BIT12                                 
003891,000408: 01,2437           50144                           INDEX    MPAC                                  
003892,000409: 01,2440           54313                           TS       DSPTAB                                
003893,000410: 01,2441           10144                           CCS      MPAC                                  
003894,000411: 01,2442           02435                           TC       DSPOFF                                
003895,000412: 
003896,000413: 01,2443           54045                           TS       INLINK                                
003897,000414: 01,2444           54345                           TS       DSPCNT                                
003898,000415: 
003899,000416: 01,2445           54327                           TS       CADRSTOR                              
003900,000417: 

Page 86

003902,000419: 01,2446           54304                           TS       REQRET                                
003903,000420: 01,2447           54306                           TS       CLPASS                                
003904,000421: 01,2450           54303                           TS       DSPLOCK                               
003905,000422: 01,2451           54311                           TS       MONSAVE                               #  KILL MONITOR
003906,000423: 01,2452           54312                           TS       MONSAVE1                              
003907,000424: 01,2453           54330                           TS       GRABLOCK                              
003908,000425: 01,2454           54272                           TS       VERBREG                               
003909,000426: 01,2455           54273                           TS       NOUNREG                               
003910,000427: 
003911,000428: 01,2456           54333                           TS       DSPLIST                               
003912,000429: 01,2457           54334                           TS       DSPLIST    +1                         
003913,000430: 01,2460           54335                           TS       DSPLIST    +2                         
003914,000431: 
003915,000432: 01,2461           54373                           TS       MARKSTAT                              
003916,000433: 01,2462           54336                           TS       EXTVBACT                              #  MAKE EXTENDED VERBS AVAILABLE
003917,000434: 01,2463           54367                           TS       IMUCADR                               
003918,000435: 01,2464           54370                           TS       OPTCADR                               
003919,000436: 01,2465           54371                           TS       RADCADR                               
003920,000437: 01,2466           54372                           TS       ATTCADR                               
003921,000438: 01,2467           54765                           TS       PHASENUM                              
003922,000439: 01,2470           54356                           TS       LGYRO                                 
003923,000440: 01,2471           54347                           TS       DSRUPTSW                              
003924,000441: 01,2472           37756                           CAF      NOUTCON                               
003925,000442: 01,2473           54307                           TS       NOUT                                  
003926,000443: 
003927,000444: 01,2474           47755                           CS       ONE                                   #  NO RADAR DESIGNATION.
003928,000445: 01,2475           54414                           TS       SAMPLIM                               #  NO RADAR RUPTS EXPECTED.
003929,000446: 
003930,000447: 01,2476           32531                           CAF      IM33INIT                              #  NO PIP OR TM FAILS.
003931,000448: 01,2477           54366                           TS       IMODES33                              
003932,000449: 
003933,000450: 01,2500           37750                           CAF      BIT6                                  #  SET LR POS.
003934,000451: 01,2501           00006                           EXTEND                                         
003935,000452: 01,2502           02033                           RAND     33                                    
003936,000453: 01,2503           62533                           AD       RMODINIT                              
003937,000454: 01,2504           54413                           TS       RADMODES                              
003938,000455: 
003939,000456: 01,2505           32520                           CAF      LESCHK                                #  SELF CHECK GO-TO REGISTER.
003940,000457: 01,2506           55356                           TS       SELFRET                               
003941,000458: 01,2507           44554                           CS       VD1                                   
003942,000459: 01,2510           54270                           TS       DSPCOUNT                              
003943,000460: 
003944,000461: 01,2511           32517                           CAF      NOMTMLST                              #  SET UP NOMINAL DOWNLINK LIST.
003945,000462: 01,2512           54411                           TS       DNLSTADR                              
003946,000463: 
003947,000464: 01,2513           00120                           TC       BUF                                   
003948,000465: 
003949,000466: 01,2514           00035        IFAILINH           OCT      35                                    #  ISS FAILURE INHIBIT BITS.
003950,000467: 01,2515           02124        LDNPHAS1           GENADR   DNPHASE1                              
003951,000468: 01,2516           03401        LDNTMGO            ECADR    DNTMGOTO                              
003952,000469: 01,2517           02354        NOMTMLST           GENADR   NOMDNLST                              
003953,000470: 

Page 87

003955,000472: 01,2520           02102        LESCHK             GENADR   SELFCHK                               
003956,000473: 01,2521           02013        LLMPRS2            GENADR   LMPRESET                              
003957,000474: 01,2522           00431        VAC1ADRC           ADRES    VAC1USE                               
003958,000475: 01,2523           00054        LTHVACA            DEC      44         B-14                       
003959,000476: 
003960,000477: 01,2524           01400        STARTEB            ECADR    LST1                                  
003961,000478: 01,2525     7760               NUMGRPS            EQUALS   FIVE                                  #  SIX GROUPS CURRENTLY.
003962,000479: 
003963,000480:                                                                                                  #           WHERE TO GO ON RESTART IF TERMINATE REQUESTED.
003964,000481: 
003965,000482: 01,2525           77755        -ELR               OCT      -22                                   #  -ERROR LIGHT RESET KEY CODE.
003966,000483: 01,2526           77757        -MKREJ             OCT      -20                                   #  - MARK REJECT.
003967,000484: 01,2527           37411        IM30INIF           OCT      37411                                 #  INHIBITS IMU FAIL FOR 5 SEC AND PIP ISSW
003968,000485: 01,2530           37400        IM30INIR           OCT      37400                                 #  LEAVE FAIL INHIBITS ALONE.
003969,000486: 
003970,000487: 01,2531           16000        IM33INIT           OCT      16000                                 #  NO PIP OR TM FAIL SIGNALS.
003971,000488: 01,2532           00440        9,6                OCT      440                                   #  MASK FOR PROG ALARM AND GIMBAL LOCK.
003972,000489: 01,2533           00102        RMODINIT           OCT      00102                                 
003973,000490: 
003974,000491: 01,2534  E6,1541                                  EBANK=   DT                                    
003975,000492: 01,2534           02136 34006  IDLEADR            2CADR    DAPIDLER                              
003976,000493: 01,2536  E6,1541                                  EBANK=   DT                                    
003977,000494: 01,2536           03620 34006  SETADR             2CADR    SETIDLE                               
003978,000495: 
003979,000496: 01,2540           00000        SWINIT             OCT      0                                     
003980,000497: 01,2541           00000                           OCT      0                                     
003981,000498: 01,2542           00005                           OCT      00005                                 
003982,000499: 01,2543           44516                           OCT      44516                                 #  INIT FOR DAPBOOLS. DB SET IN SETIDLE.
003983,000500: 01,2544           00000                           OCT      0                                     
003984,000501: 01,2545           00000                           OCT      0                                     
003985,000502: 01,2546           00000                           OCT      0                                     
003986,000503: 01,2547           00000                           OCT      0                                     
003987,000504: 

Page 88

003989,000506:                                                                                                  #  PROGRAM TO REVERT TO IDLING MODE (P 00).
003990,000507: 
003991,000508:                                                                                                  #  CALLING SEQUENCE:  TC (OR TCF)   POOH     UNDER EXEC (NOT INTERRUPTED).
003992,000509: 
003993,000510:    4261                                           BLOCK    02                                    
003994,000511:    4261           05243        POOH               TC       POSTJUMP                              
003995,000512:    4262           02550                           CADR     POOH2                                 #  DO A PARTIAL FRESH START.
003996,000513: 
003997,000514: 
003998,000515: 01,2550                                           BANK     01                                    
003999,000516: 
004000,000517: 01,2550           00004        POOH2              INHINT                                         
004001,000518: 01,2551           02326                           TC       STARTSB2                              #  DOESN'T CLOBBER DOWNLINK.
004002,000519: 
004003,000520: 01,2552           06045                           TC       FLAG2DWN                              
004004,000521: 01,2553           00020                           OCT      20                                    #  TURN OFF MISSION TIMER FLAG
004005,000522: 
004006,000523:                                                                                                  #    ***** HERE WE SHOULD RESET STATE REGISTERS, DEAL WITH DAP, ETC. *****
004007,000524: 
004008,000525: 01,2554           32556                           CA       LPOOH3                                #  PICK UP RETURN FOR MSTART.
004009,000526: 01,2555           05174                           TC       MSTART     -1                         #  START MISSION TIMERS COUNTING.
004010,000527:                                                                                                  #  WE GET A RELINT AT MSTART.
004011,000528: 
004012,000529: 
004013,000530: 01,2556           02061        LPOOH3             ADRES    POOH3                                 
004014,000531: 07,2000                                           BANK     7                                     
004015,000532: 
004016,000533: 07,2000           00004        FORGETIT           INHINT                                         #  THIS IS ALSO DOV74
004017,000534: 07,2001           00006                           EXTEND                                         
004018,000535: 07,2002           32047                           DCA      KILLCAD                               
004019,000536: 07,2003           53075                           DXCH     DVMNEXIT                              
004020,000537: 
004021,000538: 07,2004           00006                           EXTEND                                         
004022,000539: 07,2005           32045                           DCA      CADAVER                               
004023,000540: 07,2006           53073                           DXCH     AVGEXIT                               
004024,000541: 
004025,000542: 07,2007           32050                           CAF      PINGSMON                              
004026,000543: 07,2010           55322                           TS       DVSELECT                              
004027,000544: 
004028,000545: 07,2011           06071                           TC       ENGINOFF                              
004029,000546: 
004030,000547: 07,2012           42051                           CS       BGIMBALS                              #  TURN OFF TRIM GIMBALS
004031,000548: 07,2013           00006                           EXTEND                                         
004032,000549: 07,2014           03012                           WAND     12                                    
004033,000550: 
004034,000551: 07,2015           00004        ENEMA              INHINT                                         
004035,000552: 07,2016           37761                           CAF      ZERO                                  #  MAKE INACTIVE ALL RESTART PHASES
004036,000553: 07,2017           55100                           TS       PHASE1                                #  EXCEPT SERVICER
004037,000554: 

Page 89

004039,000556: 07,2020           55102                           TS       PHASE2                                
004040,000557: 07,2021           55104                           TS       PHASE3                                
004041,000558: 
004042,000559: 07,2022           55106                           TS       PHASE4                                
004043,000560: 07,2023           55112                           TS       PHASE6                                
004044,000561: 
004045,000562: 07,2024           40000                           COM                                            
004046,000563: 07,2025           55077                           TS       -PHASE1                               
004047,000564: 07,2026           55101                           TS       -PHASE2                               
004048,000565: 07,2027           55103                           TS       -PHASE3                               
004049,000566: 07,2030           55105                           TS       -PHASE4                               
004050,000567: 07,2031           55111                           TS       -PHASE6                               
004051,000568: 
004052,000569: 07,2032           55176                           TS       MPHASE1                               #  SET TIMER/PHASE PAIRS TO IDLE STATE
004053,000570: 07,2033           55175                           TS       MPHASE2                               
004054,000571: 07,2034           55174                           TS       MPHASE3                               
004055,000572: 07,2035           55173                           TS       MPHASE4                               
004056,000573: 07,2036           55167                           TS       MTIMER4                               
004057,000574: 07,2037           55170                           TS       MTIMER3                               
004058,000575: 07,2040           55171                           TS       MTIMER2                               
004059,000576: 07,2041           55172                           TS       MTIMER1                               
004060,000577: 
004061,000578:                                                                                                  #  START TASK TO RESET LMP COMMANDS HERE AND OTHER CLEANUP PROBLEMS
004062,000579: 07,2042           05243                           TC       POSTJUMP                              
004063,000580: 07,2043           02145                           CADR     GOPROG     +3                         
004064,000581: 
004065,000582: 07,2044  E3,1400                                  EBANK=   LST1                                  
004066,000583: 07,2044           02312 60063  CADAVER            2CADR    SERVEXIT                              
004067,000584: 
004068,000585: 07,2046  E3,1400                                  EBANK=   LST1                                  
004069,000586: 07,2046           02052 16003  KILLCAD            2CADR    AVEGKILL                              
004070,000587: 
004071,000588: 07,2050           02156        PINGSMON           GENADR   PGNCSMON                              
004072,000589: 07,2051           07400        BGIMBALS           OCT      7400                                  
004073,000590: 
004074,000591: 07,2052           06036        AVEGKILL           TC       FLAG1DWN                              #  COMES HERE WHEN ENGINE OFF
004075,000592: 07,2053           00001                           OCT      1                                     
004076,000593:                                                                                                  #  SERVICER GOES TO POOH AND ENABLES TIMERS AT DEAD END.  ALL PROGRAMS MUSTTURN OFF PIPAS AT END OF MISSION PHASE
004077,000594: 07,2054           15605                           TCF      ENDOFJOB                              
004078,000595: 
004079,000596: 07,2055           25360        FAKESTRT           INCR     REDOCTR                               #  FAKESTRT ALARM
004080,000597: 07,2056           04744                           TC       ALARM                                 
004081,000598: 07,2057           00316                           OCT      0316                                  
004082,000599: 
004083,000600: 07,2060           12000                           TCF      FORGETIT                              
004084,000601: 
004085,000602: 07,2061  07,2000               DOV74              EQUALS   FORGETIT                              

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