Source Code

These source-code files were transcribed from a printout in Don Eyles's personal collection, scanned by archive.org, and financially sponsored by Linden Sims. A team of volunteers performed the transcription and proof-reading. The scanned page images are available at the Virtual AGC Project website, as well as higher-quality (but much larger) images at the Virtual AGC Project's collection in the Internet Archive. Report any problems by creating "issues" at the Virtual AGC Project's GitHub Repository.

Notations on the program listing read, in part:

	GAP:  ASSEMBLE REVISION 56 OF AGC PROGRAM ZERLINA BY ZOROASTER
	9:12 OCT. 21,1970
Note that the date is the date of the printout, not the date of the program revision.

061070,000002:                                                                                                  ## Copyright:   Public domain.
061071,000003:                                                                                                  ## Filename:    DAP_INTERFACE_SUBROUTINES.agc
061072,000004:                                                                                                  ## Purpose:     A log section of Zerlina 56, the final revision of
061073,000005:                                                                                                  ##              Don Eyles's offline development program for the variable 
061074,000006:                                                                                                  ##              guidance period servicer. It also includes a new P66 with LPD 
061075,000007:                                                                                                  ##              (Landing Point Designator) capability, based on an idea of John 
061076,000008:                                                                                                  ##              Young's. Neither of these advanced features were actually flown,
061077,000009:                                                                                                  ##              but Zerlina was also the birthplace of other big improvements to
061078,000010:                                                                                                  ##              Luminary including the terrain model and new (Luminary 1E)
061079,000011:                                                                                                  ##              analog display programs. Zerlina was branched off of Luminary 145,
061080,000012:                                                                                                  ##              and revision 56 includes all changes up to and including Luminary
061081,000013:                                                                                                  ##              183. It is therefore quite close to the Apollo 14 program,
061082,000014:                                                                                                  ##              Luminary 178, where not modified with new features.
061083,000015:                                                                                                  ## Reference:   pp. 1394-1397
061084,000016:                                                                                                  ## Assembler:   yaYUL
061085,000017:                                                                                                  ## Contact:     Ron Burkey <info@sandroid.org>.
061086,000018:                                                                                                  ## Website:     www.ibiblio.org/apollo/index.html
061087,000019:                                                                                                  ## Mod history: 2017-07-28 MAS  Created from Luminary 210.
061088,000020:                                                                                                  ##              2017-08-29 MAS  Updated for Zerlina 56.
061089,000021: 

Page 1394

061091,000023: 20,2115                                           BANK     20                                    
061092,000024: 20,2000                                           SETLOC   DAPS3                                 
061093,000025: 20,2000                                           BANK                                           
061094,000026: 
061095,000027: 20,2115  E6,1634                                  EBANK=   CDUXD                                 
061096,000028: 20,2115                                           COUNT*   $$/DAPIF                              
061097,000029: 
061098,000030:                                                                                                  #  MOD 0              DATE  11/15/66          BY  GEORGE W. CHERRY
061099,000031: 
061100,000032:                                                                                                  #  MOD 1                     1/23/67          MODIFICATION BY PETER ADLER
061101,000033: 
061102,000034:                                                                                                  #  FUNCTIONAL DESCRIPTION
061103,000035: 
061104,000036:                                                                                                  #           HEREIN ARE A COLLECTION OF SUBROUTINES WHICH ALLOW MISSION CONTROL PROGRAMS TO CONTROL THE MODE
061105,000037:                                                                                                  #           AND INTERFACE WITH THE DAP.
061106,000038: 
061107,000039:                                                                                                  #  CALLING SEQUENCES
061108,000040: 
061109,000041:                                                                                                  #  IN INTERRUPT OR WITH INTERRUPT INHIBITED
061110,000042:                                                                                                  #           TC     IBNKCALL
061111,000043:                                                                                                  #           FCADR  ROUTINE
061112,000044: 
061113,000045:                                                                                                  #  IN A JOB WITHOUT INTERRUPT INHIBITED
061114,000046:                                                                                                  #           INHINT
061115,000047:                                                                                                  #           TC     IBNKCALL
061116,000048:                                                                                                  #           FCADR  ROUTINE
061117,000049:                                                                                                  #           RELINT
061118,000050: 
061119,000051:                                                                                                  #  OUTPUT
061120,000052: 
061121,000053:                                                                                                  #           SEE INDIVIDUAL ROUTINES BELOW
061122,000054: 
061123,000055:                                                                                                  #  DEBRIS
061124,000056: 
061125,000057:                                                                                                  #           A,L, AND SOMETIMES MDUETEMP                                    ODE      NOT IN PULSES MODE
061126,000058: 

Page 1395

