Source Code

These source-code files are part of a reconstructed copy of Comanche 44, the initial release (though not the final mission release) of the Apollo 10 Command Module (CM) Apollo Guidance Computer (AGC) software. Subsequent releases were Comanche 45 and Comanche 45/2 (the flown release on Apollo 10). The reconstruction is believed to be exactly accurate, but in the absence of an actual Apollo-era listing of Comanche 44, some explanation of the reconstruction process is needed to insure confidence in that accuracy.

The starting point was the source code of Comanche 51 (separately previously reconstructed from an Apollo-era listing of Comanche 55, flown on Apollo 11). Comanche 51 source code was then modified by undoing changes known to have been made between revisions 44 and 51. The now-reconstructed Comanche 44 source code was verified by assembling it and checking that the assembled code had the expected known-correct memory-bank checksums. Note that page numbers in the reconstructed code match those on the Comanche 55 printout, although the source code would likely have different page numbers in a contemporary Comanche 44 listing.

Annotations that were not present in the contemporary source code have been added to the reconstructed code to justify each change relative to Comanche 51. Here's a guide to the Apollo documentation referenced in those annotations:
In most cases, only the titles (rather than the full texts) of PCRs are known. In addition to the explanatory annotations, there is also a step-by-step commentary about the reconstruction process.

Comments expected to have been present in the original source code are prefixed with a single '#' symbol, whereas comments added later are prefixed by "##" or "###". Report any errors noted by creating an issue report at the Virtual AGC Project's GitHub repository.

012697,000002:                                                                                                  ## Copyright:   Public domain.
012698,000003:                                                                                                  ## Filename:    IMU_COMPENSATION_PACKAGE.agc
012699,000004:                                                                                                  ## Purpose:     A section of Comanche revision 044.
012700,000005:                                                                                                  ##              It is part of the reconstructed source code for the
012701,000006:                                                                                                  ##              original release of the flight software for the Command
012702,000007:                                                                                                  ##              Module's (CM) Apollo Guidance Computer (AGC) for Apollo 10.
012703,000008:                                                                                                  ##              The code has been recreated from a copy of Comanche 055. It
012704,000009:                                                                                                  ##              has been adapted such that the resulting bugger words
012705,000010:                                                                                                  ##              exactly match those specified for Comanche 44 in NASA drawing
012706,000011:                                                                                                  ##              2021153D, which gives relatively high confidence that the
012707,000012:                                                                                                  ##              reconstruction is correct.
012708,000013:                                                                                                  ## Assembler:   yaYUL
012709,000014:                                                                                                  ## Contact:     Ron Burkey <info@sandroid.org>.
012710,000015:                                                                                                  ## Website:     www.ibiblio.org/apollo/index.html
012711,000016:                                                                                                  ## Mod history: 2020-12-03 MAS  Created from Comanche 51.
012712,000017: 

Page 297

