Source Code

This is the source-code for the Apollo 9 Command Module's Guidance Computer. These files were derived originally from the scan from MIT's Dibner Institute's now-discontinued website titled "History of Recent Science and Technology", which in turn was originally created by Gary Neff, though his high-quality scans were unfortunately reduced in legibility when presented online. The markings on the front of the printout imply that it was the original AGC developer Norm Brodeur's copy. A scan by Ron Burkey has superceded it, made from a more-legible copy from the collection of original AGC developer Fred Martin. The source code was transcribed from those images by Ron Burkey. 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:

	ASSEMBLE REVISION 249 OF AGC PROGRAM COLOSSUS BY NASA 2021111-041
	20'35 OCT. 28,1968
Note that the date is the date of the printout, not the date of the program revision.

060882,000002:                                                                                                  ## Copyright:   Public domain.
060883,000003:                                                                                                  ## Filename:    IMU_MODE_SWITCHING_ROUTINES.agc
060884,000004:                                                                                                  ## Purpose:     Part of the source code for Colossus, build 249.
060885,000005:                                                                                                  ##              It is part of the source code for the Command Module's (CM)
060886,000006:                                                                                                  ##              Apollo Guidance Computer (AGC), for Apollo 9.
060887,000007:                                                                                                  ## Assembler:   yaYUL
060888,000008:                                                                                                  ## Reference:   Starts on p. 1388
060889,000009:                                                                                                  ## Contact:     Ron Burkey <info@sandroid.org>.
060890,000010:                                                                                                  ## Website:     www.ibiblio.org/apollo.
060891,000011:                                                                                                  ## Mod history: 08/30/04   RSB  Adapted from corresponding Luminary131 file.
060892,000012:                                                                                                  ##              2010-10-24 JL   Indentation fixes.
060893,000013:                                                                                                  ##              2010-10-24 JL   Fixed page number.
060894,000014:                                                                                                  ##              2011-05-07 JL   Removed workaround.
060895,000015:                                                                                                  ##              2017-01-06 RSB  Page numbers now agree with those on the
060896,000016:                                                                                                  ##                              original hardcopy, as opposed to the PDF page
060897,000017:                                                                                                  ##                              numbers in 1701.pdf.
060898,000018:                                                                                                  ##              2017-01-14 RSB  Cross-diff'd comment text (not whitespace)
060899,000019:                                                                                                  ##                              vs the already-proofed corresponding Colossus
060900,000020:                                                                                                  ##                              237 and Comanche 55 source-code files
060901,000021:                                                                                                  ##                              and corrected errors found.
060902,000022:                                                                                                  ##              2017-03-15 RSB  Comment-text fixes identified in 6-way
060903,000023:                                                                                                  ##                              side-by-side diff of Sunburst 120 and Luminary 
060904,000024:                                                                                                  ##                              69/99/116/131/210.
060905,000025: 
060906,000026:                                                                                                  ## The contents of the "Colossus249" files, in general, are transcribed 
060907,000027:                                                                                                  ## from a scanned copy of the program listing.  Notations on this
060908,000028:                                                                                                  ## document read, in part:
060909,000029:                                                                                                  ##
060910,000030:                                                                                                  ##      Assemble revision 249 of AGC program Colossus by NASA
060911,000031:                                                                                                  ##      2021111-041.  October 28, 1968.  
060912,000032:                                                                                                  ##
060913,000033:                                                                                                  ##      This AGC program shall also be referred to as
060914,000034:                                                                                                  ##                              Colossus 1A
060915,000035:                                                                                                  ##
060916,000036:                                                                                                  ##      Prepared by
060917,000037:                                                                                                  ##                      Massachusetts Institute of Technology
060918,000038:                                                                                                  ##                      75 Cambridge Parkway
060919,000039:                                                                                                  ##                      Cambridge, Massachusetts
060920,000040:                                                                                                  ##      under NASA contract NAS 9-4065.
060921,000041:                                                                                                  ##
060922,000042:                                                                                                  ## Refer directly to the online document mentioned above for further information.
060923,000043:                                                                                                  ## Please report any errors (relative to the scanned pages) to info@sandroid.org.
060924,000044:                                                                                                  ##
060925,000045:                                                                                                  ## In some cases, where the source code for Luminary 131 overlaps that of 
060926,000046:                                                                                                  ## Colossus 249, this code is instead copied from the corresponding Luminary 131
060927,000047:                                                                                                  ## source file, and then is proofed to incorporate any changes.
060928,000048: 

Page 1388

060930,000050:    5410                                           BLOCK    02                                    
060931,000051:    4000                                           SETLOC   FFTAG3                                
060932,000052:    4000                                           BANK                                           
060933,000053: 
060934,000054:    5410  E3,1471                                  EBANK=   COMMAND                               
060935,000055: 
060936,000056:                                                                                                  #  FIXED-FIXED ROUTINES.
060937,000057: 
060938,000058:    5410                                           COUNT    02/IMODE                              
060939,000059: 
060940,000060:    5410           34714        ZEROICDU           CAF      ZERO                                  #  ZERO ICDU COUNTERS.
060941,000061:    5411           54032                           TS       CDUX                                  
060942,000062:    5412           54033                           TS       CDUY                                  
060943,000063:    5413           54034                           TS       CDUZ                                  
060944,000064:    5414           00002                           TC       Q                                     
060945,000065: 
060946,000066:    5415     4702               SPSCODE            =        BIT9                                  
060947,000067: 

Page 1389

060949,000069:                                                                                                  #  IMU ZEROING ROUTINE.
060950,000070: 
060951,000071: 11,3721                                           BANK     11                                    
060952,000072: 07,2000                                           SETLOC   MODESW                                
060953,000073: 07,2000                                           BANK                                           
060954,000074: 
060955,000075: 07,2516                                           COUNT    07/IMODE                              
060956,000076: 
060957,000077: 07,2516           00004        IMUZERO            INHINT                                         #  ROUTINE TO ZERO ICDUS.
060958,000078: 07,2517           41036                           CS       DSPTAB     +11D                       #  DONT ZERO CDUS IF IMU IN GIMBAL LOCK AND
060959,000079: 07,2520           74726                           MASK     BITS4&6                               #  COARSE ALIGN (GIMBAL RUNAWAY PROTECTION)
060960,000080: 07,2521           10000                           CCS      A                                     
060961,000081: 07,2522           12526                           TCF      IMUZEROA                              
060962,000082: 
060963,000083: 07,2523           05537                           TC       ALARM                                 #  IF SO.
060964,000084: 07,2524           00206                           OCT      00206                                 
060965,000085: 
060966,000086: 07,2525           13461                           TCF      CAGETSTJ   +4                         #  IMMEDIATE FAILURE.
060967,000087: 
060968,000088: 07,2526           03455        IMUZEROA           TC       CAGETSTJ                              
060969,000089: 
060970,000090:                                                                                                  #  DO ALL THE WORK.
060971,000091: 
060972,000092: 07,2527           41321                           CS       IMODES33                              #  DISABLE DAP AUTO AND HOLD MODES
060973,000093: 07,2530           74730                           MASK     SUPER011                              #        BIT5 FOR GROUND
060974,000094: 07,2531           27321                           ADS      IMODES33                              
060975,000095: 
060976,000096: 07,2532           41320                           CS       IMODES30                              #  INHIBIT ICDUFAIL AND IMUFAIL (IN CASE WE
060977,000097: 07,2533           75656                           MASK     BITS3&4                               #  JUST CAME OUT OF COARSE ALIGN).
060978,000098: 07,2534           27320                           ADS      IMODES30                              
060979,000099: 
060980,000100: 07,2535           44726                           CS       BITS4&6                               #  SEND ZERO ENCODE WITH COARSE AND ERROR
060981,000101: 07,2536           00006                           EXTEND                                         #  COUNTER DISABLED.
060982,000102: 07,2537           03012                           WAND     CHAN12                                
060983,000103: 
060984,000104: 07,2540           03070                           TC       NOATTOFF                              #  TURN OFF NO ATT LAMP.
060985,000105: 
060986,000106: 07,2541           34706                           CAF      BIT5                                  
060987,000107: 07,2542           00006                           EXTEND                                         
060988,000108: 07,2543           05012                           WOR      CHAN12                                
060989,000109: 
060990,000110: 07,2544           05410                           TC       ZEROICDU                              
060991,000111: 07,2545           34705                           CAF      BIT6                                  #  WAIT 320 MS TO GIVE AGS ADEQUATE TIME TO
060992,000112: 07,2546           05140                           TC       WAITLIST                              #  RECEIVE ITS PULSE TRAIN.
060993,000113: 07,2547  E3,1474                                  EBANK=   CDUIND                                
060994,000114: 07,2547           02561 16103                     2CADR    IMUZERO2                              
060995,000115: 
060996,000116: 07,2551           41320                           CS       IMODES30                              #  SEE IF IMU OPERATING AND ALARM IF NOT.
060997,000117: 07,2552           74702                           MASK     BIT9                                  
060998,000118: 07,2553           10000                           CCS      A                                     
060999,000119: 07,2554           12557                           TCF      MODEEXIT                              

Page 1390

061001,000121: 07,2555           05537                           TC       ALARM                                 
061002,000122: 07,2556           00210                           OCT      210                                   
061003,000123: 
061004,000124: 07,2557           00003        MODEEXIT           RELINT                                         #  GENERAL MODE-SWITCHING EXIT.
061005,000125: 07,2560           14570                           TCF      SWRETURN                              
061006,000126: 
061007,000127: 07,2561           03443        IMUZERO2           TC       CAGETEST                              
061008,000128: 07,2562           05410                           TC       ZEROICDU                              #  ZERO CDUX, CDUY, CDUZ
061009,000129: 
061010,000130: 07,2563           44706                           CS       BIT5                                  #  REMOVE ZERO DISCRETE.
061011,000131: 07,2564           00006                           EXTEND                                         
061012,000132: 07,2565           03012                           WAND     CHAN12                                
061013,000133: 
061014,000134: 07,2566           34700                           CAF      BIT11                                 #  WAIT 10 SECS FOR CTRS TO FIND GIMBALS
061015,000135: 07,2567           05161                           TC       VARDELAY                              
061016,000136: 
061017,000137: 07,2570           03443        IMUZERO3           TC       CAGETEST                              
061018,000138: 07,2571           45656                           CS       BITS3&4                               #  REMOVE IMUFAIL AND ICDUFAIL INHIBIT.
061019,000139: 07,2572           71320                           MASK     IMODES30                              
061020,000140: 07,2573           55320                           TS       IMODES30                              
061021,000141: 
061022,000142: 07,2574           44730                           CS       SUPER011                              #  ENABLE DAP AUTO AND HOLD MODES
061023,000143: 07,2575           71321                           MASK     IMODES33                              #        BIT5 FOR GROUND
061024,000144: 07,2576           55321                           TS       IMODES33                              
061025,000145: 
061026,000146: 07,2577           04633                           TC       IBNKCALL                              #  SET ISS WARNING IF EITHER OF ABOVE ARE
061027,000147: 07,2600           14665                           CADR     SETISSW                               #  PRESENT.
061028,000148: 
061029,000149: 07,2601           13433                           TCF      ENDIMU                                
061030,000150: 