061128,000060:                                                                                                  #  SUBROUTINE NAMES:
061129,000061:                                                                                                  #           SETMAXDB, SETMINDB, RESTORDB, PFLITEDB
061130,000062: 
061131,000063:                                                                                                  #  MODIFIED: 30 JANUARY 1968 BY P S WEISSMAN TO CREATE RESTORDB.
061132,000064: 
061133,000065:                                                                                                  #  MODIFIED: 1 MARCH 1968 BY P S WEISSMAN TO SAVE EBANK AND CREATE PFLITEDB
061134,000066: 
061135,000067:                                                                                                  #  FUNCTIONAL DESCRIPTION:
061136,000068:                                                                                                  #           SETMAXDB - SET DEADBAND TO 5.0 DEGREES
061137,000069:                                                                                                  #           SETMINDB - SET DEADBAND TO 0.3 DEGREE
061138,000070:                                                                                                  #           RESTORDB - SET DEADBAND TO .3,1, OR 5 ACCORDING TO BITS 4 AND 5 OF DAPBOOLS
061139,000071:                                                                                                  #           PFLITEDB - SET DEADBAND TO 1.0 DEGREE AND ZERO THE COMMANDED ATTITUDE CHANGE AND COMMANDED RATE
061140,000072:                                                                                                  #           ALL ENTRIES SET UP A NOVAC JOB TO DO 1/ACCS SO THAT THE TJETLAW SWITCH CURVES ARE POSITIONED TO
061141,000073:                                                                                                  #  REFLECT THE NEW DEADBAND.  IT SHOULD BE NOTED THAT THE DEADBAND REFERS TO THE ATTITUDE IN THE P-,U-,AND V-AXES.
061142,000074: 
061143,000075:                                                                                                  #  SUBROUTINE CALLED:  NOVAC
061144,000076: 
061145,000077:                                                                                                  #  CALLING SEQUENCE: SAME AS ABOVE
061146,000078:                                                                                                  #                                          OR       TC     RESTORDB +1     FROM ALLCOAST
061147,000079:                                                                                                  #  DEBRIS:  A, L, Q, RUPTREG1, (ITEMPS IN NOVAC)
061148,000080: 
061149,000081: 20,2115           30111        RESTORDB           CAE      DAPBOOLS                              #  DETERMINE CREW-SELECTED DEADBAND.
061150,000082: 20,2116           74747                           MASK     DBSLECT2                              #  CHECK FOR MAX DB (5 DEG)
061151,000083: 20,2117           00006                           EXTEND                                         
061152,000084: 20,2120           12122                           BZF      +2                                    
061153,000085: 20,2121           12130                           TCF      SETMAXDB                              #  BIT5 DAPBOOLS IS SET - CREW WANTS 5 DEG
061154,000086: 20,2122           30111                           CAE      DAPBOOLS                              
061155,000087: 20,2123           74750                           MASK     DBSELECT                              #  CHECK FOR 1 DEG DEADBAND SELECTION
061156,000088: 20,2124           00006                           EXTEND                                         
061157,000089: 20,2125           12141                           BZF      SETMINDB                              
061158,000090: 
061159,000091: 20,2126           32153                           CAF      POWERDB                               #  BIT4 DAPBOOLS IS SET - CREW WANTS 1 DEG
061160,000092: 20,2127           12131                           TCF      SETMAXDB   +1                         
061161,000093: 20,2130           32152        SETMAXDB           CAF      WIDEDB                                #  SET 5 DEGREE DEADBAND.
061162,000094: 20,2131           55343                 +1        TS       DB                                    
061163,000095: 
061164,000096: 20,2132           00006                           EXTEND                                         #  SET UP JOB TO RE-POSITION SWITCH CURVES.
061165,000097: 20,2133           22070                           QXCH     RUPTREG1                              
061166,000098: 20,2134           37727        CALLACCS           CAF      PRIO27                                
061167,000099: 20,2135           05072                           TC       NOVAC                                 
061168,000100: 20,2136  E6,1536                                  EBANK=   AOSQ                                  
061169,000101: 20,2136           03555 42106                     2CADR    1/ACCJOB                              
061170,000102: 
061171,000103: 
061172,000104: 20,2140           00070                           TC       RUPTREG1                              #  RETURN TO CALLER.
061173,000105: 
061174,000106: 20,2141           32151        SETMINDB           CAF      NARROWDB                              #  SET 0.3 DEGREE DEADBAND.
061175,000107: 20,2142           12131                           TCF      SETMAXDB   +1                         
061176,000108: 

Page 1396