012714,000019: 07,2441                                           BANK     7                                     
012715,000020: 06,2000                                           SETLOC   IMUCOMP                               
012716,000021: 06,2000                                           BANK                                           
012717,000022: 06,3262  E3,1460                                  EBANK=   NBDX                                  
012718,000023: 
012719,000024: 06,3262                                           COUNT    06/ICOMP                              
012720,000025: 
012721,000026: 06,3262           33516        1/PIPA             CAF      LGCOMP                                #  SAVE EBANK OF CALLING PROGRAM
012722,000027: 06,3263           56003                           XCH      EBANK                                 
012723,000028: 06,3264           54163                           TS       MODE                                  
012724,000029: 
012725,000030: 06,3265           11477                           CCS      GCOMPSW                               #  BYPASS IF GCOMPSW NEGATIVE
012726,000031: 06,3266           13271                           TCF      +3                                    
012727,000032: 06,3267           13271                           TCF      +2                                    
012728,000033: 06,3270           13407                           TCF      IRIG1                                 #  RETURN
012729,000034: 
012730,000035: 06,3271           00004                           INHINT                                         #  ASSURE COMPLETE COMPENSATION OF DELV'S
012731,000036:                                                                                                  #  FOR DOWNLINK.
012732,000037: 
012733,000038: 06,3272           35015        1/PIPA1            CAF      FOUR                                  #  PIPAZ, PIPAY, PIPAX
012734,000039: 06,3273           54132                           TS       BUF        +2                         
012735,000040: 
012736,000041: 06,3274           50132                           INDEX    BUF        +2                         
012737,000042: 06,3275           31453                           CA       PIPASCF                               #  (P.P.M.) X 2(-9)
012738,000043: 06,3276           00006                           EXTEND                                         
012739,000044: 06,3277           50132                           INDEX    BUF        +2                         
012740,000045: 06,3300           71162                           MP       DELVX                                 #  (PP) X 2(+14) NOW (PIPA PULSES) X 2(+5)
012741,000046: 06,3301           54002                           TS       Q                                     #  SAVE MAJOR PART
012742,000047: 
012743,000048: 06,3302           30001                           CA       L                                     #  MINOR PART
012744,000049: 06,3303           00006                           EXTEND                                         
012745,000050: 06,3304           75012                           MP       BIT6                                  #  SCALE 2(+9)   SHIFT RIGHT 9   
012746,000051: 06,3305           50132                           INDEX    BUF        +2                         
012747,000052: 06,3306           55163                           TS       DELVX      +1                         #  FRACTIONAL PIPA PULSES SCALED 2(+14)
012748,000053: 
012749,000054: 06,3307           30002                           CA       Q                                     #  MAJOR PART
012750,000055: 06,3310           00006                           EXTEND                                         
012751,000056: 06,3311           75012                           MP       BIT6                                  #  SCALE 2(+9)   SHIFT RIGHT 9
012752,000057: 06,3312           50132                           INDEX    BUF        +2                         
012753,000058: 06,3313           21163                           DAS      DELVX                                 #  (PIPAI) + (PIPAI)(SFE)
012754,000059: 
012755,000060: 06,3314           50132                           INDEX    BUF        +2                         
012756,000061: 06,3315           41452                           CS       PIPABIAS                              #  (PIPA PULSES)/(CS) X 2(-8)                    *
012757,000062: 06,3316           00006                           EXTEND                                         
012758,000063: 06,3317           71074                           MP       1/PIPADT                              #  (CS) X 2(+8) NOW (PIPA PULSES) X 2(+0)        *
012759,000064: 06,3320           00006                           EXTEND                                         
012760,000065: 06,3321           75017                           MP       BIT1                                  #  SCALE 2(+14) SHIFT RIGHT 14                   *
012761,000066: 06,3322           50132                           INDEX    BUF        +2                         
012762,000067: 06,3323           21163                           DAS      DELVX                                 #  (PIPAI) + (PIPAI)(SFE) - (BIAS)(DELTAT)
012763,000068: 
012764,000069: 06,3324           10132                           CCS      BUF        +2                         #  PIPAZ, PIPAY, PIPAX

Page 298

012766,000071: 06,3325           67716                           AD       NEG1                                  
012767,000072: 06,3326           13273                           TCF      1/PIPA1    +1                         
012768,000073: 06,3327           13330                           NOOP                                           #  LESS THAN ZERO IMPOSSIBLE.
012769,000074: 06,3330           00003                           RELINT                                         

Page 299

