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 Linden Sims. 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:

	GAP:  ASSEMBLE REVISION 56 OF AGC PROGRAM ZERLINA BY ZOROASTER
	9:12 OCT. 21,1970
Note that the date is the date of the printout, not the date of the program revision.

056572,000002:                                                                                                  ## Copyright:   Public domain.
056573,000003:                                                                                                  ## Filename:    RESTARTS_ROUTINE.agc
056574,000004:                                                                                                  ## Purpose:     A log section of Zerlina 56, the final revision of
056575,000005:                                                                                                  ##              Don Eyles's offline development program for the variable 
056576,000006:                                                                                                  ##              guidance period servicer. It also includes a new P66 with LPD 
056577,000007:                                                                                                  ##              (Landing Point Designator) capability, based on an idea of John 
056578,000008:                                                                                                  ##              Young's. Neither of these advanced features were actually flown,
056579,000009:                                                                                                  ##              but Zerlina was also the birthplace of other big improvements to
056580,000010:                                                                                                  ##              Luminary including the terrain model and new (Luminary 1E)
056581,000011:                                                                                                  ##              analog display programs. Zerlina was branched off of Luminary 145,
056582,000012:                                                                                                  ##              and revision 56 includes all changes up to and including Luminary
056583,000013:                                                                                                  ##              183. It is therefore quite close to the Apollo 14 program,
056584,000014:                                                                                                  ##              Luminary 178, where not modified with new features.
056585,000015:                                                                                                  ## Reference:   pp. 1292-1297
056586,000016:                                                                                                  ## Assembler:   yaYUL
056587,000017:                                                                                                  ## Contact:     Ron Burkey <info@sandroid.org>.
056588,000018:                                                                                                  ## Website:     www.ibiblio.org/apollo/index.html
056589,000019:                                                                                                  ## Mod history: 2017-07-28 MAS  Created from Luminary 210.
056590,000020:                                                                                                  ##              2017-08-29 RSB  Transcribed.
056591,000021: 

Page 1292

056593,000023: 01,3530                                           BANK     01                                    
056594,000024: 01,2000                                           SETLOC   RESTART                               
056595,000025: 01,2000                                           BANK                                           
056596,000026: 
056597,000027: 01,3530  E3,1436                                  EBANK=   PHSNAME1                              #  GOPROG MUST SWITCH TO THIS EBANK
056598,000028: 
056599,000029: 01,3530                                           COUNT*   $$/RSROU                              
056600,000030: 01,3530           30161        RESTARTS           CA       MPAC       +5                         #  GET GROUP NUMBER -1
056601,000031: 01,3531           60000                           DOUBLE                                         #  SAVE FOR INDEXING
056602,000032: 01,3532           54155                           TS       TEMP2G                                
056603,000033: 
056604,000034: 01,3533           33772                           CA       PHS2CADR                              #  SET UP EXIT IN CASE IT IS AN EVEN
056605,000035: 01,3534           54157                           TS       TEMPSWCH                              #  TABLE PHASE
056606,000036: 
056607,000037: 01,3535           33567                           CA       RTRNCADR                              #  TO SAVE TIME ASSUME IT WILL GET NEXT
056608,000038: 01,3536           54707                           TS       GOLOC      +2                         #  GROUP AFTER THIS
056609,000039: 
056610,000040: 01,3537           30154                           CA       TEMPPHS                               
056611,000041: 01,3540           75007                           MASK     OCT1400                               
056612,000042: 01,3541           10000                           CCS      A                                     #  IS IT A VARIABLE OR TABLE RESTART
056613,000043: 01,3542           13553                           TCF      ITSAVAR                               #  IT:S A VARIABLE RESTART
056614,000044: 
056615,000045: 01,3543           10154        GETPART2           CCS      TEMPPHS                               #  IS IT AN X.1 RESTART
056616,000046: 01,3544           10000                           CCS      A                                     
056617,000047: 01,3545           13653                           TCF      ITSATBL                               #  NO, ITS A TABLE RESTART
056618,000048: 
056619,000049: 01,3546           35024                           CA       PRIO14                                #  IT IS AN X.1 RESTART, THEREFORE START
056620,000050: 01,3547           05105                           TC       FINDVAC                               #  THE DISPLAY RESTART JOB
056621,000051: 01,3550  E3,1400                                  EBANK=   LST1                                  
056622,000052: 01,3550           03040 20103                     2CADR    INITDSP                               
056623,000053: 
056624,000054: 01,3552           03567                           TC       RTRNCADR                              #  FINISHED WITH THIS GROUP, GET NEXT ONE
056625,000055: 
056626,000056: 01,3553           75007        ITSAVAR            MASK     OCT1400                               #  IS IT TYPE B ?
056627,000057: 01,3554           10000                           CCS      A                                     
056628,000058: 01,3555           13624                           TCF      ITSLIKEB                              #  YES,IT IS TYPE B
056629,000059: 
056630,000060: 01,3556           00006                           EXTEND                                         #  STORE THE JOB (OR TASK) 2CADR FOR EXIT
056631,000061: 01,3557           50155                           NDX      TEMP2G                                
056632,000062: 01,3560           31437                           DCA      PHSNAME1                              
056633,000063: 01,3561           52706                           DXCH     GOLOC                                 
056634,000064: 
056635,000065: 01,3562           30154                           CA       TEMPPHS                               #  SEE IF THIS IS A JOB, TASK, OR A LONGCAL
056636,000066: 01,3563           74757                           MASK     OCT7                                  
056637,000067: 01,3564           67760                           AD       MINUS2                                
056638,000068: 01,3565           10000                           CCS      A                                     
056639,000069: 01,3566           13736                           TCF      ITSLNGCL                              #  ITS A LONGCALL
056640,000070: 
056641,000071: 01,3567           04631        RTRNCADR           TC       SWRETURN                              #  CANT GET HERE
056642,000072: 

