Source Code

These source-code files are part of a reconstructed copy of Artemis 071, the first release of the Apollo 15 through 17 Command Module (CM) Apollo Guidance Computer (AGC) software.

The reconstruction began with source code of Artemis 072 previously transcribed from a digitized copy of that program. The code was then updated by undoing changes between the two versions. The reconstruction was verified by matching memory-bank checksums to those listed in drawing 2021154-. Note that page numbers in the reconstructed code match those on the Artemis 072 printout, although the changed code would likely have changed page numbers for a real Artemis 071 listing.

Comments from 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.

063805,000002:                                                                                                  ## Copyright:   Public domain.
063806,000003:                                                                                                  ## Filename:    UPDATE_PROGRAM.agc
063807,000004:                                                                                                  ## Purpose:     A section of Artemis revision 071.
063808,000005:                                                                                                  ##              It is part of the reconstructed source code for the first
063809,000006:                                                                                                  ##              release of the flight software for the Command Module's
063810,000007:                                                                                                  ##              (CM) Apollo Guidance Computer (AGC) for Apollo 15 through
063811,000008:                                                                                                  ##              17. The code has been recreated from a copy of Artemis 072.
063812,000009:                                                                                                  ##              It has been adapted such that the resulting bugger words
063813,000010:                                                                                                  ##              exactly match those specified for Artemis 071 in NASA
063814,000011:                                                                                                  ##              drawing 2021154-, which gives relatively high confidence
063815,000012:                                                                                                  ##              that the reconstruction is correct.
063816,000013:                                                                                                  ## Reference:   1490
063817,000014:                                                                                                  ## Assembler:   yaYUL
063818,000015:                                                                                                  ## Contact:     Ron Burkey <info@sandroid.org>.
063819,000016:                                                                                                  ## Website:     www.ibiblio.org/apollo/index.html
063820,000017:                                                                                                  ## Mod history: 2019-08-14 MAS  Created from Artemis 072.
063821,000018: 

Page 1490

063823,000020: 
063824,000021:                                                                                                  #  PROGRAM NAME:         P27
063825,000022:                                                                                                  #  WRITTEN BY:           KILROY/ DE WOLF
063826,000023: 
063827,000024:                                                                                                  #  MOD NO:               6
063828,000025:                                                                                                  #  MOD BY:               KILROY
063829,000026:                                                                                                  #  DATE:                 01DEC67
063830,000027: 
063831,000028:                                                                                                  #  LOG SECTION:          UPDATE PROGRAM.
063832,000029: 
063833,000030:                                                                                                  #  FUNCT. DESCR:         P27 (THE UPDATE PROGRAM) PROCESSES COMMANDS AND DATA
063834,000031:                                                                                                  #                            INSERTIONS REQUESTED BY THE GROUND VIA UPLINK.
063835,000032:                                                                                                  #                            THE P27 PROGRAM WILL ACCEPT UPDATES
063836,000033:                                                                                                  #                            ONLY DURING P00 FOR THE LM, AND ONLY DURING P00,
063837,000034:                                                                                                  #                        P02, AND FRESH START FOR THE CSM
063838,000035: 
063839,000036:                                                                                                  #  CALLING SEQ:          PROGRAM IS INITIATED BY UPLINK ENTRY OF VERBS 70, 71, 72 AND 73.
063840,000037: 
063841,000038:                                                                                                  #  SUBROUTINES:          TESTXACT, NEWMODEX, NEWMODEX +3, GOXDSPF, BANKCALL, FINDVAC, INTPRET, INTSTALL, TPAGREE,
063842,000039:                                                                                                  #                        INTWAKEU, ENDEXT, POSTJUMP, FALTON, NEWPHASE, PHASCHNG
063843,000040: 
063844,000041:                                                                                                  #  NORMAL EXIT:          TC ENDEXT
063845,000042: 
063846,000043:                                                                                                  #  ALARM/ABORT:          TC FALTON FOLLOWED BY TC ENDEXT
063847,000044: 
063848,000045:                                                                                                  #  RESTARTS:             P27 IS RESTART PROTECTED IN TWO WAYS...
063849,000046:                                                                                                  #                        1. PRIOR TO VERIFLAG INVERSION (WHICH IS CAUSED BY THE GROUND/ASTRONAUT'S VERIFICATION OF UPDATE
063850,000047:                                                                                                  #                           DATA BY SENDING A V33E WHEN V21N02 IS FLASHING)---
063851,000048:                                                                                                  #                           NO PROTECTION EXCEPT PRE-P27 MODE IS RESTORED, COAST + ALIGN DOWNLIST IS SELECTED AND UPLINK
063852,000049:                                                                                                  #                           ACTIVITY LIGHT IS TURNED OFF. (JUST AS IF A V34E WAS SENT DURING P27 DATA LOADS).
063853,000050:                                                                                                  #                           V70,V71,V72 OR V73 WILL HAVE TO BE COMPLETELY RESENT BY USER.
063854,000051:                                                                                                  #                        2. AFTER VERIFLAG INVERSION (WHEN UPDATE OF THE SPECIFIED ERASABLES IS BEING PERFORMED)---
063855,000052:                                                                                                  #                           PROTECTED AGAINST RESTARTS.
063856,000053: 
063857,000054:                                                                                                  #  DEBRIS:               UPBUFF  (20D)   TEMP STORAGE FOR ADDRESSES AND CONTENTS.
063858,000055:                                                                                                  #                        UPVERB  (1)     VERB NUMBER MINUS 70D (E.G. FOR V72, UPVERB = 72D - 70D = 2)
063859,000056:                                                                                                  #                        UPOLDMOD(1)     FOR MAJOR MODE INTERRUPTED BY P27.
063860,000057:                                                                                                  #                        COMPNUMB(1)     TOTAL NUMBER OF COMPONENTS TO BE TRANSMITTED.
063861,000058:                                                                                                  #                        UPCOUNT (1)     ACTUAL NUMBER OF COMPONENTS RECEIVED.
063862,000059:                                                                                                  #                        UPTEMP  (1)     SCRATCH, BUT USUALLY CONTAINS COMPONENT NUMBER TO BE CHANGED DURING VERIFY CYCLE
063863,000060: 
063864,000061:                                                                                                  #  INPUT:
063865,000062: 
063866,000063:                                                                                                  #        ENTRY:                  DESCRIPTION
063867,000064: 
063868,000065:                                                                                                  #        V70EXXXXXEXXXXXE        (LIFTOFF TIME INCREMENT) DOUBLE PRECISION OCTAL TIME INCREMENT, XXXXX XXXXX,
063869,000066:                                                                                                  #                                IS ADDED TO TEPHEM, SUBTRACTED FROM AGC CLOCK(TIME2,TIME1), SUBTRACTED FROM CSM STATE
063870,000067:                                                                                                  #                                VECTOR TIME(TETCSM) AND SUBTRACTED FROM LEM STATE VECTOR TIME (TETLEM).
063871,000068:                                                                                                  #                                THE DP OCTAL TIME INCREMENT IS SCALED AT 2(28).