Page 1391

061032,000152:                                                                                                  #  IMU COARSE ALIGN MODE.
061033,000153: 
061034,000154: 07,2602           00004        IMUCOARS           INHINT                                         
061035,000155: 07,2603           03455                           TC       CAGETSTJ                              
061036,000156: 07,2604           02746                           TC       SETCOARS                              
061037,000157: 
061038,000158: 07,2605           36211                           CAF      SIX                                   
061039,000159: 07,2606           05140                           TC       WAITLIST                              
061040,000160: 07,2607  E3,1474                                  EBANK=   CDUIND                                
061041,000161: 07,2607           02612 16103                     2CADR    COARS                                 
061042,000162: 
061043,000163: 07,2611           12557                           TCF      MODEEXIT                              
061044,000164: 
061045,000165: 07,2612           03443        COARS              TC       CAGETEST                              
061046,000166: 07,2613           34705                           CAF      BIT6                                  #  ENABLE ALL THREE ISS CDU ERROR COUNTERS
061047,000167: 07,2614           00006                           EXTEND                                         
061048,000168: 07,2615           05012                           WOR      CHAN12                                
061049,000169: 
061050,000170: 07,2616           34711                           CAF      TWO                                   #  SET CDU INDICATOR
061051,000171: 07,2617           55474        COARS1             TS       CDUIND                                
061052,000172: 
061053,000173: 07,2620           51474                           INDEX    CDUIND                                #  COMPUTE THETAD - THETAA IN 1:S
061054,000174: 07,2621           31155                           CA       THETAD                                #        COMPLEMENT FORM
061055,000175: 07,2622           00006                           EXTEND                                         
061056,000176: 07,2623           51474                           INDEX    CDUIND                                
061057,000177: 07,2624           20032                           MSU      CDUX                                  
061058,000178: 07,2625           00006                           EXTEND                                         
061059,000179: 07,2626           74676                           MP       BIT13                                 #  SHIFT RIGHT 2
061060,000180: 07,2627           56001                           XCH      L                                     #  ROUND
061061,000181: 07,2630           60000                           DOUBLE                                         
061062,000182: 07,2631           54061                           TS       ITEMP1                                
061063,000183: 07,2632           12634                           TCF      +2                                    
061064,000184: 07,2633           26001                           ADS      L                                     
061065,000185: 
061066,000186: 07,2634           51474                           INDEX    CDUIND                                #  DIFFERENCE TO BE COMPUTED
061067,000187: 07,2635           23471                           LXCH     COMMAND                               
061068,000188: 07,2636           11474                           CCS      CDUIND                                
061069,000189: 07,2637           02617                           TC       COARS1                                
061070,000190: 
061071,000191: 07,2640           34711                           CAF      TWO                                   #  MINIMUM OF 4 MS WAIT
061072,000192: 07,2641           05161                           TC       VARDELAY                              
061073,000193: 

Page 1392

061075,000195: 07,2642           03443        COARS2             TC       CAGETEST                              #  DONT CONTINUE IF CAGED.
061076,000196: 07,2643           54061                           TS       ITEMP1                                #  SETS TO +0.
061077,000197: 07,2644           34711                           CAF      TWO                                   #  SET CDU INDICATOR
061078,000198: 07,2645           55474                 +3        TS       CDUIND                                
061079,000199: 
061080,000200: 07,2646           51474                           INDEX    CDUIND                                
061081,000201: 07,2647           11471                           CCS      COMMAND                               #  NUMBER OF PULSES REQUIRED
061082,000202: 07,2650           02654                           TC       COMPOS                                #  GREATER THAN MAX ALLOWED
061083,000203: 07,2651           02663                           TC       NEXTCDU    +1                         
061084,000204: 07,2652           02721                           TC       COMNEG                                
061085,000205: 07,2653           02663                           TC       NEXTCDU    +1                         
061086,000206: 
061087,000207: 07,2654           63544        COMPOS             AD       -COMMAX                               #  COMMAX = MAX NUMBER OF PULSES ALLOWED
061088,000208: 07,2655           00006                           EXTEND                                         #        MINUS ONE
061089,000209: 07,2656           62731                           BZMF     COMZERO                               
061090,000210: 07,2657           51474                           INDEX    CDUIND                                
061091,000211: 07,2660           55471                           TS       COMMAND                               #  REDUCE COMMAND BY MAX NUMBER OF PULSES
061092,000212: 07,2661           43545                           CS       -COMMAX-                              #        ALLOWED
061093,000213: 
061094,000214: 07,2662           24061        NEXTCDU            INCR     ITEMP1                                
061095,000215: 07,2663           64713                           AD       NEG0                                  
061096,000216: 07,2664           51474                           INDEX    CDUIND                                
061097,000217: 07,2665           54050                           TS       CDUXCMD                               #  SET UP COMMAND REGISTER.
061098,000218: 
061099,000219: 07,2666           11474                           CCS      CDUIND                                
061100,000220: 07,2667           02645                           TC       COARS2     +3                         
061101,000221: 
061102,000222: 07,2670           10061                           CCS      ITEMP1                                #  SEE IF ANY PULSES TO GO OUT.
061103,000223: 07,2671           12735                           TCF      SENDPULS                              
061104,000224: 
061105,000225: 07,2672           05156                           TC       FIXDELAY                              #  WAIT FOR GIMBALS TO SETTLE.
061106,000226: 07,2673           00226                           DEC      150        B-14                       
061107,000227: 
061108,000228: 07,2674           34711                           CAF      TWO                                   #  AT END OF COMMAND, CHECK TO SEE THAT
061109,000229: 07,2675           54061        CHKCORS            TS       ITEMP1                                #  GIMBALS ARE WITHIN 2 DEGREES OF THETAD.
061110,000230: 07,2676           50000                           INDEX    A                                     
061111,000231: 07,2677           30032                           CA       CDUX                                  
061112,000232: 07,2700           00006                           EXTEND                                         
061113,000233: 07,2701           50061                           INDEX    ITEMP1                                
061114,000234: 07,2702           21155                           MSU      THETAD                                
061115,000235: 07,2703           10000                           CCS      A                                     
061116,000236: 07,2704           12712                           TCF      COARSERR                              
061117,000237: 07,2705           12707                           TCF      CORSCHK2                              
061118,000238: 07,2706           12712                           TCF      COARSERR                              
061119,000239: 

Page 1393

061121,000241: 07,2707           10061        CORSCHK2           CCS      ITEMP1                                
061122,000242: 07,2710           12675                           TCF      CHKCORS                               
061123,000243: 07,2711           13433                           TCF      ENDIMU                                #  END OF COARSE ALIGNMENT.
061124,000244: 
061125,000245: 07,2712           62720        COARSERR           AD       COARSTOL                              #  2 DEGREES.
061126,000246: 07,2713           00006                           EXTEND                                         
061127,000247: 07,2714           62707                           BZMF     CORSCHK2                              
061128,000248: 
061129,000249: 07,2715           05537                           TC       ALARM                                 #  COARSE ALIGN ERROR.
061130,000250: 07,2716           00211                           OCT      211                                   
061131,000251: 
061132,000252: 07,2717           13441                           TCF      IMUBAD                                
061133,000253: 
061134,000254: 07,2720           77511        COARSTOL           DEC      -.01111                               #  2 DEGREES SCALED AT HALF-REVOLUTIONS
061135,000255: 
061136,000256: 07,2721           63544        COMNEG             AD       -COMMAX                               
061137,000257: 07,2722           00006                           EXTEND                                         
061138,000258: 07,2723           62731                           BZMF     COMZERO                               
061139,000259: 07,2724           40000                           COM                                            
061140,000260: 07,2725           51474                           INDEX    CDUIND                                
061141,000261: 07,2726           55471                           TS       COMMAND                               
061142,000262: 07,2727           33545                           CA       -COMMAX-                              
061143,000263: 07,2730           02662                           TC       NEXTCDU                               
061144,000264: 
061145,000265: 07,2731           34714        COMZERO            CAF      ZERO                                  
061146,000266: 07,2732           51474                           INDEX    CDUIND                                
061147,000267: 07,2733           57471                           XCH      COMMAND                               
061148,000268: 07,2734           02662                           TC       NEXTCDU                               
061149,000269: 
061150,000270: 07,2735           37707        SENDPULS           CAF      13,14,15                              
061151,000271: 07,2736           00006                           EXTEND                                         
061152,000272: 07,2737           05014                           WOR      CHAN14                                
061153,000273: 07,2740           33546                           CAF      600MS                                 
061154,000274: 07,2741           12641                           TCF      COARS2     -1                         #  THEN TO VARDELAY
061155,000275: 
061156,000276: 07,2742           34705        CA+ECE             CAF      BIT6                                  #  ENABLE ALL THREE ISS CDU ERROR COUNTERS
061157,000277: 07,2743           00006                           EXTEND                                         
061158,000278: 07,2744           05012                           WOR      CHAN12                                
061159,000279: 07,2745           05213                           TC       TASKOVER                              
061160,000280: 

Page 1394

