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.

028241,000002:                                                                                                  ## Copyright:   Public domain.
028242,000003:                                                                                                  ## Filename:    KALCMANU_STEERING.agc
028243,000004:                                                                                                  ## Purpose:     A module for revision 0 of BURST120 (Sunburst). It 
028244,000005:                                                                                                  ##              is part of the source code for the Lunar Module's
028245,000006:                                                                                                  ##              (LM) Apollo Guidance Computer (AGC) for Apollo 5.
028246,000007:                                                                                                  ## Assembler:   yaYUL
028247,000008:                                                                                                  ## Contact:     Ron Burkey <info@sandroid.org>.
028248,000009:                                                                                                  ## Website:     www.ibiblio.org/apollo/index.html
028249,000010:                                                                                                  ## Mod history: 2016-09-30 RSB  Created draft version.
028250,000011:                                                                                                  ##              2016-10-22 MAS  Transcribed.
028251,000012:                                                                                                  ##              2016-10-31 RSB  Typos.
028252,000013:                                                                                                  ##              2016-11-01 RSB  More typos.
028253,000014:                                                                                                  ##              2016-12-06 RSB  Comments proofed using octopus/ProoferComments,
028254,000015:                                                                                                  ##                              no changes made.
028255,000016:                                                                                                  ##              2017-01-28 RSB  WTIH -> WITH.
028256,000017:                                                                                                  ##              2017-03-17 RSB  Comment-text fixes identified in diff'ing
028257,000018:                                                                                                  ##                              Luminary 99 vs Comanche 55.
028258,000019: 

Page 668

028260,000021:                                                                                                  #  GENERATION OF STEERING COMMANDS FOR DIGITAL AUTOPILOT FREE FALL MANEUVERS
028261,000022: 
028262,000023:                                                                                                  #  NEW COMMANDS WILL BE GENERATED EVERY ONE SECOND DURING THE MANEUVER
028263,000024: 
028264,000025: 34,3476  E3,1605                                  EBANK=   TTEMP                                 
028265,000026: 
028266,000027: 34,3476           06112        NEWDELHI           TC       INTPRET                               
028267,000028: 34,3477           75160                           AXC,1    AXC,2                                 
028268,000029: 34,3500           01535                                    MIS                                   #  COMPUTE THE NEW MATRIX FROM S/C TO
028269,000030: 34,3501           01557                                    KEL                                   #  STABLE MEMBER AXES
028270,000031: 34,3502           77624                           CALL                                           
028271,000032: 34,3503           73417                                    MXM3                                  
028272,000033: 34,3504           45575                           VLOAD    STADR                                 
028273,000034: 34,3505           52225                           STOVL    MIS        +12D                       #  CALCULATE NEW DESIRED CDU ANGLES
028274,000035: 34,3506           77626                           STADR                                          
028275,000036: 34,3507           52233                           STOVL    MIS        +6D                        
028276,000037: 34,3510           77626                           STADR                                          
028277,000038: 34,3511           76241                           STORE    MIS                                   
028278,000039: 34,3512           45160                           AXC,1    CALL                                  
028279,000040: 34,3513           01535                                    MIS                                   
028280,000041: 34,3514           70711                                    DCMTOCDU                              #  PICK UP THE NEW CDU ANGLES FROM MATRIX
028281,000042: 34,3515           77634                           RTB                                            
028282,000043: 34,3516           33526                                    V1STO2S                               
028283,000044: 34,3517           01602                           STORE    NCDU                                  #  NEW CDU ANGLES
028284,000045: 34,3520           77414                           BONCLR   EXIT                                  
028285,000046: 34,3521           01202                                    32D                                   
028286,000047: 34,3522           71602                                    MANUSTAT                              #  TO START MANEUVER
028287,000048: 34,3523           37762                           CAF      TWO                                   #           +0 OTHERWISE
028288,000049: 34,3524           55653        INCRDCDU           TS       SPNDX                                 
028289,000050: 34,3525           51653                           INDEX    SPNDX                                 
028290,000051: 34,3526           31532                           CA       BCDU                                  #  INITIAL CDU ANGLES
028291,000052: 34,3527           00006                           EXTEND                                         #  OR PREVIOUS DESIRED CDU ANGLES
028292,000053: 34,3530           51653                           INDEX    SPNDX                                 
028293,000054: 34,3531           21601                           MSU      NCDU                                  
028294,000055: 34,3532           00006                           EXTEND                                         
028295,000056: 34,3533           73601                           MP       DT/TAU                                
028296,000057: 34,3534           10000                           CCS      A                                     #  CONVERT TO 2S COMPLEMENT
028297,000058: 34,3535           67763                           AD       ONE                                   
028298,000059: 34,3536           13540                           TCF      +2                                    
028299,000060: 34,3537           40000                           COM                                            
028300,000061: 34,3540           51653                           INDEX    SPNDX                                 
028301,000062: 34,3541           54771                           TS       DELDCDU                               #  ANGLE INCREMENTS TO BE ADDED TO
028302,000063: 34,3542           51653                           INDEX    SPNDX                                 #  CDUXD, CDUYD, CDUZD EVERY TENTH SECOND
028303,000064: 34,3543           31601                           CA       NCDU                                  #  BY LEM DAP
028304,000065: 34,3544           51653                           INDEX    SPNDX                                 
028305,000066: 34,3545           57532                           XCH      BCDU                                  
028306,000067: 34,3546           51653                           INDEX    SPNDX                                 
028307,000068: 34,3547           54766                           TS       CDUXD                                 
028308,000069: 34,3550           11653                           CCS      SPNDX                                 
028309,000070: 34,3551           13524                           TCF      INCRDCDU                              #  LOOP FOR THREE AXES
028310,000071: 