Page 1491

063873,000070: 
063874,000071:                                                                                                  #        V71EIIEAAAAE            (CONTIGUOUS BLOCK UPDATE) II-2 OCTAL COMPONENTS, XXXXX,
063875,000072:                                                                                                  #        XXXXXE                  ARE LOADED INTO ERASABLE STARTING AT ECADR, AAAA.
063876,000073:                                                                                                  #        XXXXXE                  IT IS .GE. 3 .AND. .LE. 20D.,
063877,000074:                                                                                                  #                                AND (AAAA + II - 3) DOES NOT PRODUCE AN ADDRESS IN THE
063878,000075:                                                                                                  #        9 NEXT BANK
063879,000076:                                                                                                  #          .                     SCALING IS SAME AS INTERNAL REGISTERS.
063880,000077: 
063881,000078:                                                                                                  #        V72EIIE                 (SCATTER UPDATE) (II-1)/2 OCTAL COMPONENTS, XXXXX, ARE
063882,000079:                                                                                                  #        AAAAEXXXXXE             LOADED INTO ERASABLE LOCATIONS, AAAA.
063883,000080:                                                                                                  #        AAAAEXXXXXE             II IS .GE. 3 .AND. .LE. 19D, AND MUST BE ODD.
063884,000081:                                                                                                  #          .                     SCALING IS SAME AS INTERNAL REGISTERS.
063885,000082: 
063886,000083:                                                                                                  #        V73EXXXXXEXXXXXE        (OCTAL CLOCK INCREMENT) DOUBLE PRECISION OCTAL TIME
063887,000084:                                                                                                  #                                INCREMENT XXXXX XXXXX, IS ADDED TO THE AGC CLOCK, IN
063888,000085:                                                                                                  #                                CENTISECONDS SCALED AT (2)28.
063889,000086:                                                                                                  #                                THIS LOAD IS THE OCTAL EQUIVALENT OF V55.
063890,000087: 
063891,000088:                                                                                                  #  OUTPUT:               IN ADDITION TO THE ABOVE REGISTER LOADS, ALL UPDATES
063892,000089:                                                                                                  #                        COMPLEMENT BIT3 OF FLAGWORD7.
063893,000090: 
063894,000091:                                                                                                  #  ADDITIONAL NOTES:     VERB 71, JUST DEFINED ABOVE WILL BE USED TO PERFORM BUT NOT LIMITED TO THE FOLLOWING UPDATES --
063895,000092:                                                                                                  #                        1. CSM/LM STATE VECTOR UPDATE
063896,000093:                                                                                                  #                        2. REFSMMAT UPDATE
063897,000094: 
063898,000095: 
063899,000096:                                                                                                  #        THE FOLLOWING COMMENTS DELINEATE EACH SPECIAL UPDATE----
063900,000097: 
063901,000098:                                                                                                  #  1. CSM/LM STATE VECTOR UPDATE (ALL DATA ENTRIES IN OCTAL)
063902,000099: 
063903,000100:                                                                                                  #  ENTRIES:      DATA DEFINITION:                                SCALE FACTORS:
063904,000101:                                                                                                  #  V71E          CONTIGUOUS BLOCK UPDATE VERB
063905,000102:                                                                                                  #     21E        NUMBER OF COMPONENTS FOR STATE VECTOR UPDATE
063906,000103:                                                                                                  #   AAAAE        ECADR OF 'UPSVFLAG'
063907,000104:                                                                                                  #  XXXXXE        STATE VECTOR IDENTIFIER: 00001 FOR CSM, 77776 FOR LEM - EARTH SPHERE OF INFLUENCE SCALING
063908,000105:                                                                                                  #                                         00002 FOR CSM, 77775 FOR LEM - LUNAR SPHERE OF INFLUENCE SCALING
063909,000106:                                                                                                  #  XXXXXEXXXXXE  X POSITION
063910,000107:                                                                                                  #  XXXXXEXXXXXE  Y POSITION
063911,000108:                                                                                                  #  XXXXXEXXXXXE  Z POSITION
063912,000109:                                                                                                  #  XXXXXEXXXXXE  X VELOCITY
063913,000110:                                                                                                  #  XXXXXEXXXXXE  Y VELOCITY
063914,000111:                                                                                                  #  XXXXXEXXXXXE  Z VELOCITY
063915,000112:                                                                                                  #  XXXXXEXXXXXE  TIME FROM AGC CLOCK ZERO
063916,000113:                                                                                                  #  V33E          VERB 33 TO SIGNAL THAT THE STATE VECTOR IS READY TO BE STORED.
063917,000114: 
063918,000115: 
063919,000116:                                                                                                  #  2. REFSMMAT (ALL DATA ENTRIES IN OCTAL)
063920,000117:                                                                                                  #  ENTRIES:      DATA DEFINITIONS:                               SCALE FACTORS:

Page 1492