Page 1293

056644,000074: 01,3570           13572                           TCF      ITSAWAIT                              
056645,000075: 
056646,000076: 01,3571           13637                           TCF      ITSAJOB                               #  ITS A JOB
056647,000077: 
056648,000078: 01,3572           34352        ITSAWAIT           CA       WTLTCADR                              #  SET UP WAITLIST CALL
056649,000079: 01,3573           54704                           TS       GOLOC      -1                         
056650,000080: 
056651,000081: 01,3574           50155                           NDX      TEMP2G                                #  DIRECTLY STORED
056652,000082: 01,3575           31053                           CA       PHSPRDT1                              
056653,000083: 01,3576           10000        TIMETEST           CCS      A                                     #  IS IT AN IMMEDIATE RESTART
056654,000084: 01,3577           24000                           INCR     A                                     #  NO,
056655,000085: 01,3600           13603                           TCF      FINDTIME                              #  FIND OUT WHEN IT SHOULD BEGIN
056656,000086: 
056657,000087: 01,3601           15447                           TCF      ITSINDIR                              #  STORED INDIRECTLY
056658,000088: 
056659,000089: 01,3602           13622                           TCF      IMEDIATE                              #  IT WANTS AN IMMEDIATE RESTART
056660,000090: 
056661,000091:                                                                                                  #  ***** THIS MUST BE IN FIXED FIXED *****
056662,000092: 
056663,000093:    5447                                           BLOCK    02                                    
056664,000094:    4000                                           SETLOC   FFTAG2                                
056665,000095:    4000                                           BANK                                           
056666,000096: 
056667,000097:    5447                                           COUNT*   $$/RSROU                              
056668,000098:    5447           22706        ITSINDIR           LXCH     GOLOC      +1                         #  GET THE CORRECT E BANK IN CASE THIS IS
056669,000099:    5450           22006                           LXCH     BB                                    #  SWITCHED ERRASIBLE
056670,000100: 
056671,000101:    5451           50000                           NDX      A                                     #  GET THE TIME INDIRECTLY
056672,000102:    5452           30001                           CA       1                                     
056673,000103: 
056674,000104:    5453           22006                           LXCH     BB                                    #  RESTORE THE BB AND GOLOC
056675,000105:    5454           22706                           LXCH     GOLOC      +1                         
056676,000106: 
056677,000107:    5455           13603                           TCF      FINDTIME                              #  FIND OUT WHEN IT SHOULD BEGIN
056678,000108: 
056679,000109:                                                                                                  #  ***** YOU  MAY RETURN TO  SWITCHED FIXED *****
056680,000110: 
056681,000111: 01,3603                                           BANK     01                                    
056682,000112: 01,2000                                           SETLOC   RESTART                               
056683,000113: 01,2000                                           BANK                                           
056684,000114: 
056685,000115: 01,3603                                           COUNT*   $$/RSROU                              
056686,000116: 01,3603           40000        FINDTIME           COM                                            #  MAKE NEGITIVE SINCE IT WILL BE SUBTRACTD
056687,000117: 01,3604           54001                           TS       L                                     #  AND SAVE
056688,000118: 01,3605           50155                           NDX      TEMP2G                                
056689,000119: 01,3606           41052                           CS       TBASE1                                
056690,000120: 01,3607           00006                           EXTEND                                         
056691,000121: 01,3610           60025                           SU       TIME1                                 
056692,000122: 01,3611           10000                           CCS      A                                     
056693,000123: 01,3612           40000                           COM                                            
056694,000124: 