012771,000076: 
012772,000077: 06,3331           55477        IRIGCOMP           TS       GCOMPSW                               #  INDICATE COMMANDS 2 PULSES OR LESS
012773,000078: 06,3332           54130                           TS       BUF                                   #  INDEX COUNTER - IRIGX, IRIGY, IRIGZ
012774,000079: 
012775,000080: 06,3333           00006        IRIGX              EXTEND                                         
012776,000081: 06,3334           41163                           DCS      DELVX                                 #  (PIPA PULSES) X 2(+14)
012777,000082: 06,3335           52155                           DXCH     MPAC                                  
012778,000083: 06,3336           31463                           CA       ADIAX                                 #  (GYRO PULSES)/(PIPA PULSE) X 2(-3)            *
012779,000084: 06,3337           03412                           TC       GCOMPSUB                              #  -(ADIAX)(PIPAX)       (GYRO PULSES) X 2(+14)
012780,000085: 
012781,000086: 06,3340           00006                           EXTEND                                         #  
012782,000087: 06,3341           41165                           DCS      DELVY                                 #        (PIPA PULSES) X 2(+14)
012783,000088: 06,3342           52155                           DXCH     MPAC                                  #  
012784,000089: 06,3343           41466                           CS       ADSRAX                                #        (GYRO PULSES)/(PIPA PULSE) X 2(-3)      *
012785,000090: 06,3344           03412                           TC       GCOMPSUB                              #        +(ADSRAX)(PIPAY)        (GYRO PULSES) X 2(+14)
012786,000091: 
012787,000092:                                                                                                  #                EXTEND                  ***
012788,000093:                                                                                                  #                DCS     DELVZ           ***     (PIPA PULSES) X 2(+14)
012789,000094:                                                                                                  #                DXCH    MPAC            ***
012790,000095:                                                                                                  #                CA      ADOAX           ***     (GYRO PULSES)/(PIPA PULSE) X 2(-3)      *
012791,000096:                                                                                                  #                TC      GCOMPSUB        ***     -(ADOAX)(PIPAZ)         (GYRO PULSES) X 2(+14)
012792,000097: 
012793,000098: 06,3345           41460                           CS       NBDX                                  #        (GYRO PULSES)/(CS) X 2(-5)
012794,000099: 06,3346           03441                           TC       DRIFTSUB                              #        -(NBDX)(DELTAT) (GYRO PULSES) X 2(+14)
012795,000100: 
012796,000101: 06,3347           00006        IRIGY              EXTEND                                         
012797,000102: 06,3350           41165                           DCS      DELVY                                 #  (PIPA PULSES) X 2(+14)
012798,000103: 06,3351           52155                           DXCH     MPAC                                  
012799,000104: 06,3352           31464                           CA       ADIAY                                 #  (GYRO PULSES)/(PIPA PULSE) X 2(-3)            *
012800,000105: 06,3353           03412                           TC       GCOMPSUB                              #  -(ADIAY)(PIPAY)       (GYRO PULSES) X 2(+14)
012801,000106: 
012802,000107: 06,3354           00006                           EXTEND                                         
012803,000108: 06,3355           41167                           DCS      DELVZ                                 #  (PIPA PULSES) X 2(+14)
012804,000109: 06,3356           52155                           DXCH     MPAC                                  
012805,000110: 06,3357           41467                           CS       ADSRAY                                #  (GYRO PULSES)/(PIPA PULSE) X 2(-3)            *
012806,000111: 06,3360           03412                           TC       GCOMPSUB                              #  +(ADSRAY)(PIPAZ)      (GYRO PULSES) X 2(+14)
012807,000112: 
012808,000113:                                                                                                  #                EXTEND                  ***
012809,000114:                                                                                                  #                DCS     DELVX           ***     (PIPA PULSES) X 2(+14)
012810,000115:                                                                                                  #                DXCH    MPAC            ***
012811,000116:                                                                                                  #                CA      ADOAY           ***     (GYRO PULSES)/(PIPA PULSE) X 2(-3)      *
012812,000117:                                                                                                  #                TC      GCOMPSUB        ***     -(ADOAY)(PIPAX)    (GYRO PULSES) X 2(+14)
012813,000118: 
012814,000119: 06,3361           41461                           CS       NBDY                                  #        (GYRO PULSES)/(CS) X 2(-5)
012815,000120: 06,3362           03441                           TC       DRIFTSUB                              #        -(NBDY)(DELTAT) (GYRO PULSES) X 2(+14)
012816,000121: 
012817,000122: 06,3363           00006        IRIGZ              EXTEND                                         
012818,000123: 06,3364           41165                           DCS      DELVY                                 #  (PIPA PULSES) X 2(+14)
012819,000124: 06,3365           52155                           DXCH     MPAC                                  
012820,000125: 06,3366           31470                           CA       ADSRAZ                                #  (GYRO PULSES)/(PIPA PULSE) X 2(-3)            *