061162,000282: 07,2746           34707        SETCOARS           CAF      BIT4                                  #  BYPASS IF ALREADY IN COARSE ALIGN
061163,000283: 07,2747           00006                           EXTEND                                         
061164,000284: 07,2750           02012                           RAND     CHAN12                                
061165,000285: 07,2751           10000                           CCS      A                                     
061166,000286: 07,2752           00002                           TC       Q                                     
061167,000287: 
061168,000288: 07,2753           44705                           CS       BIT6                                  #  CLEAR ISS ERROR COUNTERS
061169,000289: 07,2754           00006                           EXTEND                                         
061170,000290: 07,2755           03012                           WAND     CHAN12                                
061171,000291: 
061172,000292: 07,2756           44701                           CS       BIT10                                 #  KNOCK DOWN GYRO ACTIVITY
061173,000293: 07,2757           00006                           EXTEND                                         
061174,000294: 07,2760           03014                           WAND     CHAN14                                
061175,000295: 07,2761           44714                           CS       ZERO                                  
061176,000296: 07,2762           54047                           TS       GYROCMD                               
061177,000297: 
061178,000298: 07,2763           34707                           CAF      BIT4                                  #  PUT ISS IN COARSE ALIGN
061179,000299: 07,2764           00006                           EXTEND                                         
061180,000300: 07,2765           05012                           WOR      CHAN12                                
061181,000301: 
061182,000302: 07,2766           41036                           CS       DSPTAB     +11D                       #  TURN ON NO ATT LAMP
061183,000303: 07,2767           73011                           MASK     OCT40010                              
061184,000304: 07,2770           27036                           ADS      DSPTAB     +11D                       
061185,000305: 
061186,000306: 07,2771           41321                           CS       IMODES33                              #  DISABLE DAP AUTO AND HOLD MODES
061187,000307: 07,2772           74705                           MASK     BIT6                                  
061188,000308: 07,2773           27321                           ADS      IMODES33                              
061189,000309: 
061190,000310: 07,2774           41320                           CS       IMODES30                              #  DISABLE IMUFAIL
061191,000311: 07,2775           74707                           MASK     BIT4                                  
061192,000312: 07,2776           27320                           ADS      IMODES30                              
061193,000313: 
061194,000314: 07,2777           44706        RNDREFDR           CS       BIT5                                  #  KNOCK DOWN TRACK FLAG
061195,000315: 07,3000           70075                           MASK     FLAGWRD1                              
061196,000316: 07,3001           54075                           TS       FLAGWRD1                              
061197,000317: 
061198,000318: 07,3002           44674                           CS       BIT15                                 #  KNOCK DOWN DRIFT FLAG
061199,000319: 07,3003           70076                           MASK     FLAGWRD2                              
061200,000320: 07,3004           54076                           TS       FLAGWRD2                              
061201,000321: 
061202,000322: 07,3005           44676                           CS       BIT13                                 #  KNOCK DOWN REFSMMAT FLAG
061203,000323: 07,3006           70077                           MASK     FLAGWRD3                              
061204,000324: 07,3007           54077                           TS       FLAGWRD3                              
061205,000325: 
061206,000326: 07,3010           00002                           TC       Q                                     
061207,000327: 
061208,000328: 07,3011           40010        OCT40010           OCT      40010                                 
061209,000329: 

Page 1395

061211,000331:                                                                                                  #  IMU FINE ALIGN MODE SWITCH.
061212,000332: 
061213,000333: 07,3012           00004        IMUFINE            INHINT                                         
061214,000334: 07,3013           03455                           TC       CAGETSTJ                              #  SEE IF IMU BEING CAGED.
061215,000335: 
061216,000336: 07,3014           43543                           CS       BITS4-5                               #  RESET ZERO AND COARSE
061217,000337: 07,3015           00006                           EXTEND                                         
061218,000338: 07,3016           03012                           WAND     CHAN12                                
061219,000339: 
061220,000340: 07,3017           44705                           CS       BIT6                                  #  INSURE DAP AUTO AND HOLD MODES ENABLED
061221,000341: 07,3020           71321                           MASK     IMODES33                              
061222,000342: 07,3021           55321                           TS       IMODES33                              
061223,000343: 
061224,000344: 07,3022           03070                           TC       NOATTOFF                              
061225,000345: 
061226,000346: 07,3023           34701                           CAF      BIT10                                 #  IMU FAIL WAS INHIBITED DURING THE
061227,000347: 07,3024           05140                           TC       WAITLIST                              #  PRESUMABLY PRECEDING COARSE ALIGN.  LEAVE
061228,000348: 07,3025  E3,1474                                  EBANK=   CDUIND                                
061229,000349: 07,3025           03036 16103                     2CADR    IFAILOK                               #  IT ON FOR THE FIRST 5 SECS OF FINE ALIGN
061230,000350: 
061231,000351: 07,3027           34735                           CAF      2SECS                                 
061232,000352: 07,3030           05140                           TC       WAITLIST                              
061233,000353: 07,3031  E3,1474                                  EBANK=   CDUIND                                
061234,000354: 07,3031           03034 16103                     2CADR    IMUFINED                              
061235,000355: 
061236,000356: 07,3033           12557                           TCF      MODEEXIT                              
061237,000357: 
061238,000358: 07,3034           03443        IMUFINED           TC       CAGETEST                              #  SEE THAT NO ONE HAS CAGED THE IMU.
061239,000359: 07,3035           13433                           TCF      ENDIMU                                
061240,000360: 

Page 1396

061242,000362: 07,3036           03450        IFAILOK            TC       CAGETSTQ                              #  ENABLE IMU FIAL UNLESS IMU BEING CAGED.
061243,000363: 07,3037           15213                           TCF      TASKOVER                              #  IT IS.
061244,000364: 
061245,000365: 07,3040           34707                           CAF      BIT4                                  #  DONT RESET IMU FAIL INHIBIT IF SOMEONE
061246,000366: 07,3041           00006                           EXTEND                                         #  HAS GONE INTO COARSE ALIGN.
061247,000367: 07,3042           02012                           RAND     CHAN12                                
061248,000368: 07,3043           10000                           CCS      A                                     
061249,000369: 07,3044           15213                           TCF      TASKOVER                              
061250,000370: 
061251,000371: 07,3045           41320                           CS       IMODES30                              #  RESET IMUFAIL.
061252,000372: 07,3046           74676                           MASK     BIT13                                 
061253,000373: 07,3047           27320                           ADS      IMODES30                              
061254,000374: 07,3050           44707                           CS       BIT4                                  
061255,000375: 07,3051           71320        PFAILOK2           MASK     IMODES30                              
061256,000376: 07,3052           55320                           TS       IMODES30                              
061257,000377: 07,3053           04633                           TC       IBNKCALL                              #  THE ISS WARNING LIGHT MAY COME ON NOW
061258,000378: 07,3054           14665                           CADR     SETISSW                               #  THAT THE INHIBIT HAS BEEN REMOVED.
061259,000379: 07,3055           15213                           TCF      TASKOVER                              
061260,000380: 
061261,000381: 07,3056           03450        PFAILOK            TC       CAGETSTQ                              #  ENABLE PIP FAIL PROG ALARM.
061262,000382: 07,3057           15213                           TCF      TASKOVER                              
061263,000383: 
061264,000384: 07,3060           41320                           CS       IMODES30                              #  RESET IMU AND PIPA FAIL BITS.
061265,000385: 07,3061           74701                           MASK     BIT10                                 
061266,000386: 07,3062           27320                           ADS      IMODES30                              
061267,000387: 
061268,000388: 07,3063           41321                           CS       IMODES33                              
061269,000389: 07,3064           74676                           MASK     BIT13                                 
061270,000390: 07,3065           27321                           ADS      IMODES33                              
061271,000391: 
061272,000392: 07,3066           44706                           CS       BIT5                                  
061273,000393: 07,3067           13051                           TCF      PFAILOK2                              
061274,000394: 
061275,000395: 07,3070           43011        NOATTOFF           CS       OCT40010                              #  SUBROUTINE TO TURN OFF NO ATT LAMP.
061276,000396: 07,3071           71036                           MASK     DSPTAB     +11D                       
061277,000397: 07,3072           64674                           AD       BIT15                                 
061278,000398: 07,3073           55036                           TS       DSPTAB     +11D                       
061279,000399: 07,3074           00002                           TC       Q                                     
061280,000400: 

Page 1397

061282,000402:                                                                                                  #  ROUITNES TO INITIATE AND TERMINATE PROGRAM USE OF THE PIPAS.  NO IMUSTALL REQUIRED IN EITHER CASE.
061283,000403: 
061284,000404: 07,3075           44714        PIPUSE             CS       ZERO                                  
061285,000405: 07,3076           54037                           TS       PIPAX                                 
061286,000406: 07,3077           54040                           TS       PIPAY                                 
061287,000407: 07,3100           54041                           TS       PIPAZ                                 
061288,000408: 
061289,000409: 07,3101           03450        PIPUSE1            TC       CAGETSTQ                              #  DO NOT ENABLE PIPA FAIL IF IMU IS CAGED
061290,000410: 07,3102           14570                           TCF      SWRETURN                              
061291,000411: 
061292,000412: 07,3103           00004                           INHINT                                         
061293,000413: 07,3104           44712                           CS       BIT1                                  #  IF PIPA FAILS FROM NOW ON (UNTIL
061294,000414: 07,3105           71320                           MASK     IMODES30                              #  PIPFREE), LIGHT ISS WARNING.
061295,000415: 07,3106           55320                           TS       IMODES30                              
061296,000416: 
061297,000417: 07,3107           04633        PIPFREE2           TC       IBNKCALL                              #  ISS WARNING MIGHT COME ON NOW.
061298,000418: 07,3110           14665                           CADR     SETISSW                               #  (OR GO OFF ON PIPFREE).
061299,000419: 
061300,000420: 07,3111           12557                           TCF      MODEEXIT                              
061301,000421: 
061302,000422: 07,3112           00004        PIPFREE            INHINT                                         #  PROGRAM DONE WITH PIPAS.  DONT LIGHT
061303,000423: 07,3113           41320                           CS       IMODES30                              #  ISS WARNING.
061304,000424: 07,3114           74712                           MASK     BIT1                                  
061305,000425: 07,3115           27320                           ADS      IMODES30                              
061306,000426: 
061307,000427: 07,3116           74701                           MASK     BIT10                                 #  IF PIP FAIL ON, DO PROG ALSRM AND RESET
061308,000428: 07,3117           10000                           CCS      A                                     #  ISS WARNING.
061309,000429: 07,3120           12557                           TCF      MODEEXIT                              
061310,000430: 
061311,000431: 07,3121           05537                           TC       ALARM                                 
061312,000432: 07,3122           00212                           OCT      212                                   
061313,000433: 
061314,000434: 07,3123           00004                           INHINT                                         
061315,000435: 
061316,000436: 07,3124           13107                           TCF      PIPFREE2                              
061317,000437: 