061178,000110: 20,2143           00006        PFLITEDB           EXTEND                                         #  THE RETURN FROM CALLACCS IS TO RUPTREG1.
061179,000111: 20,2144           22070                           QXCH     RUPTREG1                              
061180,000112: 20,2145           02154                           TC       ZATTEROR                              #  ZERO THE ERRORS AND COMMANDED RATES.
061181,000113: 20,2146           32153                           CAF      POWERDB                               #  SET DB TO 1.0 DEG.
061182,000114: 20,2147           55343                           TS       DB                                    
061183,000115: 20,2150           12134                           TCF      CALLACCS                              #  SET UP 1/ACCS AND RETURN TO CALLER.
061184,000116: 20,2151           00155        NARROWDB           OCTAL    00155                                 #  0.3 DEGREE SCALED AT 45.
061185,000117: 20,2152           03434        WIDEDB             OCTAL    03434                                 #  5.0 DEGREES SCALED AT 45.
061186,000118: 20,2153           00554        POWERDB            DEC      .02222                                #  1.0 DEGREE SCALED AT 45.
061187,000119: 
061188,000120: 
061189,000121: 20,2154           35015        ZATTEROR           CAF      EBANK6                                
061190,000122: 20,2155           56003                           XCH      EBANK                                 
061191,000123: 20,2156           54001                           TS       L                                     #  SAVE CALLERS EBANK IN L.
061192,000124: 20,2157           30032                           CAE      CDUX                                  
061193,000125: 20,2160           55634                           TS       CDUXD                                 
061194,000126: 20,2161           30033                           CAE      CDUY                                  
061195,000127: 20,2162           55635                           TS       CDUYD                                 
061196,000128: 20,2163           30034                           CAE      CDUZ                                  
061197,000129: 20,2164           55636                           TS       CDUZD                                 
061198,000130: 20,2165           12171                           TCF      STOPRATE   +3                         
061199,000131: 
061200,000132: 
061201,000133: 20,2166           35015        STOPRATE           CAF      EBANK6                                
061202,000134: 20,2167           56003                           XCH      EBANK                                 
061203,000135: 20,2170           54001                           TS       L                                     #  SAVE CALLERS EBANK IN L.
061204,000136: 20,2171           34755                 +3        CAF      ZERO                                  
061205,000137: 20,2172           55642                           TS       OMEGAPD                               
061206,000138: 20,2173           55643                           TS       OMEGAQD                               
061207,000139: 20,2174           55644                           TS       OMEGARD                               
061208,000140: 20,2175           55637                           TS       DELCDUX                               
061209,000141: 20,2176           55640                           TS       DELCDUY                               
061210,000142: 20,2177           55641                           TS       DELCDUZ                               
061211,000143: 20,2200           55274                           TS       DELPEROR                              
061212,000144: 20,2201           55275                           TS       DELQEROR                              
061213,000145: 20,2202           55276                           TS       DELREROR                              
061214,000146: 20,2203           22003                           LXCH     EBANK                                 #  RESTORE CALLERS EBANK.
061215,000147: 20,2204           00002                           TC       Q                                     
061216,000148: 
061217,000149:                                                                                                  #  SUBROUTINE NAME:  ALLCOAST
061218,000150: 
061219,000151:                                                                                                  #  WILL BE CALLED BY FRESH STARTS AND ENGINE OFF ROUTINES.                 .
061220,000152: 
061221,000153:                                                                                                  #  CALLING SEQUENCE: (SAME AS ABOVE)
061222,000154: 
061223,000155:                                                                                                  #  EXIT:  RETURN TO Q.
061224,000156: 
061225,000157:                                                                                                  #  SUBROUTINES CALLED:  STOPRATE, RESTORDB, NOVAC
061226,000158: 
061227,000159:                                                                                                  #  ZERO:  (FOR ALL AXES) AOS, ALPHA, AOSTERM, OMEGAD, DELCDU, DELEROR
061228,000160: 

Page 1397

061230,000162:                                                                                                  #  OUTPUT:  DRIFTBIT/DAPBOOLS, DB, JOB TO DO 1/ACCS
061231,000163: 
061232,000164:                                                                                                  #  DEBRIS:  A, L, Q, RUPTREG1, RUPTREG2, (ITEMPS IN NOVAC)
061233,000165: 
061234,000166: 20,2205           00006        ALLCOAST           EXTEND                                         #  SAVE Q FOR RETURN
061235,000167: 20,2206           22071                           QXCH     RUPTREG2                              
061236,000168: 20,2207           02166                           TC       STOPRATE                              #  CLEAR RATE INTERFACE.  RETURN WITH A=0
061237,000169: 20,2210           22003                           LXCH     EBANK                                 #    AND L=EBANK6.  SAVE CALLERS EBANK.
061238,000170: 20,2211           55536                           TS       AOSQ                                  
061239,000171: 20,2212           55537                           TS       AOSQ       +1                         
061240,000172: 20,2213           55540                           TS       AOSR                                  
061241,000173: 20,2214           55541                           TS       AOSR       +1                         
061242,000174: 20,2215           55424                           TS       ALPHAQ                                #  FOR DOWNLIST.
061243,000175: 20,2216           55425                           TS       ALPHAR                                
061244,000176: 20,2217           55544                           TS       AOSQTERM                              
061245,000177: 20,2220           55545                           TS       AOSRTERM                              
061246,000178: 20,2221           22003                           LXCH     EBANK                                 #  RESTORE EBANK  (EBANK6 NO LONGER NEEDED)
061247,000179: 
061248,000180: 20,2222           40111                           CS       DAPBOOLS                              #  SET UP DRIFTBIT
061249,000181: 20,2223           74744                           MASK     DRIFTBIT                              
061250,000182: 20,2224           26111                           ADS      DAPBOOLS                              
061251,000183: 20,2225           02116                           TC       RESTORDB   +1                         #  RESTORE DEADBANK TO CREW-SELECTED VALUE.
061252,000184: 
061253,000185: 20,2226           00071                           TC       RUPTREG2                              #  RETURN.

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