Source Code

### FILE="RESTARTS_ROUTINE.agc" ## Copyright: Public domain. ## Filename: RESTARTS_ROUTINE.agc ## Purpose: A section of Luminary revision 210. ## It is part of the source code for the Lunar Module's (LM) ## Apollo Guidance Computer (AGC) for Apollo 15-17. ## This file is intended to be a faithful transcription, except ## that the code format has been changed to conform to the ## requirements of the yaYUL assembler rather than the ## original YUL assembler. ## Reference: pp. 1300-1305 ## Assembler: yaYUL ## Contact: Ron Burkey . ## Website: www.ibiblio.org/apollo/index.html ## Mod history: 2016-11-17 JL Created from Luminary131 version. ## 2016-12-03 JS Compared to Luminary210 images. Updated where needed. ## 2016-12-26 RSB Comment-text proofed using ProoferComments ## and corrected errors found. ## 2017-03-14 RSB Comment-text fixes noted in proofing Luminary 116. ## Page 1300 BANK 01 SETLOC RESTART BANK EBANK= PHSNAME1 # GOPROG MUST SWITCH TO THIS EBANK COUNT* $$/RSROU RESTARTS CA MPAC +5 # GET GROUP NUMBER -1 DOUBLE # SAVE FOR INDEXING TS TEMP2G CA PHS2CADR # SET UP EXIT IN CASE IT IS AN EVEN TS TEMPSWCH # TABLE PHASE CA RTRNCADR # TO SAVE TIME ASSUME IT WILL GET NEXT TS GOLOC +2 # GROUP AFTER THIS CA TEMPPHS MASK OCT1400 CCS A # IS IT A VARIABLE OR TABLE RESTART TCF ITSAVAR # IT:S A VARIABLE RESTART GETPART2 CCS TEMPPHS # IS IT AN X.1 RESTART CCS A TCF ITSATBL # NO, ITS A TABLE RESTART CA PRIO14 # IT IS AN X.1 RESTART, THEREFORE START TC FINDVAC # THE DISPLAY RESTART JOB EBANK= LST1 2CADR INITDSP TC RTRNCADR # FINISHED WITH THIS GROUP, GET NEXT ONE ITSAVAR MASK OCT1400 # IS IT TYPE B ? CCS A TCF ITSLIKEB # YES,IT IS TYPE B EXTEND # STORE THE JOB (OR TASK) 2CADR FOR EXIT NDX TEMP2G DCA PHSNAME1 DXCH GOLOC CA TEMPPHS # SEE IF THIS IS A JOB, TASK, OR A LONGCAL MASK OCT7 AD MINUS2 CCS A TCF ITSLNGCL # ITS A LONGCALL RTRNCADR TC SWRETURN # CANT GET HERE ## Page 1301 TCF ITSAWAIT TCF ITSAJOB # ITS A JOB ITSAWAIT CA WTLTCADR # SET UP WAITLIST CALL TS GOLOC -1 NDX TEMP2G # DIRECTLY STORED CA PHSPRDT1 TIMETEST CCS A # IS IT AN IMMEDIATE RESTART INCR A # NO, TCF FINDTIME # FIND OUT WHEN IT SHOULD BEGIN TCF ITSINDIR # STORED INDIRECTLY TCF IMEDIATE # IT WANTS AN IMMEDIATE RESTART # ***** THIS MUST BE IN FIXED FIXED ***** BLOCK 02 SETLOC FFTAG2 BANK COUNT* $$/RSROU ITSINDIR LXCH GOLOC +1 # GET THE CORRECT E BANK IN CASE THIS IS LXCH BB # SWITCHED ERRASIBLE NDX A # GET THE TIME INDIRECTLY CA 1 LXCH BB # RESTORE THE BB AND GOLOC LXCH GOLOC +1 TCF FINDTIME # FIND OUT WHEN IT SHOULD BEGIN # ***** YOU MAY RETURN TO SWITCHED FIXED ***** BANK 01 SETLOC RESTART BANK COUNT* $$/RSROU FINDTIME COM # MAKE NEGITIVE SINCE IT WILL BE SUBTRACTD TS L # AND SAVE NDX TEMP2G CS TBASE1 EXTEND SU TIME1 CCS A COM ## Page 1302 AD OCT37776 AD ONE AD L CCS A CA ZERO TCF +2 TCF +1 IMEDIATE AD ONE TC GOLOC -1 ITSLIKEB CA RTRNCADR # TYPE B, SO STORE RETURN IN TS TEMPSWCH # TEMPSWCH IN CASE OF AN EVEN PHASE CA PRT2CADR # SET UP EXIT TO GET TABLE PART OF THIS TS GOLOC +2 # VARIABLE TYPE OF PHASE CA TEMPPHS # MAKE THE PHASE LOOK RIGHT FOR THE TABLE MASK OCT177 # PART OF THIS VARIABLE PHASE TS TEMPPHS EXTEND NDX TEMP2G # OBTAIN THE JOB:S 2CADR DCA PHSNAME1 DXCH GOLOC ITSAJOB NDX TEMP2G # NOW ADD THE PRIORITY AND LET:S GO CA PHSPRDT1 CHKNOVAC TS GOLOC -1 # SAVE PRIO UNTIL WE SEE IF ITS EXTEND # A FINDVAC OR A NOVAC BZMF ITSNOVAC CAF FVACCADR # POSITIVE, SET UP FINDVAC CALL. XCH GOLOC -1 # PICK UP PRIO, TC GOLOC -1 # AND GO ITSNOVAC CAF NOVACADR # NEGATIVE, XCH GOLOC -1 # SET UP NOVAC CALL, COM # CORRECT PRIO, TC GOLOC -1 # AND GO ITSATBL TS CYR # FIND OUT IF THE PHASE IS ODD OR EVEN CCS CYR TCF +1 # IT:S EVEN TCF ITSEVEN CA RTRNCADR # IN CASE THIS IS THE SECOND PART OF A TS GOLOC +2 # TYPE B RESTART, WE NEED PROPER EXIT CA TEMPPHS # SET UP POINTER FOR FINDING OUR PLACE IN TS SR # THE RESTART TABLES AD SR ## Page 1303 NDX TEMP2G AD SIZETAB +1 TS POINTER CONTBL2 EXTEND # FIND OUT WHAT:S IN THE TABLE NDX POINTER DCA CADRTAB # GET THE 2CADR LXCH GOLOC +1 # STORE THE BB INFORMATION CCS A # IS IT A JOB OR IS IT TIMED INCR A # POSITIVE, MUST BE A JOB TCF ITSAJOB2 INCR A # MUST BE EITHER A WAITLIST OR LONGCALL TS GOLOC # LET-S STORE THE CORRECT CADR CA WTLTCADR # SET UP OUR EXIT TO WAITLIST TS GOLOC -1 CA GOLOC +1 # NOW FIND OUT IF IT IS A WAITLIST CALL MASK BIT10 # THIS SHOULD BE ONE IF WE HAVE -BB CCS A # FOR THAT MATTER SO SHOULD BE BITS 9,8,7, # 6,5, AND LAST BUT NOT LEAST (PERHAPS NOT # IN IMPORTANCE ANYWAY. BIT 4 TCF ITSWTLST # IT IS A WAITLIST CALL NDX POINTER # OBTAIN THE ORIGINAL DELTA T CA PRDTTAB # ADDRESS FOR THIS LONGCALL TCF ITSLGCL1 # NOW GO GET THE DELTA TIME # ***** THIS MUST BE IN FIXED FIXED ***** BLOCK 02 SETLOC FFTAG2 BANK COUNT* $$/RSROU ITSLGCL1 LXCH GOLOC +1 # OBTAIN THE CORRECT E BANK LXCH BB LXCH GOLOC +1 # AND PRESERVE OUR E AND F BANKS EXTEND # GET THE DELTA TIME NDX A DCA 0 LXCH GOLOC +1 # RESTORE OUR E AND F BANK LXCH BB # RESTORE THE TASKS E AND F BANKS LXCH GOLOC +1 # AND PRESERVE OUR L ## Page 1304 TCF ITSLGCL2 # NOW LET:S PROCESS THIS LONGCALL # ***** YOU MAY RETURN TO SWITCHED FIXED ***** BANK 01 SETLOC RESTART BANK COUNT* $$/RSROU ITSLGCL2 DXCH LONGTIME EXTEND # CALCULATE TIME LEFT DCS TIME2 DAS LONGTIME EXTEND DCA LONGBASE DAS LONGTIME CCS LONGTIME # FIND OUT HOW THIS SHOULD BE RESTARTED TCF LONGCLCL TCF +2 TCF IMEDIATE -3 CCS LONGTIME +1 TCF LONGCLCL NOOP # CAN:T GET HERE ********* TCF IMEDIATE -3 TCF IMEDIATE LONGCLCL CA LGCLCADR # WE WILL GO TO LONGCALL TS GOLOC -1 EXTEND # PREPARE OUR ENTRY TO LONGCALL DCA LONGTIME TC GOLOC -1 ITSLNGCL CA WTLTCADR # ASSUME IT WILL GO TO WAITLIST TS GOLOC -1 NDX TEMP2G CS PHSPRDT1 # GET THE DELTA T ADDRESS TCF ITSLGCL1 # NOW GET THE DELTA TIME ITSWTLST CS GOLOC +1 # CORRECT THE BBCON INFORMATION TS GOLOC +1 NDX POINTER # GET THE DT AND FIND OUT IF IT WAS STORED CA PRDTTAB # DIRECTLY OR INDIRECTLY TCF TIMETEST # FIND OUT HOW THE TIME IS STORED ## Page 1305 ITSAJOB2 XCH GOLOC # STORE THE CADR NDX POINTER # ADD THE PRIORITY AND LET:S GO CA PRDTTAB TCF CHKNOVAC ITSEVEN CA TEMPSWCH # SET UP FOR EITHER THE SECOND PART OF THE TS GOLOC +2 # TABLE, OR A RETURN FOR THE NEXT GROUP NDX TEMP2G # SET UP POINTER FOR OUR LOCATION WITHIN CA SIZETAB # THE TABLE AD TEMPPHS # THIS MAY LOOK BAD BUT LET:S SEE YOU DO AD TEMPPHS # BETTER IN TIME OR NUMBERR OF LOCATIONS AD TEMPPHS TS POINTER TCF CONTBL2 # NOW PROCESS WHAT IS IN THE TABLE PHSPART2 CA THREE # SET THE POINTER FOR THE SECOND HALF OF ADS POINTER # THE TABLE CA RTRNCADR # THIS WILL BE OUR LAST TIME THROUGH THE TS GOLOC +2 # EVEN TABLE , SO AFTER IT GET THE NEXT # GROUP TCF CONTBL2 # SO LET:S GET THE SECOND ENTRY IN THE TBL TEMPPHS EQUALS MPAC TEMP2G EQUALS MPAC +1 POINTER EQUALS MPAC +2 TEMPSWCH EQUALS MPAC +3 MINUS2 EQUALS NEG2 OCT177 EQUALS LOW7 PHS2CADR GENADR PHSPART2 PRT2CADR GENADR GETPART2 LGCLCADR GENADR LONGCALL FVACCADR = TCFINDVC WTLTCADR = TCWAIT NOVACADR = TCNOVAC