Page 1398

061319,000439:                                                                                                  #  THE FOLLOWING ROUTINE TORQUES THE IRIGS ACCORDING TO DOUBLE PRECISION INPUTS IN THE SIX REGISTERS
061320,000440:                                                                                                  #  BEGINNING AT THE ECADR ARRIVING IN A.  THE MINIMUM SIZE OF ANY PULSE TRAIN IS 16 PULSES (.25 CDU COUNTS).  THE
061321,000441:                                                                                                  #  UNSENT PORTION OF THE COMMAND IS LEFT INTACT IN THE INPUT COMMAND REGISTERS.
061322,000442: 
061323,000443: 07,3125  E3,1400                                  EBANK=   1400                                  #  VARIABLE, ACTUALLY.
061324,000444: 
061325,000445: 07,3125           54161        IMUPULSE           TS       MPAC       +5                         #  SAVE ARRIVING ECADR.
061326,000446: 07,3126           03455                           TC       CAGETSTJ                              #  DONT PROCEED IF IMU BEING CAGED.
061327,000447: 
061328,000448: 07,3127           11304                           CCS      LGYRO                                 #  SEE IF GYROS BUSY.
061329,000449: 07,3130           03171                           TC       GYROBUSY                              #  SLEEP.
061330,000450: 
061331,000451: 07,3131           54156                           TS       MPAC       +2                         
061332,000452: 07,3132           34705                           CAF      BIT6                                  #  ENABLE THE POWER SUPPLY.
061333,000453: 07,3133           00006                           EXTEND                                         
061334,000454: 07,3134           05014                           WOR      CHAN14                                
061335,000455: 
061336,000456: 07,3135           34710                           CAF      FOUR                                  
061337,000457: 07,3136           05140        GWAKE2             TC       WAITLIST                              #  (IF A JOB WAS PUT TO SLEEP, THE POWER
061338,000458: 07,3137  E3,1474                                  EBANK=   CDUIND                                #  SUPPLY IS LEFT ON BY THE WAKING JOB).
061339,000459: 07,3137           03207 16103                     2CADR    STRTGYRO                              
061340,000460: 
061341,000461: 07,3141           30161                           CA       MPAC       +5                         #  SET UP EBANK, SAVING CALLER'S EBANK FOR
061342,000462: 07,3142           56003                           XCH      EBANK                                 #  RESTORATION ON RETURN.
061343,000463: 07,3143           56161                           XCH      MPAC       +5                         
061344,000464: 07,3144           55304                           TS       LGYRO                                 #  RESERVES GYROS.
061345,000465: 07,3145           74373                           MASK     LOW8                                  
061346,000466: 07,3146           54061                           TS       ITEMP1                                
061347,000467: 
061348,000468: 07,3147           34711                           CAF      TWO                                   #  FORCE SIGN AGREEMENT ON INPUTS.
061349,000469: 07,3150           54157        GYROAGRE           TS       MPAC       +3                         
061350,000470: 07,3151           60000                           DOUBLE                                         
061351,000471: 07,3152           60061                           AD       ITEMP1                                
061352,000472: 07,3153           54160                           TS       MPAC       +4                         
061353,000473: 07,3154           00006                           EXTEND                                         
061354,000474: 07,3155           50000                           INDEX    A                                     
061355,000475: 07,3156           31401                           DCA      1400                                  
061356,000476: 07,3157           52155                           DXCH     MPAC                                  
061357,000477: 07,3160           07226                           TC       TPAGREE                               
061358,000478: 07,3161           52155                           DXCH     MPAC                                  
061359,000479: 07,3162           50160                           INDEX    MPAC       +4                         
061360,000480: 07,3163           53401                           DXCH     1400                                  
061361,000481: 
061362,000482: 07,3164           10157                           CCS      MPAC       +3                         
061363,000483: 07,3165           13150                           TCF      GYROAGRE                              
061364,000484: 
061365,000485: 07,3166           30161                           CA       MPAC       +5                         #  RESTORE CALLER'S EBANK.
061366,000486: 07,3167           54003                           TS       EBANK                                 
061367,000487: 07,3170           12557                           TCF      MODEEXIT                              
061368,000488: 

Page 1399

061370,000490:                                                                                                  #  ROUTINES TO ALLOW TORQUING BY ONLY ONE JOB AT A TIME.
061371,000491: 
061372,000492: 07,3171           00006        GYROBUSY           EXTEND                                         #  SAVE RETURN 2FCADR.
061373,000493: 07,3172           30134                           DCA      BUF2                                  
061374,000494: 07,3173           52155                           DXCH     MPAC                                  
061375,000495: 07,3174           33206        REGSLEEP           CAF      LGWAKE                                
061376,000496: 07,3175           15070                           TCF      JOBSLEEP                              
061377,000497: 
061378,000498: 07,3176           11304        GWAKE              CCS      LGYRO                                 #  WHEN AWAKENED, SEE IF GYROS STILL BUSY.
061379,000499: 07,3177           13174                           TCF      REGSLEEP                              #  IF SO, SLEEP SOME MORE.
061380,000500: 
061381,000501: 07,3200           54156                           TS       MPAC       +2                         
061382,000502: 07,3201           00006                           EXTEND                                         
061383,000503: 07,3202           30155                           DCA      MPAC                                  
061384,000504: 07,3203           52134                           DXCH     BUF2                                  #  RESTORE SWRETURN INFO.
061385,000505: 07,3204           34712                           CAF      ONE                                   
061386,000506: 07,3205           13136                           TCF      GWAKE2                                
061387,000507: 
061388,000508: 07,3206           17176        LGWAKE             CADR     GWAKE                                 
061389,000509: 

Page 1400

061391,000511:                                                                                                  #  GYRO-TORQUING WAITLIST TASKS.
061392,000512: 
061393,000513: 07,3207           43430        STRTGYRO           CS       GDESELCT                              #  DE-SELECT LAST GYRO.
061394,000514: 07,3210           00006                           EXTEND                                         
061395,000515: 07,3211           03014                           WAND     CHAN14                                
061396,000516: 
061397,000517: 07,3212           03443                           TC       CAGETEST                              
061398,000518: 
061399,000519: 07,3213           31304        STRTGYR2           CA       LGYRO                                 #  JUMP ON PHASE COUNTER IN BITS 13-14.
061400,000520: 07,3214           00006                           EXTEND                                         
061401,000521: 07,3215           74707                           MP       BIT4                                  
061402,000522: 07,3216           50000                           INDEX    A                                     
061403,000523: 07,3217           13220                           TCF      +1                                    
061404,000524: 07,3220           03235                           TC       GSELECT                               #  =0.  DO Y GYRO.
061405,000525: 07,3221           00202                           OCT      00202                                 
061406,000526: 
061407,000527: 07,3222           03235                           TC       GSELECT                               #  =1.  DO Z GYRO.
061408,000528: 07,3223           00302                           OCT      00302                                 
061409,000529: 
061410,000530: 07,3224           03233                           TC       GSELECT    -2                         #  =2.  DO X GYRO.
061411,000531: 07,3225           00100                           OCT      00100                                 
061412,000532: 
061413,000533: 07,3226           34714                           CAF      ZERO                                  #  =3.  DONE
061414,000534: 07,3227           55304                           TS       LGYRO                                 
061415,000535: 07,3230           33206                           CAF      LGWAKE                                #  WAKE A POSSIBLE SLEEPING JOB.
061416,000536: 07,3231           05074                           TC       JOBWAKE                               
061417,000537: 
061418,000538: 07,3232           13034        NORESET            TCF      IMUFINED                              #  DO NOT RESET POWER SUPPLY

Page 1401

061420,000540: 07,3233           44710                 -2        CS       FOUR                                  #  SPECIAL ENTRY TO REGRESS LGYRO FOR X.
061421,000541: 07,3234           27304                           ADS      LGYRO                                 
061422,000542: 
061423,000543: 07,3235           50002        GSELECT            INDEX    Q                                     #  SELECT GYRO.
061424,000544: 07,3236           30000                           CAF      0                                     #  PACKED WORD CONTAINS GYRO SELECT BITS
061425,000545: 07,3237           54064                           TS       ITEMP4                                #  AND INCREMENT TO LGYRO.
061426,000546: 07,3240           74716                           MASK     SEVEN                                 
061427,000547: 07,3241           64676                           AD       BIT13                                 
061428,000548: 07,3242           27304                           ADS      LGYRO                                 
061429,000549: 07,3243           54003                           TS       EBANK                                 
061430,000550: 07,3244           74373                           MASK     LOW8                                  
061431,000551: 07,3245           54061                           TS       ITEMP1                                
061432,000552: 
061433,000553: 07,3246           44716                           CS       SEVEN                                 
061434,000554: 07,3247           70064                           MASK     ITEMP4                                
061435,000555: 07,3250           54064                           TS       ITEMP4                                
061436,000556: 
061437,000557: 07,3251           00006                           EXTEND                                         #  MOVE DP COMMAND TO RUPTREGS FOR TESTING.
061438,000558: 07,3252           50061                           INDEX    ITEMP1                                
061439,000559: 07,3253           31401                           DCA      1400                                  
061440,000560: 07,3254           52071                           DXCH     RUPTREG1                              
061441,000561: 
061442,000562: 07,3255           10070                           CCS      RUPTREG1                              
061443,000563: 07,3256           13271                           TCF      MAJ+                                  
061444,000564: 07,3257           13261                           TCF      +2                                    
061445,000565: 07,3260           13411                           TCF      MAJ-                                  
061446,000566: 
061447,000567: 07,3261           10071                           CCS      RUPTREG2                              
061448,000568: 07,3262           13266                           TCF      MIN+                                  
061449,000569: 07,3263           13213                           TCF      STRTGYR2                              
061450,000570: 07,3264           13406                           TCF      MIN-                                  
061451,000571: 07,3265           13213                           TCF      STRTGYR2                              
061452,000572: 