Page 300

012822,000127: 06,3367           03412                           TC       GCOMPSUB                              #  -(ADSRAZ)(PIPAY)      (GYRO PULSES) X 2(+14)
012823,000128: 
012824,000129: 06,3370           00006                           EXTEND                                         
012825,000130: 06,3371           41167                           DCS      DELVZ                                 #  (PIPA PULSES) X 2(+14)
012826,000131: 06,3372           52155                           DXCH     MPAC                                  
012827,000132: 06,3373           31465                           CA       ADIAZ                                 #  (GYRO PULSES)/(PIPA PULSE) X 2(-3)            *
012828,000133: 06,3374           03412                           TC       GCOMPSUB                              #  -(ADIAZ)(PIPAZ)       (GYRO PULSES) X 2(+14)
012829,000134: 
012830,000135:                                                                                                  #                EXTEND                  ***
012831,000136:                                                                                                  #                DCS     DELVX           ***     (PIPA PULSE) X 2(+14)
012832,000137:                                                                                                  #                DXCH    MPAC            ***
012833,000138:                                                                                                  #                CS      ADOAZ           ***     (GYRO PULSES)/(PIPA PULSE) X 2(-3)      *
012834,000139:                                                                                                  #                TC      GCOMPSUB        ***     +(ADOAZ)(PIPAX) (GYRO PULSES) X 2(+14)
012835,000140: 
012836,000141: 06,3375           31462                           CA       NBDZ                                  #        (GYRO PULSES)/(CS) X 2(-5)
012837,000142: 06,3376           03441                           TC       DRIFTSUB                              #        +(NBDZ)(DELTAT) (GYRO PULSES) X 2(+14)
012838,000143: 

Page 301

012840,000145: 06,3377           11477                           CCS      GCOMPSW                               #  ARE GYRO COMMANDS GREATER THAN 2 PULSES
012841,000146: 06,3400           13402                           TCF      +2                                    #  YES   
012842,000147: 06,3401           13407                           TCF      IRIG1                                 #  NO    
012843,000148: 
012844,000149: 06,3402           35073                           CA       PRIO21                                #  HIGHER THAN SERVICER - LESS THAN PRELAUNCH
012845,000150: 06,3403           05134                           TC       NOVAC                                 
012846,000151: 06,3404  E3,1460                                  EBANK=   NBDX                                  
012847,000152: 06,3404           03474 14063                     2CADR    1/GYRO                                
012848,000153: 
012849,000154: 06,3406           00003                           RELINT                                         
012850,000155: 06,3407           30163        IRIG1              CA       MODE                                  #  SET EBANK FOR RETURN
012851,000156: 06,3410           54003                           TS       EBANK                                 
012852,000157: 06,3411           14675                           TCF      SWRETURN                              
012853,000158: 
012854,000159: 06,3412           56154        GCOMPSUB           XCH      MPAC                                  #  ADIA OR ADSRA COEFFICIENT ARRIVES IN A
012855,000160: 06,3413           00006                           EXTEND                                         #  C(MPAC) = (PIPA PULSES) X 2(+14)
012856,000161: 06,3414           70154                           MP       MPAC                                  #  (GYRO PULSES)/(PIPA PULSE) X 2(-3)            *
012857,000162: 06,3415           52123                           DXCH     VBUF                                  #  NOW = (GYRO PULSES) X 2(+11)                  *
012858,000163: 
012859,000164: 06,3416           30155                           CA       MPAC       +1                         #  MINOR PART PIPA PULSES
012860,000165: 06,3417           00006                           EXTEND                                         
012861,000166: 06,3420           70154                           MP       MPAC                                  #  ADIA OR ADSRA
012862,000167: 06,3421           54001                           TS       L                                     
012863,000168: 06,3422           35021                           CAF      ZERO                                  
012864,000169: 06,3423           20123                           DAS      VBUF                                  #  NOW = (GYRO PULSES) X 2(+11)                  *
012865,000170: 
012866,000171: 06,3424           30122                           CA       VBUF                                  #  PARTIAL RESULT - MAJOR
012867,000172: 06,3425           00006                           EXTEND                                         
012868,000173: 06,3426           75004                           MP       BIT12                                 #  SCALE 2(+3)   SHIFT RIGHT 3                   *
012869,000174: 06,3427           50130                           INDEX    BUF                                   #  RESULT = (GYRO PULSES) X 2(+14)
012870,000175: 06,3430           21472                           DAS      GCOMP                                 #  HI(ADIA)(PIPAI) OR HI(ADSRA)(PIPAI)
012871,000176: 
012872,000177: 06,3431           30123                           CA       VBUF       +1                         #  PARTIAL RESULT - MINOR
012873,000178: 06,3432           00006                           EXTEND                                         
012874,000179: 06,3433           75004                           MP       BIT12                                 #  SCALE 2(+3)   SHIFT RIGHT 3                   *
012875,000180: 06,3434           54001                           TS       L                                     
012876,000181: 06,3435           35021                           CAF      ZERO                                  
012877,000182: 06,3436           50130                           INDEX    BUF                                   #  RESULT = (GYRO PULSES) X 2(+14)
012878,000183: 06,3437           21472                           DAS      GCOMP                                 #  (ADIA)(PIPAI) OR (ADSRA)(PIPAI)
012879,000184: 
012880,000185: 06,3440           00002                           TC       Q                                     
012881,000186: 