056202,000002:                                                                                                  ## Copyright:   Public domain.
056203,000003:                                                                                                  ## Filename:    RESTARTS_ROUTINE.agc
056204,000004:                                                                                                  ## Purpose:     A section of Luminary revision 210.
056205,000005:                                                                                                  ##              It is part of the source code for the Lunar Module's (LM)
056206,000006:                                                                                                  ##              Apollo Guidance Computer (AGC) for Apollo 15-17.
056207,000007:                                                                                                  ##              This file is intended to be a faithful transcription, except
056208,000008:                                                                                                  ##              that the code format has been changed to conform to the
056209,000009:                                                                                                  ##              requirements of the yaYUL assembler rather than the
056210,000010:                                                                                                  ##              original YUL assembler.
056211,000011:                                                                                                  ## Reference:   pp. 1300-1305
056212,000012:                                                                                                  ## Assembler:   yaYUL
056213,000013:                                                                                                  ## Contact:     Ron Burkey <info@sandroid.org>.
056214,000014:                                                                                                  ## Website:     www.ibiblio.org/apollo/index.html
056215,000015:                                                                                                  ## Mod history: 2016-11-17 JL   Created from Luminary131 version.
056216,000016:                                                                                                  ##              2016-12-03 JS   Compared to Luminary210 images. Updated where needed.
056217,000017:                                                                                                  ##              2016-12-26 RSB  Comment-text proofed using ProoferComments
056218,000018:                                                                                                  ##                              and corrected errors found.
056219,000019:                                                                                                  ##              2017-03-14 RSB  Comment-text fixes noted in proofing Luminary 116.
056220,000020: 

