Source Code

These source-code files were transcribed from scans made from Don Eyles's personal copy of BURST120 (SUNBURST 120). They were scanned at archive.org's Boston facility, and the scanning was sponsored by Mike Stewart. The code was transcribed from these scans by a team of volunteers who are referenced in the program comments. Comments from the original source code are in ALL-CAPS, whereas comments added later in transcription are in Mixed-Case. In some cases, where similar code blocks exist in previously-transcribed AGC programs (primarily Luminary 99, from Apollo 11) those code blocks were used as a starting point and then corrected to agree with the BURST120 scans. The full scans are available at the Virtual AGC project's collection at archive.org, while more-convenient reduced-size (but reduced-quality) images are available at the main Virtual AGC website. Report any errors noted by creating an issue report at the Virtual AGC project's GitHub repository. Notations on the program listing read, in part:

	YUL SYSTEM FOR AGC: REVISION 0 OF PROGRAM BURST120 
	BY NASA 2021106-031 DEC 7, 1967

	THIS LISTING IS A COPY OF A VERSION OF THE PROGRAM INTENDED 
	FOR USE IN THE ON-BOARD PRIMARY GUIDANCE COMPUTER IN THE 
	UNMANNED FLIGHT OF APOLLO LUNAR MODULE 1 --- THE AS206 MISSION.
Note that the date is the date of the printout, not the date of the program revision.

020189,000002:                                                                                                  ## Copyright:    Public domain.
020190,000003:                                                                                                  ## Filename:     DAPIDLER_PROGRAM.agc
020191,000004:                                                                                                  ## Purpose:      A module for revision 0 of BURST120 (Sunburst). It
020192,000005:                                                                                                  ##               is part of the source code for the Lunar Module's
020193,000006:                                                                                                  ##               (LM) Apollo Guidance Computer (AGC) for Apollo 5.
020194,000007:                                                                                                  ## Assembler:    yaYUL
020195,000008:                                                                                                  ## Contact:      Ron Burkey <info@sandroid.org>.
020196,000009:                                                                                                  ## Website:      www.ibiblio.org/apollo/index.html
020197,000010:                                                                                                  ## Mod history:  2016-09-30 RSB  Created draft version.
020198,000011:                                                                                                  ##               2016-10-21 HG   Transcribed
020199,000012:                                                                                                  ##               2016-10-31 RSB  Typos.
020200,000013:                                                                                                  ##               2016-11-01 RSB  More typos.
020201,000014:                                                                                                  ##               2016-12-05 RSB  Comment-proofing with octopus/ProoferComments
020202,000015:                                                                                                  ##                               completed, changes made.
020203,000016: 

Page 487

020205,000018:                                                                                                  #  THE DAPIDLER PROGRAM IS STARTED BY FRESH START AND RESTART.             THE DAPIDLER PROGRAM IS DONE 10 TIMES
020206,000019:                                                                                                  #  PER SECOND UNTIL THE ASTRONAUT DESIRES THE DAP TO WAKE UP, AND THE IMU AND CDUS ARE READY FOR USE BY THE DAP.
020207,000020:                                                                                                  #  THE NECESSARY INITIALIZATION OF THE DAP IS DONE BY THE DAPIDLER PROGRAM.
020208,000021:                                                                                                  #  ADDITIONAL WORK MUST BE DONE ON DAPIDLER IN THE FUTURE.
020209,000022: 
020210,000023: 
020211,000024: 
020212,000025: 16,2005                                           BANK     16                                    
020213,000026: 16,2005  E6,1542                                  EBANK=   DT                                    
020214,000027: 
020215,000028: 16,2005           37756        CHEKBITS           CAF      BIT6                                  
020216,000029: 16,2006           70365                           MASK     IMODES30                              
020217,000030: 16,2007           10000                           CCS      A                                     
020218,000031: 16,2010           12166                           TCF      MOREIDLE                              
020219,000032: 
020220,000033: 16,2011           37760                           CAF      BIT4                                  
020221,000034: 16,2012           67757                           AD       BIT5                                  
020222,000035: 16,2013           00006                           EXTEND                                         
020223,000036: 16,2014           02012                           RAND     12                                    
020224,000037: 16,2015           10000                           CCS      A                                     
020225,000038: 16,2016           12166                           TCF      MOREIDLE                              
020226,000039: 
020227,000040: 16,2017           37752                           CAF      BIT10                                 #  BIT10 OF 30 IS PNGCS CONTROL OF S/C
020228,000041: 16,2020           00006                           EXTEND                                         
020229,000042: 16,2021           02030                           RAND     30                                    #  BITS IN 30 ARE INVERTED
020230,000043: 16,2022           10000                           CCS      A                                     
020231,000044: 16,2023           12166                           TCF      MOREIDLE                              
020232,000045: 
020233,000046: 16,2024           00006                           EXTEND                                         
020234,000047: 16,2025           00031                           READ     31                                    #  IF BOTH    BIT13 AND BIT14 ARE ONE
020235,000048: 16,2026           40000                           COM                                            #  THEN MODE SELECT SWITCH IS IN OFF
020236,000049: 16,2027           75210                           MASK     BIT13-14                              #  POSITION.
020237,000050: 16,2030           00006                           EXTEND                                         
020238,000051: 16,2031           12166                           BZF      MOREIDLE                              #  HENCE DAP SHOULD BE OFF.
020239,000052: 
020240,000053: 16,2032           37751                           CAF      GODAPGO                               
020241,000054: 16,2033           70077                           MASK     DAPBOOLS                              
020242,000055: 16,2034           00006                           EXTEND                                         
020243,000056: 16,2035           12166                           BZF      MOREIDLE                              
020244,000057: 
020245,000058: 16,2036           00002                           RETURN                                         
020246,000059: 