Page 1294

056696,000126: 01,3613           67743                           AD       OCT37776                              
056697,000127: 01,3614           64753                           AD       ONE                                   
056698,000128: 01,3615           60001                           AD       L                                     
056699,000129: 01,3616           10000                           CCS      A                                     
056700,000130: 01,3617           34755                           CA       ZERO                                  
056701,000131: 01,3620           13622                           TCF      +2                                    
056702,000132: 01,3621           13622                           TCF      +1                                    
056703,000133: 01,3622           64753        IMEDIATE           AD       ONE                                   
056704,000134: 01,3623           00704                           TC       GOLOC      -1                         
056705,000135: 01,3624           33567        ITSLIKEB           CA       RTRNCADR                              #  TYPE B,             SO STORE RETURN IN
056706,000136: 01,3625           54157                           TS       TEMPSWCH                              #  TEMPSWCH IN CASE OF AN EVEN PHASE
056707,000137: 
056708,000138: 01,3626           33773                           CA       PRT2CADR                              #  SET UP EXIT TO GET TABLE PART OF THIS
056709,000139: 01,3627           54707                           TS       GOLOC      +2                         #  VARIABLE TYPE OF PHASE
056710,000140: 
056711,000141: 01,3630           30154                           CA       TEMPPHS                               #  MAKE THE PHASE LOOK RIGHT FOR THE TABLE
056712,000142: 01,3631           76106                           MASK     OCT177                                #  PART OF THIS VARIABLE PHASE
056713,000143: 01,3632           54154                           TS       TEMPPHS                               
056714,000144: 
056715,000145: 01,3633           00006                           EXTEND                                         
056716,000146: 01,3634           50155                           NDX      TEMP2G                                #  OBTAIN THE JOB:S 2CADR
056717,000147: 01,3635           31437                           DCA      PHSNAME1                              
056718,000148: 01,3636           52706                           DXCH     GOLOC                                 
056719,000149: 
056720,000150: 01,3637           50155        ITSAJOB            NDX      TEMP2G                                #  NOW ADD THE PRIORITY AND LET:S GO
056721,000151: 01,3640           31053                           CA       PHSPRDT1                              
056722,000152: 01,3641           54704        CHKNOVAC           TS       GOLOC      -1                         #  SAVE PRIO UNTIL WE SEE IF ITS
056723,000153: 01,3642           00006                           EXTEND                                         #  A FINDVAC OR A NOVAC
056724,000154: 01,3643           63647                           BZMF     ITSNOVAC                              
056725,000155: 
056726,000156: 01,3644           34354                           CAF      FVACCADR                              #  POSITIVE, SET UP FINDVAC CALL.
056727,000157: 01,3645           56704                           XCH      GOLOC      -1                         #  PICK UP PRIO,
056728,000158: 01,3646           00704                           TC       GOLOC      -1                         #  AND GO
056729,000159: 
056730,000160: 01,3647           34351        ITSNOVAC           CAF      NOVACADR                              #  NEGATIVE,
056731,000161: 01,3650           56704                           XCH      GOLOC      -1                         #  SET UP NOVAC CALL,
056732,000162: 01,3651           40000                           COM                                            #  CORRECT PRIO,
056733,000163: 01,3652           00704                           TC       GOLOC      -1                         #  AND GO
056734,000164: 
056735,000165: 01,3653           54020        ITSATBL            TS       CYR                                   #  FIND OUT IF THE PHASE IS ODD OR EVEN
056736,000166: 01,3654           10020                           CCS      CYR                                   
056737,000167: 01,3655           13656                           TCF      +1                                    #  IT:S EVEN
056738,000168: 01,3656           13754                           TCF      ITSEVEN                               
056739,000169: 
056740,000170: 01,3657           33567                           CA       RTRNCADR                              #  IN CASE THIS IS THE SECOND PART OF A
056741,000171: 01,3660           54707                           TS       GOLOC      +2                         #  TYPE B RESTART, WE NEED PROPER EXIT
056742,000172: 
056743,000173: 01,3661           30154                           CA       TEMPPHS                               #  SET UP POINTER FOR FINDING OUR PLACE IN
056744,000174: 01,3662           54021                           TS       SR                                    #  THE RESTART TABLES
056745,000175: 01,3663           60021                           AD       SR                                    
056746,000176: 

