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.

034130,000002:                                                                                                  ## Copyright:    Public domain.
034131,000003:                                                                                                  ## Filename:     LMP_COMMAND_ROUTINES.agc
034132,000004:                                                                                                  ## Purpose:      A module for revision 0 of BURST120 (Sunburst). It
034133,000005:                                                                                                  ##               is part of the source code for the Lunar Module's
034134,000006:                                                                                                  ##               (LM) Apollo Guidance Computer (AGC) for Apollo 5.
034135,000007:                                                                                                  ## Assembler:    yaYUL
034136,000008:                                                                                                  ## Contact:      Ron Burkey <info@sandroid.org>.
034137,000009:                                                                                                  ## Website:      www.ibiblio.org/apollo/index.html
034138,000010:                                                                                                  ## Mod history:  2016-09-30 RSB  Created draft version.
034139,000011:                                                                                                  ##               2016-10-28 HG   transcribed
034140,000012:                                                                                                  ##               2016-12-06 RSB  Comments proofed using octopus/ProoferComments,
034141,000013:                                                                                                  ##                               changes made.
034142,000014: 

Page 799

034144,000016:                                                                                                  #           THE FOLLOWING SUBROUTINES ALLOW MISSION PROGRAMS TO REQUEST LMP (LEM MISSION PROGRAMMER) OUTPUTS.
034145,000017:                                                                                                  #  THE PROPER DECIMAL CODE IS ENTERED INTO A TABLE AND FROM THENCE TO CHANNEL 10 VIA T4RUPT AND ARE INCLUDED IN
034146,000018:                                                                                                  #  THE DOWNLINK.
034147,000019: 
034148,000020:                                                                                                  #           FOUR ROUTINES ARE PROVIDED:
034149,000021: 
034150,000022:                                                                                                  #                                                   TC     1LMP            CALLED UNDER EXEC OR RUPT. DELIVERS CODE
034151,000023:                                                                                                  #                                                   DEC    LMPCODE         AND RETURNS IMMEDIATELY.
034152,000024: 
034153,000025:                                                                                                  #                                                   TC     2LMP            SAME AS 1LMP BUT TWO CODES ARE
034154,000026:                                                                                                  #                                                   DEC    LMPCODE1        SENT.
034155,000027:                                                                                                  #                                                   DEC    LMPCODE2
034156,000028: 
034157,000029:                                                                                                  #                                                   TC     1LMP+DT         ASSUMES CALLED AS PART OF WAITLIST TASK.
034158,000030:                                                                                                  #                                                   DEC    LMPCODE         DELIVERS LMP CODE, DOES A VARDELAY FOR
034159,000031:                                                                                                  #                                                   DEC    DT              DT, AND THEN RETURNS UNDER WL CONTROL.
034160,000032: 
034161,000033:                                                                                                  #                                                   TC     2LMP+DT         SAME AS 1LMP+DT BUT TWO CODES SENT.
034162,000034:                                                                                                  #                                                   DEC    LMPCODE1
034163,000035:                                                                                                  #                                                   DEC    LMPCODE2
034164,000036:                                                                                                  #                                                   DEC    DT
034165,000037: 
034166,000038:                                                                                                  #  WARNING  ***** PROGRAMS UNDER EXEC WHICH CALL 1LMP + 2LMP MUST FIRST
034167,000039:                                                                                                  #                 INHIBIT INTERRUPT....RETURNS STILL INHIBITED.
034168,000040: 
034169,000041: 
034170,000042: 
034171,000043:    5052                                           BLOCK    02                                    
034172,000044:    5052           50002        2LMP               INDEX    Q                                     #  PICK UP 1ST CODE
034173,000045:    5053           30000                           CA       0                                     
034174,000046:    5054           24002                           INCR     Q                                     
034175,000047:    5055           22002                           LXCH     Q                                     #  SAVE 2ND CODE ADDRESS IN L
034176,000048: 
034177,000049:    5056                        LMPGROUP           EQUALS   2                                     
034178,000050:    5056     1115               LMPTBASE           EQUALS   TBASE2                                
034179,000051:    5056     1102               LMPPHASE           EQUALS   PHASE2                                
034180,000052: 
034181,000053:    5056           05063                           TC       STORCOM    -1                         #  TO STORE IN BUFFER AND UPDATE POINTER
034182,000054: 
034183,000055:    5057           22002                           LXCH     Q                                     #  RETRIEVE 2ND CODE ADDRESS FROM L.
034184,000056: 
034185,000057:    5060           50002        1LMP               INDEX    Q                                     
034186,000058:    5061           30000                           CA       0                                     #  GET LMP CODE
034187,000059:    5062           24002                           INCR     Q                                     #  SET RETURN.
034188,000060:    5063           67745                           AD       BIT15                                 #  SET SIGN TO SHOW NEW COMMAND IN BUFFER
034189,000061:    5064           51143        STORCOM            INDEX    LMPIN                                 
034190,000062:    5065           55133                           TS       LMPCMD                                #  INSERT IN NEXT SLOT IN BUFFER
034191,000063: 
034192,000064:    5066           11143        UPLMPIN            CCS      LMPIN                                 #  UPDATE POINTER
034193,000065: 