Page 1300

056222,000022: 01,3530                                           BANK     01                                    
056223,000023: 01,2000                                           SETLOC   RESTART                               
056224,000024: 01,2000                                           BANK                                           
056225,000025: 
056226,000026: 01,3530  E3,1436                                  EBANK=   PHSNAME1                              #  GOPROG MUST SWITCH TO THIS EBANK
056227,000027: 
056228,000028: 01,3530                                           COUNT*   $$/RSROU                              
056229,000029: 01,3530           30161        RESTARTS           CA       MPAC       +5                         #  GET GROUP NUMBER -1
056230,000030: 01,3531           60000                           DOUBLE                                         #  SAVE FOR INDEXING
056231,000031: 01,3532           54155                           TS       TEMP2G                                
056232,000032: 
056233,000033: 01,3533           33772                           CA       PHS2CADR                              #  SET UP EXIT IN CASE IT IS AN EVEN
056234,000034: 01,3534           54157                           TS       TEMPSWCH                              #  TABLE PHASE
056235,000035: 
056236,000036: 01,3535           33567                           CA       RTRNCADR                              #  TO SAVE TIME ASSUME IT WILL GET NEXT
056237,000037: 01,3536           54707                           TS       GOLOC      +2                         #  GROUP AFTER THIS
056238,000038: 
056239,000039: 01,3537           30154                           CA       TEMPPHS                               
056240,000040: 01,3540           75000                           MASK     OCT1400                               
056241,000041: 01,3541           10000                           CCS      A                                     #  IS IT A VARIABLE OR TABLE RESTART
056242,000042: 01,3542           13553                           TCF      ITSAVAR                               #  IT:S A VARIABLE RESTART
056243,000043: 
056244,000044: 01,3543           10154        GETPART2           CCS      TEMPPHS                               #  IS IT AN X.1 RESTART
056245,000045: 01,3544           10000                           CCS      A                                     
056246,000046: 01,3545           13653                           TCF      ITSATBL                               #  NO, ITS A TABLE RESTART
056247,000047: 
056248,000048: 01,3546           35015                           CA       PRIO14                                #  IT IS AN X.1 RESTART, THEREFORE START
056249,000049: 01,3547           05076                           TC       FINDVAC                               #  THE DISPLAY RESTART JOB
056250,000050: 01,3550  E3,1400                                  EBANK=   LST1                                  
056251,000051: 01,3550           03051 20103                     2CADR    INITDSP                               
056252,000052: 
056253,000053: 01,3552           03567                           TC       RTRNCADR                              #  FINISHED WITH THIS GROUP, GET NEXT ONE
056254,000054: 
056255,000055: 01,3553           75000        ITSAVAR            MASK     OCT1400                               #  IS IT TYPE B ?
056256,000056: 01,3554           10000                           CCS      A                                     
056257,000057: 01,3555           13624                           TCF      ITSLIKEB                              #  YES,IT IS TYPE B
056258,000058: 
056259,000059: 01,3556           00006                           EXTEND                                         #  STORE THE JOB (OR TASK) 2CADR FOR EXIT
056260,000060: 01,3557           50155                           NDX      TEMP2G                                
056261,000061: 01,3560           31437                           DCA      PHSNAME1                              
056262,000062: 01,3561           52706                           DXCH     GOLOC                                 
056263,000063: 
056264,000064: 01,3562           30154                           CA       TEMPPHS                               #  SEE IF THIS IS A JOB, TASK, OR A LONGCAL
056265,000065: 01,3563           74750                           MASK     OCT7                                  
056266,000066: 01,3564           67767                           AD       MINUS2                                
056267,000067: 01,3565           10000                           CCS      A                                     
056268,000068: 01,3566           13736                           TCF      ITSLNGCL                              #  ITS A LONGCALL
056269,000069: 
056270,000070: 01,3567           04622        RTRNCADR           TC       SWRETURN                              #  CANT GET HERE
056271,000071: 

