Source Code
These source-code files are part of a reconstructed copy of Comanche 72/3 (AKA Manche72 revision 3),
the final, flown mission release of the Apollo Guidance Computer (AGC) Command Module (CM) software
for Apollo 13.
The starting point was the source code of Comanche 72 (itself previously reconstructed). Comanche 72 source code was then modified by incorporating changes known from contemporary documentation to have been made between revisions 72 and 72/3. The resulting code assembles to have identical memory-bank checksums as those specified in NASA drawing 2021153G; this gives reasonably high confidence that the changes that have been made are correct. In places where ambiguity exists, this ambiguity is discussed in "## Reconstruction:" comments. Since no contemporary listings of Comanche 72/3 are available as source material, all comments and labels are approximate. They have been taken from other AGC programs where possible, or, in some places, written from scratch to match what we believe would have been in the original listing. |
042308,000002: ## Copyright: Public domain.
042309,000003: ## Filename: TVCROLLDAP.agc
042310,000004: ## Purpose: A section of Manche72 revision 3.
042311,000005: ## It is part of the reconstructed source code for the final, flown
042312,000006: ## release of the software for the Command Module's (CM) Apollo
042313,000007: ## Guidance Computer (AGC) for Apollo 13. No original listings
042314,000008: ## of this program are available; instead, this file was recreated
042315,000009: ## from a reconstructed copy of Comanche 072. It has been adapted
042316,000010: ## such that the resulting bugger words exactly match those
042317,000011: ## specified for Manche72 revision 3 in NASA drawing 2021153G,
042318,000012: ## which gives relatively high confidence that the reconstruction
042319,000013: ## is correct.
042320,000014: ## Assembler: yaYUL
042321,000015: ## Contact: Ron Burkey <info@sandroid.org>.
042322,000016: ## Website: www.ibiblio.org/apollo/index.html
042323,000017: ## Mod history: 2024-05-19 MAS Created from Comanche 072.
042324,000018:
042325,000019: # PROGRAM NAME...TVC ROLL AUTOPILOT
042326,000020: # LOG SECTION...TVCROLLDAP SUBROUTINE...DAPCSM
042327,000021: # MODIFIED BY SCHLUNDT 21 OCTOBER 1968
042328,000022:
042329,000023: # FUNCTIONAL DESCRIPTION....
042330,000024:
042331,000025: # *AN ADAPTATION OF THE LEM P-AXIS CONTROLLER
042332,000026: # *MAINTAIN OGA WITHIN 5 DEG DEADBND OF OGAD, WHERE OGAD = OGA AS SEEN
042333,000027: # BY IGNITION (P40)
042334,000028: # *MAINTAIN OGA RATE LESS THAN 0.1 DEG/SEC LIMIT CYCLE RATE
042335,000029: # *SWITCHING LOGIC IN PHASE PLANE.... SEE GSOP CHAPTER 3
042336,000030: # *USES T6 CLOCK TO TIME JET FIRINGS
042337,000031: # *MAXIMUM JET FIRING TIME = 2.56 SECONDS, LIMITED TO 2.5 IF GREATER
042338,000032: # *MINIMUM JET FIRING TIME = 15 MS
042339,000033: # *JET PAIRS FIRE ALTERNATELY
042340,000034: # *AT LEAST 1/2 SECOND DELAY BEFORE A NEW JET PAIR IS FIRED
042341,000035: # *JET FIRINGS MAY NOT BE EXTENDED, ONLY SHORTENED, WHEN RE-EVALUATION
042342,000036: # OF A JET FIRING TIME IS MADE ON A LATER PASS
042343,000037:
042344,000038: # CALLING SEQUENCE....
042345,000039:
042346,000040: # *ROLLDAP CALL VIA WAITLIST, IN PARTICULAR BY TVCEXEC (EVERY 1/2 SEC)
042347,000041: # WITH A 3CS DELAY TO ALLOW FREE TIME FOR OTHER RUPTS (DWNRPT, ETC.)
042348,000042:
042349,000043: # NORMAL EXIT MODES.... ENDOFJOB
042350,000044:
042351,000045: # ALARM OR ABORT EXIT MODES.... NONE
042352,000046:
042353,000047: # SUBROUTINES CALLED.....NONE
042354,000048:
042355,000049: # OTHER INTERFACES....
042356,000050:
042357,000051: # *TVCEXEC SETS UP ROLLDAP TASK EVERY 1/2 SECOND AND UPDATES 1/CONACC
042358,000052: # EVERY 10 SECONDS (VIA MASSPROP AND S40.15)
042359,000053: # *RESTARTS SUSPEND ROLL DAP COMPUTATIONS UNTIL THE NEXT 1/2 SEC
042360,000054: # SAMPLE PERIOD. (THE PART OF TVCEXECUTIVE THAT CALLS ROLL DAP IS
042361,000055: # NOT RESTARTED.) THE OGAD FROM IGNITION IS MAINTAINED.
042362,000056:
042363,000057: # ERASABLE INITIALIZATION REQUIRED....
042364,000058:
042365,000059: # *1/CONACC (S40.15)
042366,000060: # *OGAD (CDUX AT IGNITION)
042367,000061: # *OGANOW (CDUX AT TVCINIT4 AND TVCEXECUTIVE)
042368,000062: # *OGAPAST (OGANOW AT TVCEXECUTIVE)
042369,000063: # *ROLLFIRE = TEMREG = ROLLWORD = 0 (MRCLEAN LOOP IN TVCDAPON)
042370,000064:
042371,000065: # OUTPUT....
042372,000066:
042373,000067: # *ROLL JET PAIR FIRINGS
042374,000068:
042375,000069: # DEBRIS.... MISCELLANEOUS, SHAREABLE WITH RCS/ENTRY, IN EBANK6 ONLY
042376,000070:
042377,000071: # SOME NOTES ON THE ROLL AUTOPILOT, AND IN PARTICULAR, ON ITS SWITCHING
042378,000072: # LOGIC. SEE SECTION THREE OF THE GSOP (SUNDISK/COLOSSUS) FOR DETAILS.
042379,000073:
042380,000074: # SWITCHING LOGIC IN THE PHASE PLANE....
042381,000075:
042382,000076: # OGARATE
042383,000077: # *
042384,000078: # *
042385,000079: # * * * * * * * * * * * *
042386,000080: # * (REGION 1, SEE TEXT BELOW)
042387,000081: # * *
042388,000082: # *
042389,000083: # * * * * * * * (COAST) * ...PARABOLA (SWITCHING = CONTROL)
042390,000084: # * * .
042391,000085: # * * *
042392,000086: # * * (FIRE NEG ROLL JETS)
042393,000087: # * * *
042394,000088: # (-DB,+LMCRATE)....* *
042395,000089: # * * *
042396,000090: # * * OGAERROR
042397,000091: # ************************************************************************
042398,000092: # * * (-AK, OGAERR)
042399,000093: # * * * (REGION 6-PRIME)
042400,000094: # * * (SEE TEXT BELOW)
042401,000095: # * * *
042402,000096: # * * ...STRAIGHT LINE
042403,000097: # (FIRE POS ROLL JETS) * * * .
042404,000098: # * (COAST) *
042405,000099: # * * * * * * * * * * *
042406,000100: # * -MINLIM
042407,000101: # * *
042408,000102: # *
042409,000103: # * * * * * * * * * * * * * * * *
042410,000104: # * -MAXLIM
042411,000105: # *
042412,000106: # *
042413,000107:
042414,000108: # SWITCHING PARABOLAS ARE CONTROL PARABOLAS, THUS REQUIRING KNOWLEDGE OF
042415,000109: # CONTROL ACCELERATION CONACC, OR ITS RECIPROCAL, 1/CONACC, THE TVC
042416,000110: # ROLL DAP GAIN (SEE TVCEXECUTIVE VARIABLE GAIN PACKAGE). JET
042417,000111: # FIRING TIME IS SIMPLY THAT REQUIRED TO ACHIEVE THE DESIRED OGARATE,
042418,000112: # SUBJECT TO THE LIMITATIONS DISCUSSED UNDER FUNCTIONAL DESCRIPTION,
042419,000113: # ABOVE.
042420,000114:
042421,000115: # THE THREE CONTROL REGIONS (+, -, AND ZERO TORQUE) ARE COMPRIZED OF
042422,000116: # TWELVE SUBSET REGIONS ( 1...6, AND THE CORRESPONDING 1-PRIME...
042423,000117: # 6-PRIME ) SEE SECTION 3 OF THE GSOP (SUNDISK OR COLOSSUS)
042424,000118:
042425,000119: # GIVEN THE OPERATING POINT NOT IN THE COAST REGION, THE DESIRED OGARATE
042426,000120: # IS AT THE POINT OF PENETRATION OF THE COAST REGION BY THE CONTROL
042427,000121: # PARABOLA WHICH PASSES THROUGH THE OPERATING POINT. FOR REGION 3
042428,000122: # DESIRED OGARATE IS SIMPLY +-MAXLIM. FOR REGIONS 1 OR 6 THE SOLUTION
042429,000123: # TO A QUADRATIC IS REQUIRED (THE PENETRATION IS ALONG THE STRAIGHT
042430,000124: # LINE OR MINLIM BOUNDRY SWITCH LINES). AN APPROXIMATION IS MADE
042431,000125: # INSTEAD. TAKE AN OPERATING POINT IN REGION 6'. PASS A TANGENT TO
042432,000126: # THE CONTROL PARABOLA THROUGH THE OPERATING POINT, AND FIND ITS
042433,000127: # INTERSECTION WITH THE STRAIGHT LINE SECTION OF THE SWITCH CURVE...
042434,000128: # THE INTERSECTION DEFINES DESIRED OGARATE. IF THE OPERATING POINT IS
042435,000129: # CLOSE TO THE SWITCH LINE, THE APPROXIMATION IS QUITE GOOD (INDEED
042436,000130: # THE APPROXIMATE AND QUADRATIC SOLUTIONS CONVERGE IN THE LIMIT AS
042437,000131: # THE SWITCH LINE IS APPROACHED). IF THE OPERATING POINT IS NOT CLOSE
042438,000132: # TO THE SWITCH LINE, THE APPROXIMATE SOLUTION GIVES VALID TREND
042439,000133: # INFORMATION (DIRECTION OF DESIRED OGARATE) AT LEAST. THE
042440,000134: # RE-EVALUATION OF DESIRED OGARATE IN SUBSEQUENT ROLL DAP PASSES (1/2
042441,000135: # SECOND INTERVALS) WILL BENEFIT FROM THE CONVERGENT NATURE OF THE
042442,000136: # APPROXIMATION.
042443,000137:
042444,000138: # FOR LARGE OGAERROR THE TANGENT INTERSECTS +-MINLIM SWITCH BOUNDRY BEFORE
042445,000139: # INTERSECTING THE STRAIGHT LINE SWITCH. HOWEVER THE MINLIM IS
042446,000140: # IGNORED IN COMPUTING THE FIRING TIME, SO THAT THE EXTENSION (INTO
042447,000141: # THE COAST REGION) OF THE STRAIGHT LINE SWITCH IS WHAT IS FIRED TO.
042448,000142: # IF THE ROLL DAP FINDS ITSELF IN THE COAST REGION BEFORE REACHING
042449,000143: # THE DESIRED INTERSECTION (IE, IN THE REGION BETWEEN THE MINLIM
042450,000144: # AND THE STRAIGHT LINE SWITCH) IT WILL EXIBIT NORMAL COAST-REGION
042451,000145: # BEHAVIOR AND TURN OFF THE JETS. THE PURPOSE OF THIS FIRING POLICY
042452,000146: # IS TO MAINTAIN STATIC ROLL STABILITY IN THE EVENT OF A JET
042453,000147: # FAILED-ON.
042454,000148:
042455,000149: # WHEN THE OPERATING POINT IS IN REGION 1 THE SAME APPROXIMATION IS
042456,000150: # MADE, BUT AT AN ARTIFICIALLY-CREATED OR DUMMY OPERATING POINT,
042457,000151: # DEFINED BY.. OGAERROR = INTERSECTION OF CONTROL PARABOLA AND
042458,000152: # OGAERROR AXIS, OGARATE = +-LMCRATE WHERE SIGN IS OPPOSITE THAT OF
042459,000153: # REAL OPERATING POINT RATE. WHEN THE OPERATING POINT HAS PASSED
042460,000154: # FROM REGION 1 TO REGION 6', THE DUMMY POINT IS NO LONGER REQUIRED,
042461,000155: # AND THE SOLUTION REVERTS TO THAT OF A REGULAR REGION 6' POINT.
042462,000156:
042463,000157: # EQUATION FOR SWITCHING PARABOLA (SEE FIGURE ABOVE)....
042464,000158: # 2
042465,000159: # SOGAERROR = (DB - (SOGARATE) (1/CONACC)/2) SGN(SOGARATE)
042466,000160:
042467,000161: # EQUATION FOR SWITCHING STRAIGHT LINE SEGMENT....
042468,000162:
042469,000163: # SOGARATE = -(-SLOPE)(SOGAERROR) - SGN(SOGARATE) INTERCEP
042470,000164:
042471,000165: # WHERE INTERCEP = DB(-SLOPE) - LMCRATE
042472,000166:
042473,000167: # EQUATION FOR INTERSECTION, CONTROL PARABOLA AND STRAIGHT SWITCH LINE....
042474,000168:
042475,000169: # DOGADOT = NUM/DEN, WHERE
042476,000170: # 2
042477,000171: # NUM = (-SLOPE)(OGARATE) (1/CONACC)
042478,000172: # +SGN(DELOGA)(-SLOPE)(OGAERROR - SGN(DELOGA)(DB))
042479,000173: # +LMCRATE
042480,000174:
042481,000175: # DEN = (-SLOPE)(LMCRATE)(1/CONACC) - SGN(DELOGA)
042482,000176: # 2
042483,000177: # DELOGA = OGAERROR - (DB - OGARATE (1/CONACC)/2)SGN(OGARATE)
042484,000178:
042485,000179: # FOR REGIONS 6 AND 6-PRIME USE ACTUAL OPERATING POINT (OGA, OGARATE)
042486,000180: # FOR OGAERROR AND OGARATE IN THE INTERSECTION EQUATIONS ABOVE.
042487,000181: # FOR REGIONS 1 AND 1-PRIME USE DUMMY OPERATING POINT FOR OGAERROR
042488,000182: # AND OGARATE, WHERE THE DUMMY POINT IS GIVEN BY....
042489,000183:
042490,000184: # OGAERROR = DELOGA + DB SGN(OGARATE)
042491,000185:
042492,000186: # OGARATE = -LMCRATE SGN(OGARATE)
042493,000187:
042494,000188: # NOTE, OGAERROR = OGA - OGAD USES DUMMY REGISTER OGA IN ROLL DAP CODING
042495,000189: # ALSO, AT POINT WHERE DOGARATE IS COMPUTED, REGISTER DELOGA IS USED
042496,000190: # AS A DUMMY REGISTER FOR THE OGAERROR IN THE NUM EQUATION ABOVE
042497,000191:
042498,000192: # ROLLDAP CODING....
042499,000193:
042500,000194: 16,2000 SETLOC DAPROLL
042501,000195: 16,2000 BANK
042502,000196: 16,3344 E6,1664 EBANK= OGANOW
042503,000197: 16,3344 COUNT* $$/ROLL
042504,000198: 16,3344 31664 ROLLDAP CAE OGANOW # OGA RATE ESTIMATOR...SIMPLE FIRST-ORDER
042505,000199: 16,3345 00006 EXTEND # DIFFERENCE (SAMPLE TIME = 1/2 SEC)
042506,000200: 16,3346 21665 MSU OGAPAST
042507,000201: 16,3347 00006 EXTEND
042508,000202: 16,3350 75027 MP BIT5
042509,000203: 16,3351 22000 LXCH A
042510,000204: 16,3352 55533 TS OGARATE # SC.AT B-4 REV/SEC
042511,000205:
042512,000206: # COMPUTATIONS WHICH FOLLOW USE OGA FOR OGAERR (SAME REGISTER)
042513,000207: # EXAMINE DURATION OF LAST JET FIRING IF JETS NOW ON.
042514,000208:
042515,000209: 16,3353 31571 DURATION CA ROLLFIRE # SAME SGN AS PRESENT TORQ,MAGN=POSMAX
042516,000210: 16,3354 00006 EXTEND
042517,000211: 16,3355 13357 BZF +2 # ROLL JETS ARE NOW OFF.
042518,000212: 16,3356 13365 TCF ROLLOGIC # ENTER LOGIC, JETS NOW ON.
042519,000213:
042520,000214: 16,3357 31573 CAE TEMREG # EXAMINE LAST FIRING INTERVAL
042521,000215: 16,3360 00006 EXTEND # IF POSITIVE, DONT FIRE
042522,000216: 16,3361 13365 BZF ROLLOGIC # ENTER LOGIC, JETS NOW OFF.
042523,000217:
042524,000218: 16,3362 35035 CAF ZERO # JETS HAVE NOT BEEN OFF FOR 1/2 SEC. WAIT
042525,000219: 16,3363 55573 TS TEMREG # RESET TEMREG
042526,000220: 16,3364 15340 WAIT1/2 TCF TASKOVER # EXIT ROLL DAP
042527,000221:
042528,000222: # COMPUTE DB-(1/2 CONACC) (OGARATE)SQ (1/2 IN THE SCALING)
042529,000223:
042530,000224: 16,3365 41533 ROLLOGIC CS OGARATE # SCALED AT 2(-4) REV/SEC
042531,000225: 16,3366 00006 EXTEND
042532,000226: 16,3367 71640 MP 1/CONACC # SCALED AT 2(+9) SEC SQ /REV
042533,000227: 16,3370 00006 EXTEND
042534,000228: 16,3371 71533 MP OGARATE
042535,000229: 16,3372 63760 AD DB # SCALED AT 2(+0) REV
042536,000230: 16,3373 55573 TS TEMREG # QUANTITY SCALED AT 2(+0) REV.
042537,000231:
042538,000232: # GET SIGN OF OGARATE
042539,000233:
042540,000234: 16,3374 31533 CA OGARATE
042541,000235: 16,3375 00006 EXTEND
042542,000236: 16,3376 63401 BZMF +3 # LET SGN(0) BE NEGATIVE
042543,000237: 16,3377 35033 CA BIT1
042544,000238: 16,3400 13402 TCF +2
042545,000239: 16,3401 45033 CS BIT1
042546,000240: 16,3402 55670 TS SGNRT # + OR - 2(-14)
042547,000241:
042548,000242: # CALCULATE DISTANCE FROM SWITCH PARABOLA (DELOGA)
042549,000243: 16,3403 00006 EXTEND
042550,000244: 16,3404 71573 MP TEMREG # SGN(OGARATE) TEMREG NOW IN L
042551,000245: 16,3405 40001 CS L
042552,000246: 16,3406 61666 AD OGA # SCALED AT 2(+0) REV
042553,000247: 16,3407 55671 DELOGAC TS DELOGA # SCALE B+0 REV, PLUS TO RIGHT OF C-PARAB
042554,000248:
042555,000249: # EXAMINE SGN(DELOGA) AND CREATE CA OR CS INSTR. DEPENDING UPON SIGN.
042556,000250:
042557,000251: 16,3410 00006 EXTEND
042558,000252: 16,3411 63414 BZMF +3
042559,000253: 16,3412 34371 CAF PRIO30 # = CA (30000)
042560,000254: 16,3413 13415 TCF +2
042561,000255: 16,3414 35015 CAF BIT15 # = CS (40000)
042562,000256: 16,3415 55672 TS I
042563,000257:
042564,000258: 16,3416 51672 INDEX I # TSET ON I SGN(OGARATE)
042565,000259: 16,3417 01670 0 SGNRT # CA OR CS
042566,000260: 16,3420 40000 COM
042567,000261: 16,3421 00006 EXTEND
042568,000262: 16,3422 63473 REG1TST BZMF ROLLON # IF REGION 1 (DELOGA OGARATE SAME SIGN)
042569,000263:
042570,000264: # NO JET FIRE YET, TEST FOR MAX OGARATE
042571,000265:
042572,000266: 16,3423 51672 INDEX I
042573,000267: 16,3424 01533 0 OGARATE # CA OR CS...BOTH MUST BE NEG. HERE
042574,000268: 16,3425 55673 TS IOGARATE # I.E. I OGARATE
042575,000269: 16,3426 63766 AD MAXLIM # SCALED AT 2(-4) REV/SEC
042576,000270: 16,3427 00006 EXTEND
042577,000271: 16,3430 63552 REG3TST BZMF RATELIM # IF REGION 3 (RATES TOO HIGH, FIRE JETS)
042578,000272:
042579,000273: # COMPUTATION OF I((-SLOPE)OGA + OGARATE) - INTERCEPT..NOTE THAT STR. LINE
042580,000274: # SWITCH SLOPE IS (SLOPE) DEG/SEC/DEG, A NEG QUANTITY
042581,000275:
042582,000276: 16,3431 31533 CA OGARATE
042583,000277: 16,3432 00006 EXTEND
042584,000278: 16,3433 75016 MP BIT14
042585,000279: 16,3434 55573 TS TEMREG
042586,000280: 16,3435 31666 CA OGA
042587,000281: 16,3436 00006 EXTEND
042588,000282: 16,3437 73761 MP -SLOPE
042589,000283: 16,3440 20001 DDOUBL
042590,000284: 16,3441 20001 DDOUBL
042591,000285: 16,3442 20001 DDOUBL # (OGA ERROR MUST BE LESS THAN +-225 DEG)
042592,000286: 16,3443 61573 AD TEMREG
042593,000287:
042594,000288: 16,3444 51672 INDEX I
042595,000289: 16,3445 00000 0 A # I((-SLOPE)OGA+OGARATE) AT 2(-3)REV/SEC
042596,000290: 16,3446 40000 COM
042597,000291: 16,3447 63763 AD INTERCEP # SCALED AT 2(-3) REV.
042598,000292: 16,3450 40000 COM
042599,000293: 16,3451 00006 EXTEND
042600,000294: 16,3452 63663 REG2TST BZMF NOROLL # IF REGION 2 (COAST SIDE OF STRT LINE)
042601,000295:
042602,000296: # CHECK TO SEE IF OGARATE IS ABOVE MINLIM BOUNDARY
042603,000297:
042604,000298: 16,3453 31673 CA IOGARATE # ALWAYS NEGATIVE
042605,000299: 16,3454 63764 AD MINLIM # SCALED AT 2(-4) REV/SEC
042606,000300: 16,3455 00006 EXTEND
042607,000301: 16,3456 63663 REG4TST BZMF NOROLL # IF REGION 4 (COAST SIDE OF MINLIM)
042608,000302:
042609,000303: # ALL AREAS CHECKED EXCEPT LAST AREA...NO FIRE IN THIS SMALL SEGMENT
042610,000304:
042611,000305: 16,3457 51672 INDEX I
042612,000306: 16,3460 01666 0 OGA
042613,000307: 16,3461 40000 COM
042614,000308: 16,3462 63760 AD DB
042615,000309: 16,3463 40000 COM
042616,000310: 16,3464 00006 EXTEND
042617,000311: 16,3465 63663 REG5TST BZMF NOROLL # IF REGION 5 (COAST SIDE OF DB)
042618,000312:
042619,000313: # JETS MUST FIRE NOW. OGARATE IS NEG. (OR VISA VERSA). USE DIRECT STR. LINE.
042620,000314: # DELOGA AND DELOGART ARE USED AS DUMMY VARIABLES IN THE SOLUTION OF A
042621,000315: # STRAIGHT LINE APPROXIMATION TO A QUADRATIC SOLUTION OF THE INTERSECTION
042622,000316: # OF THE CONTROL PARABOLA AND THE STRAIGHT-LINE SWITCH LINE. THE STRAIGHT
042623,000317: # LINE IS THE TANGENT TO THE CONTROL PARABOLA AT THE OPERATING POINT. (FOR
042624,000318: # OPERATING POINTS IN REGIONS 6 OR 6')
042625,000319:
042626,000320: 16,3466 31666 REGION6 CAE OGA # USE ACTUAL OPERATING POINT FOR TANGENT
042627,000321: 16,3467 55671 TS DELOGA # ACTUAL STATE
042628,000322: 16,3470 31533 CA OGARATE
042629,000323: 16,3471 55667 TS DELOGART # ACTUAL STATE, I.E. DEL OGARATE
042630,000324: 16,3472 13502 TCF ONROLL
042631,000325:
042632,000326: # JETS ALSO FIRE FROM HERE EXCEPT OGARATE IS POS (VISA VERSA), USE INDIRECT
042633,000327: # STRAIGHT LINE ESTABLISHED BY TANGENT TO A CONTROL PARABOLA AT ((DELOGA
042634,000328: # + DB SGN(DELOGA) ), -LMCRATE SGN(DELOGA) ) (THIS IS THE DUMMY
042635,000329: # OPERATING POINT FOR OPERATING POINTS IN REGIONS 1 AND 1')
042636,000330:
042637,000331: 16,3473 51672 ROLLON INDEX I
042638,000332: 16,3474 03760 0 DB
042639,000333: 16,3475 27671 ADS DELOGA # DELOGA WAS DIST. FROM SWITCH PARABOLA
042640,000334:
042641,000335: 16,3476 43762 CS LMCRATE # LIMIT CYCLE RATE AT 2(-4) REV/SEC
042642,000336: 16,3477 51672 INDEX I
042643,000337: 16,3500 00000 0 A
042644,000338: 16,3501 55667 TS DELOGART # EVALUATE STATE FOR INDIRECT LINE.
042645,000339:
042646,000340: # SOLVE STRAIGHT LINES SIMULTANEOUSLY TO OBTAIN DESIRED OGARATE.
042647,000341:
042648,000342: 16,3502 00006 ONROLL EXTEND # DELOGART IN ACC. ON ARRIVAL
042649,000343: 16,3503 71640 MP 1/CONACC
042650,000344: 16,3504 60000 DOUBLE
042651,000345: 16,3505 00006 EXTEND
042652,000346: 16,3506 73761 MP -SLOPE
042653,000347: 16,3507 55573 TS TEMREG # 2(-SLOPE)RATE /CONACC
042654,000348: 16,3510 00006 EXTEND
042655,000349: 16,3511 71667 MP DELOGART
042656,000350: 16,3512 55667 TS DELOGART # 2(-SLOPE)(RATESQ)/CONACC
042657,000351: 16,3513 45021 CS BIT11
042658,000352: 16,3514 51672 INDEX I
042659,000353: 16,3515 00000 0 A
042660,000354: 16,3516 27573 RATEDEN ADS TEMREG # DENOMINATOR COMPLETED
042661,000355:
042662,000356: 16,3517 51672 INDEX I
042663,000357: 16,3520 01671 0 DELOGA
042664,000358: 16,3521 40000 COM
042665,000359: 16,3522 63760 AD DB
042666,000360: 16,3523 40000 COM
042667,000361: 16,3524 00006 EXTEND
042668,000362: 16,3525 73761 MP -SLOPE
042669,000363: 16,3526 27667 ADS DELOGART
042670,000364: 16,3527 33762 CA LMCRATE
042671,000365: 16,3530 00006 EXTEND
042672,000366: 16,3531 75021 MP BIT11
042673,000367: 16,3532 61667 RATENUM AD DELOGART # NUMERATOR COMPLETED
042674,000368:
042675,000369: 16,3533 56001 XCH L # PLACE NUMERATOR IN L FOR OVERFL. CHECK
042676,000370: 16,3534 35035 CA ZERO
042677,000371: 16,3535 00006 EXTEND
042678,000372: 16,3536 11573 DV TEMREG # OVERFLOW, IF ANYTHING, NOW APPEARS IN A
042679,000373: 16,3537 00006 EXTEND
042680,000374: 16,3540 13546 BZF DVOK # NO OVERFLOW....(0,L)/TEMREG = 0,L
042681,000375:
042682,000376: 16,3541 10000 MINLIMAP CCS A
042683,000377: 16,3542 35013 CAF POSMAX # POSITIVE OVERFLOW
042684,000378: 16,3543 13555 TCF ROLLSET
042685,000379: 16,3544 45013 CS POSMAX # NEGATIVE OVERFLOW
042686,000380: 16,3545 13555 TCF ROLLSET
042687,000381:
042688,000382: 16,3546 22000 DVOK LXCH A # PUT NUMERATOR BACK INTO A, 0 IN L
042689,000383: 16,3547 00006 EXTEND
042690,000384: 16,3550 11573 DV TEMREG # RESULT OF DIVISION IS DESIRED OGARATE
042691,000385: 16,3551 13555 TCF ROLLSET # (SCALED AT B-4 REV/SEC)
042692,000386:
042693,000387: 16,3552 43766 RATELIM CS MAXLIM
042694,000388: 16,3553 51672 INDEX I
042695,000389: 16,3554 00000 0 A # IF I = CA, DESIRED RATE IS -MAXLIM
042696,000390:
042697,000391: # COMPUTE JET FIRE TIME, BASED ON DESIRED RATE MINUS PRESENT RATE
042698,000392:
042699,000393: 16,3555 55573 ROLLSET TS TEMREG # STORE DESIRED OGARATE (SCALED B-4)
042700,000394: 16,3556 00006 EXTEND
042701,000395: 16,3557 61533 SU OGARATE # RATE DIFF. SCALED AT 2(-4) REV/SEC
042702,000396: 16,3560 55573 TS TEMREG # OVERFLOW PROTECT
042703,000397: 16,3561 13564 TCF +3 # " "
042704,000398: 16,3562 50000 INDEX A # " "
042705,000399: 16,3563 45014 CS LIMITS # " "
042706,000400: 16,3564 00006 EXTEND
042707,000401: 16,3565 77665 MP T6SCALE # T6SCALE = 8/10.24
042708,000402: 16,3566 00006 EXTEND
042709,000403: 16,3567 71640 MP 1/CONACC # SCALED AT B+9 SECSQ/REV (MAX < .60)
042710,000404: 16,3570 20001 DDOUBL
042711,000405: 16,3571 20001 DDOUBL
042712,000406: 16,3572 55573 TS TEMREG # OVERFLOW PROTECT
042713,000407: 16,3573 13576 TCF +3 # " "
042714,000408: 16,3574 50000 INDEX A # " "
042715,000409: 16,3575 45014 CS LIMITS # " "
042716,000410: 16,3576 55573 TS TEMREG # JET FIRE TIME AT 625 MICROSEC/BIT
042717,000411: 16,3577 00006 EXTEND # POS MEANS POSITIVE ROLL TORQUE.
042718,000412: 16,3600 13663 BZF NOROLL
042719,000413:
042720,000414: # JET FIRE TIME IS NZ, TEST FOR JETS NOW ON.
042721,000415:
042722,000416: 16,3601 31573 CAE TEMREG # DESIRED CHANGE IN OGARATE
042723,000417: 16,3602 00006 EXTEND
042724,000418: 16,3603 71571 MP ROLLFIRE # (SGN OF TORQUE..ZERO IF JETS NOW OFF)
042725,000419: 16,3604 10000 CCS A
042726,000420: 16,3605 13611 TCF MOREROLL # CONTINUE FIRING WITH PRESENT POLARITY
042727,000421: 16,3606 13614 TCF NEWROLL # START NEW FIRING NOW, PLUS
042728,000422: 16,3607 13663 TCF NOROLL # TERMINATE OLD FIRING, NEW SIGN REQUESTED
042729,000423: 16,3610 13614 TCF NEWROLL # START NEW FIRING NOW, MINUS
042730,000424:
042731,000425: # CONTINUE PRESENT FIRING
042732,000426:
042733,000427: 16,3611 35035 MOREROLL CAF ZERO
042734,000428: 16,3612 55672 TS I # USE TEMP. AS MOREROLL SWITCH
042735,000429: 16,3613 13625 TCF MAXTFIRE
042736,000430:
042737,000431: # START NEW FIRING, BUT CHECK IF GREATER THAN MIN FIRE TIME.
042738,000432:
042739,000433: 16,3614 11573 NEWROLL CCS TEMREG # CALL THIS T6FIRE
042740,000434: 16,3615 65033 AD ONE
042741,000435: 16,3616 13620 TCF +2
042742,000436: 16,3617 65033 AD ONE
042743,000437: 16,3620 40000 COM # -MAG(T6FIRE)
042744,000438: 16,3621 63767 AD TMINFIRE # TMINFIRE-MAG(T6FIRE)
042745,000439: 16,3622 40000 COM
042746,000440: 16,3623 00006 EXTEND
042747,000441: 16,3624 63663 MINTST BZMF NOROLL # IF NOT GREATER THAN TMINFIRE (NEW FIRE)
042748,000442:
042749,000443: # PROCEED WITH NEW FIRING, BUT NOT LONGER THAN TMAXFIRE.
042750,000444:
042751,000445: 16,3625 31573 MAXTFIRE CA TEMREG
042752,000446: 16,3626 00006 EXTEND
042753,000447: 16,3627 75031 MP 1/TMXFIR # I.E. 1/TMAXFIRE
042754,000448: 16,3630 00006 EXTEND
042755,000449: 16,3631 13637 MAXTST BZF NOMXFIRE # IF LESS THAN TMAXFIRE
042756,000450:
042757,000451: 16,3632 10000 CCS A
042758,000452: 16,3633 33770 CAF TMAXFIRE # USE MAXIMUM
042759,000453: 16,3634 13636 TCF +2
042760,000454: 16,3635 43770 CS TMAXFIRE # USE MAXIMUM
042761,000455: 16,3636 55573 TS TEMREG
042762,000456:
042763,000457: # SET UP SIGN OF REQUIRED TORQUE.
042764,000458:
042765,000459: 16,3637 11573 NOMXFIRE CCS TEMREG # FOR TORQUE SIGN
042766,000460: 16,3640 35013 CA POSMAX # POSITIVE TORQUE REQUIRED
042767,000461: 16,3641 13643 TCF +2
042768,000462: 16,3642 35015 CA NEGMAX # NEGATIVE TORQUE REQUIRED
042769,000463: 16,3643 55571 TS ROLLFIRE # SET ROLLFIRE FOR + OR - TORQUE
042770,000464:
042771,000465: 16,3644 40000 COM # COMPLEMENT... POS. FOR NEG. TORQUE
042772,000466: 16,3645 00006 EXTEND
042773,000467: 16,3646 63651 BZMF +3 # POSITIVE TORQUE REQUIRED
042774,000468: 16,3647 41573 CS TEMREG
042775,000469: 16,3650 55573 TS TEMREG
042776,000470:
042777,000471: 16,3651 31672 FIRELOOK CA I # IS IT MOREROLL
042778,000472: 16,3652 00006 EXTEND
042779,000473: 16,3653 13655 BZF FIREPLUG # YES
042780,000474: 16,3654 13666 TCF JETROLL # MAG(T6FIRE) NOW IN TEMREG
042781,000475:
042782,000476: 16,3655 30031 FIREPLUG CAE TIME6 # CHECK FOR EXTENDED FIRING
042783,000477: 16,3656 00006 EXTEND
042784,000478: 16,3657 61573 SU TEMREG
042785,000479: 16,3660 00006 EXTEND
042786,000480: 16,3661 65340 EXTENTST BZMF TASKOVER # IF EXTENSION WANTED, DONT, EXIT ROLL DAP
042787,000481: 16,3662 13666 TCF JETROLL
042788,000482:
042789,000483: 16,3663 45035 NOROLL CS ZERO # COAST....(NEG ZERO FOR TIME6)
042790,000484: 16,3664 55571 TS ROLLFIRE # NOTE, JETS CAN FIRE NEXT PASS
042791,000485: 16,3665 55573 TS TEMREG
042792,000486:
042793,000487: 16,3666 00006 JETROLL EXTEND
042794,000488: 16,3667 33757 DCA NOROL1T6
042795,000489: 16,3670 53311 DXCH T6LOC
042796,000490: 16,3671 31573 CA TEMREG # ENTER JET FIRING TIME
042797,000491: 16,3672 54031 TS TIME6
042798,000492:
042799,000493: 16,3673 31672 CA I # I=0 IF MOREROLL, KEEP SAME JETS ON
042800,000494: 16,3674 00006 EXTEND
042801,000495: 16,3675 15340 SAMEJETS BZF TASKOVER # IF JETS ON KEEP SAME JETS. EXIT ROLL DAP
042802,000496:
042803,000497: 16,3676 11571 CCS ROLLFIRE
042804,000498: 16,3677 13703 TCF +TORQUE
042805,000499: 16,3700 13744 TCF T6ENABL
042806,000500: 16,3701 13724 TCF -TORQUE
042807,000501: 16,3702 13744 TCF T6ENABL
042808,000502:
042809,000503: # PROCEED WITH PLUS TORQUE.
042810,000504:
042811,000505: 16,3703 31572 +TORQUE CA ROLLWORD # WHAT WAS THE LAST +TORQUE COMBINATION
042812,000506: 16,3704 75033 MASK BIT1 # WAS IT NO.9-11
042813,000507: 16,3705 00006 EXTEND
042814,000508: 16,3706 13716 BZF NO.9-11 # NOT 9-11, SO USE IT THIS TIME
042815,000509:
042816,000510: 16,3707 45033 NO.13-15 CS BIT1
042817,000511: 16,3710 71572 MASK ROLLWORD
042818,000512: 16,3711 55572 TS ROLLWORD # CHANGE BIT 1 TO ZERO
042819,000513: 16,3712 35053 CAF +ROLL2
042820,000514: 16,3713 00006 EXTEND
042821,000515: 16,3714 01006 WRITE CHAN6
042822,000516: 16,3715 13744 TCF T6ENABL
042823,000517:
042824,000518: 16,3716 35033 NO.9-11 CAF BIT1 # 1ST + JETS TO FIRE (MRCLEAN OS ROLLWORD)
042825,000519: 16,3717 27572 ADS ROLLWORD # CHANGE BIT 1 TO ONE
042826,000520: 16,3720 35036 CAF +ROLL1
042827,000521: 16,3721 00006 EXTEND
042828,000522: 16,3722 01006 WRITE CHAN6
042829,000523: 16,3723 13744 TCF T6ENABL
042830,000524:
042831,000525: 16,3724 31572 -TORQUE CA ROLLWORD # WHAT WAS LAST -TORQUE COMBINATION
042832,000526: 16,3725 75032 MASK BIT2 # WAS IT NO.12-10
042833,000527: 16,3726 00006 EXTEND
042834,000528: 16,3727 13737 BZF NO.12-10 # NOT 12-10, SO USE IT THIS TIME
042835,000529:
042836,000530: 16,3730 45032 NO.16-14 CS BIT2
042837,000531: 16,3731 71572 MASK ROLLWORD
042838,000532: 16,3732 55572 TS ROLLWORD # CHANGE BIT 2 TO ZERO
042839,000533: 16,3733 33771 CAF -ROLL2
042840,000534: 16,3734 00006 EXTEND
042841,000535: 16,3735 01006 WRITE CHAN6
042842,000536: 16,3736 13744 TCF T6ENABL
042843,000537:
042844,000538: 16,3737 35032 NO.12-10 CAF BIT2 # 1ST -JETS TO FIRE (MRCLEAN OS ROLLWORD)
042845,000539: 16,3740 27572 ADS ROLLWORD # CHANGE BIT 2 TO ONE
042846,000540: 16,3741 34377 CAF -ROLL1
042847,000541: 16,3742 00006 EXTEND
042848,000542: 16,3743 01006 WRITE CHAN6
042849,000543:
042850,000544: 16,3744 35015 T6ENABL CAF BIT15
042851,000545: 16,3745 00006 EXTEND
042852,000546: 16,3746 05013 WOR CHAN13
042853,000547: 16,3747 15340 RDAPEND TCF TASKOVER # EXIT ROLL DAP
042854,000548:
042855,000549: # THIS T6 TASK SHUTS OFF ALL ROLL JETS
042856,000550:
042857,000551: 16,3750 22016 NOROLL1 LXCH BANKRUPT # SHUT OFF ALL (ROLL) JETS, (A T6 TASK
042858,000552: 16,3751 35035 CAF ZERO # CALLED BY ..JETROLL..)
042859,000553: 16,3752 55571 TS ROLLFIRE # ZERO INDICATES JETS NOW OFF
042860,000554: 16,3753 00006 EXTEND
042861,000555: 16,3754 01006 KILLJETS WRITE CHAN6
042862,000556: 16,3755 15351 TCF NOQRSM
042863,000557:
042864,000558: # CONSTANTS FOR ROLL AUTOPILOT....
042865,000559:
042866,000560: 16,3756 E6,1704 EBANK= BZERO
042867,000561: 16,3756 03750 34066 NOROL1T6 2CADR NOROLL1
042868,000562:
042869,000563: 16,3760 00344 DB DEC .01388889 # DEAD BAND (5 DEG), SC.AT B+0 REV
042870,000564:
042871,000565: 16,3761 06315 -SLOPE DEC 0.2 # -SWITCHLINE SLOPE(0.2 PER SEC) SC.AT B+0
042872,000566: # PER SEC
042873,000567: 16,3762 00111 LMCRATE DEC .00027778 B+4 # LIMIT CYCLE RATE (0.1 DEG/SEC) SC.AT
042874,000568: # B-4 REV/SEC
042875,000569: 16,3763 00510 INTERCEP DEC .0025 B+3 # DB(-SLOPE) - LMCRATE, SC.AT B-3 REV/SC
042876,000570:
042877,000571: 16,3764 01330 MINLIM DEC .00277778 B+4 # RATELIM,MIN (1DEG/SEC), SC.AT B-4 REV/SC
042878,000572:
042879,000573: 16,3765 00027 1/MINLIM DEC 360 B-18 # RECIPROCAL THEREOF, SHIFTED 14 RIGHT
042880,000574:
042881,000575: 16,3766 07071 MAXLIM DEC .01388889 B+4 # RATELIM,MAX (5DEG/SEC), SC.AT B-4 REV/SC
042882,000576:
042883,000577: 16,3767 00030 TMINFIRE DEC 1.5 B+4 # 15 MS (14MIN), SC.AT 16 BITS/CS
042884,000578:
042885,000579: 16,3770 07640 TMAXFIRE DEC 250 B+4 # 2.5 SEC, SC.AT 16 BITS/CS
042886,000580:
042887,000581: 16,3771 5031 1/TMXFIR = BIT3 # RECIPROCAL THEREOF, SHIFTED 14 RIGHT,
042888,000582: # ROUNDS TO OCT00004, SO ALLOWS 2.56
042889,000583: # SEC FIRINGS BEFORE APPLYING LIMIT
042890,000584: 16,3771 7665 T6SCALE = PRIO31 # (B+3) (16 BITS/CS) (100CS/SEC)
042891,000585:
042892,000586: 16,3771 5036 +ROLL1 = FIVE # ONBITS FOR JETS 9 AND 11
042893,000587: 16,3771 5053 +ROLL2 = OCT120 # ONBITS FOR JETS 13 AND 15
042894,000588: 16,3771 4377 -ROLL1 = TEN # ONBITS FOR JETS 12 NAD 10
042895,000589: 16,3771 00240 -ROLL2 OCT 240 # ONBITS FOR JETS 16 AND 14
042896,000590:
End of include-file TVCROLLDAP.agc. Parent file is MAIN.agc