063922,000119:                                                                                                  #  V71E          CONTIGUOUS BLOCK UPDATE VERB
063923,000120:                                                                                                  #     24E        NUMBER OF COMPONENTS FOR REFSMMAT UPDATE
063924,000121:                                                                                                  #   AAAAE        ECADR OF 'REFSMMAT'
063925,000122:                                                                                                  #  XXXXXEXXXXXE  ROW 1 COLUMN 1                                  2(-1)
063926,000123:                                                                                                  #  XXXXXEXXXXXE  ROW 1 COLUMN 2                                  2(-1)
063927,000124:                                                                                                  #  XXXXXEXXXXXE  ROW 1 COLUMN 3                                  2(-1)
063928,000125:                                                                                                  #  XXXXXEXXXXXE  ROW 2 COLUMN 1                                  2(-1)
063929,000126:                                                                                                  #  XXXXXEXXXXXE  ROW 2 COLUMN 2                                  2(-1)
063930,000127:                                                                                                  #  XXXXXEXXXXXE  ROW 2 COLUMN 3                                  2(-1)
063931,000128:                                                                                                  #  XXXXXEXXXXXE  ROW 3 COLUMN 1                                  2(-1)
063932,000129:                                                                                                  #  XXXXXEXXXXXE  ROW 3 COLUMN 2                                  2(-1)
063933,000130:                                                                                                  #  XXXXXEXXXXXE  ROW 3 COLUMN 3                                  2(-1)
063934,000131:                                                                                                  #  V33E          VERB 33 TO SIGNAL THAT REFSMMAT IS READY TO BE STORED.
063935,000132: 
063936,000133: 43,2000                                           SETLOC   EXTVERBS                              
063937,000134: 43,2000                                           BANK                                           
063938,000135: 
063939,000136: 43,3656  E3,1706                                  EBANK=   TEPHEM                                
063940,000137: 
063941,000138: 43,3656                                           COUNT*   $$/P27                                
063942,000139: 43,3656           34772        V70UPDAT           CAF      UP70                                  #  COMES HERE ON V70E
063943,000140: 43,3657           13665                           TCF      V73UPDAT   +1                         
063944,000141: 
063945,000142: 43,3660           34770        V71UPDAT           CAF      UP71                                  #  COMES HERE ON V71E
063946,000143: 43,3661           13665                           TCF      V73UPDAT   +1                         
063947,000144: 
063948,000145: 43,3662           34767        V72UPDAT           CAF      UP72                                  #  COMES HERE ON V72E
063949,000146: 43,3663           13665                           TCF      V73UPDAT   +1                         
063950,000147: 
063951,000148: 43,3664           36214        V73UPDAT           CAF      UP73                                  #  COMES HERE ON V73E
063952,000149: 
063953,000150: 43,3665           54331                 +1        TS       UPVERBSV                              #  SAVE UPVERB UNTIL IT'S OK TO ENTER P27
063954,000151: 
063955,000152: 43,3666           02076                           TC       TESTXACT                              #  GRAB DISPLAY IF AVAILABLE, OTHERWISE
063956,000153:                                                                                                  #  TURN *OPERATOR ERROR* ON AND TERMINATE JOB
063957,000154: 
063958,000155: 43,3667           31214                           CA       MODREG                                #  CHECK IF UPDATE ALLOWED
063959,000156: 43,3670           00006                           EXTEND                                         #  FIRST CHECK FOR MODREG = +0, -0
063960,000157: 43,3671           13707                           BZF      UPDATEOK                              #  FRESH START OR P00
063961,000158: 43,3672           40104                           CS       FLAGWRD8                              
063962,000159: 43,3673           74760                           MASK     UTBIT                                 
063963,000160: 43,3674           10000                           CCS      A                                     
063964,000161: 43,3675           13702                           TCF      +5                                    
063965,000162: 
063966,000163: 43,3676           41214                           CS       MODREG                                
063967,000164: 43,3677           64124                           AD       OCT24                                 

Page 1493

063969,000166: 43,3700           00006                           EXTEND                                         
063970,000167: 43,3701           13707                           BZF      UPDATEOK                              
063971,000168: 
063972,000169: 43,3702           44767                           CS       TWO                                   
063973,000170: 43,3703           71214                           MASK     MODREG                                
063974,000171: 43,3704           00006                           EXTEND                                         
063975,000172: 43,3705           13707                           BZF      +2                                    #  P02
063976,000173: 43,3706           13717                           TCF      UPERROR                               
063977,000174: 43,3707           31214        UPDATEOK           CAE      MODREG                                #  UPDATE ALLOWED.
063978,000175: 43,3710           54301                           TS       UPOLDMOD                              #  SAVE CURRENT MAJOR MODE
063979,000176: 
063980,000177: 43,3711           30331                           CAE      UPVERBSV                              #  SET UPVERB TO INDICATE TO P27
063981,000178: 43,3712           54302                           TS       UPVERB                                #  WHICH EXTENDED VERB CALLED IT.
063982,000179: 
063983,000180: 43,3713           34770                           CAF      ONE                                   
063984,000181: 43,3714           54303                           TS       UPCOUNT                               #  INITIALIZE UPCOUNT TO 1
063985,000182: 
063986,000183: 43,3715           04655                           TC       POSTJUMP                              #  LEAVE EXTENDED VERB BANK AND
063987,000184: 43,3716           65626                           CADR     UPPART2                               #  GO TO UPDATE PROGRAM (P27) BANK.
063988,000185: 
063989,000186: 43,3717           04362        UPERROR            TC       FALTON                                #  TURN ON OP. ERROR
063990,000187: 43,3720           04415                           TC       UPACTOFF                              #  TURN OFF UPLINK ACT LITE
063991,000188: 43,3721           15524                           TCF      ENDEXT                                #  (RESTART GROUP NOT ESTABLISHED YET)
063992,000189: 
063993,000190: 43,3722     4772               UP70               EQUALS   ZERO                                  
063994,000191: 43,3722     4770               UP71               EQUALS   ONE                                   
063995,000192: 43,3722     4767               UP72               EQUALS   TWO                                   
063996,000193: 43,3722     6214               UP73               EQUALS   THREE                                 
063997,000194: 
063998,000195: 42,2000                                           SETLOC   UPDATE3                               
063999,000196: 42,2000                                           BANK                                           
064000,000197: 
064001,000198: 42,3626                                           COUNT*   $$/P27                                
064002,000199: 
064003,000200: 42,3626                        UPPART2            EQUALS                                         #  UPDATE PROGRAM - PART 2
064004,000201: 
064005,000202: 42,3626           05402                           TC       PHASCHNG                              #  SET RESTART GROUP 6 TO RESTORE OLD MODE
064006,000203: 42,3627           07026                           OCT      07026                                 #  AND DOWNLIST AND EXIT IF RESTART OCCURS.
064007,000204: 42,3630           30000                           OCT      30000                                 #  PRIORITY SAME AS CHRPRIO
064008,000205: 42,3631     0304                                  EBANK=   UPBUFF                                
064009,000206: 42,3631           03706 56100                     2CADR    UPOUT      +1                         
064010,000207: 
064011,000208: 42,3633           34770                           CAF      ONE                                   
064012,000209: 42,3634           54332                           TS       DNLSTCOD                              #  DOWNLIST
064013,000210: 
064014,000211: 42,3635           05344                           TC       NEWMODEX                              #  SET MAJOR MODE = 27
064015,000212: 42,3636           00033                           DEC      27         B-14                       

