Source Code
![]() |
These source-code files were from the printout at the MIT Museum, with many thanks
to Deborah Douglas, the Museum's Curator of Science and Technology, for releasing
it to us. The printout was digitally photographed by Paul Fjeld. A team of
volunteers transcribed the source code manually from these images or, where
appropriate, modified already-transcribed but similar source Colossus 249 (Apollo 9)
source code to agree with the images from the printout. Note that the page images
presented online are of reduced quality, and that higher-quality 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 055 OF AGC PROGRAM COMANCHE BY NASA 2021113-051 10:28 APR. 1,1969Note that the date is the date of the printout, not the date of the program revision. |
064942,000002: ## Copyright: Public domain.
064943,000003: ## Filename: ALARM_AND_ABORT.agc
064944,000004: ## Purpose: Part of the source code for Comanche, build 055. It
064945,000005: ## is part of the source code for the Command Module's
064946,000006: ## (CM) Apollo Guidance Computer (AGC), Apollo 11.
064947,000007: ## Assembler: yaYUL
064948,000008: ## Reference: pp. 1493-1496
064949,000009: ## Contact: Ron Burkey <info@sandroid.org>
064950,000010: ## Website: http://www.ibiblio.org/apollo.
064951,000011: ## Mod history: 2009-05-07 RSB Adapted from Colossus249 file of the same
064952,000012: ## name, and page images. Corrected various
064953,000013: ## typos in the transcription of program
064954,000014: ## comments, and these should be back-ported
064955,000015: ## to Colossus249.
064956,000016: ## 2010-08-24 JL Fixed page numbers and some indents.
064957,000017: ## 2016-12-22 RSB Proofed comment text using octopus/ProoferComments
064958,000018: ## and corrected the errors found.
064959,000019: ##
064960,000020: ## The contents of the "Comanche055" files, in general, are transcribed
064961,000021: ## from scanned documents.
064962,000022: ##
064963,000023: ## Assemble revision 055 of AGC program Comanche by NASA
064964,000024: ## 2021113-051. April 1, 1969.
064965,000025: ##
064966,000026: ## This AGC program shall also be referred to as Colossus 2A
064967,000027: ##
064968,000028: ## Prepared by
064969,000029: ## Massachusetts Institute of Technology
064970,000030: ## 75 Cambridge Parkway
064971,000031: ## Cambridge, Massachusetts
064972,000032: ##
064973,000033: ## under NASA contract NAS 9-4065.
064974,000034: ##
064975,000035: ## Refer directly to the online document mentioned above for further
064976,000036: ## information. Please report any errors to info@sandroid.org.
064977,000037:
![]() |
Page 1493 |
064979,000039: # THE FOLLOWING SUBROUTINE MAY BE CALLED TO DISPLAY A NON-ABORTIVE ALARM CONDITION. IT MAY BE CALLED
064980,000040: # EITHER IN INTERRUPT OR UNDER EXECUTIVE CONTROL.
064981,000041:
064982,000042: # CALLING SEQUENCE IS AS FOLLOWS:
064983,000043: # TC ALARM
064984,000044: # OCT NNNNN
064985,000045: # (RETURNS HERE)
064986,000046:
064987,000047: 5650 BLOCK 02
064988,000048: 4000 SETLOC FFTAG7
064989,000049: 4000 BANK
064990,000050:
064991,000051: 5650 0375 EBANK= FAILREG
064992,000052:
064993,000053: 5650 COUNT 02/ALARM
064994,000054:
064995,000055: # ALARM TURNS ON THE PROGRAM ALARM LIGHT, BUT DOES NOT DISPLAY.
064996,000056:
064997,000057: 5650 00004 ALARM INHINT
064998,000058:
064999,000059: 5651 30002 CA Q
065000,000060: 5652 55363 ALARM2 TS ALMCADR
065001,000061: 5653 50002 INDEX Q
065002,000062: 5654 30000 CA 0
065003,000063: 5655 54001 BORTENT TS L
065004,000064:
065005,000065: 5656 30006 PRIOENT CA BBANK
065006,000066: 5657 00006 +1 EXTEND
065007,000067: 5660 04007 ROR SUPERBNK # ADD SUPER BITS.
065008,000068: 5661 55364 TS ALMCADR +1
065009,000069:
065010,000070: 5662 30002 LARMENT CA Q # STORE RETURN FOR ALARM
065011,000071: 5663 54061 TS ITEMP1
065012,000072:
065013,000073: 5664 30164 CA LOC
065014,000074: 5665 54057 TS LOCALARM
065015,000075: 5666 30165 CA BANKSET
065016,000076: 5667 54060 TS BANKALRM
065017,000077:
065018,000078: 5670 10375 CHKFAIL1 CCS FAILREG # IS ANYTHING IN FAILREG
065019,000079: 5671 15674 TCF CHKFAIL2 # YES TRY NEXT REG
065020,000080: 5672 22375 LXCH FAILREG
065021,000081: 5673 15706 TCF PROGLARM # TURN ALARM LIGHT ON FOR FIRST ALARM
065022,000082:
065023,000083: 5674 10376 CHKFAIL2 CCS FAILREG +1
065024,000084: 5675 15700 TCF FAIL3
065025,000085: 5676 22376 LXCH FAILREG +1
065026,000086: 5677 15711 TCF MULTEXIT
065027,000087:
065028,000088: 5700 30377 FAIL3 CA FAILREG +2
![]() |
Page 1494 |
065030,000090: 5701 74777 MASK POSMAX
065031,000091: 5702 10000 CCS A
065032,000092: 5703 15715 TCF MULTFAIL
065033,000093: 5704 22377 LXCH FAILREG +2
065034,000094: 5705 15711 TCF MULTEXIT
065035,000095:
065036,000096: 5706 41036 PROGLARM CS DSPTAB +11D
065037,000097: 5707 77765 MASK OCT40400
065038,000098: 5710 27036 ADS DSPTAB +11D
065039,000099:
065040,000100: 5711 56061 MULTEXIT XCH ITEMP1 # OBTAIN RETURN ADDRESS IN A
065041,000101: 5712 00003 RELINT
065042,000102: 5713 50000 INDEX A
065043,000103: 5714 00001 TC 1
065044,000104:
065045,000105: 5715 30001 MULTFAIL CA L
065046,000106: 5716 65001 AD BIT15
065047,000107: 5717 54377 TS FAILREG +2
065048,000108:
065049,000109: 5720 15711 TCF MULTEXIT
065050,000110:
065051,000111: # PRIOLARM DISPLAYS V05N09 VIA PRIODSPR WITH 3 RETURNS TO THE USER FROM THE ASTRONAUT AT CALL LOC +1,+2,+3 AND
065052,000112: # AN IMMEDIATE RETURN TO THE USER AT CALL LOC +4. EXAMPLE FOLLOWS,
065053,000113: # CAF OCTXX ALARM CODE
065054,000114: # TC BANKCALL
065055,000115: # CADR PRIOLARM
065056,000116:
065057,000117: # ... ...
065058,000118: # ... ...
065059,000119: # ... ... ASTRONAUT RETURN
065060,000120: # TC PHASCHNG IMMEDIATE RETURN TO USER. RESTART
065061,000121: # OCT X.1 PHASE CHANGE FOR PRIO DISPLAY
065062,000122:
065063,000123: 10,3766 BANK 10
065064,000124: 10,2000 SETLOC DISPLAYS
065065,000125: 10,2000 BANK
065066,000126:
065067,000127: 10,3766 COUNT 10/DSPLA
065068,000128: 10,3766 00004 PRIOLARM INHINT # * * * KEEP IN DISPLAY ROUTINES BANK
065069,000129: 10,3767 54001 TS L # SAVE ALARM CODE
065070,000130:
065071,000131: 10,3770 30133 CA BUF2 # 2 CADR OF PRIOLARM USER
065072,000132: 10,3771 55363 TS ALMCADR
065073,000133: 10,3772 30134 CA BUF2 +1
065074,000134: 10,3773 05657 TC PRIOENT +1 # * LEAVE L ALONE
065075,000135: 10,3774 77467 -2SEC DEC -200 B-14 # *** DONT MOVE
065076,000136: 10,3775 35050 CAF V05N09
065077,000137: 10,3776 12726 TCF PRIODSPR
065078,000138:
![]() |
Page 1495 |
065080,000140:
065081,000141: 5721 BLOCK 02
065082,000142: 6000 SETLOC FFTAG13
065083,000143: 6000 BANK
065084,000144:
065085,000145: 7755 COUNT 02/ALARM
065086,000146:
065087,000147: 7755 00004 BAILOUT INHINT
065088,000148: 7756 30002 CA Q
065089,000149: 7757 55363 TS ALMCADR
065090,000150:
065091,000151: 7760 04662 TC BANKCALL
065092,000152: 7761 40000 CADR VAC5STOR
065093,000153:
065094,000154: 7762 51363 INDEX ALMCADR
065095,000155: 7763 30000 CAF 0
065096,000156: 7764 05655 TC BORTENT
065097,000157: 7765 40400 OCT40400 OCT 40400
065098,000158:
065099,000159: 7766 00004 INHINT
065100,000160: 7767 35016 WHIMPER CA TWO
065101,000161: 7770 60005 AD Z
065102,000162: 7771 54017 TS BRUPT
065103,000163: 7772 50017 RESUME
065104,000164: 7773 04701 TC POSTJUMP # RESUME SENDS CONTROL HERE
065105,000165: 7774 12651 CADR ENEMA
065106,000166:
065107,000167: 4000 SETLOC FFTAG7
065108,000168: 4000 BANK
065109,000169:
065110,000170: 5721 00004 POODOO INHINT
065111,000171: 5722 30002 CA Q
065112,000172: 5723 55363 TS ALMCADR
065113,000173:
065114,000174: 5724 04662 TC BANKCALL
065115,000175: 5725 40000 CADR VAC5STOR # STORE ERASABLES FOR DEBUGGING PURPOSES.
065116,000176:
065117,000177: 5726 51363 INDEX ALMCADR
065118,000178: 5727 30000 CAF 0
065119,000179: 5730 05655 ABORT2 TC BORTENT
065120,000180: 5731 77770 OCT77770 OCT 77770 # DONT MOVE
065121,000181: 5732 35012 CA V37FLBIT # IS AVERAGE G ON
065122,000182: 5733 70103 MASK FLAGWRD7
065123,000183: 5734 10000 CCS A
065124,000184: 5735 07766 TC WHIMPER -1 # YES. DONT DO POODOO. DO BAILOUT.
065125,000185:
065126,000186: 5736 05560 TC DOWNFLAG
065127,000187: 5737 00067 ADRES STATEFLG
065128,000188:
065129,000189: 5740 05560 TC DOWNFLAG
065130,000190:
![]() |
Page 1496 |
065132,000192: 5741 00236 ADRES REINTFLG
065133,000193:
065134,000194: 5742 05560 TC DOWNFLAG
065135,000195: 5743 00054 ADRES NODOFLAG
065136,000196:
065137,000197: 5744 04662 TC BANKCALL
065138,000198: 5745 12501 CADR MR.KLEAN
065139,000199: 5746 07767 TC WHIMPER
065140,000200:
065141,000201: 5747 00004 CCSHOLE INHINT
065142,000202: 5750 30002 CA Q
065143,000203: 5751 55363 TS ALMCADR
065144,000204: 5752 04662 TC BANKCALL
065145,000205: 5753 40000 CADR VAC5STOR
065146,000206: 5754 35756 CA OCT1103
065147,000207: 5755 05730 TC ABORT2
065148,000208: 5756 01103 OCT1103 OCT 1103
065149,000209: 5757 00004 CURTAINS INHINT
065150,000210: 5760 30002 CA Q
065151,000211: 5761 05652 TC ALARM2
065152,000212: 5762 00217 OCT217 OCT 00217
065153,000213: 5763 01363 TC ALMCADR # RETURN TO USER
065154,000214:
065155,000215: 5764 5217 DOALARM EQUALS ENDOFJOB
065156,000216:
065157,000217: # CALLING SEQUENCE FOR VARALARM
065158,000218:
065159,000219: # CAF (ALARM)
065160,000220: # TC VARALARM
065161,000221:
065162,000222: # VARALARM TURNS ON PROGRAM ALARM LIGHT BUT DOES NOT DISPLAY
065163,000223:
065164,000224: 5764 00004 VARALARM INHINT
065165,000225:
065166,000226: 5765 54001 TS L # SAVE USERS ALARM CODE
065167,000227:
065168,000228: 5766 30002 CA Q # SAVE USERS Q
065169,000229: 5767 55363 TS ALMCADR
065170,000230:
065171,000231: 5770 05656 TC PRIOENT
065172,000232: 5771 00014 OCT14 OCT 14 # DONT MOVE
065173,000233:
065174,000234: 5772 01363 TC ALMCADR # RETURN TO USER
065175,000235:
065176,000236: 5773 7755 ABORT EQUALS BAILOUT # *** TEMPORARY UNTIL ABORT CALLS OUT
End of include-file ALARM_AND_ABORT.agc. Parent file is MAIN.agc