Page 1301

056273,000073: 01,3570           13572                           TCF      ITSAWAIT                              
056274,000074: 
056275,000075: 01,3571           13637                           TCF      ITSAJOB                               #  ITS A JOB
056276,000076: 
056277,000077: 01,3572           34343        ITSAWAIT           CA       WTLTCADR                              #  SET UP WAITLIST CALL
056278,000078: 01,3573           54704                           TS       GOLOC      -1                         
056279,000079: 
056280,000080: 01,3574           50155                           NDX      TEMP2G                                #  DIRECTLY STORED
056281,000081: 01,3575           31053                           CA       PHSPRDT1                              
056282,000082: 01,3576           10000        TIMETEST           CCS      A                                     #  IS IT AN IMMEDIATE RESTART
056283,000083: 01,3577           24000                           INCR     A                                     #  NO,
056284,000084: 01,3600           13603                           TCF      FINDTIME                              #  FIND OUT WHEN IT SHOULD BEGIN
056285,000085: 
056286,000086: 01,3601           15440                           TCF      ITSINDIR                              #  STORED INDIRECTLY
056287,000087: 
056288,000088: 01,3602           13622                           TCF      IMEDIATE                              #  IT WANTS AN IMMEDIATE RESTART
056289,000089: 
056290,000090:                                                                                                  #  ***** THIS MUST BE IN FIXED FIXED *****
056291,000091: 
056292,000092:    5440                                           BLOCK    02                                    
056293,000093:    4000                                           SETLOC   FFTAG2                                
056294,000094:    4000                                           BANK                                           
056295,000095: 
056296,000096:    5440                                           COUNT*   $$/RSROU                              
056297,000097:    5440           22706        ITSINDIR           LXCH     GOLOC      +1                         #  GET THE CORRECT E BANK IN CASE THIS IS
056298,000098:    5441           22006                           LXCH     BB                                    #  SWITCHED ERRASIBLE
056299,000099: 
056300,000100:    5442           50000                           NDX      A                                     #  GET THE TIME INDIRECTLY
056301,000101:    5443           30001                           CA       1                                     
056302,000102: 
056303,000103:    5444           22006                           LXCH     BB                                    #  RESTORE THE BB AND GOLOC
056304,000104:    5445           22706                           LXCH     GOLOC      +1                         
056305,000105: 
056306,000106:    5446           13603                           TCF      FINDTIME                              #  FIND OUT WHEN IT SHOULD BEGIN
056307,000107: 
056308,000108:                                                                                                  #  ***** YOU MAY RETURN TO SWITCHED FIXED *****
056309,000109: 
056310,000110: 01,3603                                           BANK     01                                    
056311,000111: 01,2000                                           SETLOC   RESTART                               
056312,000112: 01,2000                                           BANK                                           
056313,000113: 
056314,000114: 01,3603                                           COUNT*   $$/RSROU                              
056315,000115: 01,3603           40000        FINDTIME           COM                                            #  MAKE NEGITIVE SINCE IT WILL BE SUBTRACTD
056316,000116: 01,3604           54001                           TS       L                                     #  AND SAVE
056317,000117: 01,3605           50155                           NDX      TEMP2G                                
056318,000118: 01,3606           41052                           CS       TBASE1                                
056319,000119: 01,3607           00006                           EXTEND                                         
056320,000120: 01,3610           60025                           SU       TIME1                                 
056321,000121: 01,3611           10000                           CCS      A                                     
056322,000122: 01,3612           40000                           COM                                            
056323,000123: 