Page 800

034195,000067:    5067           15071                           TCF      +2                                    
034196,000068:    5070           37765                           CAF      SEVEN                                 
034197,000069:    5071           55143                           TS       LMPIN                                 
034198,000070:    5072           00002                           TC       Q                                     
034199,000071: 
034200,000072:    5073           50002        2LMP+DT            INDEX    Q                                     
034201,000073:    5074           30000                           CA       0                                     #  PICK UP 1ST CODE
034202,000074:    5075           24002                           INCR     Q                                     
034203,000075:    5076           22002                           LXCH     Q                                     #  2ND CODE ADDRESS IN L.
034204,000076: 
034205,000077:    5077           05063                           TC       STORCOM    -1                         #  STORE IN BUFFER AND UPDATE POINTER
034206,000078: 
034207,000079:    5100           15102                           TCF      +2                                    
034208,000080: 
034209,000081:    5101           00006        1LMP+DT            EXTEND                                         #  SAVE RETURN FOR RESTARTS
034210,000082:    5102           23146                           QXCH     LMPRET                                #  IS LXCH IF FROM ABOVE
034211,000083:    5103           30006                           CA       BBANK                                 
034212,000084:    5104           55147                           TS       LMPBBANK                              
034213,000085: 
034214,000086:    5105           00006                           EXTEND                                         
034215,000087:    5106           51146                           INDEX    LMPRET                                
034216,000088:    5107           30001                           DCA      0                                     #  PICK UP CODE AND DT
034217,000089:    5110           05063                           TC       STORCOM    -1                         #  GO TO STORE CODE AND UPDATE POINTER
034218,000090: 
034219,000091:    5111           23150                           LXCH     SAVDT                                 #  SAVE FOR RESTART
034220,000092:    5112           04161                           TC       PHASCHNG                              #  RESTART PROTECT DELAY
034221,000093:    5113           47012                           OCT      47012                                 
034222,000094:    5114           76627                           -GENADR  SAVDT                                 
034223,000095:    5115     1115                                  EBANK=   TBASE2                                
034224,000096:    5115           05123 04062                     2CADR    LMPRST                                
034225,000097: 
034226,000098:    5117           31150                           CA       SAVDT                                 #  WAIT DT SECONDS
034227,000099:    5120           05704                           TC       VARDELAY                              
034228,000100: 
034229,000101:    5121           51146        LMPEXIT            INDEX    LMPRET                                
034230,000102:    5122           00002                           TC       2                                     
034231,000103: 
034232,000104:    5123           31147        LMPRST             CA       LMPBBANK                              #  LMP+DT RESTARTS COME HERE
034233,000105:    5124           54006                           TS       BBANK                                 #  AFTER DELAY.
034234,000106:    5125           05121                           TC       LMPEXIT                               

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