Page 669

028312,000073:                                                                                                  #  COMPARE PRESENT TIME WITH TIME TO TERMINATE MANEUVER
028313,000074: 
028314,000075: 34,3552           00006        TMANUCHK           EXTEND                                         
028315,000076: 34,3553           40025                           DCS      TIME2                                 
028316,000077: 34,3554           53606                           DXCH     TTEMP                                 
028317,000078: 34,3555           00006                           EXTEND                                         
028318,000079: 34,3556           31645                           DCA      TM                                    
028319,000080: 34,3557           21606                           DAS      TTEMP                                 #  TM+T0-1-T
028320,000081: 34,3560           11605                           CCS      TTEMP                                 
028321,000082: 34,3561           13642                           TCF      CONTMANU                              #  (TM+T0)-T G 164 SEC
028322,000083: 34,3562           13564                           TCF      +2                                    
028323,000084: 34,3563           13640                           TCF      OVERMANU                              #  (TM+T0)-T L -164 SEC
028324,000085: 34,3564           11606                           CCS      TTEMP      +1                         
028325,000086: 34,3565           13642                           TCF      CONTMANU                              #  (TM+T0)-T G 1 SEC
028326,000087: 34,3566           13570                           TCF      MANUOFF                               #  (TM+T0)-T E 1 SEC
028327,000088: 34,3567           40000                           COM                                            #  (TM+T0)-T L 1 SEC
028328,000089: 34,3570           63637        MANUOFF            AD       ONESEK     +1                         #  (TM+T0)-T E 1 SEC
028329,000090: 34,3571           00006                           EXTEND                                         
028330,000091: 34,3572           63640                           BZMF     OVERMANU                              #  THIS IS A SAFETY PLAY
028331,000092: 34,3573           00004        MANUSTAL           INHINT                                         #  PREPARE TO STOP THE MANEUVER
028332,000093: 34,3574           05663                           TC       WAITLIST                              
028333,000094: 34,3575  E3,1605                                  EBANK=   TTEMP                                 
028334,000095: 34,3575           03666 70063                     2CADR    MANUSTOP                              
028335,000096: 
028336,000097: 34,3577           00003                           RELINT                                         
028337,000098: 34,3600           15567                           TCF      ENDOFJOB                              
028338,000099: 
028339,000100: 34,3601           03146        DT/TAU             DEC      .1                                    
028340,000101: 
028341,000102: 34,3602           77776        MANUSTAT           EXIT                                           #  INITIALIZATION ROUTINE
028342,000103: 34,3603           00006                           EXTEND                                         #  FOR AUTOMATIC MANEUVERS
028343,000104: 34,3604           30025                           DCA      TIME2                                 
028344,000105: 34,3605           21645                           DAS      TM                                    #  TM+T0    MANEUVER COMPLETION TIME
028345,000106: 34,3606           00006                           EXTEND                                         
028346,000107: 34,3607           43637                           DCS      ONESEK                                
028347,000108: 34,3610           21645                           DAS      TM                                    #  (TM+T0)-1
028348,000109: 34,3611           00004                           INHINT                                         
028349,000110: 34,3612           31634                           CA       BRATE                                 #  X-AXIS MANEUVER RATE
028350,000111: 34,3613           54774                           TS       OMEGAPD                               
028351,000112: 34,3614           31636                           CA       BRATE      +2                         #  Y-AXIS MANEUVER RATE
028352,000113: 34,3615           54775                           TS       OMEGAQD                               
028353,000114: 34,3616           31640                           CA       BRATE      +4                         #  Z-AXIS MANEUVER RATE
028354,000115: 34,3617           54776                           TS       OMEGARD                               
028355,000116: 
028356,000117: 34,3620           00006                           EXTEND                                         
028357,000118: 34,3621           30034                           DCA      CDUY                                  
028358,000119: 34,3622           52770                           DXCH     CDUYD                                 
028359,000120: 34,3623           30032                           CAE      CDUX                                  
028360,000121: 34,3624           54766                           TS       CDUXD                                 
028361,000122: 34,3625           05270                           TC       IBNKCALL                              