Page 1302

056325,000125: 01,3613           67752                           AD       OCT37776                              
056326,000126: 01,3614           64744                           AD       ONE                                   
056327,000127: 01,3615           60001                           AD       L                                     
056328,000128: 01,3616           10000                           CCS      A                                     
056329,000129: 01,3617           34746                           CA       ZERO                                  
056330,000130: 01,3620           13622                           TCF      +2                                    
056331,000131: 01,3621           13622                           TCF      +1                                    
056332,000132: 01,3622           64744        IMEDIATE           AD       ONE                                   
056333,000133: 01,3623           00704                           TC       GOLOC      -1                         
056334,000134: 01,3624           33567        ITSLIKEB           CA       RTRNCADR                              #  TYPE B,             SO STORE RETURN IN
056335,000135: 01,3625           54157                           TS       TEMPSWCH                              #  TEMPSWCH IN CASE OF AN EVEN PHASE
056336,000136: 
056337,000137: 01,3626           33773                           CA       PRT2CADR                              #  SET UP EXIT TO GET TABLE PART OF THIS
056338,000138: 01,3627           54707                           TS       GOLOC      +2                         #  VARIABLE TYPE OF PHASE
056339,000139: 
056340,000140: 01,3630           30154                           CA       TEMPPHS                               #  MAKE THE PHASE LOOK RIGHT FOR THE TABLE
056341,000141: 01,3631           76115                           MASK     OCT177                                #  PART OF THIS VARIABLE PHASE
056342,000142: 01,3632           54154                           TS       TEMPPHS                               
056343,000143: 
056344,000144: 01,3633           00006                           EXTEND                                         
056345,000145: 01,3634           50155                           NDX      TEMP2G                                #  OBTAIN THE JOB:S 2CADR
056346,000146: 01,3635           31437                           DCA      PHSNAME1                              
056347,000147: 01,3636           52706                           DXCH     GOLOC                                 
056348,000148: 
056349,000149: 01,3637           50155        ITSAJOB            NDX      TEMP2G                                #  NOW ADD THE PRIORITY AND LET:S GO
056350,000150: 01,3640           31053                           CA       PHSPRDT1                              
056351,000151: 01,3641           54704        CHKNOVAC           TS       GOLOC      -1                         #  SAVE PRIO UNTIL WE SEE IF ITS
056352,000152: 01,3642           00006                           EXTEND                                         #  A FINDVAC OR A NOVAC
056353,000153: 01,3643           63647                           BZMF     ITSNOVAC                              
056354,000154: 
056355,000155: 01,3644           34345                           CAF      FVACCADR                              #  POSITIVE, SET UP FINDVAC CALL.
056356,000156: 01,3645           56704                           XCH      GOLOC      -1                         #  PICK UP PRIO,
056357,000157: 01,3646           00704                           TC       GOLOC      -1                         #  AND GO
056358,000158: 
056359,000159: 01,3647           34342        ITSNOVAC           CAF      NOVACADR                              #  NEGATIVE,
056360,000160: 01,3650           56704                           XCH      GOLOC      -1                         #  SET UP NOVAC CALL,
056361,000161: 01,3651           40000                           COM                                            #  CORRECT PRIO,
056362,000162: 01,3652           00704                           TC       GOLOC      -1                         #  AND GO
056363,000163: 
056364,000164: 01,3653           54020        ITSATBL            TS       CYR                                   #  FIND OUT IF THE PHASE IS ODD OR EVEN
056365,000165: 01,3654           10020                           CCS      CYR                                   
056366,000166: 01,3655           13656                           TCF      +1                                    #  IT:S EVEN
056367,000167: 01,3656           13754                           TCF      ITSEVEN                               
056368,000168: 
056369,000169: 01,3657           33567                           CA       RTRNCADR                              #  IN CASE THIS IS THE SECOND PART OF A
056370,000170: 01,3660           54707                           TS       GOLOC      +2                         #  TYPE B RESTART, WE NEED PROPER EXIT
056371,000171: 
056372,000172: 01,3661           30154                           CA       TEMPPHS                               #  SET UP POINTER FOR FINDING OUR PLACE IN
056373,000173: 01,3662           54021                           TS       SR                                    #  THE RESTART TABLES
056374,000174: 01,3663           60021                           AD       SR                                    
056375,000175: 