Page 488

020248,000061:                                                                                                  #  DAPIDLER ENTRY.
020249,000062: 
020250,000063: 16,2037           22016        DAPIDLER           LXCH     BANKRUPT                              #  INTERRUPT LEAD INS (CONTINUED)
020251,000064:                                                                                                  #  START CODING FOR MODULE 3 REMAKE, AUGUST 1967***START CODING FOR MODULE 3 REMAKE, AUGUST 1967*******************
020252,000065: 16,2040           13627                           TCF      T5IDLERI                              
020253,000066: 16,2041           04736                           TC       CCSHOLE                               
020254,000067: 
020255,000068: 16,2042           37761        DAPIDLEI           CAF      DATAGOOD                              
020256,000069:                                                                                                  #  **END CODING FOR MODULE 3 REMAKE, AUGUST 1967*****END CODING FOR MODULE 3 REMAKE, AUGUST 1967*******************
020257,000070: 
020258,000071: 16,2043           70077                           MASK     DAPBOOLS                              
020259,000072: 16,2044           00006                           EXTEND                                         
020260,000073: 16,2045           12207                           BZF      TESTMASS                              
020261,000074: 16,2046           02005                           TC       CHEKBITS                              #  CHECK TO SEE IF LM DAP IS TO GO ON.
020262,000075: 
020263,000076: 16,2047           05270        STARTDAP           TC       IBNKCALL                              
020264,000077: 16,2050           40114                           FCADR    STOPRATE                              
020265,000078: 16,2051           37767                           CAF      ZERO                                  #  ********** INITIALIZE: **********
020266,000079: 16,2052           54031                           TS       TIME6                                 #  T6RUPT CLOCK
020267,000080: 16,2053           55611                           TS       TP                                    #  RATE DERIVATION DTS
020268,000081: 16,2054           55612                           TS       TQR                                   
020269,000082: 16,2055           55605                           TS       JETRATEQ                              #  Q,R JETRATES USED IN Q,R-AXES BEFORE
020270,000083: 16,2056           55606                           TS       JETRATER                              #  BEING SET, GIVEN TQR ZERO.
020271,000084: 16,2057           55463                           TS       LASTPER                               #  ATTITUDE ERROR RECORDS FOR EIGHTBALL.
020272,000085: 16,2060           55464                           TS       LASTQER                               
020273,000086: 16,2061           55465                           TS       LASTRER                               
020274,000087: 16,2062           55466                           TS       PERROR                                
020275,000088: 16,2063           55467                           TS       QERROR                                
020276,000089: 16,2064           55470                           TS       RERROR                                
020277,000090: 16,2065           55415                           TS       OMEGAP                                #  RATES IN BODY (PILOT) COORDINATES.
020278,000091: 16,2066           55416                           TS       OMEGAQ                                
020279,000092: 16,2067           55420                           TS       OMEGAR                                
020280,000093: 16,2070           55002                           TS       T6NEXT                                #  JTLST VARIABLES.
020281,000094: 16,2071           55003                           TS       T6NEXT     +1                         
020282,000095: 16,2072           55473                           TS       ADDT6JTS                              
020283,000096: 16,2073           55474                           TS       ADDTLT6                               
020284,000097: 16,2074           55007                           TS       DELAYCTR                              #  MINIMUM IMPULSE RHC MODE COUNTER.
020285,000098: 16,2075           55417                           TS       ALPHAQ                                #  DESCENT ACCELERATION ESTIMATES.
020286,000099: 16,2076           55421                           TS       ALPHAR                                
020287,000100: 16,2077           55515                           TS       DISPLACT                              #  EIGHTBALL ROUTINE SWITCH.
020288,000101: 16,2100           55642                           TS       (1-K)                                 #  K=1 FIRST PASS.
020289,000102: 
020290,000103:                                                                                                  #  START CODING FOR MODULE 3 REMAKE, AUGUST 1967***START CODING FOR MODULE 3 REMAKE, AUGUST 1967*******************
020291,000104: 
020292,000105: 16,2101           12455        INSRT16B           TCF      PROTCTOR                              #  RESTART PROTECT ENGINE-ON AND GIMBAL
020293,000106:                                                                                                  #    DRIVE BITS.
020294,000107:                                                                                                  #  **END CODING FOR MODULE 3 REMAKE, AUGUST 1967*****END CODING FOR MODULE 3 REMAKE, AUGUST 1967*******************
020295,000108: 
020296,000109: 16,2102           37762                           CAF      BIT2                                  #  CHECK FOR STAGE
020297,000110: 16,2103           00006                           EXTEND                                         
020298,000111: 