Page 670

028363,000124: 34,3626           40046                           FCADR    SETMINDB                              
028364,000125: 34,3627           00003                           RELINT                                         
028365,000126: 34,3630           30025                           CA       TIME1                                 
028366,000127: 34,3631           63637                           AD       ONESEK     +1                         
028367,000128: 34,3632           57604                           XCH      NEXTIME                               
028368,000129: 34,3633           06060                           TC       FLAG2UP                               #  SET BIT 11 OF FLAGWRD2
028369,000130: 34,3634           02000                           OCT      2000                                  #  TO SIGNAL KALCMANU IN PROCESS
028370,000131: 34,3635           13523                           TCF      INCRDCDU   -1                         
028371,000132: 
028372,000133: 34,3636           00000        ONESEK             DEC      0          B-14                       
028373,000134: 34,3637           00144                           DEC      100        B-14                       
028374,000135: 
028375,000136: 34,3640           37763        OVERMANU           CAF      ONE                                   #  SAFETY PLAY
028376,000137: 34,3641           13573                           TCF      MANUSTAL                              
028377,000138: 
028378,000139: 34,3642           40025        CONTMANU           CS       TIME1                                 #  RESET FOR NEXT DCDU UPDATE
028379,000140: 34,3643           61604                           AD       NEXTIME                               
028380,000141: 34,3644           10000                           CCS      A                                     
028381,000142: 34,3645           67763                           AD       ONE                                   
028382,000143: 34,3646           13651                           TCF      MANUCALL                              
028383,000144: 34,3647           67745                           AD       NEGMAX                                
028384,000145: 34,3650           40000                           COM                                            
028385,000146: 34,3651           00004        MANUCALL           INHINT                                         #  CALL FOR NEXT UPDATE VIA WAITLIST
028386,000147: 34,3652           05663                           TC       WAITLIST                              
028387,000148: 34,3653  E3,1605                                  EBANK=   TTEMP                                 
028388,000149: 34,3653           03661 70063                     2CADR    UPDTCALL                              
028389,000150: 
028390,000151: 34,3655           00003                           RELINT                                         
028391,000152: 34,3656           33637                           CAF      ONESEK     +1                         #  INCREMENT TIME FOR NEXT UPDATE
028392,000153: 34,3657           27604                           ADS      NEXTIME                               
028393,000154: 34,3660           15567                           TCF      ENDOFJOB                              
028394,000155: 
028395,000156: 
028396,000157: 
028397,000158: 34,3661           35655        UPDTCALL           CAF      PRIO34                                #  SATELLITE PROGRAM TO CALL FOR UPDATE
028398,000159: 34,3662           05516                           TC       FINDVAC                               #  OF STEERING COMMANDS
028399,000160: 34,3663  E3,1605                                  EBANK=   TTEMP                                 
028400,000161: 34,3663           03476 70063                     2CADR    NEWDELHI                              
028401,000162: 
028402,000163: 34,3665           05727                           TC       TASKOVER                              
028403,000164: 

