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 Mike Higgins. A team of volunteers performed the transcription and proof-reading. Note that 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 section on archive.org. 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 BLK2: REVISION 0 OF PROGRAM RETRED44 BY NASA 2021100
	JUL 9, 1965
Note that the date is the date of the printout, not the date of the program revision.

004467,000002:                                                                                                  ## Copyright:   Public domain.
004468,000003:                                                                                                  ## Filename:    FRESH_START_AND_RESTART.agc
004469,000004:                                                                                                  ## Purpose:     Part of the source code for Retread 44 (revision 0). It was
004470,000005:                                                                                                  ##              the very first program for the Block II AGC, created as an
004471,000006:                                                                                                  ##              extensive rewrite of the Block I program Sunrise.
004472,000007:                                                                                                  ##              This file is intended to be a faithful transcription, except
004473,000008:                                                                                                  ##              that the code format has been changed to conform to the
004474,000009:                                                                                                  ##              requirements of the yaYUL assembler rather than the
004475,000010:                                                                                                  ##              original YUL assembler.
004476,000011:                                                                                                  ## Reference:   pp. 124-127
004477,000012:                                                                                                  ## Assembler:   yaYUL
004478,000013:                                                                                                  ## Contact:     Ron Burkey <info@sandroid.org>.
004479,000014:                                                                                                  ## Website:     www.ibiblio.org/apollo/index.html
004480,000015:                                                                                                  ## Mod history: 2016-12-13 MAS  Created from Aurora 12 version.
004481,000016:                                                                                                  ##              2016-12-13 MAS  Transcribed.
004482,000017:                                                                                                  ##              2016-12-27 RSB  Proofed comment text using octopus/ProoferComments,
004483,000018:                                                                                                  ##                              and fixed errors found.
004484,000019: 

Page 124 The log section title, FRESH START AND RESTART, is circled in red. Below it is written "Program starts here", with an arrow drawn to the SLAP1 line.

004488,000023: 01,2677                                           SETLOC   ENDWAITS                              
004489,000024: 
004490,000025: 01,2677           00004        SLAP1              INHINT                                         #  FRESH START. COMES HERE FROM PINBALL.
004491,000026: 01,2700           37653                           CAF      ZERO                                  #   (ZERO FAILREG IN FRESH START ONLY).
004492,000027: 01,2701           54721                           TS       FAILREG                               
004493,000028: 01,2702           54715                           TS       UPLOCK                                #  FREE UPLINK INTERLOCK
004494,000029: 01,2703           37630                           CAF      BIT15                                 #  TURNS OFF AUTO, HOLD, FREE, NO ATT,
004495,000030: 01,2704           54675                           TS       DSPTAB     +11D                       #  SPARE, GIMBAL LOCK, SPARE, TRACKER,
004496,000031:                                                                                                  #  PROG ALM (BITS 1-9 OF DSPTAB+11D),
004497,000032:                                                                                                  #  IN FRESH START ONLY.
004498,000033: 01,2705           47632                           CS       BIT13                                 #  TURN OFF :TEST ALARM: OUTBIT (CHAN13
004499,000034: 01,2706           00006                           EXTEND                                         #  BIT10).  FRESH START ONLY.
004500,000035: 01,2707           03013                           WAND     CHAN13                                
004501,000036: 01,2710           47643                           CS       BIT4                                  #  TURN OFF TEMP (FRESH START ONLY)
004502,000037: 01,2711           00006                           EXTEND                                         
004503,000038: 01,2712           03011                           WAND     DSALMOUT                              
004504,000039: 01,2713           32722                           CAF      STARTEB                               
004505,000040: 01,2714           54003                           TS       EBANK                                 #  SET FOR E3
004506,000041: 01,2715           37653        SLAP2              CAF      ZERO                                  
004507,000042: 01,2716           55047                           TS       SMODE                                 
004508,000043: 01,2717           02723                           TC       STARTSUB                              #  SUBROUTINE DOES MOST OF THE WORK.
004509,000044: 
004510,000045: 01,2720           14215                           TCF      DUMMYJOB                              
004511,000046: 
004512,000047: 01,2721           02715        GOPROG             TC       SLAP2                                 #  COMES HERE FROM 4050  RESTART.
004513,000048: 
004514,000049: 
004515,000050: 
004516,000051: 01,2722  E3,1400                                  EBANK=   LST1                                  
004517,000052: 01,2722           01400        STARTEB            ECADR    LST1                                  
004518,000053: 01,2723           56002        STARTSUB           XCH      Q                                     
004519,000054: 01,2724           54114                           TS       BUF                                   #  EXEC TEMPS ARE AVAILABLE TO US.
004520,000055: 
004521,000056: 01,2725           37626                           CAF      POSMAX                                #  T3 AND T4 OVERFLOW AS SOON AS POSSIBLE.
004522,000057: 01,2726           54026                           TS       TIME3                                 #    (POSMAX IS PSEUDO INTERRUPT SIGNAL IN
004523,000058: 01,2727           54027                           TS       TIME4                                 #    CASE RUPT SIGNALLED BEFORE TS TIME3).
004524,000059: 
004525,000060: 01,2730           37627                           CAF      NEG1/2                                #  INITIALIZE WAITLIST DELTA-TS.
004526,000061: 01,2731           55404                           TS       LST1       +4                         
004527,000062: 01,2732           55403                           TS       LST1       +3                         
004528,000063: 01,2733           55402                           TS       LST1       +2                         
004529,000064: 01,2734           55401                           TS       LST1       +1                         
004530,000065: 01,2735           55400                           TS       LST1                                  
004531,000066: 
004532,000067: 01,2736           44267                           CS       ENDTASK                               
004533,000068: 01,2737           55405                           TS       LST2                                  
004534,000069: 01,2740           55407                           TS       LST2       +2                         
004535,000070: 01,2741           55411                           TS       LST2       +4                         
004536,000071: 01,2742           55413                           TS       LST2       +6                         
004537,000072: 01,2743           55415                           TS       LST2       +8D                        