Page 1494

064017,000214: 
064018,000215: 42,3637           50302                           INDEX    UPVERB                                #  BRANCH DEPENDING ON WHETHER THE UPDATE
064019,000216: 42,3640           13641                           TCF      +1                                    #  VERB REQUIRES A FIXED OR VARIABLE NUMBER
064020,000217: 42,3641           13644                           TCF      +3                                    #  V70 FIXED.               (OF COMPONENTS.
064021,000218: 42,3642           13647                           TCF      OHWELL1                               #  V71 VARIABLE - GO GET NO. OF COMPONENTS
064022,000219: 42,3643           13647                           TCF      OHWELL1                               #  V72 VARIABLE - GO GET NO. OF COMPONENTS
064023,000220: 42,3644           34767                           CA       TWO                                   #  V73 (AND V70) FIXED
064024,000221: 42,3645           54300                           TS       COMPNUMB                              #  SET NUMBER OF COMPONENTS TO 2.
064025,000222: 42,3646           13672                           TCF      OHWELL2                               #  GO GET THE TWO UPDATE COMPONENTS
064026,000223: 
064027,000224: 42,3647           33744        OHWELL1            CAF      ADUPBUFF                              #  * REQUEST USER TO SEND NUMBER  *
064028,000225: 42,3650           54156                           TS       MPAC       +2                         #  * OF COMPONENTS PARAMETER(II). *
064029,000226: 42,3651           33746                 +2        CAF      UPLOADNV                              #  (CK4V32 RETURNS HERE IF V32 ENCOUNTERED)
064030,000227: 42,3652           04636                           TC       BANKCALL                              #  DISPLAY A FLASHING V21N01
064031,000228: 42,3653           20576                           CADR     GOXDSPF                               #  TO REQUEST II.
064032,000229: 42,3654           13733                           TCF      UPOUT4                                #  V34 TERMINATE UPDATE (P27) RETURN
064033,000230: 42,3655           13651                           TCF      OHWELL1    +2                         
064034,000231: 42,3656           03735                           TC       CK4V32                                #  DATA OR V32 RETURN
064035,000232: 42,3657           44767                           CS       BIT2                                  
064036,000233: 42,3660           60304                           AD       UPBUFF                                #  IS II (NUMBER OF COMPONENTS PARAMETER)
064037,000234: 42,3661           00006                           EXTEND                                         #  .GE. 3 AND .LE. 20D.
064038,000235: 42,3662           63651                           BZMF     OHWELL1    +2                         
064039,000236: 42,3663           40304                           CS       UPBUFF                                
064040,000237: 42,3664           64353                           AD       UP21                                  
064041,000238: 42,3665           00006                           EXTEND                                         
064042,000239: 42,3666           63651                           BZMF     OHWELL1    +2                         
064043,000240: 42,3667           30304                           CAE      UPBUFF                                
064044,000241: 42,3670           54300                           TS       COMPNUMB                              #  SAVE II IN COMPNUMB
064045,000242: 
064046,000243:                                                                                                  #  UPBUFF LOADING SEQUENCE
064047,000244: 
064048,000245: 42,3671           24303                 -1        INCR     UPCOUNT                               #  INCREMENT COUNT OF COMPONENTS RECEIVED
064049,000246: 42,3672           33745        OHWELL2            CAF      ADUPBFM1                              #  CALCULATE LOCATION (ECADR) IN UPBUFF
064050,000247: 42,3673           60303                           AD       UPCOUNT                               #  WHERE NEXT COMPONENT SHOULD BE STORED.
064051,000248: 42,3674           54156                 +2        TS       MPAC       +2                         #  PLACE ECADR INTO R3.
064052,000249: 42,3675           33746                 +3        CAF      UPLOADNV                              #  (CK4V32 RETURNS HERE IF V32 ENCOUNTERED)
064053,000250: 42,3676           04636                           TC       BANKCALL                              #  DISPLAY A FLASHING V21N01
064054,000251: 42,3677           20576                           CADR     GOXDSPF                               #  TO REQUEST DATA.
064055,000252: 42,3700           13733                           TCF      UPOUT4                                #  V34 TERMINATE UPDATE (P27) RETURN.
064056,000253: 42,3701           13675                           TCF      OHWELL2    +3                         #  V33 PROCEED RETURN
064057,000254: 42,3702           03735                           TC       CK4V32                                #  DATA OR V32 RETURN
064058,000255: 42,3703           40303                           CS       UPCOUNT                               #  HAVE WE FINISHED RECEIVING ALL
064059,000256: 42,3704           60300                           AD       COMPNUMB                              #  THE DATA WE EXPECTED.
064060,000257: 42,3705           00006                           EXTEND                                         
064061,000258: 42,3706           63710                           BZMF     UPVERIFY                              #  YES - GO TO VERIFICATION SEQUENCE
064062,000259: 42,3707           13671                           TCF      OHWELL2    -1                         #  NO - REQUEST ADDITIONAL DATA.
064063,000260: 
064064,000261:                                                                                                  #  VERIFY SEQUENCE