Page 1303

056377,000177: 01,3664           50155                           NDX      TEMP2G                                
056378,000178: 01,3665           62003                           AD       SIZETAB    +1                         
056379,000179: 01,3666           54156                           TS       POINTER                               
056380,000180: 
056381,000181: 01,3667           00006        CONTBL2            EXTEND                                         #  FIND OUT WHAT:S IN THE TABLE
056382,000182: 01,3670           50156                           NDX      POINTER                               
056383,000183: 01,3671           32002                           DCA      CADRTAB                               #  GET THE 2CADR
056384,000184: 
056385,000185: 01,3672           22706                           LXCH     GOLOC      +1                         #  STORE THE BB INFORMATION
056386,000186: 
056387,000187: 01,3673           10000                           CCS      A                                     #  IS IT A JOB OR IS IT TIMED
056388,000188: 01,3674           24000                           INCR     A                                     #  POSITIVE, MUST BE A JOB
056389,000189: 01,3675           13750                           TCF      ITSAJOB2                              
056390,000190: 
056391,000191: 01,3676           24000                           INCR     A                                     #  MUST BE EITHER A WAITLIST OR LONGCALL
056392,000192: 01,3677           54705                           TS       GOLOC                                 #  LET-S STORE THE CORRECT CADR
056393,000193: 
056394,000194: 01,3700           34343                           CA       WTLTCADR                              #  SET UP OUR EXIT TO WAITLIST
056395,000195: 01,3701           54704                           TS       GOLOC      -1                         
056396,000196: 
056397,000197: 01,3702           30706                           CA       GOLOC      +1                         #  NOW FIND OUT IF IT IS A WAITLIST CALL
056398,000198: 01,3703           74733                           MASK     BIT10                                 #  THIS SHOULD BE ONE IF WE HAVE -BB
056399,000199: 01,3704           10000                           CCS      A                                     #  FOR THAT MATTER SO SHOULD BE BITS 9,8,7,
056400,000200:                                                                                                  #  6,5, AND LAST BUT NOT LEAST (PERHAPS NOT
056401,000201:                                                                                                  #  IN IMPORTANCE ANYWAY.  BIT 4
056402,000202: 01,3705           13743                           TCF      ITSWTLST                              #  IT IS A WAITLIST CALL
056403,000203: 
056404,000204: 01,3706           50156                           NDX      POINTER                               #  OBTAIN THE ORIGINAL DELTA T
056405,000205: 01,3707           32000                           CA       PRDTTAB                               #  ADDRESS FOR THIS LONGCALL
056406,000206: 
056407,000207: 01,3710           15447                           TCF      ITSLGCL1                              #  NOW GO GET THE DELTA TIME
056408,000208: 
056409,000209:                                                                                                  #  ***** THIS MUST BE IN FIXED FIXED *****
056410,000210: 
056411,000211:    5447                                           BLOCK    02                                    
056412,000212:    4000                                           SETLOC   FFTAG2                                
056413,000213:    4000                                           BANK                                           
056414,000214: 
056415,000215:    5447                                           COUNT*   $$/RSROU                              
056416,000216:    5447           22706        ITSLGCL1           LXCH     GOLOC      +1                         #  OBTAIN THE CORRECT E BANK
056417,000217:    5450           22006                           LXCH     BB                                    
056418,000218:    5451           22706                           LXCH     GOLOC      +1                         #  AND PRESERVE OUR E AND F BANKS
056419,000219: 
056420,000220:    5452           00006                           EXTEND                                         #  GET THE DELTA TIME
056421,000221:    5453           50000                           NDX      A                                     
056422,000222:    5454           30001                           DCA      0                                     
056423,000223: 
056424,000224:    5455           22706                           LXCH     GOLOC      +1                         #  RESTORE OUR E AND F BANK
056425,000225:    5456           22006                           LXCH     BB                                    #  RESTORE THE TASKS E AND F BANKS
056426,000226:    5457           22706                           LXCH     GOLOC      +1                         #  AND PRESERVE OUR L
056427,000227: 