Page 1402

061454,000574: 07,3266           63322        MIN+               AD       -GYROMIN                              #  SMALL POSITIVE COMMAND.  SEE IF AT LEAST
061455,000575: 07,3267           00006                           EXTEND                                         #  16 GYRO PULSES.
061456,000576: 07,3270           63213                           BZMF     STRTGYR2                              
061457,000577: 
061458,000578: 07,3271           00006        MAJ+               EXTEND                                         #  DEFINITE POSITIVE OUTPUT.
061459,000579: 07,3272           33432                           DCA      GYROFRAC                              
061460,000580: 07,3273           20071                           DAS      RUPTREG1                              
061461,000581: 
061462,000582: 07,3274           30064                           CA       ITEMP4                                #  SELECT POSITIVE TORQUING FOR THIS GYRO.
061463,000583: 07,3275           00006                           EXTEND                                         
061464,000584: 07,3276           05014                           WOR      CHAN14                                
061465,000585: 
061466,000586: 07,3277           36043                           CAF      LOW7                                  #  LEAVE NUMBER OF POSSIBLE 8192 AUGMENTS
061467,000587: 07,3300           70071                           MASK     RUPTREG2                              #  TO INITIAL COMMAND IN MAJOR PART OF LONG
061468,000588: 07,3301           56071                           XCH      RUPTREG2                              #  TERM STORAGE AND TRUNCATED FRACTION
061469,000589: 07,3302           00006        GMERGE             EXTEND                                         #  IN MINOR PART.  THE MAJOR PART WILL BE
061470,000590: 07,3303           74703                           MP       BIT8                                  #  COUNTED DOWN TO ZERO IN THE COURSE OF
061471,000591: 07,3304           54062                           TS       ITEMP2                                #  PUTTING OUT THE ENTIRE COMMAND.
061472,000592: 07,3305           30070                           CA       RUPTREG1                              
061473,000593: 07,3306           00006                           EXTEND                                         
061474,000594: 07,3307           74702                           MP       BIT9                                  
061475,000595: 07,3310           54070                           TS       RUPTREG1                              
061476,000596: 07,3311           30001                           CA       L                                     
061477,000597: 07,3312           00006                           EXTEND                                         
061478,000598: 07,3313           74675                           MP       BIT14                                 
061479,000599: 07,3314           26062                           ADS      ITEMP2                                #  INITIAL COMMAND.
061480,000600: 
061481,000601: 07,3315           00006                           EXTEND                                         #  SEE IF MORE THAN ONE PULSE TRAIN NEEDED
061482,000602: 07,3316           30071                           DCA      RUPTREG1                              #  (MORE THAN 16383 PULSES).
061483,000603: 07,3317           67716                           AD       MINUS1                                
061484,000604: 07,3320           10000                           CCS      A                                     
061485,000605: 07,3321           13345                           TCF      LONGGYRO                              
061486,000606: 07,3322           77601        -GYROMIN           OCT      -176                                  #  MAY BE ADJUSTED TO SPECIFY MINIMUM CMD
061487,000607: 07,3323           13327                           TCF      +4                                    
061488,000608: 
061489,000609: 07,3324           34675                           CAF      BIT14                                 
061490,000610: 07,3325           26062                           ADS      ITEMP2                                
061491,000611: 07,3326           34714                           CAF      ZERO                                  
061492,000612: 
061493,000613: 07,3327           50061                 +4        INDEX    ITEMP1                                
061494,000614: 07,3330           53401                           DXCH     1400                                  

Page 1403

061496,000616: 07,3331           30062                           CA       ITEMP2                                #  ENTIRE COMMAND.
061497,000617: 07,3332           54047        LASTSEG            TS       GYROCMD                               
061498,000618: 07,3333           00006                           EXTEND                                         
061499,000619: 07,3334           74701                           MP       BIT10                                 #  WAITLIST DT
061500,000620: 07,3335           66214                           AD       THREE                                 #  TRUNCATION AND PHASE UNCERTAINTIES.
061501,000621: 07,3336           05140                           TC       WAITLIST                              
061502,000622: 07,3337  E3,1474                                  EBANK=   CDUIND                                
061503,000623: 07,3337           03207 16103                     2CADR    STRTGYRO                              
061504,000624: 
061505,000625: 07,3341           34701        GYROEXIT           CAF      BIT10                                 
061506,000626: 07,3342           00006                           EXTEND                                         
061507,000627: 07,3343           05014                           WOR      CHAN14                                
061508,000628: 07,3344           15213                           TCF      TASKOVER                              
061509,000629: 
061510,000630: 07,3345           50061        LONGGYRO           INDEX    ITEMP1                                
061511,000631: 07,3346           53401                           DXCH     1400                                  #  INITIAL COMMAND OUT PLUS N AUGMENTS OF
061512,000632: 07,3347           34675                           CAF      BIT14                                 #  8192.  INITIAL COMMAND IS AT LEAST 8192.
061513,000633: 07,3350           60062                           AD       ITEMP2                                
061514,000634: 07,3351           54047                           TS       GYROCMD                               
061515,000635: 
061516,000636: 07,3352           00006        AUG3               EXTEND                                         #  GET WAITLIST DT TO TIME WHEN TRAIN IS
061517,000637: 07,3353           74701                           MP       BIT10                                 #  ALMOST OUT.
061518,000638: 07,3354           67714                           AD       NEG3                                  
061519,000639: 07,3355           05140                           TC       WAITLIST                              
061520,000640: 07,3356  E3,1474                                  EBANK=   CDUIND                                
061521,000641: 07,3356           03361 16103                     2CADR    8192AUG                               
061522,000642: 
061523,000643: 07,3360           13341                           TCF      GYROEXIT                              
061524,000644: 
061525,000645: 07,3361           03443        8192AUG            TC       CAGETEST                              
061526,000646: 
061527,000647: 07,3362           34707                           CAF      BIT4                                  
061528,000648: 07,3363           00006                           EXTEND                                         
061529,000649: 07,3364           02012                           RAND     CHAN12                                
061530,000650: 07,3365           10000                           CCS      A                                     
061531,000651: 07,3366           13441                           TCF      IMUBAD                                
061532,000652: 07,3367           31304                           CA       LGYRO                                 #  ADD 8192 PULSES TO GYROCMD
061533,000653: 07,3370           54003                           TS       EBANK                                 
061534,000654: 07,3371           74373                           MASK     LOW8                                  
061535,000655: 07,3372           54061                           TS       ITEMP1                                
061536,000656: 
061537,000657: 07,3373           50061                           INDEX    ITEMP1                                #  SEE IF THIS IS THE LAST AUG.
061538,000658: 07,3374           11400                           CCS      1400                                  
061539,000659: 07,3375           13401                           TCF      AUG2                                  #  MORE TO COME.
061540,000660: 
061541,000661: 07,3376           34675                           CAF      BIT14                                 
061542,000662: 07,3377           26047                           ADS      GYROCMD                               
061543,000663: 07,3400           13333                           TCF      LASTSEG    +1                         
061544,000664: 

Page 1404

061546,000666: 07,3401           50061        AUG2               INDEX    ITEMP1                                
061547,000667: 07,3402           55400                           TS       1400                                  
061548,000668: 07,3403           34675                           CAF      BIT14                                 
061549,000669: 07,3404           26047                           ADS      GYROCMD                               
061550,000670: 07,3405           13352                           TCF      AUG3                                  #  COMPUTE DT.
061551,000671: 

Page 1405

061553,000673: 07,3406           63322        MIN-               AD       -GYROMIN                              #  POSSIBLE NEGATIVE OUTPUT.
061554,000674: 07,3407           00006                           EXTEND                                         
061555,000675: 07,3410           63213                           BZMF     STRTGYR2                              
061556,000676: 
061557,000677: 07,3411           00006        MAJ-               EXTEND                                         #  DEFINITE NEGATIVE OUTPUT.
061558,000678: 07,3412           43432                           DCS      GYROFRAC                              
061559,000679: 07,3413           20071                           DAS      RUPTREG1                              
061560,000680: 
061561,000681: 07,3414           30064                           CA       ITEMP4                                #  SELECT NEGATIVE TORQUING FOR THIS GYRO.
061562,000682: 07,3415           64702                           AD       BIT9                                  
061563,000683: 07,3416           00006                           EXTEND                                         
061564,000684: 07,3417           05014                           WOR      CHAN14                                
061565,000685: 
061566,000686: 07,3420           40070                           CS       RUPTREG1                              #  SET UP RUPTREGS TO FALL INTO GMERGE.
061567,000687: 07,3421           54070                           TS       RUPTREG1                              #  ALL NUMBERS PUT INTO GYROCMD ARE
061568,000688: 07,3422           40071                           CS       RUPTREG2                              #  POSITIVE - BIT9 OF CHAN 14 DETERMINES
061569,000689: 07,3423           76043                           MASK     LOW7                                  #  THE SIGN OF THE COMMAND.
061570,000690: 07,3424           40000                           COM                                            
061571,000691: 07,3425           56071                           XCH      RUPTREG2                              
061572,000692: 07,3426           40000                           COM                                            
061573,000693: 07,3427           13302                           TCF      GMERGE                                
061574,000694: 
061575,000695: 07,3430           01700        GDESELCT           OCT      1700                                  #  TURN OFF SELECT AND ACTIVITY BITS.
061576,000696: 
061577,000697: 07,3431           00000 00034  GYROFRAC           2DEC     .215       B-21                       
061578,000698: 

Page 1406