Page 1495

064066,000263: 42,3710           33743        UPVERIFY           CAF      ADUPTEMP                              #  PLACE ECADR WHERE COMPONENT NO. INDEX
064067,000264: 42,3711           54156                           TS       MPAC       +2                         #  IS TO BE STORED INTO R3.
064068,000265: 42,3712           33747                           CAF      UPVRFYNV                              #  (CK4V32 RETURNS HERE IF V32 ENCOUNTERED)
064069,000266: 42,3713           04636                           TC       BANKCALL                              #  DISPLAY A FLASHING V21N02 TO REQUEST
064070,000267: 42,3714           20576                           CADR     GOXDSPF                               #  DATA CORRECTION OR VERIFICATION.
064071,000268: 42,3715           13733                           TCF      UPOUT4                                #  V34 TERMINATE UPDATE(P27) RETURN
064072,000269: 42,3716           13750                           TCF      UPSTORE                               #  V33 DATA SENT IS GOOD. GO STORE IT.
064073,000270: 42,3717           03735                           TC       CK4V32                                #  COMPONENT NO. INDEX OR V32 RETURN
064074,000271: 42,3720           30330                           CA       UPTEMP                                #  DOES THE COMPONENT NO. INDEX JUST SENT
064075,000272: 42,3721           00006                           EXTEND                                         #  SPECIFY A LEGAL COMPONENT NUMBER?
064076,000273: 42,3722           63710                           BZMF     UPVERIFY                              #  NO, IT IS NOT POSITIVE NONZERO
064077,000274: 42,3723           40330                           CS       UPTEMP                                
064078,000275: 42,3724           60300                           AD       COMPNUMB                              
064079,000276: 42,3725           64770                           AD       BIT1                                  
064080,000277: 42,3726           00006                           EXTEND                                         
064081,000278: 42,3727           63710                           BZMF     UPVERIFY                              #  NO
064082,000279: 42,3730           33745                           CAF      ADUPBFM1                              #  YES - BASED ON THE COMPONENT NO. INDEX
064083,000280: 42,3731           60330                           AD       UPTEMP                                #  CALCULATE THE ECADR OF LOCATION IN
064084,000281: 42,3732           13674                           TCF      OHWELL2    +2                         #  UPBUFF WHICH USER WANTS TO CHANGE.
064085,000282: 
064086,000283: 42,3733           04655        UPOUT4             TC       POSTJUMP                              #  COMES HERE ON V34 TO TERMINATE UPDATE
064087,000284: 42,3734           57706                           CADR     UPOUT      +1                         
064088,000285: 
064089,000286:                                                                                                  #  CHECK FOR VERB 32 SEQUENCE
064090,000287: 
064091,000288: 42,3735           40154        CK4V32             CS       MPAC                                  #  ON DATA RETURN FROM 'GOXDSPF'
064092,000289: 42,3736           74763                           MASK     BIT6                                  #  ON DATA RETURN FROM "GOXDSP"& THE CON-
064093,000290: 42,3737           10000                           CCS      A                                     #  TENTS OF MPAC = VERB.  SO TEST FOR V32.
064094,000291: 42,3740           00002                           TC       Q                                     #  IT'S NOT A V32, IT'S DATA.  PROCEED.
064095,000292: 42,3741           50002                           INDEX    Q                                     
064096,000293: 42,3742           77771                           TC       0          -6                         #  V32 ENCOUNTERED - GO BACK AND GET DATA
064097,000294: 
064098,000295: 42,3743           00330        ADUPTEMP           ADRES    UPTEMP                                #  ADDRESS OF TEMP STORAGE FOR CORRECTIONS
064099,000296: 42,3744           00304        ADUPBUFF           ADRES    UPBUFF                                #  ADDRESS OF UPDATE DATA STORAGE BUFFER
064100,000297: 42,3745           00303        ADUPBFM1           ADRES    UPBUFF     -1                         #  SAME AS ADUPBUFF BUT LESS ONE
064101,000298: 42,3746           05201        UPLOADNV           VN       2101                                  #  VERB 21 NOUN 01
064102,000299: 42,3747           05202        UPVRFYNV           VN       2102                                  #  VERB 21 NOUN 02
064103,000300: 42,3750     4353               UP21               =        MD1                                   #  DEC 21 = MAX NO OF COMPONENTS +1
064104,000301: 42,3750     4773               UPDTPHAS           EQUALS   FIVE                                  
064105,000302: 
064106,000303:                                                                                                  #  PRE-STORE AND FAN TO APPROPRIATE BRANCH SEQUENCE
064107,000304: 
064108,000305: 42,3750                        UPSTORE            EQUALS                                         #  GROUND HAS VERIFIED UPDATE. STORE DATA.
064109,000306: 
064110,000307: 42,3750           00004                           INHINT                                         
064111,000308: 
064112,000309: 42,3751           30103                           CAE      FLAGWRD7                              #  INVERT VERIFLAG(BIT3 OF FLAGWRD7) TO
064113,000310: 42,3752           56001                           XCH      L                                     #  INDICATE TO THE GROUND(VIA DOWNLINK)
064114,000311: 42,3753           34766                           CAF      VERIFBIT                              #  THAT THE V33 (WHICH THE GROUND SENT TO
064115,000312: 42,3754           00006                           EXTEND                                         #  VERIFY THE UPDATE) HAS BEEN SUCCESSFULLY

Page 1496