Page 489

020300,000113: 16,2104           02030                           RAND     30                                    
020301,000114: 16,2105           00006                           EXTEND                                         
020302,000115: 16,2106           12117                           BZF      +9D                                   #  (BRANCH FOR ASCENT.)
020303,000116: 
020304,000117: 16,2107           37767                           CAF      ZERO                                  #  1/ACCS BRANCHING VALUE IS ZERO FOR
020305,000118: 16,2110           55655                           TS       -.06R/S2                              #  DESCENT LM DAP.
020306,000119: 
020307,000120: 16,2111           00006                           EXTEND                                         #  SET DESCENT URGENCY LIMIT = 1.5 SECONDS
020308,000121: 16,2112           32251                           DCA      URGLMDWN                              #  AS BOUND TO USE MAXIMUM JETS.
020309,000122: 16,2113           53477                           DXCH     URGLMS                                
020310,000123: 16,2114           00006                           EXTEND                                         #  RATE ERROR LIMIT W/MIN JETS: 1.4 DEG/SEC
020311,000124: 16,2115           32245                           DCA      RCOMDOWN                              #  RATE ERROR DB    W/MIN JETS: 0.4 DEG/SEC
020312,000125: 16,2116           12126                           TCF      +8D                                   
020313,000126: 
020314,000127: 16,2117           32254                 +9D       CAF      ACCLIMIT                              #  1/ACCS BRANCHING VALUE MUST BE
020315,000128: 16,2120           55655                           TS       -.06R/S2                              #  0.06 RADIANS/SECOND(2) FOR ASCENT DAP.
020316,000129: 
020317,000130: 16,2121           00006                           EXTEND                                         #  SET ASCENT URGENCY LIMIT = .25 SECONDS
020318,000131: 16,2122           32253                           DCA      URGLMUP                               #  AS BOUND TO USE MAXIMUM JETS.
020319,000132: 16,2123           53477                           DXCH     URGLMS                                
020320,000133: 16,2124           00006                           EXTEND                                         #  RATE ERROR LIMIT W/MIN JETS: 2.0 DEG/SEC
020321,000134: 16,2125           32247                           DCA      RCOMNDUP                              #  RATE ERROR DB    W/MIN JETS: 1.0 DEG/SEC
020322,000135: 16,2126           53501                 +8D       DXCH     -2JETLIM                              
020323,000136: 
020324,000137:                                                                                                  #  SET UP "OLD" MEASURED CDU ANGLES:
020325,000138: 
020326,000139: 16,2127           00006                           EXTEND                                         
020327,000140: 16,2130           30033                           DCA      CDUX                                  #  OLDXFORP AND OLDYFORP
020328,000141: 16,2131           53426                           DXCH     OLDXFORP                              
020329,000142: 16,2132           00006                           EXTEND                                         
020330,000143: 16,2133           30034                           DCA      CDUY                                  #  OLDYFORQ AND OLDZFORQ
020331,000144: 16,2134           53430                           DXCH     OLDYFORQ                              
020332,000145: 
020333,000146: 16,2135           32230                           CAF      0.62170                               
020334,000147: 16,2136           55455                           TS       4JETTORK                              
020335,000148: 16,2137           32231                           CAF      .68387                                #  2200 FT LBS. SCALED AT 2(10) X PI.
020336,000149: 16,2140           55456                           TS       JETTORK4                              #  QR AXIS JET TORQUE FOR 4 JETS.
020337,000150:                                                                                                  #  SET UP THE TORQUE VECTOR RECONSTRUCTION SWITCHES:
020338,000151: 
020339,000152: 16,2141           00006                           EXTEND                                         
020340,000153: 16,2142           32241                           DCA      VISNORMQ                              #  PJUMPADR AND QJUMPADR
020341,000154: 16,2143           53653                           DXCH     PJUMPADR                              
020342,000155: 
020343,000156:                                                                                                  #  SET SWITCH TO SKIP Q,R-TJETLAW SQUARE ROOT:
020344,000157: 
020345,000158:                                                                                                  #  SET UP INITIAL VALUES FOR WFORP AND WFORQR:
020346,000159: 
020347,000160: 16,2144           00006                           EXTEND                                         #  SCALED AT 16:
020348,000161: 16,2145           32243                           DCA      WFORPQRK                              #  WFORP  = K/DT = K/.1  = 1/.1  = 0.625
020349,000162: 16,2146           53641                           DXCH     WFORP                                 #  WFORQR = K/DT = K/.15 = 1/.15 = 0.41667
020350,000163: 