Page 1304

056429,000229:    5460           13711                           TCF      ITSLGCL2                              #  NOW LET:S PROCESS THIS LONGCALL
056430,000230: 
056431,000231:                                                                                                  #  ***** YOU MAY RETURN TO SWITCHED FIXED *****
056432,000232: 
056433,000233: 01,3711                                           BANK     01                                    
056434,000234: 01,2000                                           SETLOC   RESTART                               
056435,000235: 01,2000                                           BANK                                           
056436,000236: 
056437,000237: 01,3711                                           COUNT*   $$/RSROU                              
056438,000238: 01,3711           53153        ITSLGCL2           DXCH     LONGTIME                              
056439,000239: 
056440,000240: 01,3712           00006                           EXTEND                                         #  CALCULATE TIME LEFT
056441,000241: 01,3713           40025                           DCS      TIME2                                 
056442,000242: 01,3714           21153                           DAS      LONGTIME                              
056443,000243: 01,3715           00006                           EXTEND                                         
056444,000244: 01,3716           31151                           DCA      LONGBASE                              
056445,000245: 01,3717           21153                           DAS      LONGTIME                              
056446,000246: 
056447,000247: 01,3720           11152                           CCS      LONGTIME                              #  FIND OUT HOW THIS SHOULD BE RESTARTED
056448,000248: 01,3721           13731                           TCF      LONGCLCL                              
056449,000249: 01,3722           13724                           TCF      +2                                    
056450,000250: 01,3723           13617                           TCF      IMEDIATE   -3                         
056451,000251: 01,3724           11153                           CCS      LONGTIME   +1                         
056452,000252: 01,3725           13731                           TCF      LONGCLCL                              
056453,000253: 01,3726           13727                           NOOP                                           #  CAN:T GET HERE    *********
056454,000254: 01,3727           13617                           TCF      IMEDIATE   -3                         
056455,000255: 01,3730           13622                           TCF      IMEDIATE                              
056456,000256: 
056457,000257: 01,3731           33774        LONGCLCL           CA       LGCLCADR                              #  WE WILL GO TO LONGCALL
056458,000258: 01,3732           54704                           TS       GOLOC      -1                         
056459,000259: 
056460,000260: 01,3733           00006                           EXTEND                                         #  PREPARE OUR ENTRY TO LONGCALL
056461,000261: 01,3734           31153                           DCA      LONGTIME                              
056462,000262: 01,3735           00704                           TC       GOLOC      -1                         
056463,000263: 
056464,000264: 01,3736           34343        ITSLNGCL           CA       WTLTCADR                              #  ASSUME IT WILL GO TO WAITLIST
056465,000265: 01,3737           54704                           TS       GOLOC      -1                         
056466,000266: 
056467,000267: 01,3740           50155                           NDX      TEMP2G                                
056468,000268: 01,3741           41053                           CS       PHSPRDT1                              #  GET THE DELTA T ADDRESS
056469,000269: 
056470,000270: 01,3742           15447                           TCF      ITSLGCL1                              #  NOW GET THE DELTA TIME
056471,000271: 
056472,000272: 01,3743           40706        ITSWTLST           CS       GOLOC      +1                         #  CORRECT THE BBCON INFORMATION
056473,000273: 01,3744           54706                           TS       GOLOC      +1                         
056474,000274: 
056475,000275: 01,3745           50156                           NDX      POINTER                               #  GET THE DT AND FIND OUT IF IT WAS STORED
056476,000276: 01,3746           32000                           CA       PRDTTAB                               #  DIRECTLY OR INDIRECTLY
056477,000277: 
056478,000278: 01,3747           13576                           TCF      TIMETEST                              #  FIND OUT HOW THE TIME IS STORED
056479,000279: 