064117,000314: 42,3755           06001                           RXOR     LCHAN                                 #  RECEIVED BY THE UPDATE PROGRAM
064118,000315: 42,3756           54103                           TS       FLAGWRD7                              
064119,000316: 
064120,000317: 42,3757           05402                           TC       PHASCHNG                              #  SET RESTART GROUP 6 TO REDO THE UPDATE
064121,000318: 42,3760           04026                           OCT      04026                                 #  DATA STORE IF A RESTART OCCURS.
064122,000319: 42,3761           00004                           INHINT                                         #  (BECAUSE PHASCHNG DID A RELINT)
064123,000320: 
064124,000321: 42,3762           44767                           CS       TWO                                   #  GO TO UPFNDVAC IF INSTALL IS REQUIRED,
064125,000322: 42,3763           60302                           AD       UPVERB                                #  THAT IS, IF IT'S A V70 - V72.
064126,000323: 42,3764           00006                           EXTEND                                         #  GO TO UPEND73 IF IT'S A V73.
064127,000324: 42,3765           63770                           BZMF     UPFNDVAC                              
064128,000325: 
064129,000326: 42,3766           04655                           TC       POSTJUMP                              
064130,000327: 42,3767           57757                           CADR     UPEND73                               
064131,000328: 
064132,000329: 42,3770           34346        UPFNDVAC           CAF      CHRPRIO                               #  (USE EXTENDED VERB PRIORITY)
064133,000330: 42,3771           05135                           TC       FINDVAC                               #  GET VAC AREA FOR 'CALL INTSTALL'
064134,000331: 42,3772  E3,1706                                  EBANK=   TEPHEM                                
064135,000332: 42,3772           03545 56103                     2CADR    UPJOB                                 #  (NOTE: THIS WILL ALSO SET EBANK FOR
064136,000333: 
064137,000334: 42,3774           05205                           TC       ENDOFJOB                              #  'TEPHEM' UPDATE BY V70)
064138,000335: 
064139,000336: 27,2000                                           SETLOC   UPDATE2                               
064140,000337: 27,2000                                           BANK                                           
064141,000338: 
064142,000339: 27,3545                                           COUNT*   $$/P27                                
064143,000340: 27,3545           06006        UPJOB              TC       INTPRET                               #  THIS COULD BE A STATE VECTOR UPDATE--SO
064144,000341: 27,3546           77624                           CALL                                           #  WAIT(PUT JOB TO SLEEP) IF ORBIT INT(OI)
064145,000342: 27,3547           27516                                    INTSTALL                              #  IS IN PROGRESS--OR--GRAB OI AND RETURN
064146,000343:                                                                                                  #  TO UPWAKE IF OI IS NOT IN PROGRESS.
064147,000344: 
064148,000345: 27,3550           77776        UPWAKE             EXIT                                           
064149,000346: 
064150,000347: 27,3551           05402                           TC       PHASCHNG                              #  RESTART PROTECT(GROUP 6)
064151,000348: 27,3552           04026                           OCT      04026                                 
064152,000349: 
064153,000350: 27,3553           05547                           TC       UPFLAG                                #  SET INTEGRATION RESTART BIT
064154,000351: 27,3554           00230                           ADRES    REINTFLG                              
064155,000352: 27,3555           00004                           INHINT                                         
064156,000353: 27,3556                        UPPART3            EQUALS                                         
064157,000354: 
064158,000355: 27,3556           50302                           INDEX    UPVERB                                #  BRANCH TO THE APPROPRIATE UPDATE VERB
064159,000356: 27,3557           13560                           TCF      +1                                    #  ROUTINE TO ACTUALLY PERFORM THE UPDATE
064160,000357: 27,3560           13722                           TCF      UPEND70                               #  V70
064161,000358: 27,3561           13626                           TCF      UPEND71                               #  V71
064162,000359: 27,3562           13660                           TCF      UPEND72                               #  V72
064163,000360: 
064164,000361:                                                                                                  #  ROUTINE TO INCREMENT CLOCK (TIME2,TIME1) WITH CONTENTS OF DP WORD AT UPBUFF.

Page 1497

064166,000363: 27,3563           00006        TIMEDIDL           EXTEND                                         
064167,000364: 27,3564           22330                           QXCH     UPTEMP                                #  SAVE Q FOR RETURN
064168,000365: 27,3565           34772                           CAF      ZERO                                  #  ZERO AND SAVE TIME2,TIME1
064169,000366: 27,3566           22007                           ZL                                             
064170,000367: 27,3567           52025                           DXCH     TIME2                                 
064171,000368: 27,3570           52327                           DXCH     UPBUFF     +18D                       #  STORE IN CASE OF OVERFLOW
064172,000369: 
064173,000370: 27,3571           34773                           CAF      UPDTPHAS                              #  DO
064174,000371: 27,3572           54001                           TS       L                                     #  A
064175,000372: 27,3573           40000                           COM                                            #  QUICK
064176,000373: 27,3574           53170                           DXCH     -PHASE6                               #  PHASCHNG
064177,000374: 
064178,000375: 27,3575  01,2330               6P5SPT1            =        6.5SPOT                               
064179,000376: 27,3575           00004        TIMEDIDR           INHINT                                         
064180,000377: 27,3576           34772                           CAF      ZERO                                  
064181,000378: 27,3577           22007                           ZL                                             #  PICK UP INCREMENTER(AND ZERO
064182,000379: 27,3600           54156                           TS       MPAC       +2                         #  IT IN CASE OF RESTARTS) AND
064183,000380: 27,3601           52315                           DXCH     UPBUFF     +8D                        #  STORE IT
064184,000381: 27,3602           52155                           DXCH     MPAC                                  #  INTO MPAC FOR TPAGREE.
064185,000382: 
064186,000383: 27,3603           00006                           EXTEND                                         
064187,000384: 27,3604           30327                           DCA      UPBUFF     +18D                       
064188,000385: 27,3605           20155                           DAS      MPAC                                  #  FORM SUM IN MPAC
064189,000386: 27,3606           00006                           EXTEND                                         
064190,000387: 27,3607           13616                           BZF      DELTATOK                              #  TEST FOR OVERFLOW
064191,000388: 27,3610           34772                           CAF      ZERO                                  
064192,000389: 27,3611           52327                           DXCH     UPBUFF     +18D                       #  OVERFLOW, RESTORE OLD VALUE OF CLOCK
064193,000390: 27,3612           20025                           DAS      TIME2                                 #  AND TURN ON OPERATOR ERROR
064194,000391: 
064195,000392: 27,3613           05402                           TC       PHASCHNG                              #  RESTART PROTECT (GROUP 6)
064196,000393: 27,3614           04026                           OCT      04026                                 
064197,000394: 
064198,000395: 27,3615           00330                           TC       UPTEMP                                #  GO TO ERROR EXIT
064199,000396: 
064200,000397: 27,3616           07226        DELTATOK           TC       TPAGREE                               #  FORCE SIGN AGREEMENT
064201,000398: 27,3617           52155                           DXCH     MPAC                                  
064202,000399: 27,3620           20025                           DAS      TIME2                                 #  INCREMENT TIME2,TIME1
064203,000400: 
064204,000401: 27,3621           05402                           TC       PHASCHNG                              #  RESTART PROTECT (GROUP 6)
064205,000402: 27,3622           04026                           OCT      04026                                 
064206,000403: 
064207,000404: 27,3623           00004                           INHINT                                         
064208,000405: 27,3624           50330                           INDEX    UPTEMP                                #  (CODED THIS WAY FOR RESTART PROTECTION)
064209,000406: 27,3625           00001                           TC       1                                     #  NORMAL RETURN
064210,000407: 
064211,000408:                                                                                                  #  VERB 71 BRANCH
064212,000409: 
064213,000410: 27,3626           30305        UPEND71            CAE      UPBUFF     +1                         #  SET EBANK
064214,000411: 27,3627           54003                           TS       EBANK                                 #     AND
064215,000412: 27,3630           74350                           MASK     LOW8                                  #  CALCULATE