061580,000700:                                                                                                  #  IMU MODE SWITCHING ROUTINES COME HERE WHEN ACTION COMPLETE.
061581,000701: 
061582,000702: 07,3433           00006        ENDIMU             EXTEND                                         #  MODE IS BAD IF CAGE HAS OCCURED OR IF
061583,000703: 07,3434           00011                           READ     DSALMOUT                              #  ISS WARNING IS ON.
061584,000704: 07,3435           74712                           MASK     BIT1                                  
061585,000705: 07,3436           10000                           CCS      A                                     
061586,000706: 07,3437           13441                           TCF      IMUBAD                                
061587,000707: 
061588,000708: 07,3440           13467        IMUGOOD            TCF      GOODEND                               #  WITH C(A) = 0.
061589,000709: 
061590,000710: 07,3441           34714        IMUBAD             CAF      ZERO                                  
061591,000711: 07,3442           13464                           TCF      BADEND                                
061592,000712: 
061593,000713: 07,3443           34705        CAGETEST           CAF      BIT6                                  #  SUBROUTINE TO TERMINATE IMU MODE
061594,000714: 07,3444           71320                           MASK     IMODES30                              #  SWITCH IF IMU HAS BEEN CAGED.
061595,000715: 07,3445           10000                           CCS      A                                     
061596,000716: 07,3446           13441                           TCF      IMUBAD                                #  DIRECTLY.
061597,000717: 07,3447           00002                           TC       Q                                     #  WITH C(A) = +0.
061598,000718: 
061599,000719: 07,3450           41320        CAGETSTQ           CS       IMODES30                              #  SKIP IF IMU NOT BEING CAGED.
061600,000720: 07,3451           74705                           MASK     BIT6                                  
061601,000721: 07,3452           10000                           CCS      A                                     
061602,000722: 07,3453           24002                           INCR     Q                                     
061603,000723: 07,3454           00002                           TC       Q                                     
061604,000724: 
061605,000725: 07,3455           41320        CAGETSTJ           CS       IMODES30                              #  IF DURING MODE SWITCH INITIALIZATION
061606,000726: 07,3456           74705                           MASK     BIT6                                  #  IT IS FOUND THAT THE IMU IS BEING CAGED,
061607,000727: 07,3457           10000                           CCS      A                                     #  SET IMUCADR TO -0 TO INDICATE OPERATION
061608,000728: 07,3460           00002                           TC       Q                                     #  COMPLETE BUT FAILED.  RETURN IMMEDIATELY
061609,000729: 07,3461           44714                           CS       ZERO                                  #  TO SWRETURN.
061610,000730: 07,3462           55322                           TS       IMUCADR                               
061611,000731: 07,3463           12557                           TCF      MODEEXIT                              
061612,000732: 

Page 1407

061614,000734:                                                                                                  #  GENERALIZED MODE SWITCHING TERMINATION.  ENTER AT GOODEND FOR SUCCESSFUL COMPLETION OF AN I/O OPERATION
061615,000735:                                                                                                  #  OR AT BADEND FOR AN UNSUCCESSFUL ONE.  C(A) OR ARRIVAL =0 FOR IMU, 1 FOR OPTICS.
061616,000736: 
061617,000737: 07,3464           54071        BADEND             TS       RUPTREG2                              #  DEVICE INDEX.
061618,000738: 07,3465           44714                           CS       ZERO                                  #  FOR FAILURE.
061619,000739: 07,3466           13471                           TCF      GOODEND    +2                         
061620,000740: 
061621,000741: 07,3467           54071        GOODEND            TS       RUPTREG2                              
061622,000742: 07,3470           44712                           CS       ONE                                   #  FOR SUCCESS.
061623,000743: 
061624,000744: 07,3471           54072                           TS       RUPTREG3                              
061625,000745: 07,3472           50071                           INDEX    RUPTREG2                              #  SEE IF USING PROGRAM ASLEEP.
061626,000746: 07,3473           11322                           CCS      MODECADR                              
061627,000747: 07,3474           13476                           TCF      +2                                    #  YES - WAKE IT UP.
061628,000748: 07,3475           13506                           TCF      ENDMODE                               #  IF 0, PROGRAM NOT IN YET.
061629,000749: 
061630,000750: 07,3476           34714                           CAF      ZERO                                  #  WAKE SLEEPING PROGRAM.
061631,000751: 07,3477           50071                           INDEX    RUPTREG2                              
061632,000752: 07,3500           57322                           XCH      MODECADR                              
061633,000753: 07,3501           05074                           TC       JOBWAKE                               
061634,000754: 
061635,000755: 07,3502           40072                           CS       RUPTREG3                              #  ADVANCE LOC IF SUCCESSFUL.
061636,000756: 07,3503           50064                           INDEX    LOCCTR                                
061637,000757: 07,3504           26164                           ADS      LOC                                   
061638,000758: 
061639,000759: 07,3505           15213                           TCF      TASKOVER                              
061640,000760: 
061641,000761: 07,3506           30072        ENDMODE            CA       RUPTREG3                              #  -0 INDICATES OPERATION COMPLETE BUT
061642,000762: 07,3507           50071                           INDEX    RUPTREG2                              #  UNSUCCESSFUL - -1 INDICATES COMPLETE AND
061643,000763: 07,3510           55322                           TS       MODECADR                              #  SUCCESSFUL.
061644,000764: 07,3511           15213                           TCF      TASKOVER                              
061645,000765: 

Page 1408

061647,000767:                                                                                                  #  GENERAL STALLING ROUTINE.  USING PROGRAMS COME HERE TO WAIT FOR I/O COMPLETION.
061648,000768: 
061649,000769:                                                                                                  #  PROGRAM DESCRIPTION                           DATE - 21 FEB 1967
061650,000770:                                                                                                  #                                                LOG SECTION IMU MODE SWITCHING
061651,000771:                                                                                                  #  MOD BY - R. MELANSON TO ADD DOCUMENTATION     ASSEMBLY SUNDISK REV. 82
061652,000772: 
061653,000773:                                                                                                  #  FUNCTIONAL DESCRIPTION -
061654,000774:                                                                                                  #        TO DELAY FURTHER EXECUTION OF THE CALLING ROUTINE UNTIL ITS SELECTED
061655,000775:                                                                                                  #        I/O FUNCTION IS COMPLETE.  THE FOLLOWING CHECKS ON THE CALLING ROUTINE:S
061656,000776:                                                                                                  #        MODECADR ARE MADE AND ACTED UPON.
061657,000777:                                                                                                  #        1) +0 INDICATES INCOMPLETE I/O OPERATION.  CALLING ROUTINE IS PUT TO
061658,000778:                                                                                                  #           SLEEP.
061659,000779:                                                                                                  #        2) -1 INDICATES COMPLETED I/O OPERATION.  STALL BYPASSES JOBSLEEP
061660,000780:                                                                                                  #           CALL AND RETURNS TO CALLING ROUTINE AT L+3
061661,000781:                                                                                                  #        3) -0 INDICATES COMPLETED I/O WITH FAILURE.  STALL CLEARS MODECADR
061662,000782:                                                                                                  #           AND RETURNS TO CALLING ROUTINE AT L+2.
061663,000783:                                                                                                  #        4) VALUE GREATER THAN 0 INDICATES TWO ROUTINES CALLING FOR USE OF
061664,000784:                                                                                                  #           SAME DEVICE.  STALL EXITS TO ABORT WHICH EXECUTES A PROGRAM
061665,000785:                                                                                                  #           RESTART WHICH IN TURN CLEARS ALL MODECADR REGISTERS.
061666,000786: 
061667,000787:                                                                                                  #  CALLING SEQUENCE -
061668,000788:                                                                                                  #        L       TC      BANKCALL
061669,000789:                                                                                                  #        L+1     CADR    (ONE OF 5 STALL ADDRESSES  I.E. IMUSTALL, OPTSTALL, RADSTALL,
061670,000790:                                                                                                  #                        AOTSTALL, OR ATTSTALL)
061671,000791: 
061672,000792:                                                                                                  #  NORMAL-EXIT MODE -
061673,000793:                                                                                                  #        TCF JOBSLEEP    OR      TCF MODEXIT
061674,000794: 
061675,000795:                                                                                                  #  ALARM OR ABORT EXIT MODE -
061676,000796:                                                                                                  #        TC      ABORT
061677,000797: 
061678,000798:                                                                                                  #  OUTPUT -
061679,000799:                                                                                                  #        MODECADR=CADR   IF JOBSLEEP
061680,000800:                                                                                                  #        MODECADR=+0     IF I/O COMPLETE
061681,000801:                                                                                                  #        BUF2=L+3        IF I/O COMPLETE AND GOOD.
061682,000802:                                                                                                  #        BUF2=L+2        IF I/O COMPLETE BUT FAILED.
061683,000803: 
061684,000804:                                                                                                  #  ERASABLE INITIALIZATION -
061685,000805:                                                                                                  #        BUF2 CONTAINS RETURN ADDRESS PLUS 1,(L+2)
061686,000806:                                                                                                  #        BUF2+1 CONTAINS FBANK VALUE OF CALLING ROUTINE.
061687,000807:                                                                                                  #        MODECADR OF CALLING ROUTINE CONTAINS +0,-1,-0 OR CADR RETURN ADDRESS.
061688,000808: 
061689,000809:                                                                                                  #  DEBRIS -
061690,000810:                                                                                                  #        RUPTREG2 AND CALLING ROUTINE MODECADR.
061691,000811: 
061692,000812: 07,3512           34712        AOTSTALL           CAF      ONE                                   #  AOT.
061693,000813: 07,3513           03517                           TC       STALL                                 
061694,000814: 
061695,000815: 07,3514           34711        RADSTALL           CAF      TWO                                   
061696,000816: 07,3515           13517                           TCF      STALL                                 
061697,000817: 

Page 1409