Page 490

020352,000165:                                                                                                  #  SET UP WAITLIST CALL TO RESET WFORP AND WFORQR:
020353,000166: 
020354,000167: 16,2147           32236                           CAF      180MS                                 
020355,000168: 16,2150           05663                           TC       WAITLIST                              
020356,000169: 16,2151  E6,1641                                  EBANK=   WFORQR                                
020357,000170: 16,2151           03435 40066                     2CADR    WCHANGER                              
020358,000171: 
020359,000172: 16,2153           00006                           EXTEND                                         #  SET UP P-AXIS TO GO TO DUMMYFIL
020360,000173: 16,2154           32225                           DCA      DF2CADR                               
020361,000174: 16,2155           53573                           DXCH     PFILTADR                              
020362,000175: 
020363,000176: 16,2156           00006                           EXTEND                                         
020364,000177: 16,2157           32223                           DCA      PAXADIDL                              
020365,000178: 16,2160           53001                           DXCH     T5ADR                                 
020366,000179: 16,2161           32226        SETTIME5           CAF      MS100                                 
020367,000180: 16,2162           54030                           TS       TIME5                                 
020368,000181: 16,2163           15733                           TCF      RESUME                                
020369,000182: 16,2164  E6,1542                                  EBANK=   DT                                    
020370,000183: 16,2164           02037 34066  IDLERADR           2CADR    DAPIDLER                              
020371,000184: 16,2166           42222        MOREIDLE           CS       PAXADIDL                              #  DAP SHOULD BE OFF
020372,000185: 16,2167           61000                           AD       T5ADR                                 
020373,000186: 16,2170           00006                           EXTEND                                         
020374,000187: 16,2171           12176                           BZF      SHUTDOWN                              #  CHECK TO SEE WHETHER THIS IS FROM P-AXIS
020375,000188: 
020376,000189: 16,2172           00006        SETT5ADR           EXTEND                                         
020377,000190: 16,2173           32165                           DCA      IDLERADR                              
020378,000191: 16,2174           53001                           DXCH     T5ADR                                 
020379,000192: 16,2175           12161                           TCF      SETTIME5                              
020380,000193: 
020381,000194: 16,2176           37767        SHUTDOWN           CAF      ZERO                                  #  COMMAND JETS OFF
020382,000195: 16,2177           00006                           EXTEND                                         
020383,000196: 16,2200           01005                           WRITE    5                                     
020384,000197: 16,2201           00006                           EXTEND                                         
020385,000198: 16,2202           01006                           WRITE    6                                     
020386,000199: 
020387,000200: 16,2203           42220                           CS       BGIM23                                #  TURN TRIM GIMBAL OFF
020388,000201: 16,2204           00006                           EXTEND                                         
020389,000202: 16,2205           03012                           WAND     12                                    
020390,000203: 
020391,000204: 16,2206           12172                           TCF      SETT5ADR                              
020392,000205: 16,2207           37750        TESTMASS           CAF      MASSGOOD                              
020393,000206: 16,2210           70077                           MASK     DAPBOOLS                              
020394,000207: 16,2211           00006                           EXTEND                                         
020395,000208: 16,2212           12166                           BZF      MOREIDLE                              
020396,000209: 
020397,000210: 16,2213           35655                           CAF      PRIO34                                
020398,000211: 16,2214           05505                           TC       NOVAC                                 
020399,000212: 16,2215  E6,1542                                  EBANK=   DT                                    
020400,000213: 16,2215           02713 54066                     2BCADR   1/ACCS                                
020401,000214: 