Page 1498

064217,000414: 27,3631           54330                           TS       UPTEMP                                #  S-REG VALUE OF RECEIVING AREA
064218,000415: 
064219,000416: 27,3632           67700                           AD       NEG3                                  #  IN THE PROCESS OF
064220,000417: 27,3633           60300                           AD       COMPNUMB                              #  PERFORMING
064221,000418: 27,3634           00006                           EXTEND                                         #  THIS UPDATE
064222,000419: 27,3635           13643                           BZF      STORLP71                              #  WILL WE
064223,000420: 27,3636           74760                           MASK     BIT9                                  #  OVERFLOW
064224,000421: 27,3637           10000                           CCS      A                                     #  INTO THE NEXT EBANK....
064225,000422: 27,3640           13656                           TCF      UPERROUT                              #  YES
064226,000423: 
064227,000424: 27,3641           37700                           CA       NEG3                                  #  NO - CALCULATE NUMBER OF
064228,000425: 27,3642           60300                           AD       COMPNUMB                              #  WORDS TO BE STORED MINUS ONE
064229,000426: 27,3643           54154        STORLP71           TS       MPAC                                  #  SAVE NO. OF WORDS REMAINING MINUS ONE
064230,000427: 27,3644           50000                           INDEX    A                                     #  TAKE NEXT UPDATE WORD FROM
064231,000428: 27,3645           30306                           CA       UPBUFF     +2                         #  UPBUFF AND
064232,000429: 27,3646           54001                           TS       L                                     #  SAVE IT IN L
064233,000430: 27,3647           30154                           CA       MPAC                                  #  CALCULATE NEXT
064234,000431: 27,3650           60330                           AD       UPTEMP                                #  RECEIVING ADDRESS
064235,000432: 27,3651           50000                           INDEX    A                                     
064236,000433: 27,3652  E3,1400                                  EBANK=   1400                                  
064237,000434: 27,3652           23400                           LXCH     1400                                  #  UPDATE THE REGISTER BY CONTENTS OF L
064238,000435: 27,3653  E3,1706                                  EBANK=   TEPHEM                                
064239,000436: 27,3653           10154                           CCS      MPAC                                  #  ARE THERE ANY WORDS LEFT TO BE STORED
064240,000437: 27,3654           13643                           TCF      STORLP71                              #  YES
064241,000438: 27,3655           13705                           TCF      UPOUT                                 #  NO - THEN EXIT UPDATE PROGRAM
064242,000439: 27,3656           04362        UPERROUT           TC       FALTON                                #  TURN ON OP ERROR, CCS CANT GET HERE
064243,000440: 27,3657           13705                           TCF      UPOUT                                 #  NO - EXIT UPDATE (HERE WHEN COMPNUMB = 3)
064244,000441: 
064245,000442:                                                                                                  #  VERB 72 BRANCH
064246,000443: 
064247,000444: 27,3660           34770        UPEND72            CAF      BIT1                                  #  HAVE AN ODD NO. OF COMPONENTS
064248,000445: 27,3661           70300                           MASK     COMPNUMB                              #  BEEN SENT FOR A V72 UPDATE...
064249,000446: 27,3662           10000                           CCS      A                                     
064250,000447: 27,3663           13665                           TCF      +2                                    #  YES
064251,000448: 27,3664           13656                           TCF      UPERROUT                              #  ERROR - SHOULD BE ODD NO. OF COMPONENTS
064252,000449: 27,3665           44767                           CS       BIT2                                  
064253,000450: 27,3666           60300                           AD       COMPNUMB                              
064254,000451: 27,3667           54154        LDLOOP72           TS       MPAC                                  #  NOW PERFORM THE UPDATE
064255,000452: 27,3670           50000                           INDEX    A                                     
064256,000453: 27,3671           30305                           CAE      UPBUFF     +1                         #  PICK UP NEXT UPDATE WORD
064257,000454: 27,3672           22000                           LXCH     A                                     
064258,000455: 27,3673           10154                           CCS      MPAC                                  #  SET POINTER TO ECADR (MUST BE CCS)
064259,000456: 27,3674           54154                           TS       MPAC                                  
064260,000457: 27,3675           50000                           INDEX    A                                     
064261,000458: 27,3676           30305                           CAE      UPBUFF     +1                         #  PICK UP NEXT ECADR OF REG TO BE UPDATED
064262,000459: 27,3677           54003                           TS       EBANK                                 #  SET EBANK
064263,000460: 27,3700           74350                           MASK     LOW8                                  #  ISOLATE RELATIVE ADDRESS
064264,000461: 27,3701           50000                           INDEX    A                                     
064265,000462: 27,3702  E3,1400                                  EBANK=   1400                                  