Page 125

004539,000074: 01,2744           55417                           TS       LST2       +10D                       
004540,000075: 01,2745           44270                           CS       ENDTASK    +1                         
004541,000076: 01,2746           55406                           TS       LST2       +1                         
004542,000077: 01,2747           55410                           TS       LST2       +3                         
004543,000078: 01,2750           55412                           TS       LST2       +5                         
004544,000079: 01,2751           55414                           TS       LST2       +7                         
004545,000080: 01,2752           55416                           TS       LST2       +9D                        
004546,000081: 01,2753           55420                           TS       LST2       +11D                       
004547,000082: 
004548,000083: 01,2754           47653                           CS       ZERO                                  #  MAKE ALL EXECUTIVE REGISTER SETS
004549,000084: 01,2755           54153                           TS       PRIORITY                              #  AVAILABLE.
004550,000085: 01,2756           54167                           TS       PRIORITY   +12D                       
004551,000086: 01,2757           54203                           TS       PRIORITY   +24D                       
004552,000087: 01,2760           54217                           TS       PRIORITY   +36D                       
004553,000088: 01,2761           54233                           TS       PRIORITY   +48D                       
004554,000089: 01,2762           54247                           TS       PRIORITY   +60D                       
004555,000090: 01,2763           54263                           TS       PRIORITY   +72D                       
004556,000091: 
004557,000092: 01,2764           54067                           TS       NEWJOB                                #  SHOWS NO ACTIVE JOBS.
004558,000093: 
004559,000094: 01,2765           33050                           CAF      VAC1ADRC                              #  MAKE ALL VAC AREAS AVAILABLE.
004560,000095: 01,2766           54264                           TS       VAC1USE                               
004561,000096: 01,2767           63051                           AD       LTHVACA                               
004562,000097: 01,2770           54340                           TS       VAC2USE                               
004563,000098: 01,2771           63051                           AD       LTHVACA                               
004564,000099: 01,2772           54414                           TS       VAC3USE                               
004565,000100: 01,2773           63051                           AD       LTHVACA                               
004566,000101: 01,2774           54470                           TS       VAC4USE                               
004567,000102: 01,2775           63051                           AD       LTHVACA                               
004568,000103: 01,2776           54544                           TS       VAC5USE                               
004569,000104: 
004570,000105: 01,2777           37646                           CAF      ONE                                   #  GIVES 110 MS TO GET READY FOR T4.
004571,000106: 01,3000           55020                           TS       DSRUPTSW                              
004572,000107: 01,3001           37650                           CAF      TEN                                   #  TURN OFF ALL DISPLAY SYSTEM RELAYS.
004573,000108: 01,3002           54140        DSPOFF             TS       MPAC                                  
004574,000109: 01,3003           47633                           CS       BIT12                                 
004575,000110: 01,3004           50140                           INDEX    MPAC                                  
004576,000111: 01,3005           54662                           TS       DSPTAB                                
004577,000112: 01,3006           10140                           CCS      MPAC                                  
004578,000113: 01,3007           03002                           TC       DSPOFF                                
004579,000114: 
004580,000115: 01,3010           54045                           TS       INLINK                                
004581,000116: 01,3011           54714                           TS       DSPCNT                                
004582,000117: 01,3012           54651                           TS       MODREG                                
004583,000118: 01,3013           54676                           TS       CADRSTOR                              
004584,000119: 01,3014           54653                           TS       REQRET                                
004585,000120: 01,3015           54655                           TS       CLPASS                                
004586,000121: 01,3016           54652                           TS       DSPLOCK                               
004587,000122: 01,3017           54660                           TS       MONSAVE                               #  KILL MONITOR
004588,000123: 01,3020           54661                           TS       MONSAVE1                              