Page 1295

056748,000178: 01,3664           50155                           NDX      TEMP2G                                
056749,000179: 01,3665           62003                           AD       SIZETAB    +1                         
056750,000180: 01,3666           54156                           TS       POINTER                               
056751,000181: 
056752,000182: 01,3667           00006        CONTBL2            EXTEND                                         #  FIND OUT WHAT:S IN THE TABLE
056753,000183: 01,3670           50156                           NDX      POINTER                               
056754,000184: 01,3671           32002                           DCA      CADRTAB                               #  GET THE 2CADR
056755,000185: 
056756,000186: 01,3672           22706                           LXCH     GOLOC      +1                         #  STORE THE BB INFORMATION
056757,000187: 
056758,000188: 01,3673           10000                           CCS      A                                     #  IS IT A JOB OR IS IT  TIMED
056759,000189: 01,3674           24000                           INCR     A                                     #  POSITIVE, MUST BE A JOB
056760,000190: 01,3675           13750                           TCF      ITSAJOB2                              
056761,000191: 
056762,000192: 01,3676           24000                           INCR     A                                     #  MUST BE EITHER A WAITLIST OR LONGCALL
056763,000193: 01,3677           54705                           TS       GOLOC                                 #  LET-S STORE THE CORRECT CADR
056764,000194: 
056765,000195: 01,3700           34352                           CA       WTLTCADR                              #  SET UP OUR EXIT TO WAITLIST
056766,000196: 01,3701           54704                           TS       GOLOC      -1                         
056767,000197: 
056768,000198: 01,3702           30706                           CA       GOLOC      +1                         #  NOW FIND OUT IF IT IS A WAITLIST CALL
056769,000199: 01,3703           74742                           MASK     BIT10                                 #  THIS SHOULD BE ONE IF WE HAVE -BB
056770,000200: 01,3704           10000                           CCS      A                                     #  FOR THAT MATTER SO SHOULD BE BITS 9,8,7,
056771,000201:                                                                                                  #  6,5, AND LAST BUT NOT LEAST (PERHAPS NOT
056772,000202:                                                                                                  #  IN IMPORTANCE ANYWAY. BIT 4
056773,000203: 01,3705           13743                           TCF      ITSWTLST                              #  IT IS A WAITLIST CALL
056774,000204: 
056775,000205: 01,3706           50156                           NDX      POINTER                               #  OBTAIN THE ORIGINAL DELTA T
056776,000206: 01,3707           32000                           CA       PRDTTAB                               #  ADDRESS FOR THIS LONGCALL
056777,000207: 
056778,000208: 01,3710           15456                           TCF      ITSLGCL1                              #  NOW GO GET THE DELTA TIME
056779,000209: 
056780,000210:                                                                                                  #  ***** THIS MUST BE IN FIXED FIXED *****
056781,000211: 
056782,000212:    5456                                           BLOCK    02                                    
056783,000213:    4000                                           SETLOC   FFTAG2                                
056784,000214:    4000                                           BANK                                           
056785,000215: 
056786,000216:    5456                                           COUNT*   $$/RSROU                              
056787,000217:    5456           22706        ITSLGCL1           LXCH     GOLOC      +1                         #  OBTAIN THE CORRECT E BANK
056788,000218:    5457           22006                           LXCH     BB                                    
056789,000219:    5460           22706                           LXCH     GOLOC      +1                         #  AND PRESERVE OUR E AND F BANKS
056790,000220: 
056791,000221:    5461           00006                           EXTEND                                         #  GET THE DELTA TIME
056792,000222:    5462           50000                           NDX      A                                     
056793,000223:    5463           30001                           DCA      0                                     
056794,000224: 
056795,000225:    5464           22706                           LXCH     GOLOC      +1                         #  RESTORE OUR E AND F BANK
056796,000226:    5465           22006                           LXCH     BB                                    #  RESTORE THE TASKS E AND F BANKS
056797,000227:    5466           22706                           LXCH     GOLOC      +1                         #  AND PRESERVE OUR L
056798,000228: 