Page 302

012883,000188: 06,3441           00006        DRIFTSUB           EXTEND                                         
012884,000189: 06,3442           22131                           QXCH     BUF        +1                         
012885,000190: 
012886,000191: 06,3443           00006                           EXTEND                                         #  C(A) = NBD    (GYRO PULSES)/(CS) X 2(-5)
012887,000192: 06,3444           71074                           MP       1/PIPADT                              #  (CS) X 2(+8)   NOW (GYRO PULSES) X 2(+3)
012888,000193: 06,3445           22155                           LXCH     MPAC       +1                         #  SAVE FOR FRACTIONAL COMPENSATION
012889,000194: 06,3446           00006                           EXTEND                                         
012890,000195: 06,3447           75014                           MP       BIT4                                  #  SCALE 2(+11)  SHIFT RIGHT 11
012891,000196: 06,3450           50130                           INDEX    BUF                                   
012892,000197: 06,3451           21472                           DAS      GCOMP                                 #  HI(NBD)(DELTAT)       (GYRO PULSES) X 2(+14)
012893,000198: 
012894,000199: 06,3452           30155                           CA       MPAC       +1                         #  NOW MINOR PART
012895,000200: 06,3453           00006                           EXTEND                                         
012896,000201: 06,3454           75014                           MP       BIT4                                  #  SCALE 2(+11)          SHIFT RIGHT 11
012897,000202: 06,3455           54001                           TS       L                                     
012898,000203: 06,3456           35021                           CAF      ZERO                                  
012899,000204: 06,3457           50130                           INDEX    BUF                                   #  ADD IN FRACTIONAL COMPENSATION
012900,000205: 06,3460           21472                           DAS      GCOMP                                 #  (NBD)(DELTAT)         (GYRO PULSES) X 2(+14)
012901,000206: 
012902,000207: 06,3461           35016        DRFTSUB2           CAF      TWO                                   #  PIPAX, PIPAY, PIPAZ
012903,000208: 06,3462           60130                           AD       BUF                                   
012904,000209: 06,3463           56130                           XCH      BUF                                   
012905,000210: 06,3464           50000                           INDEX    A                                     
012906,000211: 06,3465           11471                           CCS      GCOMP                                 #  ARE GYRO COMMANDS 1 PULSE OR GREATER
012907,000212: 06,3466           13470                           TCF      +2                                    #  YES
012908,000213: 06,3467           00131                           TC       BUF        +1                         #  NO
012909,000214: 
012910,000215: 06,3470           77716                           MASK     NEGONE                                
012911,000216: 06,3471           10000                           CCS      A                                     #  ARE GYRO COMMANDS GREATER THAN 2 PULSES
012912,000217: 06,3472           55477                           TS       GCOMPSW                               #  YES - SET GCOMPSW POSITIVE
012913,000218: 06,3473           00131                           TC       BUF        +1                         #  NO
012914,000219: 

