Source Code

044354,000001: # Copyright: Public domain. 044355,000002: # Filename: MYSUBS.agc 044356,000003: # Purpose: Part of the source code for Colossus 2A, AKA Comanche 055. 044357,000004: # It is part of the source code for the Command Module's (CM) 044358,000005: # Apollo Guidance Computer (AGC), for Apollo 11. 044359,000006: # Assembler: yaYUL 044360,000007: # Contact: Ron Burkey <info@sandroid.org>. 044361,000008: # Website: www.ibiblio.org/apollo. 044362,000009: # Pages: 999-1001 044363,000010: # Mod history: 2009-05-13 RSB Adapted from the Colossus249/ file of the 044364,000011: # same name, using Comanche055 page images. 044365,000012: # 2009-05-20 RSB Corrections: EBANK= changed from MPAC to KMPAC. 044366,000013: 044367,000014: # This source code has been transcribed or otherwise adapted from digitized 044368,000015: # images of a hardcopy from the MIT Museum. The digitization was performed 044369,000016: # by Paul Fjeld, and arranged for by Deborah Douglas of the Museum. Many 044370,000017: # thanks to both. The images (with suitable reduction in storage size and 044371,000018: # consequent reduction in image quality as well) are available online at 044372,000019: # www.ibiblio.org/apollo. If for some reason you find that the images are 044373,000020: # illegible, contact me at info@sandroid.org about getting access to the 044374,000021: # (much) higher-quality images which Paul actually created. 044375,000022: 044376,000023: # Notations on the hardcopy document read, in part: 044377,000024: 044378,000025: # Assemble revision 055 of AGC program Comanche by NASA 044379,000026: # 2021113-051. 10:28 APR. 1, 1969 044380,000027: 044381,000028: # This AGC program shall also be referred to as 044382,000029: # Colossus 2A 044383,000030: 044384,000031: # Page 999 044385,000032: 20,3612 BANK 20 044386,000033: 21,2000 SETLOC MYSUBS 044387,000034: 21,2000 BANK 044388,000035: 044389,000036: 21,2042 E6,1510 EBANK= KMPAC 044390,000037: 21,2042 5074 SPCOS1 EQUALS SPCOS 044391,000038: 21,2042 5075 SPSIN1 EQUALS SPSIN 044392,000039: 21,2042 5074 SPCOS2 EQUALS SPCOS 044393,000040: 21,2042 5075 SPSIN2 EQUALS SPSIN 044394,000041: 044395,000042: 21,2042 COUNT 21/DAPMS 044396,000043: 044397,000044: # ONE AND ONE HALF PRECISION MULTIPLICATION ROUTINE 044398,000045: 044399,000046: 21,2042 55512 SMALLMP TS KMPTEMP # A(X+Y) 044400,000047: 21,2043 00006 EXTEND 044401,000048: 21,2044 71511 MP KMPAC +1 044402,000049: 21,2045 55511 TS KMPAC +1 # AY 044403,000050: 21,2046 35021 CAF ZERO 044404,000051: 21,2047 57510 XCH KMPAC 044405,000052: 21,2050 00006 EXTEND 044406,000053: 21,2051 71512 MP KMPTEMP # AX 044407,000054: 21,2052 21511 DAS KMPAC # AX+AY 044408,000055: 21,2053 00002 TC Q 044409,000056: 044410,000057: # SUBROUTINE FOR DOUBLE PRECISION ADDITIONS OF ANGLES 044411,000058: # A AND L CONTAIN A DP(1S) ANGLE SCALED BY 180 DEGS TO BE ADDED TO KMPAC. 044412,000059: # RESULT IS PLACED IN KMPAC. TIMING = 6 MCT (22 MCT ON OVERFLOW) 044413,000060: 044414,000061: 21,2054 21511 DPADD DAS KMPAC 044415,000062: 21,2055 00006 EXTEND 044416,000063: 21,2056 12073 BZF TSK +1 # NO OVERFLOW 044417,000064: 21,2057 11510 CCS KMPAC 044418,000065: 21,2060 12074 TCF DPADD+ # + OVERFLOW 044419,000066: 21,2061 12063 TCF +2 044420,000067: 21,2062 12076 TCF DPADD- # - OVERFLOW 044421,000068: 21,2063 11511 CCS KMPAC +1 044422,000069: 21,2064 12101 TCF DPADD2+ # UPPER = 0, LOWER + 044423,000070: 21,2065 12067 TCF +2 044424,000071: 21,2066 40000 COM # UPPER = 0, LOWER - 044425,000072: 21,2067 64777 AD POSMAX # LOWER = 0, A = 0 044426,000073: 21,2070 55511 TS KMPAC +1 # CAN NOT OVERFLOW 044427,000074: 21,2071 34777 CA POSMAX # UPPER WAS = 0 044428,000075: 21,2072 55510 TSK TS KMPAC 044429,000076: 21,2073 00002 TC Q 044430,000077: 044431,000078: 21,2074 65001 DPADD+ AD NEGMAX # KMPAC GREATER THAN 0 044432,000079: 21,2075 12072 TCF TSK 044433,000080: 044434,000081: # Page 1000 044435,000082: 21,2076 40000 DPADD- COM 044436,000083: 21,2077 64777 AD POSMAX # KMPAC LESS THAN 0 044437,000084: 21,2100 12072 TCF TSK 044438,000085: 044439,000086: 21,2101 65001 DPADD2+ AD NEGMAX # CAN NOT OVERFLOW 044440,000087: 21,2102 55511 TS KMPAC +1 044441,000088: 21,2103 35001 CA NEGMAX # UPPER WAS = 0 044442,000089: 21,2104 12072 TCF TSK 044443,000090: 044444,000091: # Page 1001 (empty page) 044445,000092: End of include-file MYSUBS.agc. Parent file is MAIN.agc