Page 1296

056800,000230:    5467           13711                           TCF      ITSLGCL2                              #  NOW LET:S PROCESS THIS LONGCALL
056801,000231: 
056802,000232:                                                                                                  #  ***** YOU  MAY RETURN  TO SWITCHED FIXED *****
056803,000233: 
056804,000234: 01,3711                                           BANK     01                                    
056805,000235: 01,2000                                           SETLOC   RESTART                               
056806,000236: 01,2000                                           BANK                                           
056807,000237: 
056808,000238: 01,3711                                           COUNT*   $$/RSROU                              
056809,000239: 01,3711           53153        ITSLGCL2           DXCH     LONGTIME                              
056810,000240: 
056811,000241: 01,3712           00006                           EXTEND                                         #  CALCULATE TIME LEFT
056812,000242: 01,3713           40025                           DCS      TIME2                                 
056813,000243: 01,3714           21153                           DAS      LONGTIME                              
056814,000244: 01,3715           00006                           EXTEND                                         
056815,000245: 01,3716           31151                           DCA      LONGBASE                              
056816,000246: 01,3717           21153                           DAS      LONGTIME                              
056817,000247: 
056818,000248: 01,3720           11152                           CCS      LONGTIME                              #  FIND OUT HOW THIS SHOULD BE RESTARTED
056819,000249: 01,3721           13731                           TCF      LONGCLCL                              
056820,000250: 01,3722           13724                           TCF      +2                                    
056821,000251: 01,3723           13617                           TCF      IMEDIATE   -3                         
056822,000252: 01,3724           11153                           CCS      LONGTIME   +1                         
056823,000253: 01,3725           13731                           TCF      LONGCLCL                              
056824,000254: 01,3726           13727                           NOOP                                           #  CAN:T GET HERE    *********
056825,000255: 01,3727           13617                           TCF      IMEDIATE   -3                         
056826,000256: 01,3730           13622                           TCF      IMEDIATE                              
056827,000257: 
056828,000258: 01,3731           33774        LONGCLCL           CA       LGCLCADR                              #  WE WILL GO TO LONGCALL
056829,000259: 01,3732           54704                           TS       GOLOC      -1                         
056830,000260: 
056831,000261: 01,3733           00006                           EXTEND                                         #  PREPARE OUR ENTRY TO LONGCALL
056832,000262: 01,3734           31153                           DCA      LONGTIME                              
056833,000263: 01,3735           00704                           TC       GOLOC      -1                         
056834,000264: 
056835,000265: 01,3736           34352        ITSLNGCL           CA       WTLTCADR                              #  ASSUME IT WILL GO TO WAITLIST
056836,000266: 01,3737           54704                           TS       GOLOC      -1                         
056837,000267: 
056838,000268: 01,3740           50155                           NDX      TEMP2G                                
056839,000269: 01,3741           41053                           CS       PHSPRDT1                              #  GET THE DELTA T ADDRESS
056840,000270: 
056841,000271: 01,3742           15456                           TCF      ITSLGCL1                              #  NOW GET THE DELTA TIME
056842,000272: 
056843,000273: 01,3743           40706        ITSWTLST           CS       GOLOC      +1                         #  CORRECT THE BBCON INFORMATION
056844,000274: 01,3744           54706                           TS       GOLOC      +1                         
056845,000275: 
056846,000276: 01,3745           50156                           NDX      POINTER                               #  GET THE DT AND FIND OUT IF IT WAS STORED
056847,000277: 01,3746           32000                           CA       PRDTTAB                               #  DIRECTLY OR INDIRECTLY
056848,000278: 
056849,000279: 01,3747           13576                           TCF      TIMETEST                              #  FIND OUT HOW THE TIME IS STORED
056850,000280: 