061699,000819: 07,3516  07,3512               OPTSTALL           EQUALS   AOTSTALL                              
061700,000820: 
061701,000821: 07,3516           34714        IMUSTALL           CAF      ZERO                                  #  IMU.
061702,000822: 
061703,000823: 07,3517           00004        STALL              INHINT                                         
061704,000824: 07,3520           54071                           TS       RUPTREG2                              #  SAVE DEVICE INDEX.
061705,000825: 07,3521           50000                           INDEX    A                                     #  SEE IF OPERATION COMPLETE.
061706,000826: 07,3522           11322                           CCS      MODECADR                              
061707,000827: 07,3523           13541                           TCF      MODABORT                              #  ALLOWABLE STATES ARE +0, -1, AND -0.
061708,000828: 07,3524           13535                           TCF      MODESLP                               #  OPERATION INCOMPLETE.
061709,000829: 07,3525           13531                           TCF      MODEGOOD                              #  COMPLETE AND GOOD IF = -1.
061710,000830: 
061711,000831: 07,3526           50071        MG2                INDEX    RUPTREG2                              #  COMPLETE AND FAILED IF -0.  RESET TO +0.
061712,000832: 07,3527           55322                           TS       MODECADR                              #  RETURN TO CALLER.
061713,000833: 07,3530           12557                           TCF      MODEEXIT                              
061714,000834: 
061715,000835: 07,3531           10000        MODEGOOD           CCS      A                                     #  MAKE SURE INITIAL STATE -1.
061716,000836: 07,3532           13541                           TCF      MODABORT                              
061717,000837: 
061718,000838: 07,3533           24133                           INCR     BUF2                                  #  IF SO, INCREMENT RETURN ADDRESS AND
061719,000839: 07,3534           13526                           TCF      MG2                                   #  RETURN IMMEDIATELY, SETTING CADR = +0.
061720,000840: 
061721,000841: 07,3535           04604        MODESLP            TC       MAKECADR                              #  CALL FROM SWITCHABLE FIXED ONLY.
061722,000842: 07,3536           50071                           INDEX    RUPTREG2                              
061723,000843: 07,3537           55322                           TS       MODECADR                              
061724,000844: 07,3540           15070                           TCF      JOBSLEEP                              
061725,000845: 
061726,000846: 07,3541           05622        MODABORT           TC       POODOO                                #  TWO PROGRAMS USING SAME DEVICE.
061727,000847: 07,3542           01210                           OCT      1210                                  
061728,000848: 

Page 1410

061730,000850:                                                                                                  #  CONSTANTS FOR MODE SWITCHING ROUTINES
061731,000851: 
061732,000852: 07,3543     5656               BITS3&4            =        OCT14                                 
061733,000853: 07,3543     4726               BITS4&6            =        OCT50                                 
061734,000854: 07,3543           00030        BITS4-5            OCT      00030                                 
061735,000855: 07,3544     4703               IMUSEFLG           EQUALS   BIT8                                  #  INTERPRETER SWITCH 7.
061736,000856: 07,3544           77500        -COMMAX            DEC      -191       B-14                       
061737,000857: 07,3545           77477        -COMMAX-           DEC      -192       B-14                       
061738,000858: 07,3546           00074        600MS              DEC      60         B-14                       
061739,000859: 07,3547  07,3012               IMUFIN20           =        IMUFINE                               
061740,000860: 07,3547           31325        GOMANUR            CA       ATTCADR                               #  IS KALCMANU FREE
061741,000861: 07,3550           00006                           EXTEND                                         
061742,000862: 07,3551           13554                           BZF      +3                                    
061743,000863: 07,3552           05622                           TC       POODOO                                #  NO
061744,000864: 07,3553           01210                           OCT      1210                                  #  2 TRYING TO USE SAME DEVICE
061745,000865: 
061746,000866: 07,3554           00006                 +3        EXTEND                                         
061747,000867: 07,3555           30134                           DCA      BUF2                                  
061748,000868: 07,3556           53326                           DXCH     ATTCADR                               #  SAVE FINAL RETURN FOR KALCMAN3
061749,000869: 
061750,000870: 07,3557           30006                           CA       BBANK                                 
061751,000871: 07,3560           74716                           MASK     SEVEN                                 
061752,000872: 07,3561           27326                           ADS      ATTCADR    +1                         
061753,000873: 
061754,000874: 07,3562           30167                           CA       PRIORITY                              
061755,000875: 07,3563           77674                           MASK     PRIO37                                
061756,000876: 07,3564           55327                           TS       ATTPRIO                               #  SAVE USERS PRIO
061757,000877: 
061758,000878: 07,3565           33571                           CAF      KALEBCON                              #  SET EBANK FOR KALCMAN3
061759,000879: 07,3566           54003                           TS       EBANK                                 
061760,000880: 07,3567           04574                           TC       POSTJUMP                              
061761,000881: 07,3570           44000                           CADR     KALCMAN3                              
061762,000882: 07,3571           03261        KALEBCON           ECADR    BCDU                                  
061763,000883: 

Page 1411

061765,000885:                                                                                                  #  PROGRAM DESCRIPTION
061766,000886:                                                                                                  #  IMU STATUS CHECK ROUTINE R02 (SUBROUTINE UTILITY)
061767,000887:                                                                                                  #  MOD NO - 1
061768,000888:                                                                                                  #  MOD BY - N.BRODEUR
061769,000889: 
061770,000890:                                                                                                  #  FUNCTIONAL DESCRIPTION
061771,000891:                                                                                                  #        TO CHECK WHETHER IMU IS ON AND IF ON WHETHER IT IS ALIGNED TO AN
061772,000892:                                                                                                  #        ORIENTATION KNOWN BY THE CMC.  TO REQUEST SELECTION OF THE APPROPRIATE
061773,000893:                                                                                                  #        PROGRAM IF THE IMU IS OFF OR NOT ALIGNED TO AN ORIENTATION KNOWN BY THE
061774,000894:                                                                                                  #        CMC.  CALLED THROUGH BANKCALL
061775,000895: 
061776,000896:                                                                                                  #  CALLING SEQUENCE -
061777,000897:                                                                                                  #        L       TC      BANKCALL
061778,000898:                                                                                                  #        L+1     CADR    R02BOTH
061779,000899: 
061780,000900:                                                                                                  #  SUBROUTINES CALLED
061781,000901:                                                                                                  #        VARALARM
061782,000902:                                                                                                  #        FLAGUP
061783,000903: 
061784,000904:                                                                                                  #  NORMAL EXIT MODES
061785,000905:                                                                                                  #        AT L+2 OF CALLING SEQUENCE
061786,000906: 
061787,000907:                                                                                                  #  ALARM OR ABORT EXIT MODES
061788,000908:                                                                                                  #        GOTOPOOH, WITH ALARM
061789,000909: 
061790,000910:                                                                                                  #  ERASABLE INITIALIZATION REQUIRED
061791,000911:                                                                                                  #        NONE
061792,000912: 
061793,000913:                                                                                                  #  DEBRIS
061794,000914:                                                                                                  #        CENTRALS-A,Q,L
061795,000915: 
061796,000916: 34,3775                                           BANK     34                                    
061797,000917: 07,2000                                           SETLOC   R02                                   
061798,000918: 07,2000                                           BANK                                           
061799,000919: 07,3572                                           COUNT    04/R02                                #  COUNT*
061800,000920: 
061801,000921: 07,3572           00063        DEC51              DEC      51         B-14                       
061802,000922: 07,3573           34676        R02BOTH            CAF      BIT13                                 
061803,000923: 07,3574           70077                           MASK     STATE      +3                         #  REFSMFLG
061804,000924: 07,3575           10000                           CCS      A                                     
061805,000925: 07,3576           03607                           TC       R02ZERO                               #  ZERO IMUS
061806,000926: 
061807,000927: 07,3577           31320                           CA       IMODES30                              
061808,000928: 07,3600           74702                           MASK     BIT9                                  #  IS ISS INITIALIZED
061809,000929: 07,3601           00006                           EXTEND                                         
061810,000930: 07,3602           13604                           BZF      +2                                    
061811,000931: 07,3603           44707                           CS       BIT4                                  #  SEND IMU ALARM CODE 210
061812,000932: 07,3604           63612                           AD       OCT220                                #  SEND REFSMM ALARM
061813,000933: 07,3605           05651                           TC       VARALARM                              
061814,000934: 
061815,000935: 07,3606           04106                           TC       GOTOPOOH                              
061816,000936: 

Page 1412

061818,000938: 07,3607           05435        R02ZERO            TC       UPFLAG                                
061819,000939: 07,3610           00007                           ADRES    IMUSE                                 
061820,000940: 07,3611           14570                           TCF      SWRETURN                              
061821,000941: 07,3612           00220        OCT220             OCT      220                                   
061822,000942: 

Page 1413

061824,000944:                                                                                                  #  PROGRAM DESCRIPTION   P06             10FEB67
061825,000945: 
061826,000946:                                                                                                  #  TRANSFER THE ISS/CMC FROM THE OPERATE TO THE STANDBY CONDITION.
061827,000947: 
061828,000948:                                                                                                  #  THE NORMAL CONDITION OF READINESS OF THE GNCS WHEN NOT IN USE IS STANDBY.  IN THIS CONDITION THE IMU
061829,000949:                                                                                                  #  HEATER POWER IS ON.  THE IMU OPERATE POWER IS OFF.  THE COMPUTER POWER IS ON.  THE OPTICS POWER IS OFF.  THE
061830,000950:                                                                                                  #  CMC STANDBY ON THE MAIN AND LEB DISKYS IS ON.
061831,000951: 
061832,000952:                                                                                                  #  CALLING SEQUENCE:
061833,000953:                                                                                                  #        ASTRONAUT REQUEST THROUGH DSKY  V37E 06E.
061834,000954: 
061835,000955:                                                                                                  #  SUBROUTINES CALLED:
061836,000956:                                                                                                  #        GOPERF1
061837,000957:                                                                                                  #        BANKCALL
061838,000958:                                                                                                  #        FLAGDOWN
061839,000959: 

Page 1414