Page 671

028405,000166:                                                                                                  #  ROUTINE FOR TERMINATING AUTOMATIC MANEUVERS
028406,000167: 
028407,000168: 34,3666           37767        MANUSTOP           CAF      ZERO                                  #  ZERO MANEUVER RATES
028408,000169: 34,3667           54773                           TS       DELDCDU2                              
028409,000170: 34,3670           54776                           TS       OMEGARD                               
028410,000171: 34,3671           54772                           TS       DELDCDU1                              
028411,000172: 34,3672           54775                           TS       OMEGAQD                               
028412,000173: 34,3673           31633                           CA       CPSI                                  #  SET DESIRED GIMBAL ANGLES TO
028413,000174: 34,3674           54770                           TS       CDUZD                                 #  DESIRED FINAL GIMBAL ANGLES
028414,000175: 34,3675           31632                           CA       CTHETA                                
028415,000176: 34,3676           54767                           TS       CDUYD                                 
028416,000177: 34,3677           30076                           CA       STATE      +2                         #  CHECK TO SEE IF A FINAL YAW NECESSARY
028417,000178: 34,3700           77746                           MASK     BIT14                                 
028418,000179: 34,3701           00006                           EXTEND                                         
028419,000180: 34,3702           13714                           BZF      KALCROLL                              
028420,000181: 34,3703           31631        ENDROLL            CA       CPHI                                  #  NO FINAL YAW
028421,000182: 34,3704           54766                           TS       CDUXD                                 
028422,000183: 34,3705           37767                           CAF      ZERO                                  
028423,000184: 34,3706           54774                           TS       OMEGAPD                               #  I.E. MANEUVER DID NOT GO THRU
028424,000185: 34,3707           54771                           TS       DELDCDU                               #  GIMBAL LOCK ORIGINALLY
028425,000186: 34,3710           06076        GOODMANU           TC       FLAG2DWN                              #  RESET BIT 11 OF FLAGWRD2 TO SIGNAL END
028426,000187: 34,3711           02000                           OCT      2000                                  #  OF KALCMANU
028427,000188: 34,3712           05225                           TC       POSTJUMP                              #  RETURN UNDER WAITLIST VIA GOODEND
028428,000189: 34,3713           73520                           CADR     CHKAKS                                
028429,000190: 
028430,000191: 35,3520                                           BANK     35                                    
028431,000192: 35,3520  E3,1605                                  EBANK=   TTEMP                                 
028432,000193: 35,3520           37762        CHKAKS             CAF      TWO                                   
028433,000194: 35,3521           55653        AKLOOP             TS       SPNDX                                 #  CHECK THE MAGNITUDE OF THE ATTITUDE
028434,000195: 35,3522           50000                           INDEX    A                                     #  ERROR ON COMPLETION OF A KALCMANU
028435,000196: 35,3523           30766                           CA       CDUXD                                 #  SUPERVISED MANEUVER
028436,000197: 35,3524           00006                           EXTEND                                         
028437,000198: 35,3525           51653                           INDEX    SPNDX                                 #  I.E.   CDUD - CDU
028438,000199: 35,3526           20032                           MSU      CDUX                                  
028439,000200: 35,3527           10000                           CCS      A                                     #  IF THE MAGNITUDE OF THE ERROR EXCEEDS
028440,000201: 35,3530           63545                           AD       =-5DEG                                #  5 DEGREES ON ANY AXIS DISPLAY AN ALARM
028441,000202: 35,3531           13533                           TCF      CHECKASG                              #  INDICATING THAT SPACECRAFT MAY NOT HAVE
028442,000203: 35,3532           63545                           AD       =-5DEG                                #  ACHIEVED THE DESIRED ATTITUDE.
028443,000204: 35,3533           00006        CHECKASG           EXTEND                                         
028444,000205: 35,3534           63540                           BZMF     AKOK                                  
028445,000206: 35,3535           04755                           TC       ALARM                                 
028446,000207: 35,3536           01412                           OCT      01412                                 
028447,000208: 35,3537           13542                           TCF      ENDKMANU                              
028448,000209: 
028449,000210: 35,3540           11653        AKOK               CCS      SPNDX                                 
028450,000211: 35,3541           13521                           TCF      AKLOOP                                
028451,000212: 
028452,000213: 35,3542           36311        ENDKMANU           CAF      THREE                                 #  TERMINATE KALCMANU VIA GOODEND
028453,000214: 35,3543           05225                           TC       POSTJUMP                              
028454,000215: 35,3544           26720                           CADR     GOODEND                               
028455,000216: 