Page 303

012916,000221: 06,3474           35015        1/GYRO             CAF      FOUR                                  #  PIPAZ, PIPAY, PIPAX
012917,000222: 06,3475           54130                           TS       BUF                                   
012918,000223: 
012919,000224: 06,3476           50130                           INDEX    BUF                                   #  SCALE GYRO COMMANDS FOR IMUPULSE
012920,000225: 06,3477           31472                           CA       GCOMP      +1                         #  FRACTIONAL PULSES
012921,000226: 06,3500           00006                           EXTEND                                         
012922,000227: 06,3501           75010                           MP       BIT8                                  #  SHIFT RIGHT 7
012923,000228: 06,3502           50130                           INDEX    BUF                                   
012924,000229: 06,3503           55472                           TS       GCOMP      +1                         #  FRACTIONAL PULSES SCALED
012925,000230: 
012926,000231: 06,3504           35021                           CAF      ZERO                                  #  SET GCOMP = 0 FOR DAS INSTRUCTION
012927,000232: 06,3505           50130                           INDEX    BUF                                   
012928,000233: 06,3506           57471                           XCH      GCOMP                                 #  GYRO PULSES
012929,000234: 06,3507           00006                           EXTEND                                         
012930,000235: 06,3510           75010                           MP       BIT8                                  #  SHIFT RIGHT 7
012931,000236: 06,3511           50130                           INDEX    BUF                                   
012932,000237: 06,3512           21472                           DAS      GCOMP                                 #  ADD THESE TO FRACTIONAL PULSES ABOVE
012933,000238: 
012934,000239: 06,3513           10130                           CCS      BUF                                   #  PIPAZ, PIPAY, PIPAX
012935,000240: 06,3514           67716                           AD       NEG1                                  
012936,000241: 06,3515           13475                           TCF      1/GYRO     +1                         
012937,000242: 06,3516           01471        LGCOMP             ECADR    GCOMP                                 #  LESS THAN ZERO IMPOSSIBLE
012938,000243: 
012939,000244: 06,3517           33516                           CAF      LGCOMP                                
012940,000245: 06,3520           04662                           TC       BANKCALL                              
012941,000246: 06,3521           17206                           CADR     IMUPULSE                              #  CALL GYRO TORQUING ROUTINE
012942,000247: 06,3522           04662                           TC       BANKCALL                              
012943,000248: 06,3523           17577                           CADR     IMUSTALL                              #  WAIT FOR PULSES TO GET OUT
012944,000249: 06,3524           15217                           TCF      ENDOFJOB                              #  TEMPORARY
012945,000250: 
012946,000251: 06,3525           35015        GCOMP1             CAF      FOUR                                  #  PIPAZ, PIPAY, PIPAX
012947,000252: 06,3526           54130                           TS       BUF                                   
012948,000253: 
012949,000254: 06,3527           50130                           INDEX    BUF                                   #  RESCALE
012950,000255: 06,3530           31472                           CA       GCOMP      +1                         
012951,000256: 06,3531           00006                           EXTEND                                         
012952,000257: 06,3532           75010                           MP       BIT8                                  #  SHIFT MINOR PART LEFT 7 - MAJOR PART = 0
012953,000258: 06,3533           50130                           INDEX    BUF                                   
012954,000259: 06,3534           23472                           LXCH     GCOMP      +1                         #  BITS 8-14 OF MINOR PART WERE = 0
012955,000260: 
012956,000261: 06,3535           10130                           CCS      BUF                                   #  PIPAZ, PIPAY, PIPAX
012957,000262: 06,3536           67716                           AD       NEG1                                  
012958,000263: 06,3537           13526                           TCF      GCOMP1     +1                         
012959,000264: 
012960,000265: 06,3540           01436        V06N30S            VN       0630                                  
012961,000266: 06,3541           15217                           TCF      ENDOFJOB                              
012962,000267: 