061841,000961:                                                                                                  #  PRESTAND PREPARES FOR STANDBY BY SNAPSHOTTING THE SCALER AND TIME1 TIME2
061842,000962:                                                                                                  #  THE LOW 5 BITS OF THE SCALER ARE INSPECTED TO INSURE COMPATABILITY
061843,000963:                                                                                                  #  BETWEEN THE SCALER READING AND THE TIME1 TIME2 READING.
061844,000964: 
061845,000965: 26,2000                                           SETLOC   P05P06                                
061846,000966: 26,2000                                           BANK                                           
061847,000967: 
061848,000968: 26,3655     1150                                  EBANK=   TIME2SAV                              
061849,000969: 26,3655                                           COUNT*   $$/P06                                
061850,000970: 
061851,000971: 26,3655           05435        P06                TC       UPFLAG                                #  SET NODOV37 BIT
061852,000972: 26,3656           00054                           ADRES    NODOFLAG                              
061853,000973: 
061854,000974: 26,3657           00004        PRESTAND           INHINT                                         
061855,000975: 26,3660           00006                           EXTEND                                         
061856,000976: 26,3661           30025                           DCA      TIME2                                 #  SNAPSHOT TIME1 TIME2
061857,000977: 26,3662           53151                           DXCH     TIME2SAV                              
061858,000978: 26,3663           03714                           TC       SCALPREP                              
061859,000979: 26,3664           03657                           TC       PRESTAND                              #  T1,T2,SCALER NOT COMPATIBLE
061860,000980: 26,3665           52155                           DXCH     MPAC                                  #  T1,T2 AND SCALER OK
061861,000981: 26,3666           53153                           DXCH     SCALSAVE                              #  STORE SCALER
061862,000982: 26,3667           00004                           INHINT                                         
061863,000983: 26,3670           04555                           TC       BANKCALL                              
061864,000984: 26,3671           16777                           CADR     RNDREFDR                              #  REFSMM, DRIFT, TRACK FLAGS DOWN
061865,000985: 
061866,000986: 26,3672           05447                           TC       DOWNFLAG                              
061867,000987: 26,3673           00007                           ADRES    IMUSE                                 #  IMUSE DOWN
061868,000988: 26,3674           05447                           TC       DOWNFLAG                              
061869,000989: 26,3675           00010                           ADRES    RNDVZFLG                              #  RNDVZFLG DOWN
061870,000990: 
061871,000991: 26,3676           34700                           CAF      BIT11                                 
061872,000992: 26,3677           00006                           EXTEND                                         
061873,000993: 26,3700           05013                           WOR      CHAN13                                #  SET STANDBY ENABLE BIT
061874,000994: 
061875,000995: 26,3701           05301                           TC       PHASCHNG                              #  SET RESTART TO POSTAND WHEN STANDBY
061876,000996: 26,3702           07024                           OCT      07024                                 #        RECOVERS
061877,000997: 26,3703           20000                           OCT      20000                                 
061878,000998: 26,3704     1152                                  EBANK=   SCALSAVE                              
061879,000999: 26,3704           03734 54102                     2CADR    POSTAND                               
061880,001000: 
061881,001001: 26,3706           34731                           CAF      OCT62                                 
061882,001002: 26,3707           04555                           TC       BANKCALL                              
061883,001003: 26,3710           20751                           CADR     GOPERF1                               
061884,001004: 26,3711           13706                           TCF      -3                                    
061885,001005: 26,3712           13706                           TCF      -4                                    
061886,001006: 26,3713           13706                           TCF      -5                                    
061887,001007: 
061888,001008: 26,3714     4731               OCT62              EQUALS   .5SEC                                 #  DEC 50 = OCT 62
061889,001009: 
061890,001010:                                                                                                  #  THE LOW 5 BITS OF THE SCALER READS 10000 FOR THE FIRST INTERVAL AFTER A

Page 1415

061892,001012:                                                                                                  #  T1 INCREMENT.  IF SCALPREP DETECTS THIS INTERVAL THE T1,T2 AND SCALER
061893,001013:                                                                                                  #  DATA ARE NOT COMPATABLE AND RETURN IS TO L+1 FOR ANOTHER READING OF THE
061894,001014:                                                                                                  #  DATA.  OTHERWISE, THE RETURN IS TO L+2 TO PROCEED.  ROUTINE ALSO PREPARES
061895,001015:                                                                                                  #  THE SCALER READING FOR COMPUTATION OF THE INCREMENT TO UPDATE T1T2.  (THE
061896,001016:                                                                                                  #  10 MS BIT (BIT 6) OF THE SCALER IS INCREMENTED 5 MS OUT OF PHASE FROM
061897,001017:                                                                                                  #  T1.) ADDITION OF 5 MS (BIT 5) TO THE SCALER READING HAS THE EFFECT OF
061898,001018:                                                                                                  #  ADJUSTING BIT 6 IN THE SCALER TO BE IN PHASE WITH BIT 1 OF T1.  THE LOW 5
061899,001019:                                                                                                  #  BITS OF THE SCALER READING ARE THEN SET TO ZERO, TO TRUNCATE THE SCALER
061900,001020:                                                                                                  #  DATA TO 10 MS.  RESULTS ARE STORED IN MPAC, +1.
061901,001021: 
061902,001022: 26,3714           00006        SCALPREP           EXTEND                                         
061903,001023: 26,3715           22156                           QXCH     MPAC       +2                         
061904,001024: 26,3716           04527                           TC       FINETIME   +1                         
061905,001025: 26,3717           00003                           RELINT                                         
061906,001026: 26,3720           52155                           DXCH     MPAC                                  
061907,001027: 26,3721           34706                           CA       BIT5                                  #  ADD 5 MS TO THE SCALER READING.
061908,001028: 26,3722           54001                           TS       L                                     
061909,001029: 26,3723           34714                           CA       ZERO                                  
061910,001030: 26,3724           20155                           DAS      MPAC                                  
061911,001031: 26,3725           44362                           CS       LOW5                                  #  SET LOW 5 BITS OF (SCALER+5MS) TO ZERO
061912,001032: 26,3726           70155                           MASK     MPAC       +1                         #  AND STORE RESULTS IN MPAC,+1.
061913,001033: 26,3727           56155                           XCH      MPAC       +1                         
061914,001034: 26,3730           74362                           MASK     LOW5                                  #  TEST LOW 5 BITS OF SCALER FOR THE FIRST
061915,001035:                                                                                                  #  INTERVAL AFTER THE T1 INCREMENT
061916,001036:                                                                                                  #  (NOW = 00000, SINCE BIT 5 ADDED).
061917,001037: 26,3731           10000                           CCS      A                                     #  IS IT 1ST INTERVAL AFTER T1 INCREMENT
061918,001038: 26,3732           24156                           INCR     MPAC       +2                         #  NO
061919,001039: 26,3733           00156                           TC       MPAC       +2                         #  YES
061920,001040: 
061921,001041:                                                                                                  #  POSTAND RECOVERS TIME AFTER STANDBY.  THE SCALER IS SNAPSHOTTED AND THE
061922,001042:                                                                                                  #  TIME1 TIME2 COUNTER IS SET TO ZERO.  THE LOW 5 BITS OF THE SCALER ARE
061923,001043:                                                                                                  #  INSPECTED TO INSURE COMPATABILITY BETWEEN THE SCALER READING AND THE
061924,001044:                                                                                                  #  CLEARING OF THE TIME COUNTER.  IT THEN COMPUTES THE DIFFERENCE IN SCALER
061925,001045:                                                                                                  #  VALUES (IN DP) AND ADDS THIS TO THE PREVIOUSLY SNAPSHOTTED VALUES OF
061926,001046:                                                                                                  #  TIME1 TIME2 AND PLACES THIS NEW TIME INTO THE TIME1 TIME2 COUNTER.
061927,001047: 
061928,001048: 26,3734                                           COUNT*   $$/P05                                
061929,001049: 
061930,001050: 26,3734           44700        POSTAND            CS       BIT11                                 #  RECOVER TIME AFTER STANDBY.
061931,001051: 26,3735           00006                           EXTEND                                         
061932,001052: 26,3736           03013                           WAND     CHAN13                                #  CLEAR STANDBY ENABLE BIT
061933,001053: 26,3737           00004                           INHINT                                         
061934,001054: 26,3740           34714                           CA       ZERO                                  
061935,001055: 26,3741           54001                           TS       L                                     
061936,001056: 26,3742           52025                           DXCH     TIME2                                 #  CLEAR TIME1 TIME2
061937,001057: 26,3743           03714                           TC       SCALPREP                              #  STORE SCALER IN MPAC, MPAC+1
061938,001058: 26,3744           03737                           TC       POSTAND    +3                         #  T1,T2,SCALER NOT COMPATIBLE
061939,001059: 26,3745           00006                           EXTEND                                         #  T1,T2 AND SCALER OK
061940,001060: 26,3746           41153                           DCS      SCALSAVE                              
061941,001061: 26,3747           20155                           DAS      MPAC                                  #  FORM DP DIFFERENCE OF POSTSTANDBY SCALER

Page 1416

061943,001063: 26,3750           34701                           CAF      BIT10                                 #  MINUS PRESTANDBY SCALER AND SHIFT RIGHT
061944,001064: 26,3751           07256                           TC       SHORTMP                               #  5 TO ALIGN BITS WITH TIME1 TIME2.
061945,001065: 26,3752           34714                           CAF      ZERO                                  
061946,001066: 26,3753           54156                           TS       MPAC       +2                         #  NEEDED FOR TP AGREE
061947,001067: 26,3754           07226                           TC       TPAGREE                               #  MAKE DP DIFF AGREE
061948,001068: 26,3755           10154                           CCS      MPAC                                  
061949,001069: 26,3756           03763                           TC       POSTCOM                               #  IF DP DIFF NET +, NO SCALER OVERFLOW
061950,001070: 26,3757           03763                           TC       POSTCOM                               #  BETWEEN PRE AND POST STANDBY.
061951,001071: 26,3760           03761                           TC       +1                                    #  IF DP DIFF NET -, SCALER OVERFLOWED.  ADD
061952,001072: 26,3761           34701                           CAF      BIT10                                 #  BIT 10 TO HIGH DIFF TO CORRECT.
061953,001073: 26,3762           26154                           ADS      MPAC                                  
061954,001074: 26,3763           00006        POSTCOM            EXTEND                                         #  C(MPAC,+1) IS MAGNITUDE OF DELTA SCALER.
061955,001075: 26,3764           31151                           DCA      TIME2SAV                              #  PRESTANDBY TIME1 TIME2
061956,001076: 26,3765           20155                           DAS      MPAC                                  
061957,001077: 26,3766           07226                           TC       TPAGREE                               #  FORCE SIGN AGREEMENT
061958,001078: 26,3767           52155                           DXCH     MPAC                                  #  UPDATED VALUE FOR T1,T2.
061959,001079: 26,3770           20025                           DAS      TIME2                                 #  LOAD UPDATED VALUE INTO T1,T2, WITH
061960,001080: 26,3771           05447                           TC       DOWNFLAG                              #  CLEAR NODOFLAG
061961,001081: 26,3772           00054                           ADRES    NODOFLAG                              
061962,001082: 
061963,001083: 26,3773           04106                           TC       GOTOPOOH                              
061964,001084: 
061965,001085: 
061966,001086: 

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