Source Code

These source-code files were derived from scans of the Colossus 237 (Apollo 8 Command Module) program listing from the private collection of original AGC developer Fred Martin. Scanning was by Ron Burkey. Pre-existing Colossus 249 (Apollo 9 CM) source files were used as a template, and changes between Colossus 249 and Colossus 237 were manually transcribed by a team of volunteers. Note that the page images presented online are of reduced quality, and that additional images are available. Report any conversion errors or legibility problems in page images to info@sandroid.org. Notations on the program listing read, in part:

	GAP: ASSEMBLE REVISION 237 OF AGC PROGRAM COLOSSUS 
	BY NASA 2021111-031  1:17 AUG. 24, 1968
Note that the date is the date of the printout, not the date of the program revision.

021682,000002:                                                                                                  ## Copyright:   Public domain.
021683,000003:                                                                                                  ## Filename:    P76.agc
021684,000004:                                                                                                  ## Purpose:     Part of the source code for Colossus build 237.
021685,000005:                                                                                                  ##              This is for the Command Module's (CM) Apollo Guidance
021686,000006:                                                                                                  ##              Computer (AGC), for Apollo 8.
021687,000007:                                                                                                  ## Assembler:   yaYUL
021688,000008:                                                                                                  ## Contact:     Jim Lawton <jim DOT lawton AT gmail DOT com>
021689,000009:                                                                                                  ## Website:     www.ibiblio.org/apollo/index.html
021690,000010:                                                                                                  ## Page Scans:  www.ibiblio.org/apollo/ScansForConversion/Colossus237/
021691,000011:                                                                                                  ## Mod history: 2011-02-05 JL   Adapted from corresponding Colossus 249 file.
021692,000012:                                                                                                  ##              2016-12-31 RSB  Proofed comment text using octopus/ProoferComments,
021693,000013:                                                                                                  ##                              and corrected errors found.
021694,000014: 

Page 500