Page 126

004590,000125: 01,3021           54677                           TS       GRABLOCK                              
004591,000126: 01,3022           54641                           TS       VERBREG                               
004592,000127: 01,3023           54642                           TS       NOUNREG                               
004593,000128: 01,3024           54702                           TS       DSPLIST                               
004594,000129: 01,3025           54703                           TS       DSPLIST    +1                         
004595,000130: 01,3026           54704                           TS       DSPLIST    +2                         
004596,000131: 

Page 127

004598,000133: 01,3027           54620                           TS       STATE                                 #  TURN OFF INTERPRETER SWITCHES.
004599,000134: 01,3030           54621                           TS       STATE      +1                         
004600,000135: 01,3031           54622                           TS       STATE      +2                         
004601,000136: 01,3032           54623                           TS       STATE      +3                         
004602,000137: 01,3033           54705                           TS       EXTVBACT                              #  MAKE EXTENDED VERBS AVAILABLE
004603,000138: 01,3034           37647                           CAF      NOUTCON                               
004604,000139: 01,3035           54656                           TS       NOUT                                  
004605,000140: 
004606,000141: 01,3036           43046                           CS       CHAN11C                               #  TURN OFF UPLINK ACTIVITY, KEY
004607,000142: 01,3037           00006                           EXTEND                                         #  RLSE, V/N FLASH, OPERATOR ERROR
004608,000143: 01,3040           03011                           WAND     DSALMOUT                              #  IN BOTH FRESH START AND RESTART.
004609,000144: 01,3041           33047                           CAF      LESCHK                                #  SELF CHECK GO-TO REGISTER.
004610,000145: 01,3042           55043                           TS       SELFRET                               
004611,000146: 01,3043           44506                           CS       VD1                                   
004612,000147: 01,3044           54637                           TS       DSPCOUNT                              
004613,000148: 01,3045           00114                           TC       BUF                                   
004614,000149: 
004615,000150: 01,3046           00164        CHAN11C            OCT      00164                                 #  CHAN 11 BITS 3,5,6,7.
004616,000151:                                                                                                  #  UPLINK ACTIVITY, KEY RLSE,
004617,000152:                                                                                                  #  V/N FLASH, OPERATOR ERROR.
004618,000153: 01,3047           05010        LESCHK             ADRES    SMODECHK                              
004619,000154: 01,3050           00264        VAC1ADRC           ADRES    VAC1USE                               
004620,000155: 01,3051           00054        LTHVACA            DEC      44         B-14                       

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