Page 1499

064267,000464: 27,3702           23400                           LXCH     1400                                  #  UPDATE THE REGISTER BY CONTENTS OF L
064268,000465: 27,3703  E3,1706                                  EBANK=   TEPHEM                                
064269,000466: 27,3703           10154                           CCS      MPAC                                  #  ARE WE THROUGH THE V72 UPDATE...
064270,000467: 27,3704           13667                           TCF      LDLOOP72                              #  NO
064271,000468: 
064272,000469:                                                                                                  #  NORMAL FINISH OF P27
064273,000470: 
064274,000471: 27,3705                        UPOUT              EQUALS                                         
064275,000472: 27,3705           03072                           TC       INTWAKEU                              #  RELEASE  GRAB  OF ORBITAL INTEGRATION
064276,000473: 27,3706           30301                 +1        CAE      UPOLDMOD                              #  RESTORE PRIOR P27 MODE
064277,000474: 27,3707           05347                           TC       NEWMODEA                              
064278,000475: 27,3710           44770                           CS       BIT1                                  
064279,000476: 27,3711           61214                           AD       MODREG                                
064280,000477: 27,3712           10000                           CCS      A                                     
064281,000478: 27,3713           10000                           CCS      A                                     
064282,000479: 27,3714           34767                           CAF      TWO                                   
064283,000480: 27,3715           54332                           TS       DNLSTCOD                              
064284,000481: 27,3716           04415                           TC       UPACTOFF                              #  TURN OFF 'UPLINK ACTIVITY' LIGHT
064285,000482: 27,3717           04636                           TC       BANKCALL                              #  KILL GROUP 6
064286,000483: 27,3720           12556                           CADR     UPKLEAN                               
064287,000484: 
064288,000485: 27,3721           05524                           TC       ENDEXT                                #  EXTENDED VERB EXIT
064289,000486: 
064290,000487:                                                                                                  #  VERB 70 BRANCH
064291,000488: 
064292,000489: 27,3722           00006        UPEND70            EXTEND                                         #  V70 DOES THE FOLLOWING WITH DP DELTA
064293,000490: 27,3723           40305                           DCS      UPBUFF                                #  TIME IN UPBUFF
064294,000491: 27,3724           52315                           DXCH     UPBUFF     +8D                        
064295,000492: 27,3725           03563                           TC       TIMEDIDL                              #  DECREMENT AGC CLOCK
064296,000493: 
064297,000494: 27,3726           03656                           TC       UPERROUT                              #  ERROR WHILE DECREMENTING CLOCK -- EXIT
064298,000495: 
064299,000496: 27,3727  E3,1706                                  EBANK=   TEPHEM                                
064300,000497: 27,3727           00006                           EXTEND                                         
064301,000498: 27,3730           40305                           DCS      UPBUFF                                #  COPY DECREMENTERS FOR
064302,000499: 27,3731           52317                           DXCH     UPBUFF     +10D                       #  RESTART PROTECTION
064303,000500: 27,3732           00006                           EXTEND                                         
064304,000501: 27,3733           40305                           DCS      UPBUFF                                
064305,000502: 27,3734           52321                           DXCH     UPBUFF     +12D                       
064306,000503: 
064307,000504: 27,3735           05402                           TC       PHASCHNG                              #  RESTART PROTECT (GROUP 6)
064308,000505: 27,3736           04026                           OCT      04026                                 
064309,000506: 
064310,000507: 27,3737           34772                           CAF      ZERO                                  
064311,000508: 27,3740           22007                           ZL                                             
064312,000509: 27,3741           52317                           DXCH     UPBUFF     +10D                       #  DECREMENT CSM STATE VECTOR TIME
064313,000510: 27,3742           21571                           DAS      TETCSM                                
064314,000511: 

Page 1500

064316,000513: 27,3743           34772                           CAF      ZERO                                  
064317,000514: 27,3744           22007                           ZL                                             
064318,000515: 27,3745           52321                           DXCH     UPBUFF     +12D                       #  DECREMENT LEM STATE VECTOR TIME
064319,000516: 27,3746           21643                           DAS      TETLEM                                
064320,000517: 
064321,000518: 27,3747           34772                           CAF      ZERO                                  
064322,000519: 27,3750           22007                           ZL                                             
064323,000520: 27,3751           52305                           DXCH     UPBUFF                                
064324,000521: 27,3752           21710                           DAS      TEPHEM     +1                         #  INCREMENT TP TEPHEM
064325,000522: 27,3753           27706                           ADS      TEPHEM                                
064326,000523: 
064327,000524: 27,3754           05402                           TC       PHASCHNG                              #  RESTART PROTECT (GROUP 6)
064328,000525: 27,3755           04026                           OCT      04026                                 
064329,000526: 
064330,000527: 27,3756     0304                                  EBANK=   UPBUFF                                
064331,000528: 
064332,000529: 27,3756           03705                           TC       UPOUT                                 #  GO TO STANDARD UPDATE PROGRAM EXIT
064333,000530: 
064334,000531:                                                                                                  #  VERB 73 BRANCH
064335,000532: 
064336,000533: 27,3757           00006        UPEND73            EXTEND                                         
064337,000534: 27,3760           30305                           DCA      UPBUFF                                
064338,000535: 27,3761           52315                           DXCH     UPBUFF     +8D                        
064339,000536: 27,3762           03563                           TC       TIMEDIDL                              
064340,000537: 27,3763           04362                           TC       FALTON                                
064341,000538: 27,3764           03706                           TC       UPOUT      +1                         
064342,000539: 
064343,000540:                                                                                                  #  ERROR SEQUENCE
064344,000541: 
064345,000542: 27,3765  30,2000                                  SBANK=   LOWSUPER                              

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