Page 304

012964,000269: 06,3542           11477        NBDONLY            CCS      GCOMPSW                               #  BYPASS IF GCOMPSW NEGATIVE
012965,000270: 06,3543           13546                           TCF      +3                                    
012966,000271: 06,3544           13546                           TCF      +2                                    
012967,000272: 06,3545           15217                           TCF      ENDOFJOB                              
012968,000273: 
012969,000274: 06,3546           00004                           INHINT                                         
012970,000275: 06,3547           10076                           CCS      FLAGWRD2                              #  PREREAD T3RUPT MAY COINCIDE
012971,000276: 06,3550           15217                           TCF      ENDOFJOB                              
012972,000277: 06,3551           15217                           TCF      ENDOFJOB                              
012973,000278: 06,3552           13553                           TCF      +1                                    
012974,000279: 
012975,000280: 06,3553           30025                           CA       TIME1                                 #  (CS) X 2(+14)
012976,000281: 06,3554           57074                           XCH      1/PIPADT                              #  PREVIOUS TIME
012977,000282: 06,3555           00003                           RELINT                                         
012978,000283: 06,3556           40000                           COM                                            
012979,000284: 06,3557           61074                           AD       1/PIPADT                              
012980,000285: 06,3560           10000        NBD2               CCS      A                                     #  CALCULATE ELAPSED TIME
012981,000286: 06,3561           65017                           AD       ONE                                   #  NO TIME1 OVERFLOW
012982,000287: 06,3562           13567                           TCF      NBD3                                  #  RESTORE TIME DIFFERENCE AND JUMP
012983,000288: 06,3563           13565                           TCF      +2                                    #  TIME1 OVERFLOW
012984,000289: 06,3564           15217                           TCF      ENDOFJOB                              #  IF ELAPSED TIME = 0 (DIFFERENCE = -0)
012985,000290: 
012986,000291: 06,3565           40000                           COM                                            #  CALCULATE ABSOLUTE DIFFERENCE
012987,000292: 06,3566           64777                           AD       POSMAX                                
012988,000293: 
012989,000294: 06,3567           00006        NBD3               EXTEND                                         #  C(A) = DELTAT         (CS) X 2(+14)
012990,000295: 06,3570           75006                           MP       BIT10                                 #  SHIFT RIGHT 5
012991,000296: 06,3571           52123                           DXCH     VBUF                                  
012992,000297: 06,3572           00006                           EXTEND                                         
012993,000298: 06,3573           30123                           DCA      VBUF                                  
012994,000299: 06,3574           52155                           DXCH     MPAC                                  #  DELTAT NOW SCALED (CS) X 2(+19)
012995,000300: 
012996,000301: 06,3575           35021                           CAF      ZERO                                  
012997,000302: 06,3576           55477                           TS       GCOMPSW                               #  INDICATE COMMANDS 2 PULSES OR LESS
012998,000303: 06,3577           54130                           TS       BUF                                   #  PIPAX, PIPAY, PIPAZ
012999,000304: 
013000,000305: 06,3600           41460                           CS       NBDX                                  #  (GYRO PULSES)/(CS) X 2(-5)
013001,000306: 06,3601           03617                           TC       FBIASSUB                              #  -(NBDX)(DELTAT)       (GYRO PULSES) X 2(+14)
013002,000307: 
013003,000308: 06,3602           00006                           EXTEND                                         
013004,000309: 06,3603           40123                           DCS      VBUF                                  
013005,000310: 06,3604           52155                           DXCH     MPAC                                  #  DELTAT SCALED (CS) X 2(+19)
013006,000311: 06,3605           31461                           CA       NBDY                                  #  (GYRO PULSES)/(CS) X 2(-5)
013007,000312: 06,3606           03617                           TC       FBIASSUB                              #  -(NBDY)(DELTAT)       (GYRO PULSES) X 2(+14)
013008,000313: 
013009,000314: 06,3607           00006                           EXTEND                                         
013010,000315: 06,3610           40123                           DCS      VBUF                                  
013011,000316: 06,3611           52155                           DXCH     MPAC                                  #  DELTAT SCALED (CS) X 2(+19)
013012,000317: 06,3612           41462                           CS       NBDZ                                  #  (GYRO PULSES)/(CS) X 2(-5)
013013,000318: 06,3613           03617                           TC       FBIASSUB                              #  +(NBDZ)(DELTAT)       (GYRO PULSES) X 2(+14)