Page 672

028457,000218: 35,3545           77070        =-5DEG             DEC      -455       B-14                       #  =-5 DEGREES SCALED 180 DEG
028458,000219: 
028459,000220: 
028460,000221: 
028461,000222: 34,3714                                           BANK     34                                    
028462,000223: 34,3714  E3,1605                                  EBANK=   TTEMP                                 
028463,000224: 34,3714           30076        KALCROLL           CA       STATE      +2                         #  STATE SWITCH NO. 33
028464,000225: 34,3715           77750                           MASK     BIT12                                 #  0(OFF) = PERFORM A FINAL YAW
028465,000226: 34,3716           00006                           EXTEND                                         #           IF NECESSARY
028466,000227: 34,3717           13721                           BZF      DOROLL                                #  1(ON) = IGNORE ANY FINAL YAW
028467,000228: 34,3720           13705                           TCF      ENDROLL    +2                         
028468,000229: 34,3721           31631        DOROLL             CA       CPHI                                  
028469,000230: 34,3722           00006                           EXTEND                                         #  PERFORM A FINAL ROLL  TO
028470,000231: 34,3723           20766                           MSU      CDUXD                                 #  COMPLETE AUTOMATIC MANEUVER
028471,000232: 34,3724           00006                           EXTEND                                         
028472,000233: 34,3725           63735                           BZMF     FROLLNEG                              
028473,000234: 34,3726           54001        FROLLPOS           TS       L                                     
028474,000235: 34,3727           33754                           CA       ROLLRATE                              
028475,000236: 34,3730           54774                           TS       OMEGAPD                               
028476,000237: 34,3731           43755                           CS       DELFROLL                              
028477,000238: 34,3732           67763                           AD       ONE                                   
028478,000239: 34,3733           54771                           TS       DELDCDU                               
028479,000240: 34,3734           13743                           TCF      ROLLSTAL                              
028480,000241: 34,3735           40000        FROLLNEG           COM                                            
028481,000242: 34,3736           54001                           TS       L                                     
028482,000243: 34,3737           43754                           CS       ROLLRATE                              
028483,000244: 34,3740           54774                           TS       OMEGAPD                               
028484,000245: 34,3741           33755                           CA       DELFROLL                              
028485,000246: 34,3742           54771                           TS       DELDCDU                               
028486,000247: 34,3743           30001        ROLLSTAL           CA       L                                     #  ABS(CPHI-CDUXD)
028487,000248: 34,3744           00006                           EXTEND                                         
028488,000249: 34,3745           73756                           MP       INVRATE                               
028489,000250: 34,3746           00006                           EXTEND                                         
028490,000251: 34,3747           63703                           BZMF     ENDROLL                               
028491,000252: 34,3750           05663                           TC       WAITLIST                              
028492,000253: 34,3751  E3,1605                                  EBANK=   TTEMP                                 
028493,000254: 34,3751           03703 70063                     2CADR    ENDROLL                               
028494,000255: 
028495,000256: 34,3753           05727                           TC       TASKOVER                              
028496,000257: 
028497,000258: 34,3754           01320        ROLLRATE           DEC      720        B-14                       #  = 1.98 DEGREES/SEC
028498,000259: 34,3755           00022        DELFROLL           DEC      18         B-14                       #  MUST BE A WHOLE NUMBER
028499,000260: 34,3756           21616        INVRATE            DEC      .555555                               

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