Page 1305

056481,000281: 01,3750           56705        ITSAJOB2           XCH      GOLOC                                 #  STORE THE CADR
056482,000282: 
056483,000283: 01,3751           50156                           NDX      POINTER                               #  ADD THE PRIORITY AND LET:S GO
056484,000284: 01,3752           32000                           CA       PRDTTAB                               
056485,000285: 
056486,000286: 01,3753           13641                           TCF      CHKNOVAC                              
056487,000287: 
056488,000288: 01,3754           30157        ITSEVEN            CA       TEMPSWCH                              #  SET UP FOR EITHER THE SECOND PART OF THE
056489,000289: 01,3755           54707                           TS       GOLOC      +2                         #  TABLE, OR A RETURN FOR THE NEXT GROUP
056490,000290: 
056491,000291: 01,3756           50155                           NDX      TEMP2G                                #  SET UP POINTER FOR OUR LOCATION WITHIN
056492,000292: 01,3757           32002                           CA       SIZETAB                               #  THE TABLE
056493,000293: 01,3760           60154                           AD       TEMPPHS                               #  THIS MAY LOOK BAD BUT LET:S SEE YOU DO
056494,000294: 01,3761           60154                           AD       TEMPPHS                               #  BETTER IN TIME OR NUMBERR OF LOCATIONS
056495,000295: 01,3762           60154                           AD       TEMPPHS                               
056496,000296: 01,3763           54156                           TS       POINTER                               
056497,000297: 
056498,000298: 01,3764           13667                           TCF      CONTBL2                               #  NOW PROCESS WHAT IS IN THE TABLE
056499,000299: 
056500,000300: 01,3765           36266        PHSPART2           CA       THREE                                 #  SET THE POINTER FOR THE SECOND HALF OF
056501,000301: 01,3766           26156                           ADS      POINTER                               #  THE TABLE
056502,000302: 
056503,000303: 01,3767           33567                           CA       RTRNCADR                              #  THIS WILL BE OUR LAST TIME THROUGH THE
056504,000304: 01,3770           54707                           TS       GOLOC      +2                         #  EVEN TABLE , SO AFTER IT GET THE NEXT
056505,000305:                                                                                                  #  GROUP
056506,000306: 01,3771           13667                           TCF      CONTBL2                               #  SO LET:S GET THE SECOND ENTRY IN THE TBL
056507,000307: 
056508,000308: 01,3772     0154               TEMPPHS            EQUALS   MPAC                                  
056509,000309: 01,3772     0155               TEMP2G             EQUALS   MPAC       +1                         
056510,000310: 01,3772     0156               POINTER            EQUALS   MPAC       +2                         
056511,000311: 01,3772     0157               TEMPSWCH           EQUALS   MPAC       +3                         
056512,000312: 01,3772     7767               MINUS2             EQUALS   NEG2                                  
056513,000313: 01,3772     6115               OCT177             EQUALS   LOW7                                  
056514,000314: 
056515,000315: 01,3772           03765        PHS2CADR           GENADR   PHSPART2                              
056516,000316: 01,3773           03543        PRT2CADR           GENADR   GETPART2                              
056517,000317: 01,3774           05301        LGCLCADR           GENADR   LONGCALL                              
056518,000318: 01,3775     4345               FVACCADR           =        TCFINDVC                              
056519,000319: 01,3775     4343               WTLTCADR           =        TCWAIT                                
056520,000320: 01,3775     4342               NOVACADR           =        TCNOVAC                               
056521,000321: 
056522,000322: 

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