021696,000016:                                                                                                  #  1) PROGRAM NAME - TARGET DELTA V PROGRAM (P76).
021697,000017:                                                                                                  #  2) FUNCTIONAL DESCRIPTION - UPON ENTRY BY ASTRONAUT ACTION, P76 FLASHES DSKY REQUESTS TO THE ASTRONAUT
021698,000018:                                                                                                  #           TO PROVIDE VIA DSKY (1) THE DELTA V TO BE APPLIED TO THE OTHER VEHICLE STATE VECTOR AND (2) THE
021699,000019:                                                                                                  #           TIME (TIG) AT WHICH THE OTHER VEHICLE VELOCITY WAS CHANGED BY  EXECUTION OF A THRUSTING MANEUVER. THE
021700,000020:                                                                                                  #           OTHER VEHICLE STATE VECTOR IS INTEGRATED TO TIG AND UPDATED BY THE ADDITION OF DELTA V (DELTA V HAVING
021701,000021:                                                                                                  #           BEEN TRANSFORMED FROM LV TO REF COSYS). USING INTEGRVS, THE    PROGRAM THEN INTEGRATES THE OTHER
021702,000022:                                                                                                  #  VEHICLE STATE VECTOR TO THE STATE VECTOR OF THIS VEHICLE, THUS INSURING THAT THE W-MATRIX AND BOTH VEHICLE
021703,000023:                                                                                                  #  STATES CORRESPOND TO THE SAME TIME.
021704,000024:                                                                                                  #  3) ERASABLE INITIALIZATION REQUIRED - NONE.
021705,000025:                                                                                                  #  4) CALLING SEQUENCES AND EXIT MODES - CALLED BY ASTRONAUT REQUEST THRU DSKY V 37 E 76 E.
021706,000026:                                                                                                  #           EXITS BY TCF ENDOFJOB.
021707,000027:                                                                                                  #  5) OUTPUT - OTHER VEHICLE STATE VECTOR INTEGRATED TO TIG AND INCREMENTED BY DELTA V IN REF COSYS.
021708,000028:                                                                                                  #           THE PUSHLIST CONTAINS THE MATRIX BY WHICH THE INPUT DELTA V MUST BE POST-MULTIPLIED TO CONVERT FROM LV
021709,000029:                                                                                                  #           TO REF COSYS.
021710,000030:                                                                                                  #  6) DEBRIS - OTHER VEHICLE STATE VECTOR.
021711,000031:                                                                                                  #  7) SUBROUTINES CALLED - BANKCALL,GOXDSPF,CSMPREC (OR LEMPREC),ATOPCSM (OR ATOPLEM),INTSTALL,INTWAKE, PHASCHNG
021712,000032:                                                                                                  #           INTPRET, INTEGRVS, AND MINIRECT.
021713,000033: 
021714,000034:                                                                                                  #  8) FLAG USE - MOONFLAG,CMOONFLAG,INTYPFLG,RASFLAG, AND MARKCTR.
021715,000035: 
021716,000036: 30,2000                                           BANK     30                                    
021717,000037: 13,2000                                           SETLOC   P76LOC                                
021718,000038: 13,2000                                           BANK                                           
021719,000039: 
021720,000040: 13,2036                                           COUNT*   $$/P76                                
021721,000041: 
021722,000042: 13,2036  E7,1412                                  EBANK=   TIG                                   
021723,000043: 
021724,000044: 13,2036           05435        P76                TC       UPFLAG                                
021725,000045: 13,2037           00031                           ADRES    TRACKFLG                              
021726,000046: 
021727,000047: 13,2040           32163                           CAF      V06N84                                #  FLASH LAST DELTA V,
021728,000048: 13,2041           04555                           TC       BANKCALL                              #  AND WAIT FOR KEYBOARD ACTION.
021729,000049: 13,2042           20624                           CADR     GOFLASH                               
021730,000050: 13,2043           12155                           TCF      ENDP76                                
021731,000051: 13,2044           02046                           TC       +2                                    #  PROCEED
021732,000052: 13,2045           02040                           TC       -5                                    #  STORE DATA AND REPEAT FLASHING
021733,000053: 13,2046           32164                           CAF      V06N84     +1                         #  FLASH VERB 06 NOUN 33, DISPLAY LAST TIG,
021734,000054: 13,2047           04555                           TC       BANKCALL                              #  AND WAIT FOR KEYBOARD ACTION.
021735,000055: 13,2050           20624                           CADR     GOFLASH                               
021736,000056: 13,2051           12155                           TCF      ENDP76                                
021737,000057: 13,2052           02054                           TC       +2                                    
021738,000058: 13,2053           02046                           TC       -5                                    
021739,000059: 13,2054           06006                           TC       INTPRET                               #  RETURN TO INTERPRETIVE CODE
021740,000060: 13,2055           77745                           DLOAD                                          #  SET D(MPAC)=TIG IN CSEC B28
021741,000061: 13,2056           03413                                    TIG                                   
021742,000062: 13,2057           34041                           STCALL   TDEC1                                 #  SET TDEC1=TIG FOR ORBITAL INTEGRATION
021743,000063: 13,2060           27036                                    OTHPREC                               
021744,000064: 13,2061           53575        COMPMAT            VLOAD    UNIT                                  
021745,000065: 13,2062           00001                                    RATT                                  

Page 501