Page 305

013015,000320: 06,3614           11477                           CCS      GCOMPSW                               #  ARE GYRO COMMANDS GREATER THAN 2 PULSES
013016,000321: 06,3615           13474                           TCF      1/GYRO                                #  YES
013017,000322: 06,3616           15217                           TCF      ENDOFJOB                              #  NO
013018,000323: 

Page 306

013020,000325: 06,3617           56002        FBIASSUB           XCH      Q                                     
013021,000326: 06,3620           54131                           TS       BUF        +1                         
013022,000327: 
013023,000328: 06,3621           30002                           CA       Q                                     #  NBD SCALED (GYRO PULSES)/(CS) X 2(-5)
013024,000329: 06,3622           00006                           EXTEND                                         
013025,000330: 06,3623           70154                           MP       MPAC                                  #  DELTAT SCALED (CS) X 2(+19)
013026,000331: 06,3624           50130                           INDEX    BUF                                   
013027,000332: 06,3625           21472                           DAS      GCOMP                                 #  HI(NBD)(DELTAT)       (GYRO PULSES) X 2(+14)
013028,000333: 
013029,000334: 06,3626           30002                           CA       Q                                     #  NOW FRACTIONAL PART
013030,000335: 06,3627           00006                           EXTEND                                         
013031,000336: 06,3630           70155                           MP       MPAC       +1                         
013032,000337: 06,3631           54001                           TS       L                                     
013033,000338: 06,3632           35021                           CAF      ZERO                                  
013034,000339: 06,3633           50130                           INDEX    BUF                                   
013035,000340: 06,3634           21472                           DAS      GCOMP                                 #  (NBD)(DELTAT)         (GYRO PULSES) X 2(+14)
013036,000341: 
013037,000342: 06,3635           13461                           TCF      DRFTSUB2                              #  CHECK MAGNITUDE OF COMPENSATION
013038,000343: 
013039,000344: 06,3636           04662        LASTBIAS           TC       BANKCALL                              
013040,000345: 06,3637           17156                           CADR     PIPUSE                                
013041,000346: 
013042,000347: 06,3640           11477                           CCS      GCOMPSW                               #  BYPASS IF GCOMPSW NEGATIVE
013043,000348: 06,3641           13644                           TCF      +3                                    
013044,000349: 06,3642           13644                           TCF      +2                                    
013045,000350: 06,3643           15217                           TCF      ENDOFJOB                              
013046,000351: 
013047,000352: 06,3644           37665                           CAF      PRIO31                                #  2 SECONDS SCALED (CS) X 2(+8)
013048,000353: 06,3645           57074                           XCH      1/PIPADT                              
013049,000354: 06,3646           40000                           COM                                            
013050,000355: 06,3647           61246                           AD       PIPTIME1   +1                         #  TIME AT PIPA1 =0
013051,000356: 06,3650           13560                           TCF      NBD2                                  
013052,000357: 

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