Page 1297

056852,000282: 01,3750           56705        ITSAJOB2           XCH      GOLOC                                 #  STORE THE CADR
056853,000283: 
056854,000284: 01,3751           50156                           NDX      POINTER                               #  ADD THE PRIORITY AND LET:S GO
056855,000285: 01,3752           32000                           CA       PRDTTAB                               
056856,000286: 
056857,000287: 01,3753           13641                           TCF      CHKNOVAC                              
056858,000288: 
056859,000289: 01,3754           30157        ITSEVEN            CA       TEMPSWCH                              #  SET UP FOR EITHER THE SECOND PART OF THE
056860,000290: 01,3755           54707                           TS       GOLOC      +2                         #  TABLE, OR A RETURN FOR THE NEXT GROUP
056861,000291: 
056862,000292: 01,3756           50155                           NDX      TEMP2G                                #  SET UP POINTER FOR OUR LOCATION WITHIN
056863,000293: 01,3757           32002                           CA       SIZETAB                               #  THE TABLE
056864,000294: 01,3760           60154                           AD       TEMPPHS                               #  THIS MAY LOOK BAD BUT LET:S SEE YOU DO
056865,000295: 01,3761           60154                           AD       TEMPPHS                               #  BETTER IN TIME OR NUMBERR OF LOCATIONS
056866,000296: 01,3762           60154                           AD       TEMPPHS                               
056867,000297: 01,3763           54156                           TS       POINTER                               
056868,000298: 
056869,000299: 01,3764           13667                           TCF      CONTBL2                               #  NOW PROCESS WHAT IS IN THE TABLE
056870,000300: 
056871,000301: 01,3765           36257        PHSPART2           CA       THREE                                 #  SET THE POINTER FOR THE SECOND HALF OF
056872,000302: 01,3766           26156                           ADS      POINTER                               #  THE TABLE
056873,000303: 
056874,000304: 01,3767           33567                           CA       RTRNCADR                              #  THIS WILL BE OUR LAST TIME THROUGH THE
056875,000305: 01,3770           54707                           TS       GOLOC      +2                         #  EVEN TABLE , SO AFTER IT  GET THE NEXT
056876,000306:                                                                                                  #  GROUP
056877,000307: 01,3771           13667                           TCF      CONTBL2                               #  SO LET:S GET THE SECOND ENTRY IN THE TBL
056878,000308: 
056879,000309: 01,3772     0154               TEMPPHS            EQUALS   MPAC                                  
056880,000310: 01,3772     0155               TEMP2G             EQUALS   MPAC       +1                         
056881,000311: 01,3772     0156               POINTER            EQUALS   MPAC       +2                         
056882,000312: 01,3772     0157               TEMPSWCH           EQUALS   MPAC       +3                         
056883,000313: 01,3772     7760               MINUS2             EQUALS   NEG2                                  
056884,000314: 01,3772     6106               OCT177             EQUALS   LOW7                                  
056885,000315: 
056886,000316: 01,3772           03765        PHS2CADR           GENADR   PHSPART2                              
056887,000317: 01,3773           03543        PRT2CADR           GENADR   GETPART2                              
056888,000318: 01,3774           05310        LGCLCADR           GENADR   LONGCALL                              
056889,000319: 01,3775     4354               FVACCADR           =        TCFINDVC                              
056890,000320: 01,3775     4352               WTLTCADR           =        TCWAIT                                
056891,000321: 01,3775     4351               NOVACADR           =        TCNOVAC                               
056892,000322: 
056893,000323: 

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