Page 491

020403,000216: 16,2217           12172                           TCF      SETT5ADR                              
020404,000217: 16,2220           07400        BGIM23             OCTAL    07400                                 
020405,000218: 16,2221           26501        .707P              DEC      .70711                                #  SQUARE ROOT OF 1/2
020406,000219: 16,2222  E6,1415                                  EBANK=   OMEGAP                                
020407,000220: 16,2222           02255 34066  PAXADIDL           2CADR    PAXIS                                 
020408,000221: 
020409,000222: 16,2224  E6,1417                                  EBANK=   ALPHAQ                                
020410,000223: 16,2224           03642 34066  DF2CADR            2CADR    DUMMYFIL                              
020411,000224: 
020412,000225: 16,2226           37766        MS100              OCTAL    37766                                 
020413,000226: 16,2227           00033        0.00167            DEC      0.00167                               
020414,000227: 16,2230           23712        0.62170            DEC      0.62170                               
020415,000228: 16,2231           25705        .68387             DEC      0.68387                               
020416,000229: 16,2232           12000        0.31250            DEC      0.31250                               
020417,000230: 
020418,000231: 16,2233           02215        DELTADOT           DEC      0.07111                               #  0.2 DEG/SEC SCALED AT PI/64
020419,000232: 16,2234           11643        .5ACCMIN           DEC      0.30680                               
020420,000233: 16,2235           00033        DBMNMP             DEC      0.00167                               #  .3 DEGREES SCALED AT PI RADIANS
020421,000234:                                                                                                  #  TORQUE AND WEIGHTING CONSTANTS:
020422,000235: 
020423,000236: 16,2236           00022        180MS              DEC      18         B-14                       #  180 MS WAITLIST DT.
020424,000237: 16,2237           02315        .075DEC            DEC      0.075                                 #  100 MS JET PULSE TORQUE TERM WITH K = .5
020425,000238: 16,2240           02404        VISNORMQ           GENADR   CHKVISFZ                              #  D.P. GENADR FOR INITIALIZATION OF THE
020426,000239: 16,2241           02106                           GENADR   NORMALQ                               #  TORQUE VECTOR RECONSTRUCTION SWITCHES.
020427,000240: 16,2242           24000        10AT16             DEC      0.625                                 #  INITIAL VALUE FOR WFORP.
020428,000241: 16,2243           15253        6.6AT16            DEC      0.41667                               #  INITIAL VALUE FOR WFORQR.
020429,000242: 16,2244  16,2242               WFORPQRK           EQUALS   10AT16                                #  D.P. NAME FOR BOTH CONSTANTS
020430,000243: 
020431,000244: 
020432,000245: 
020433,000246: 16,2244           77001        RCOMDOWN           OCTAL    77001                                 #  -1.4 DEG/SEC SCALED AT PI/4 RADIANS/SEC.
020434,000247: 16,2245           77555                           OCTAL    77555                                 #  -0.4 DEG/SEC SCALED AT PI/4 RADIANS/SEC.
020435,000248: 16,2246           76447        RCOMNDUP           OCTAL    76447                                 #  -2.0 DEG/SEC SCALED AT PI/4 RADIANS/SEC.
020436,000249: 16,2247           77223                           OCTAL    77223                                 #  -1.0 DEG/SEC SCALED AT PI/4 RADIANS/SEC.
020437,000250: 16,2250           77717        URGLMDWN           DEC      -.00293                               #  -1.5 SECONDS SCALED AT 2(+9).
020438,000251: 16,2251           74777                           DEC      -.09375                               #  -1.5 SECONDS SCALED AT 2(+4).
020439,000252: 16,2252           77767        URGLMUP            DEC      -0.25      B-9                        #  -0.25 SECONDS SCALED AT 2(+9).
020440,000253: 16,2253           77377                           DEC      -0.25      B-4                        #  -0.25 SECONDS SCALED AT 2(+4).
020441,000254: 16,2254           76615        ACCLIMIT           DEC      -0.03820                              #  -.06 RADIANS/SECOND(2) SCALED AT PI/2.

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