Source Code
These source-code files are part of a reconstructed copy of Comanche 45/2 (AKA Manche45 revision 2),
the final, flown mission release of the Apollo 10 Command Module (CM) Apollo Guidance
Computer (AGC) software. Comanche 45/2 was preceded by Comanche 44 and Comanche 45. The
reconstruction is believed to be exactly accurate, but in the absence of an actual Apollo-era
listing of Comanche 45/2, some explanation of the reconstruction process is needed
to insure confidence in that accuracy.
The starting point was the source code of Comanche 45 (itself previously accurately reconstructed). Comanche 45 source code was then modified by incorporating changes known from contemporary documentation to have been made between revisions 45 and 45/2. The now-reconstructed Comanche 45/2 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 tend to match those in the Comanche 55, the most-similar revision of Comanche for which we have access to an actual non-reconstructed hardcopy; the source code would likely have different page numbers in a contemporary Comanche 45 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 44. Here's a guide to the Apollo documentation referenced in those annotations:
|
042951,000002: ## Copyright: Public domain.
042952,000003: ## Filename: TVCROLLDAP.agc
042953,000004: ## Purpose: A section of Manche45 revision 2.
042954,000005: ## It is part of the reconstructed source code for the
042955,000006: ## final, flown release of the flight software for the Command
042956,000007: ## Module's (CM) Apollo Guidance Computer (AGC) for Apollo 10.
042957,000008: ## The code has been recreated from a copy of Comanche 055. It
042958,000009: ## has been adapted such that the resulting bugger words
042959,000010: ## exactly match those specified for Manche 45/2 in NASA drawing
042960,000011: ## 2021153D, which gives relatively high confidence that the
042961,000012: ## reconstruction is correct.
042962,000013: ## Assembler: yaYUL
042963,000014: ## Contact: Ron Burkey <info@sandroid.org>.
042964,000015: ## Website: www.ibiblio.org/apollo/index.html
042965,000016: ## Mod history: 2020-12-24 MAS Created from Comanche 45.
042966,000017:
Page 984 |
042968,000019: # PROGRAM NAME...TVC ROLL AUTOPILOT
042969,000020: # LOG SECTION...TVCROLLDAP SUBROUTINE...DAPCSM
042970,000021: # MODIFIED BY SCHLUNDT 21 OCTOBER 1968
042971,000022:
042972,000023: # FUNCTIONAL DESCRIPTION....
042973,000024:
042974,000025: # *AN ADAPTATION OF THE LEM P-AXIS CONTROLLER
042975,000026: # *MAINTAIN OGA WITHIN 5 DEG DEADBND OF OGAD, WHERE OGAD = OGA AS SEEN
042976,000027: # BY IGNITION (P40)
042977,000028: # *MAINTAIN OGA RATE LESS THAN 0.1 DEG/SEC LIMIT CYCLE RATE
042978,000029: # *SWITCHING LOGIC IN PHASE PLANE.... SEE GSOP CHAPTER 3
042979,000030: # *USES T6 CLOCK TO TIME JET FIRINGS
042980,000031: # *MAXIMUM JET FIRING TIME = 2.56 SECONDS, LIMITED TO 2.5 IF GREATER
042981,000032: # *MINIMUM JET FIRING TIME = 15 MS
042982,000033: # *JET PAIRS FIRE ALTERNATELY
042983,000034: # *AT LEAST 1/2 SECOND DELAY BEFORE A NEW JET PAIR IS FIRED
042984,000035: # *JET FIRINGS MAY NOT BE EXTENDED, ONLY SHORTENED, WHEN RE-EVALUATION
042985,000036: # OF A JET FIRING TIME IS MADE ON A LATER PASS
042986,000037:
042987,000038: # CALLING SEQUENCE....
042988,000039:
042989,000040: # *ROLLDAP CALL VIA WAITLIST, IN PARTICULAR BY TVCEXEC (EVERY 1/2 SEC)
042990,000041: # WITH A 3CS DELAY TO ALLOW FREE TIME FOR OTHER RUPTS (DWNRPT, ETC.)
042991,000042:
042992,000043: # NORMAL EXIT MODES.... ENDOFJOB
042993,000044:
042994,000045: # ALARM OR ABORT EXIT MODES.... NONE
042995,000046:
042996,000047: # SUBROUTINES CALLED.....NONE
042997,000048:
042998,000049: # OTHER INTERFACES....
042999,000050:
043000,000051: # *TVCEXEC SETS UP ROLLDAP TASK EVERY 1/2 SECOND AND UPDATES 1/CONACC
043001,000052: # EVERY 10 SECONDS (VIA MASSPROP AND S40.15)
043002,000053: # *RESTARTS SUSPEND ROLL DAP COMPUTATIONS UNTIL THE NEXT 1/2 SEC
043003,000054: # SAMPLE PERIOD. (THE PART OF TVCEXECUTIVE THAT CALLS ROLL DAP IS
043004,000055: # NOT RESTARTED.) THE OGAD FROM IGNITION IS MAINTAINED.
043005,000056:
043006,000057: # ERASABLE INITIALIZATION REQUIRED....
043007,000058:
043008,000059: # *1/CONACC (S40.15)
043009,000060: # *OGAD (CDUX AT IGNITION)
043010,000061: # *OGANOW (CDUX AT TVCINIT4 AND TVCEXECUTIVE)
043011,000062: # *OGAPAST (OGANOW AT TVCEXECUTIVE)
043012,000063: # *ROLLFIRE = TEMREG = ROLLWORD = 0 (MRCLEAN LOOP IN TVCDAPON)
043013,000064:
043014,000065: # OUTPUT....
043015,000066:
043016,000067: # *ROLL JET PAIR FIRINGS
043017,000068:
Page 985 |
043019,000070: # DEBRIS.... MISCELLANEOUS, SHAREABLE WITH RCS/ENTRY, IN EBANK6 ONLY
043020,000071:
Page 986 |
043022,000073: # SOME NOTES ON THE ROLL AUTOPILOT, AND IN PARTICULAR, ON ITS SWITCHING
043023,000074: # LOGIC. SEE SECTION THREE OF THE GSOP (SUNDISK/COLOSSUS) FOR DETAILS.
043024,000075:
043025,000076: # SWITCHING LOGIC IN THE PHASE PLANE....
043026,000077:
043027,000078: # OGARATE
043028,000079: # *
043029,000080: # *
043030,000081: # * * * * * * * * * * * *
043031,000082: # * (REGION 1, SEE TEXT BELOW)
043032,000083: # * *
043033,000084: # *
043034,000085: # * * * * * * * (COAST) * ...PARABOLA (SWITCHING = CONTROL)
043035,000086: # * * .
043036,000087: # * * *
043037,000088: # * * (FIRE NEG ROLL JETS)
043038,000089: # * * *
043039,000090: # (-DB,+LMCRATE)....* *
043040,000091: # * * *
043041,000092: # * * OGAERROR
043042,000093: # ************************************************************************
043043,000094: # * * (-AK, OGAERR)
043044,000095: # * * * (REGION 6-PRIME)
043045,000096: # * * (SEE TEXT BELOW)
043046,000097: # * * *
043047,000098: # * * ...STRAIGHT LINE
043048,000099: # (FIRE POS ROLL JETS) * * * .
043049,000100: # * (COAST) *
043050,000101: # * * * * * * * * * * *
043051,000102: # * -MINLIM
043052,000103: # * *
043053,000104: # *
043054,000105: # * * * * * * * * * * * * * * * *
043055,000106: # * -MAXLIM
043056,000107: # *
043057,000108: # *
043058,000109:
043059,000110: # SWITCHING PARABOLAS ARE CONTROL PARABOLAS, THUS REQUIRING KNOWLEDGE OF
043060,000111: # CONTROL ACCELERATION CONACC, OR ITS RECIPROCAL, 1/CONACC, THE TVC
043061,000112: # ROLL DAP GAIN (SEE TVCEXECUTIVE VARIABLE GAIN PACKAGE). JET
043062,000113: # FIRING TIME IS SIMPLY THAT REQUIRED TO ACHIEVE THE DESIRED OGARATE,
043063,000114: # SUBJECT TO THE LIMITATIONS DISCUSSED UNDER FUNCTIONAL DESCRIPTION,
043064,000115: # ABOVE.
043065,000116:
043066,000117: # THE THREE CONTROL REGIONS (+, -, AND ZERO TORQUE) ARE COMPRIZED OF
043067,000118: # TWELVE SUBSET REGIONS ( 1...6, AND THE CORRESPONDING 1-PRIME...
043068,000119: # 6-PRIME ) SEE SECTION 3 OF THE GSOP (SUNDISK OR COLOSSUS)
Page 987 |
043070,000121:
043071,000122: # GIVEN THE OPERATING POINT NOT IN THE COAST REGION, THE DESIRED OGARATE
043072,000123: # IS AT THE POINT OF PENETRATION OF THE COAST REGION BY THE CONTROL
043073,000124: # PARABOLA WHICH PASSES THROUGH THE OPERATING POINT. FOR REGION 3
043074,000125: # DESIRED OGARATE IS SIMPLY +-MAXLIM. FOR REGIONS 1 OR 6 THE SOLUTION
043075,000126: # TO A QUADRATIC IS REQUIRED (THE PENETRATION IS ALONG THE STRAIGHT
043076,000127: # LINE OR MINLIM BOUNDRY SWITCH LINES). AN APPROXIMATION IS MADE
043077,000128: # INSTEAD. TAKE AN OPERATING POINT IN REGION 6'. PASS A TANGENT TO
043078,000129: # THE CONTROL PARABOLA THROUGH THE OPERATING POINT, AND FIND ITS
043079,000130: # INTERSECTION WITH THE STRAIGHT LINE SECTION OF THE SWITCH CURVE...
043080,000131: # THE INTERSECTION DEFINES DESIRED OGARATE. IF THE OPERATING POINT IS
043081,000132: # CLOSE TO THE SWITCH LINE, THE APPROXIMATION IS QUITE GOOD (INDEED
043082,000133: # THE APPROXIMATE AND QUADRATIC SOLUTIONS CONVERGE IN THE LIMIT AS
043083,000134: # THE SWITCH LINE IS APPROACHED). IF THE OPERATING POINT IS NOT CLOSE
043084,000135: # TO THE SWITCH LINE, THE APPROXIMATE SOLUTION GIVES VALID TREND
043085,000136: # INFORMATION (DIRECTION OF DESIRED OGARATE) AT LEAST. THE
043086,000137: # RE-EVALUATION OF DESIRED OGARATE IN SUBSEQUENT ROLL DAP PASSES (1/2
043087,000138: # SECOND INTERVALS) WILL BENEFIT FROM THE CONVERGENT NATURE OF THE
043088,000139: # APPROXIMATION.
043089,000140:
043090,000141: # FOR LARGE OGAERROR THE TANGENT INTERSECTS +-MINLIM SWITCH BOUNDRY BEFORE
043091,000142: # INTERSECTING THE STRAIGHT LINE SWITCH. HOWEVER THE MINLIM IS
043092,000143: # IGNORED IN COMPUTING THE FIRING TIME, SO THAT THE EXTENSION (INTO
043093,000144: # THE COAST REGION) OF THE STRAIGHT LINE SWITCH IS WHAT IS FIRED TO.
043094,000145: # IF THE ROLL DAP FINDS ITSELF IN THE COAST REGION BEFORE REACHING
043095,000146: # THE DESIRED INTERSECTION (IE, IN THE REGION BETWEEN THE MINLIM
043096,000147: # AND THE STRAIGHT LINE SWITCH) IT WILL EXIBIT NORMAL COAST-REGION
043097,000148: # BEHAVIOR AND TURN OFF THE JETS. THE PURPOSE OF THIS FIRING POLICY
043098,000149: # IS TO MAINTAIN STATIC ROLL STABILITY IN THE EVENT OF A JET
043099,000150: # FAILED-ON.
043100,000151:
043101,000152: # WHEN THE OPERATING POINT IS IN REGION 1 THE SAME APPROXIMATION IS
043102,000153: # MADE, BUT AT AN ARTIFICIALLY-CREATED OR DUMMY OPERATING POINT,
043103,000154: # DEFINED BY.. OGAERROR = INTERSECTION OF CONTROL PARABOLA AND
043104,000155: # OGAERROR AXIS, OGARATE = +-LMCRATE WHERE SIGN IS OPPOSITE THAT OF
043105,000156: # REAL OPERATING POINT RATE. WHEN THE OPERATING POINT HAS PASSED
043106,000157: # FROM REGION 1 TO REGION 6', THE DUMMY POINT IS NO LONGER REQUIRED,
043107,000158: # AND THE SOLUTION REVERTS TO THAT OF A REGULAR REGION 6' POINT.
043108,000159:
043109,000160: # EQUATION FOR SWITCHING PARABOLA (SEE FIGURE ABOVE)....
043110,000161: # 2
043111,000162: # SOGAERROR = (DB - (SOGARATE) (1/CONACC)/2) SGN(SOGARATE)
043112,000163:
043113,000164: # EQUATION FOR SWITCHING STRAIGHT LINE SEGMENT....
043114,000165:
043115,000166: # SOGARATE = -(-SLOPE)(SOGAERROR) - SGN(SOGARATE) INTERCEP
043116,000167:
043117,000168: # WHERE INTERCEP = DB(-SLOPE) - LMCRATE
Page 988 |
043119,000170:
043120,000171: # EQUATION FOR INTERSECTION, CONTROL PARABOLA AND STRAIGHT SWITCH LINE....
043121,000172:
043122,000173: # DOGADOT = NUM/DEN, WHERE
043123,000174: # 2
043124,000175: # NUM = (-SLOPE)(OGARATE) (1/CONACC)
043125,000176: # +SGN(DELOGA)(-SLOPE)(OGAERROR - SGN(DELOGA)(DB))
043126,000177: # +LMCRATE
043127,000178:
043128,000179: # DEN = (-SLOPE)(LMCRATE)(1/CONACC) - SGN(DELOGA)
043129,000180: # 2
043130,000181: # DELOGA = OGAERROR - (DB - OGARATE (1/CONACC)/2)SGN(OGARATE)
043131,000182:
043132,000183: # FOR REGIONS 6 AND 6-PRIME USE ACTUAL OPERATING POINT (OGA, OGARATE)
043133,000184: # FOR OGAERROR AND OGARATE IN THE INTERSECTION EQUATIONS ABOVE.
043134,000185: # FOR REGIONS 1 AND 1-PRIME USE DUMMY OPERATING POINT FOR OGAERROR
043135,000186: # AND OGARATE, WHERE THE DUMMY POINT IS GIVEN BY....
043136,000187:
043137,000188: # OGAERROR = DELOGA + DB SGN(OGARATE)
043138,000189:
043139,000190: # OGARATE = -LMCRATE SGN(OGARATE)
043140,000191:
043141,000192: # NOTE, OGAERROR = OGA - OGAD USES DUMMY REGISTER OGA IN ROLL DAP CODING
043142,000193: # ALSO, AT POINT WHERE DOGARATE IS COMPUTED, REGISTER DELOGA IS USED
043143,000194: # AS A DUMMY REGISTER FOR THE OGAERROR IN THE NUM EQUATION ABOVE
Page 989 |
043145,000196:
043146,000197: # ROLLDAP CODING....
043147,000198:
043148,000199: 16,2000 SETLOC DAPROLL
043149,000200: 16,2000 BANK
043150,000201: 16,3267 E6,1662 EBANK= OGANOW
043151,000202: 16,3267 COUNT* $$/ROLL
043152,000203: 16,3267 31662 ROLLDAP CAE OGANOW # OGA RATE ESTIMATOR...SIMPLE FIRST-ORDER
043153,000204: 16,3270 00006 EXTEND # DIFFERENCE (SAMPLE TIME = 1/2 SEC)
043154,000205: 16,3271 21663 MSU OGAPAST
043155,000206: 16,3272 00006 EXTEND
043156,000207: 16,3273 75013 MP BIT5
043157,000208: 16,3274 22000 LXCH A
043158,000209: 16,3275 55533 TS OGARATE # SC.AT B-4 REV/SEC
043159,000210:
043160,000211: # COMPUTATIONS WHICH FOLLOW USE OGA FOR OGAERR (SAME REGISTER)
043161,000212: # EXAMINE DURATION OF LAST JET FIRING IF JETS NOW ON.
043162,000213:
043163,000214: 16,3276 31571 DURATION CA ROLLFIRE # SAME SGN AS PRESENT TORQ,MAGN=POSMAX
043164,000215: 16,3277 00006 EXTEND
043165,000216: 16,3300 13302 BZF +2 # ROLL JETS ARE NOW OFF.
043166,000217: 16,3301 13310 TCF ROLLOGIC # ENTER LOGIC, JETS NOW ON.
043167,000218:
043168,000219: 16,3302 31573 CAE TEMREG # EXAMINE LAST FIRING INTERVAL
043169,000220: 16,3303 00006 EXTEND # IF POSITIVE, DONT FIRE
043170,000221: 16,3304 13310 BZF ROLLOGIC # ENTER LOGIC, JETS NOW OFF.
043171,000222:
043172,000223: 16,3305 35021 CAF ZERO # JETS HAVE NOT BEEN OFF FOR 1/2 SEC. WAIT
043173,000224: 16,3306 55573 TS TEMREG # RESET TEMREG
043174,000225: 16,3307 15324 WAIT1/2 TCF TASKOVER # EXIT ROLL DAP
043175,000226:
043176,000227: # COMPUTE DB-(1/2 CONACC) (OGARATE)SQ (1/2 IN THE SCALING)
043177,000228:
043178,000229: 16,3310 41533 ROLLOGIC CS OGARATE # SCALED AT 2(-4) REV/SEC
043179,000230: 16,3311 00006 EXTEND
043180,000231: 16,3312 71640 MP 1/CONACC # SCALED AT 2(+9) SEC SQ /REV
043181,000232: 16,3313 00006 EXTEND
043182,000233: 16,3314 71533 MP OGARATE
043183,000234: 16,3315 63703 AD DB # SCALED AT 2(+0) REV
043184,000235: 16,3316 55573 TS TEMREG # QUANTITY SCALED AT 2(+0) REV.
043185,000236:
043186,000237: # GET SIGN OF OGARATE
043187,000238:
043188,000239: 16,3317 31533 CA OGARATE
043189,000240: 16,3320 00006 EXTEND
043190,000241: 16,3321 63324 BZMF +3 # LET SGN(0) BE NEGATIVE
043191,000242: 16,3322 35017 CA BIT1
043192,000243: 16,3323 13325 TCF +2
043193,000244: 16,3324 45017 CS BIT1
043194,000245: 16,3325 55666 TS SGNRT # + OR - 2(-14)
043195,000246:
Page 990 |
043197,000248: # CALCULATE DISTANCE FROM SWITCH PARABOLA (DELOGA)
043198,000249: 16,3326 00006 EXTEND
043199,000250: 16,3327 71573 MP TEMREG # SGN(OGARATE) TEMREG NOW IN L
043200,000251: 16,3330 40001 CS L
043201,000252: 16,3331 61664 AD OGA # SCALED AT 2(+0) REV
043202,000253: 16,3332 55667 DELOGAC TS DELOGA # SCALE B+0 REV, PLUS TO RIGHT OF C-PARAB
043203,000254:
043204,000255: # EXAMINE SGN(DELOGA) AND CREATE CA OR CS INSTR. DEPENDING UPON SIGN.
043205,000256:
043206,000257: 16,3333 00006 EXTEND
043207,000258: 16,3334 63337 BZMF +3
043208,000259: 16,3335 34371 CAF PRIO30 # = CA (30000)
043209,000260: 16,3336 13340 TCF +2
043210,000261: 16,3337 35001 CAF BIT15 # = CS (40000)
043211,000262: 16,3340 55670 TS I
043212,000263:
043213,000264: 16,3341 51670 INDEX I # TSET ON I SGN(OGARATE)
043214,000265: 16,3342 01666 0 SGNRT # CA OR CS
043215,000266: 16,3343 40000 COM
043216,000267: 16,3344 00006 EXTEND
043217,000268: 16,3345 63416 REG1TST BZMF ROLLON # IF REGION 1 (DELOGA OGARATE SAME SIGN)
043218,000269:
043219,000270: # NO JET FIRE YET, TEST FOR MAX OGARATE
043220,000271:
043221,000272: 16,3346 51670 INDEX I
043222,000273: 16,3347 01533 0 OGARATE # CA OR CS...BOTH MUST BE NEG. HERE
043223,000274: 16,3350 55671 TS IOGARATE # I.E. I OGARATE
043224,000275: 16,3351 63711 AD MAXLIM # SCALED AT 2(-4) REV/SEC
043225,000276: 16,3352 00006 EXTEND
043226,000277: 16,3353 63475 REG3TST BZMF RATELIM # IF REGION 3 (RATES TOO HIGH, FIRE JETS)
043227,000278:
043228,000279: # COMPUTATION OF I((-SLOPE)OGA + OGARATE) - INTERCEPT..NOTE THAT STR. LINE
043229,000280: # SWITCH SLOPE IS (SLOPE) DEG/SEC/DEG, A NEG QUANTITY
043230,000281:
043231,000282: 16,3354 31533 CA OGARATE
043232,000283: 16,3355 00006 EXTEND
043233,000284: 16,3356 75002 MP BIT14
043234,000285: 16,3357 55573 TS TEMREG
043235,000286: 16,3360 31664 CA OGA
043236,000287: 16,3361 00006 EXTEND
043237,000288: 16,3362 73704 MP -SLOPE
043238,000289: 16,3363 20001 DDOUBL
043239,000290: 16,3364 20001 DDOUBL
043240,000291: 16,3365 20001 DDOUBL # (OGA ERROR MUST BE LESS THAN +-225 DEG)
043241,000292: 16,3366 61573 AD TEMREG
043242,000293:
043243,000294: 16,3367 51670 INDEX I
043244,000295: 16,3370 00000 0 A # I((-SLOPE)OGA+OGARATE) AT 2(-3)REV/SEC
043245,000296: 16,3371 40000 COM
Page 991 |
043247,000298: 16,3372 63706 AD INTERCEP # SCALED AT 2(-3) REV.
043248,000299: 16,3373 40000 COM
043249,000300: 16,3374 00006 EXTEND
043250,000301: 16,3375 63606 REG2TST BZMF NOROLL # IF REGION 2 (COAST SIDE OF STRT LINE)
043251,000302:
043252,000303: # CHECK TO SEE IF OGARATE IS ABOVE MINLIM BOUNDARY
043253,000304:
043254,000305: 16,3376 31671 CA IOGARATE # ALWAYS NEGATIVE
043255,000306: 16,3377 63707 AD MINLIM # SCALED AT 2(-4) REV/SEC
043256,000307: 16,3400 00006 EXTEND
043257,000308: 16,3401 63606 REG4TST BZMF NOROLL # IF REGION 4 (COAST SIDE OF MINLIM)
043258,000309:
043259,000310: # ALL AREAS CHECKED EXCEPT LAST AREA...NO FIRE IN THIS SMALL SEGMENT
043260,000311:
043261,000312: 16,3402 51670 INDEX I
043262,000313: 16,3403 01664 0 OGA
043263,000314: 16,3404 40000 COM
043264,000315: 16,3405 63703 AD DB
043265,000316: 16,3406 40000 COM
043266,000317: 16,3407 00006 EXTEND
043267,000318: 16,3410 63606 REG5TST BZMF NOROLL # IF REGION 5 (COAST SIDE OF DB)
043268,000319:
043269,000320: # JETS MUST FIRE NOW. OGARATE IS NEG. (OR VISA VERSA). USE DIRECT STR. LINE.
043270,000321: # DELOGA AND DELOGART ARE USED AS DUMMY VARIABLES IN THE SOLUTION OF A
043271,000322: # STRAIGHT LINE APPROXIMATION TO A QUADRATIC SOLUTION OF THE INTERSECTION
043272,000323: # OF THE CONTROL PARABOLA AND THE STRAIGHT-LINE SWITCH LINE. THE STRAIGHT
043273,000324: # LINE IS THE TANGENT TO THE CONTROL PARABOLA AT THE OPERATING POINT. (FOR
043274,000325: # OPERATING POINTS IN REGIONS 6 OR 6')
043275,000326:
043276,000327: 16,3411 31664 REGION6 CAE OGA # USE ACTUAL OPERATING POINT FOR TANGENT
043277,000328: 16,3412 55667 TS DELOGA # ACTUAL STATE
043278,000329: 16,3413 31533 CA OGARATE
043279,000330: 16,3414 55665 TS DELOGART # ACTUAL STATE, I.E. DEL OGARATE
043280,000331: 16,3415 13425 TCF ONROLL
043281,000332:
043282,000333: # JETS ALSO FIRE FROM HERE EXCEPT OGARATE IS POS (VISA VERSA), USE INDIRECT
043283,000334: # STRAIGHT LINE ESTABLISHED BY TANGENT TO A CONTROL PARABOLA AT ((DELOGA
043284,000335: # + DB SGN(DELOGA) ), -LMCRATE SGN(DELOGA) ) (THIS IS THE DUMMY
043285,000336: # OPERATING POINT FOR OPERATING POINTS IN REGIONS 1 AND 1')
043286,000337:
043287,000338: 16,3416 51670 ROLLON INDEX I
043288,000339: 16,3417 03703 0 DB
043289,000340: 16,3420 27667 ADS DELOGA # DELOGA WAS DIST. FROM SWITCH PARABOLA
043290,000341:
043291,000342: 16,3421 43705 CS LMCRATE # LIMIT CYCLE RATE AT 2(-4) REV/SEC
043292,000343: 16,3422 51670 INDEX I
043293,000344: 16,3423 00000 0 A
043294,000345: 16,3424 55665 TS DELOGART # EVALUATE STATE FOR INDIRECT LINE.
043295,000346:
Page 992 |
043297,000348: # SOLVE STRAIGHT LINES SIMULTANEOUSLY TO OBTAIN DESIRED OGARATE.
043298,000349:
043299,000350: 16,3425 00006 ONROLL EXTEND # DELOGART IN ACC. ON ARRIVAL
043300,000351: 16,3426 71640 MP 1/CONACC
043301,000352: 16,3427 60000 DOUBLE
043302,000353: 16,3430 00006 EXTEND
043303,000354: 16,3431 73704 MP -SLOPE
043304,000355: 16,3432 55573 TS TEMREG # 2(-SLOPE)RATE /CONACC
043305,000356: 16,3433 00006 EXTEND
043306,000357: 16,3434 71665 MP DELOGART
043307,000358: 16,3435 55665 TS DELOGART # 2(-SLOPE)(RATESQ)/CONACC
043308,000359: 16,3436 45005 CS BIT11
043309,000360: 16,3437 51670 INDEX I
043310,000361: 16,3440 00000 0 A
043311,000362: 16,3441 27573 RATEDEN ADS TEMREG # DENOMINATOR COMPLETED
043312,000363:
043313,000364: 16,3442 51670 INDEX I
043314,000365: 16,3443 01667 0 DELOGA
043315,000366: 16,3444 40000 COM
043316,000367: 16,3445 63703 AD DB
043317,000368: 16,3446 40000 COM
043318,000369: 16,3447 00006 EXTEND
043319,000370: 16,3450 73704 MP -SLOPE
043320,000371: 16,3451 27665 ADS DELOGART
043321,000372: 16,3452 33705 CA LMCRATE
043322,000373: 16,3453 00006 EXTEND
043323,000374: 16,3454 75005 MP BIT11
043324,000375: 16,3455 61665 RATENUM AD DELOGART # NUMERATOR COMPLETED
043325,000376:
043326,000377: 16,3456 56001 XCH L # PLACE NUMERATOR IN L FOR OVERFL. CHECK
043327,000378: 16,3457 35021 CA ZERO
043328,000379: 16,3460 00006 EXTEND
043329,000380: 16,3461 11573 DV TEMREG # OVERFLOW, IF ANYTHING, NOW APPEARS IN A
043330,000381: 16,3462 00006 EXTEND
043331,000382: 16,3463 13471 BZF DVOK # NO OVERFLOW....(0,L)/TEMREG = 0,L
043332,000383:
043333,000384: 16,3464 10000 MINLIMAP CCS A
043334,000385: 16,3465 34777 CAF POSMAX # POSITIVE OVERFLOW
043335,000386: 16,3466 13500 TCF ROLLSET
043336,000387: 16,3467 44777 CS POSMAX # NEGATIVE OVERFLOW
043337,000388: 16,3470 13500 TCF ROLLSET
043338,000389:
043339,000390: 16,3471 22000 DVOK LXCH A # PUT NUMERATOR BACK INTO A, 0 IN L
043340,000391: 16,3472 00006 EXTEND
043341,000392: 16,3473 11573 DV TEMREG # RESULT OF DIVISION IS DESIRED OGARATE
043342,000393: 16,3474 13500 TCF ROLLSET # (SCALED AT B-4 REV/SEC)
043343,000394:
043344,000395: 16,3475 43711 RATELIM CS MAXLIM
043345,000396: 16,3476 51670 INDEX I
Page 993 |
043347,000398: 16,3477 00000 0 A # IF I = CA, DESIRED RATE IS -MAXLIM
043348,000399:
043349,000400: # COMPUTE JET FIRE TIME, BASED ON DESIRED RATE MINUS PRESENT RATE
043350,000401:
043351,000402: 16,3500 55573 ROLLSET TS TEMREG # STORE DESIRED OGARATE (SCALED B-4)
043352,000403: 16,3501 00006 EXTEND
043353,000404: 16,3502 61533 SU OGARATE # RATE DIFF. SCALED AT 2(-4) REV/SEC
043354,000405: 16,3503 55573 TS TEMREG # OVERFLOW PROTECT
043355,000406: 16,3504 13507 TCF +3 # " "
043356,000407: 16,3505 50000 INDEX A # " "
043357,000408: 16,3506 45000 CS LIMITS # " "
043358,000409: 16,3507 00006 EXTEND
043359,000410: 16,3510 77665 MP T6SCALE # T6SCALE = 8/10.24
043360,000411: 16,3511 00006 EXTEND
043361,000412: 16,3512 71640 MP 1/CONACC # SCALED AT B+9 SECSQ/REV (MAX < .60)
043362,000413: 16,3513 20001 DDOUBL
043363,000414: 16,3514 20001 DDOUBL
043364,000415: 16,3515 55573 TS TEMREG # OVERFLOW PROTECT
043365,000416: 16,3516 13521 TCF +3 # " "
043366,000417: 16,3517 50000 INDEX A # " "
043367,000418: 16,3520 45000 CS LIMITS # " "
043368,000419: 16,3521 55573 TS TEMREG # JET FIRE TIME AT 625 MICROSEC/BIT
043369,000420: 16,3522 00006 EXTEND # POS MEANS POSITIVE ROLL TORQUE.
043370,000421: 16,3523 13606 BZF NOROLL
043371,000422:
043372,000423: # JET FIRE TIME IS NZ, TEST FOR JETS NOW ON.
043373,000424:
043374,000425: 16,3524 31573 CAE TEMREG # DESIRED CHANGE IN OGARATE
043375,000426: 16,3525 00006 EXTEND
043376,000427: 16,3526 71571 MP ROLLFIRE # (SGN OF TORQUE..ZERO IF JETS NOW OFF)
043377,000428: 16,3527 10000 CCS A
043378,000429: 16,3530 13534 TCF MOREROLL # CONTINUE FIRING WITH PRESENT POLARITY
043379,000430: 16,3531 13537 TCF NEWROLL # START NEW FIRING NOW, PLUS
043380,000431: 16,3532 13606 TCF NOROLL # TERMINATE OLD FIRING, NEW SIGN REQUESTED
043381,000432: 16,3533 13537 TCF NEWROLL # START NEW FIRING NOW, MINUS
043382,000433:
043383,000434: # CONTINUE PRESENT FIRING
043384,000435:
043385,000436: 16,3534 35021 MOREROLL CAF ZERO
043386,000437: 16,3535 55670 TS I # USE TEMP. AS MOREROLL SWITCH
043387,000438: 16,3536 13550 TCF MAXTFIRE
043388,000439:
043389,000440: # START NEW FIRING, BUT CHECK IF GREATER THAN MIN FIRE TIME.
043390,000441:
043391,000442: 16,3537 11573 NEWROLL CCS TEMREG # CALL THIS T6FIRE
043392,000443: 16,3540 65017 AD ONE
043393,000444: 16,3541 13543 TCF +2
043394,000445: 16,3542 65017 AD ONE
043395,000446: 16,3543 40000 COM # -MAG(T6FIRE)
043396,000447: 16,3544 63712 AD TMINFIRE # TMINFIRE-MAG(T6FIRE)
Page 994 |
043398,000449: 16,3545 40000 COM
043399,000450: 16,3546 00006 EXTEND
043400,000451: 16,3547 63606 MINTST BZMF NOROLL # IF NOT GREATER THAN TMINFIRE (NEW FIRE)
043401,000452:
043402,000453: # PROCEED WITH NEW FIRING, BUT NOT LONGER THAN TMAXFIRE.
043403,000454:
043404,000455: 16,3550 31573 MAXTFIRE CA TEMREG
043405,000456: 16,3551 00006 EXTEND
043406,000457: 16,3552 75015 MP 1/TMXFIR # I.E. 1/TMAXFIRE
043407,000458: 16,3553 00006 EXTEND
043408,000459: 16,3554 13562 MAXTST BZF NOMXFIRE # IF LESS THAN TMAXFIRE
043409,000460:
043410,000461: 16,3555 10000 CCS A
043411,000462: 16,3556 33713 CAF TMAXFIRE # USE MAXIMUM
043412,000463: 16,3557 13561 TCF +2
043413,000464: 16,3560 43713 CS TMAXFIRE # USE MAXIMUM
043414,000465: 16,3561 55573 TS TEMREG
043415,000466:
043416,000467: # SET UP SIGN OF REQUIRED TORQUE.
043417,000468:
043418,000469: 16,3562 11573 NOMXFIRE CCS TEMREG # FOR TORQUE SIGN
043419,000470: 16,3563 34777 CA POSMAX # POSITIVE TORQUE REQUIRED
043420,000471: 16,3564 13566 TCF +2
043421,000472: 16,3565 35001 CA NEGMAX # NEGATIVE TORQUE REQUIRED
043422,000473: 16,3566 55571 TS ROLLFIRE # SET ROLLFIRE FOR + OR - TORQUE
043423,000474:
043424,000475: 16,3567 40000 COM # COMPLEMENT... POS. FOR NEG. TORQUE
043425,000476: 16,3570 00006 EXTEND
043426,000477: 16,3571 63574 BZMF +3 # POSITIVE TORQUE REQUIRED
043427,000478: 16,3572 41573 CS TEMREG
043428,000479: 16,3573 55573 TS TEMREG
043429,000480:
043430,000481: 16,3574 31670 FIRELOOK CA I # IS IT MOREROLL
043431,000482: 16,3575 00006 EXTEND
043432,000483: 16,3576 13600 BZF FIREPLUG # YES
043433,000484: 16,3577 13611 TCF JETROLL # MAG(T6FIRE) NOW IN TEMREG
043434,000485:
043435,000486: 16,3600 30031 FIREPLUG CAE TIME6 # CHECK FOR EXTENDED FIRING
043436,000487: 16,3601 00006 EXTEND
043437,000488: 16,3602 61573 SU TEMREG
043438,000489: 16,3603 00006 EXTEND
043439,000490: 16,3604 65324 EXTENTST BZMF TASKOVER # IF EXTENSION WANTED, DONT, EXIT ROLL DAP
043440,000491: 16,3605 13611 TCF JETROLL
043441,000492:
043442,000493: 16,3606 45021 NOROLL CS ZERO # COAST....(NEG ZERO FOR TIME6)
043443,000494: 16,3607 55571 TS ROLLFIRE # NOTE, JETS CAN FIRE NEXT PASS
043444,000495: 16,3610 55573 TS TEMREG
043445,000496:
043446,000497: 16,3611 00006 JETROLL EXTEND
043447,000498: 16,3612 33702 DCA NOROL1T6
Page 995 |
043449,000500: 16,3613 53311 DXCH T6LOC
043450,000501: 16,3614 31573 CA TEMREG # ENTER JET FIRING TIME
043451,000502: 16,3615 54031 TS TIME6
043452,000503:
043453,000504: 16,3616 31670 CA I # I=0 IF MOREROLL, KEEP SAME JETS ON
043454,000505: 16,3617 00006 EXTEND
043455,000506: 16,3620 15324 SAMEJETS BZF TASKOVER # IF JETS ON KEEP SAME JETS. EXIT ROLL DAP
043456,000507:
043457,000508: 16,3621 11571 CCS ROLLFIRE
043458,000509: 16,3622 13626 TCF +TORQUE
043459,000510: 16,3623 13667 TCF T6ENABL
043460,000511: 16,3624 13647 TCF -TORQUE
043461,000512: 16,3625 13667 TCF T6ENABL
043462,000513:
043463,000514: # PROCEED WITH PLUS TORQUE.
043464,000515:
043465,000516: 16,3626 31572 +TORQUE CA ROLLWORD # WHAT WAS THE LAST +TORQUE COMBINATION
043466,000517: 16,3627 75017 MASK BIT1 # WAS IT NO.9-11
043467,000518: 16,3630 00006 EXTEND
043468,000519: 16,3631 13641 BZF NO.9-11 # NOT 9-11, SO USE IT THIS TIME
043469,000520:
043470,000521: 16,3632 45017 NO.13-15 CS BIT1
043471,000522: 16,3633 71572 MASK ROLLWORD
043472,000523: 16,3634 55572 TS ROLLWORD # CHANGE BIT 1 TO ZERO
043473,000524: 16,3635 35037 CAF +ROLL2
043474,000525: 16,3636 00006 EXTEND
043475,000526: 16,3637 01006 WRITE CHAN6
043476,000527: 16,3640 13667 TCF T6ENABL
043477,000528:
043478,000529: 16,3641 35017 NO.9-11 CAF BIT1 # 1ST + JETS TO FIRE (MRCLEAN OS ROLLWORD)
043479,000530: 16,3642 27572 ADS ROLLWORD # CHANGE BIT 1 TO ONE
043480,000531: 16,3643 35022 CAF +ROLL1
043481,000532: 16,3644 00006 EXTEND
043482,000533: 16,3645 01006 WRITE CHAN6
043483,000534: 16,3646 13667 TCF T6ENABL
043484,000535:
043485,000536: 16,3647 31572 -TORQUE CA ROLLWORD # WHAT WAS LAST -TORQUE COMBINATION
043486,000537: 16,3650 75016 MASK BIT2 # WAS IT NO.12-10
043487,000538: 16,3651 00006 EXTEND
043488,000539: 16,3652 13662 BZF NO.12-10 # NOT 12-10, SO USE IT THIS TIME
043489,000540:
043490,000541: 16,3653 45016 NO.16-14 CS BIT2
043491,000542: 16,3654 71572 MASK ROLLWORD
043492,000543: 16,3655 55572 TS ROLLWORD # CHANGE BIT 2 TO ZERO
043493,000544: 16,3656 33714 CAF -ROLL2
043494,000545: 16,3657 00006 EXTEND
043495,000546: 16,3660 01006 WRITE CHAN6
043496,000547: 16,3661 13667 TCF T6ENABL
043497,000548:
043498,000549: 16,3662 35016 NO.12-10 CAF BIT2 # 1ST -JETS TO FIRE (MRCLEAN OS ROLLWORD)
Page 996 |
043500,000551: 16,3663 27572 ADS ROLLWORD # CHANGE BIT 2 TO ONE
043501,000552: 16,3664 34377 CAF -ROLL1
043502,000553: 16,3665 00006 EXTEND
043503,000554: 16,3666 01006 WRITE CHAN6
043504,000555:
043505,000556: 16,3667 35001 T6ENABL CAF BIT15
043506,000557: 16,3670 00006 EXTEND
043507,000558: 16,3671 05013 WOR CHAN13
043508,000559: 16,3672 15324 RDAPEND TCF TASKOVER # EXIT ROLL DAP
043509,000560:
Page 997 |
043511,000562: # THIS T6 TASK SHUTS OFF ALL ROLL JETS
043512,000563:
043513,000564: 16,3673 22016 NOROLL1 LXCH BANKRUPT # SHUT OFF ALL (ROLL) JETS, (A T6 TASK
043514,000565: 16,3674 35021 CAF ZERO # CALLED BY ..JETROLL..)
043515,000566: 16,3675 55571 TS ROLLFIRE # ZERO INDICATES JETS NOW OFF
043516,000567: 16,3676 00006 EXTEND
043517,000568: 16,3677 01006 KILLJETS WRITE CHAN6
043518,000569: 16,3700 15335 TCF NOQRSM
043519,000570:
Page 998 |
043521,000572: # CONSTANTS FOR ROLL AUTOPILOT....
043522,000573:
043523,000574: 16,3701 E6,1702 EBANK= BZERO
043524,000575: 16,3701 03673 34066 NOROL1T6 2CADR NOROLL1
043525,000576:
043526,000577: 16,3703 00344 DB DEC .01388889 # DEAD BAND (5 DEG), SC.AT B+0 REV
043527,000578:
043528,000579: 16,3704 06315 -SLOPE DEC 0.2 # -SWITCHLINE SLOPE(0.2 PER SEC) SC.AT B+0
043529,000580: # PER SEC
043530,000581: 16,3705 00111 LMCRATE DEC .00027778 B+4 # LIMIT CYCLE RATE (0.1 DEG/SEC) SC.AT
043531,000582: # B-4 REV/SEC
043532,000583: 16,3706 00510 INTERCEP DEC .0025 B+3 # DB(-SLOPE) - LMCRATE, SC.AT B-3 REV/SC
043533,000584:
043534,000585: 16,3707 01330 MINLIM DEC .00277778 B+4 # RATELIM,MIN (1DEG/SEC), SC.AT B-4 REV/SC
043535,000586:
043536,000587: 16,3710 00027 1/MINLIM DEC 360 B-18 # RECIPROCAL THEREOF, SHIFTED 14 RIGHT
043537,000588:
043538,000589: 16,3711 07071 MAXLIM DEC .01388889 B+4 # RATELIM,MAX (5DEG/SEC), SC.AT B-4 REV/SC
043539,000590:
043540,000591: 16,3712 00030 TMINFIRE DEC 1.5 B+4 # 15 MS (14MIN), SC.AT 16 BITS/CS
043541,000592:
043542,000593: 16,3713 07640 TMAXFIRE DEC 250 B+4 # 2.5 SEC, SC.AT 16 BITS/CS
043543,000594:
043544,000595: 16,3714 5015 1/TMXFIR = BIT3 # RECIPROCAL THEREOF, SHIFTED 14 RIGHT,
043545,000596: # ROUNDS TO OCT00004, SO ALLOWS 2.56
043546,000597: # SEC FIRINGS BEFORE APPLYING LIMIT
043547,000598: 16,3714 7665 T6SCALE = PRIO31 # (B+3) (16 BITS/CS) (100CS/SEC)
043548,000599:
043549,000600: 16,3714 5022 +ROLL1 = FIVE # ONBITS FOR JETS 9 AND 11
043550,000601: 16,3714 5037 +ROLL2 = OCT120 # ONBITS FOR JETS 13 AND 15
043551,000602: 16,3714 4377 -ROLL1 = TEN # ONBITS FOR JETS 12 NAD 10
043552,000603: 16,3714 00240 -ROLL2 OCT 240 # ONBITS FOR JETS 16 AND 14
043553,000604:
End of include-file TVCROLLDAP.agc. Parent file is MAIN.agc