021747,000067: 13,2063           77676                           VCOMP                                          #  U(-R)
021748,000068: 13,2064           00031                           STORE    24D                                   #  U(-R) TO 24D
021749,000069: 13,2065           53435                           VXV      UNIT                                  #  U(-R)XV = U(VXR)
021750,000070: 13,2066           00007                                    VATT                                  
021751,000071: 13,2067           00023                           STORE    18D                                   
021752,000072: 13,2070           53435                           VXV      UNIT                                  #  U(VXR)XU(-R) = U((RXV)XR)
021753,000073: 13,2071           00031                                    24D                                   
021754,000074: 13,2072           24015                           STOVL    12D                                   
021755,000075: 13,2073           03540                                    DELVOV                                
021756,000076: 13,2074           76505                           VXM      VSL1                                  #  V(MPAC)=DELTA V IN REFCOSYS
021757,000077: 13,2075           00015                                    12D                                   
021758,000078: 13,2076           77655                           VAD                                            
021759,000079: 13,2077           00007                                    VATT                                  
021760,000080: 13,2100           00007                           STORE    6                                     #  V(PD6)=VATT + DELTA V
021761,000081: 13,2101           77624                           CALL                                           #  PREVENT WOULD-BE USER OF ORBITAL
021762,000082: 13,2102           27371                                    INTSTALL                              #  INTEG FROM INTERFERING WITH UPDATING
021763,000083: 13,2103           77624                           CALL                                           
021764,000084: 13,2104           26165                                    P76SUB1                               
021765,000085: 13,2105           53775                           VLOAD    VSR*                                  
021766,000086: 13,2106           00007                                    6                                     
021767,000087: 13,2107           57176                                    0,2                                   
021768,000088: 13,2110           25543                           STOVL    VCV                                   
021769,000089: 13,2111           00001                                    RATT                                  
021770,000090: 13,2112           77657                           VSR*                                           
021771,000091: 13,2113           57176                                    0,2                                   
021772,000092: 13,2114           15535                           STODL    RCV                                   
021773,000093: 13,2115           03413                                    TIG                                   
021774,000094: 13,2116           01517                           STORE    TET                                   
021775,000095: 13,2117           71214                           CLEAR    DLOAD                                 
021776,000096: 13,2120           01673                                    INTYPFLG                              
021777,000097: 13,2121           01571                                    TETTHIS                               
021778,000098: 13,2122           34041        INTOTHIS           STCALL   TDEC1                                 
021779,000099: 13,2123           27066                                    INTEGRVS                              
021780,000100: 13,2124           77624                           CALL                                           
021781,000101: 13,2125           27371                                    INTSTALL                              
021782,000102: 13,2126           77775                           VLOAD                                          
021783,000103: 13,2127           00017                                    RATT1                                 
021784,000104: 13,2130           01503                           STORE    RRECT                                 
021785,000105: 13,2131           15535                           STODL    RCV                                   
021786,000106: 13,2132           00015                                    TAT                                   
021787,000107: 13,2133           25517                           STOVL    TET                                   
021788,000108: 13,2134           00025                                    VATT1                                 
021789,000109: 13,2135           77624                           CALL                                           
021790,000110: 13,2136           23360                                    MINIRECT                              
021791,000111: 13,2137           77776                           EXIT                                           
021792,000112: 13,2140           05301                           TC       PHASCHNG                              
021793,000113: 13,2141           04024                           OCT      04024                                 
021794,000114: 
021795,000115: 13,2142           05435                           TC       UPFLAG                                
021796,000116: 13,2143           00236                           ADRES    REINTFLG                              
021797,000117: 

Page 502

021799,000119: 13,2144           06006                           TC       INTPRET                               
021800,000120: 13,2145           77624                           CALL                                           
021801,000121: 13,2146           26711                                    ATOPOTH                               
021802,000122: 13,2147           77531                           SSP      EXIT                                  
021803,000123: 13,2150           00053                                    QPRET                                 
021804,000124: 13,2151           26154                                    OUT                                   
021805,000125: 13,2152           04555                           TC       BANKCALL                              #  PERMIT USE OF ORBITAL INTEGRATION
021806,000126: 13,2153           27426                           CADR     INTWAKE1                              
021807,000127: 13,2154           77776        OUT                EXIT                                           
021808,000128: 13,2155           34714        ENDP76             CAF      ZERO                                  
021809,000129: 13,2156           55126                           TS       MARKCTR                               #  CLEAR RR TRACKING MARK COUNTER
021810,000130: 13,2157           55125                           TS       VHFCNT                                
021811,000131: 
021812,000132: 13,2160           37716                           CAF      NEGONE                                
021813,000133: 13,2161           55734                           TS       MRKBUF2                               #  INVALIDATE MARK BUFFER
021814,000134: 
021815,000135: 13,2162           14106                           TCF      GOTOPOOH                              
021816,000136: 
021817,000137: 13,2163           01524        V06N84             NV       0684                                  
021818,000138: 13,2164           01441                           NV       0633                                  
021819,000139: 13,2165           43174        P76SUB1            AXT,2    SET                                   
021820,000140: 13,2166           00002                                    2                                     
021821,000141: 13,2167           00063                                    MOONFLAG                              #  SET MEANS MOON IS SPHERE OF INFLUENCE.
021822,000142: 13,2170           77014                           BON      AXT,2                                 
021823,000143: 13,2171           04303                                    CMOONFLG                              #  SET MEANS PERM CM STATE IN LUNAR SPHERE.
021824,000144: 13,2172           00052                                    QPRET                                 
021825,000145: 13,2173           00000                                    0                                     
021826,000146: 13,2174           43414                           CLEAR    RVQ                                   
021827,000147: 13,2175           00263                                    MOONFLAG                              

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