+1,5 10/20/74 PLS #12238
*
*  THE CONDITIONAL ASSEMBLY FLAGS IN COC ARE CONTROLLED BY 'SET'
*  DIRECTIVES IN A METASYM PROCEDURE SYSTEM CALLED 'ASSEMDEF'.
*
*  1  IF 'ASSEMDEF' DOESN'T CONTAIN A 'SET' FOR A PARTICULAR FLAG,
*     AN ASSEMBLED-IN DEFAULT IS USED.
*  2  IF 'ASSEMDEF' CONTAINS A SET FOR A FLAG, THE VALUE SPECIFIED
*     WILL BE USED.
*     A  TO INCLUDE A PARTICULAR FEATURE, THE CORRESPONDING
*        LABEL SHOULD BE 'SET' TO A 1 (E.G., 2741CODE SET 0).
*     B  TO EXCLUDE A PARTICULAR FEATURE, THE LABEL SHOULD
*        BE 'SET' TO A 0 (E.G., 2741CODE SET 0).
*     C  VALUE-TYPE ASSEMBLY PARAMETERS SHOULD BE 'SET' TO THE
*        DESIRED VALUE (E.G., C:140 SET 200).
*
*  TO ASSEMBLE THE MINI VERSION OF COC (MINICOC):
*MINICOC SET       1
*
*  TO ASSEMBLE THE TRANSACTION PROCESSING VERSION OF COC:
*CNM     SET      1
*
*  THE OTHER COC ASSEMBLY PARAMETERS APPEARING IN THE LABEL
*  FIELD OF THE 'ASSEMCON' PROC CAN BE SET IN A SIMILAR MANNER.
*
         PSYS     1
         SYSTEM   ASSEMDEF
         PSYS     0
*
+40,47 10/20/74 PLS #22375
*  IF THE LABEL FIELD HAS NOT BEEN DEFINED YET, SET IT TO THE VALUE
*  OF THE ARGUMENT FIELD
*
ASSEMCON CNAME
         PROC
         DO1      TCOR(S:FR,LF(1))
LF(1)    SET      AF(1)
         DISP     LF(1)
         PEND
*
CNM      ASSEMCON 0                 GEN TRANSACTION PROCESSING CODE
MINICOC  ASSEMCON 0                 GENERATE SUBSET OF 'NORMAL' COC
RCVRCHK  ASSEMCON 0                 CHECK RECEIVERS DURING COC INIT
COCPCP   ASSEMCON MINICOC=0         GEN PAGE HEADING CODE
2741CODE ASSEMCON MINICOC=0         GEN 2741-HANDLING CODE
C:140    ASSEMCON 140               MAX SIZE FOR READ AND WRITE REQUEST
+53,54 10/20/74 PLS #21089
COCGBUG  ASSEMCON MINICOC=0         GEN CODE FOR GET BUF CHECKING
COCPBUG  ASSEMCON MINICOC=0         GEN CODE FOR PUT BUF CHECKING
+70,74 10/20/74 PLS #22529
COCGBUGE ASSEMCON 0                 EXECUTE GET BUF CHECKING CODE
COCPBUGE ASSEMCON 0                 EXECUTE PUT BUF CHECKING CODE
SECTB    ASSEMCON 0                 SECTION ECHO GO TO'S
2741ARUB ASSEMCON 0                 UPPER-CASE BACKSPACE RUBOUT CODE
+199,200 10/20/74 PLS #21969
*                                   .. INTERRUPT LEVEL
+211,212 10/20/74 PLS #7960
+224 10/20/74 PLS #22407
         REF      MODE4INIT         INITIAL VALUE TABLE FOR MODE4
+262 10/20/74 PLS #23010
         DEF      COCISIO           COCINIT SIO INSTRUCTION ADR
         DEF      COCITIO           INPUT INTERRUPT TIO INST ADR
         DEF      COCSTIO           T:COCHC COC STATUS TIO INST ADR
         DEF      COCRDPND          READ PENDING REPORTING POINT
         DEF      COCSETAC          SET ACTIVATION RECEIVED POINT
+275 10/20/74 PLS #11468
         REF      Y4
+434 10/20/74 PLS #23010
COCITIO  EQU      $
+711,711 10/20/74 PLS #22407
         BE       $+3               BE; CONTIGUOUS BACKSPACE
         CI,R7    BSBS              C/CHAR W/CONTIGUOUS BACKSPACE
*                                   .. 'CHARACTER'
         BNE      COCIP55           BNE; NOT CONTIGUOUS BACKSPACE
+769,769 10/20/74 PLS #22447
         LB,R6    LB:UN,R2          L/USER NUMBER
         SLS,R6   1                 SHIFT; G/BTD TO UH:FLG2 ENTRY
+807,807 10/20/74 PLS #22496
         PUSH     (R7,R10)          PUSH R7 -> R10
+811,813 10/20/74 PLS #23010
+855 10/20/74 PLS #23010
         SPACE    3
COCACK   EQU      $                 PROCESS ESC-Q
         LB,R5    COCOC,R2          L/COCOC; OUTPUT CHARACTER COUNT
         BNEZ     COCIP01           BNEZ; OUTPUT IN PROGRESS, IGNORE
         LI,R5    X'5A'             L/EXCLAMATION POINT CHARACTER
         BAL,R9   COCSEND2          SEND EXCLAMATION POINT CHARACTER
         BAL,R9   COCSEND2          SEND EXCLAMATION POINT CHARACTER
         B        COCIP01           RETURN TO TOP OF INPUT INT PROCESSING
+904,912 10/20/74 PLS #23010
+1314,1314 10/20/74 PLS #23010
         BCR,8    ECHO6C            B/NOT IN ECHOPLEX MODE
+1344 10/20/74 PLS #23010
         BAL,R15  CHKLOGON          SEE IF LOGON IS ASSOCIATED
         BE       ECHO8A            B/LOGON; ALLOW ANY ACTIVATION SET
+1553,1553 10/20/74 PLS #23010
+1630,1630 10/20/74 PLS #23010
         LB,R6    COCBUF,R7         L/TRUE RECORD SIZE (TRSZ)
+1632,1633 10/20/74 PLS #23010
         SW,R6    R11               TRSZ - BSEPOS = MOVEMENT
         AI,R6    -X'80'            -.80
+1640,1646 10/20/84 PLS #23010
         AI,R6    -1                -1 TO -(BS COUNT); EXTRA BS FOR R
ESCR1X   LI,R5    X'20'             L/LINE-FEED-ONLY CHARACTER
         BAL,R9   COCSEND1          SEND LINE FEED CHARACTER
         BAL,R15  ECHOCR2           INC LINES UPSPACED
         LI,R5    BS                L/BACKSPACE CHARACTER
ESCRADJ  AW,R3    R6                +TRSZ OR BSEPOS; ADJUST CPOS
         LAW,R6   R6                MAKE SURE MOVEMENT COUNT POSITIVE
         BAL,R9   COCSEND1          ADJUST CARRIAGE POSITION; SEND
         BDR,R6   COCSEND1          .. BACKSPACES OR BLANKS
+1810 10/20/74 PLS #23010
COCSETAC EQU      $
         LB,R6    LB:UN,R2          L/USER NUMBER
         LH,R6    UH:FLG,R6         L/UH:FLG
         STB,R6   R15               S/BITS 8-15 OF UH:FLG IN R15
         LB,R6    MODE2,R2          L/MODE2; BREAK SET
         AI,R6    1                 INC BREAK SET (ACTIVATION CHAR SET)
         CI,R6    3                 C/ACTIV SET W/3
         BANZ     $+2               BANZ; NOT ACTIV SET 3
         OR,R15   Y4                SET DELTA-IN-CONTROL FOR SET 3
         INT,R15  R15               BITS 0-3 TO CC'S, 16-31 TO 16-31
         B        *R15              RETURN
+2061,2061 10/20/74 PLS #23318
+2588 10/20/74 PLS #23010
COCRDPND EQU      $
+2918,2918 10/20/74 PLS #23010
+2940,2940 10/20/74 PLS #23010
         BNE      COCWR33           B/NOT TOP OF FORM CHARACTER
         LI,R3    JB:LPP            L/BA OF LINES/PAGE IN JIT
         LB,R12   0,R3              L/# OF LINES PER PAGE
         BEZ      COCWR33           BEZ; NO PAGE HEADINGS OR UPSPACES
         CI,R12   11                C/LINES/PAGE W/11
         BG       COCWRFF           BG; GIVE PAGE HEADING
         BAL,R9   COCNL             SEND CR/LF TO UPSPACE PAGE
         BDR,R12  COCNL             BDR # OF LINES/PAGE
         B        COCWR70           B; CONTINUE PROCESSING OF WRITE
COCWR33  EQU      $
+3101,3101 10/20/74 PLS #23010
+3302,3302 10/20/74 PLS #23010
         SB       SENDBSBS          BS-BS (CONTIGUOUS BACKSPACE)
+3335,3335 10/20/74 PLS #23010
         AI,R5    4                 FOR CHANGING 8B TO 2B (BS)
SENDBSBS EQU      $
         AI,R5    -X'64'            FOR CHANGING 8F TO 2B (BS-BS)
+3690,3690 10/20/74 PLS #23010
+3692,3692 10/20/74 PLS #23010
+3768,3772 10/20/74 PLS #23010
+4195 10/20/74 PLS #23010
COCSTIO  EQU      $
+4286,4286 10/20/74 PLS #11468
         LB,R6    COCOC,R7          L/COCOC; OUTPUT CHARACTER COUNT
+4431,4437 10/20/74 PLS #23010
*  EXECUTE AN SIO TO THE COC HARDWARE.  IF THE COC IS UNSTARTABLE
*     (E.G., NO ADDRESS RECOGNITION) AND THE DEVICE IS NOT
*     PARTITIONED, AN ERROR MESSAGE IS ISSUED TO THE OPERATOR'S
*     CONSOLE.
+4447,4448 10/20/74 PLS #23010
*  IF THE COC IS BEING SUCCESSFULLY STARTED, TRANSMIT A BELL
*     CHARACTER TO EACH LINE ON THAT COC.
+4452 10/20/74 PLS #23010
*
*  NOTE:
*  A  T:COCHC DETECTS CHANGES IN THE STATUS OF THE COC HARDWARE VIA
*     TIO CONDITION CODES, AND CALLS COCINIT WHENEVER ONE OF THE
*     FOLLOWING IS TRUE:
*     1  THERE IS ADDRESS RECOGNITION BUT THE COC IS NOT BUSY (E.G.,
*        IO RESET HAS BEEN HIT OR A COC HAS BEEN PLACED ONLINE).
*     2  THERE IS NO ADDRESS RECOGNITION BUT THE LAST SAVED SIO CC'S
*        INDICATE THAT THERE PREVIOUSLY WAS ADDRESS RECOGNITION
*        (E.G., THE COC HAS BEEN TAKEN OFFLINE).
*  B  WHEN COCINIT IS CALLED, IT WILL ATTEMPT TO START ALL COCS,
*     AND WILL ADJUST THE INTERRUPT LOCATIONS AND LEVEL SELECT BITS
*     TO REFLECT THE LATEST HARDWARE STATUS.
+4477,4478 10/20/74 PLS #23010
+4480 10/20/74 PLS #23010
COCISIO  EQU      $
+4483 10/20/74 PLS #23010
         AI,R5    0                 CHECK FOR NEGATIVE DEVICE ADR
         BLZ      INIT300           B/NEGATIVE; DEVICE IS PARTITIONED
+4508 10/20/74 PLS #23010
         LCH,R0   COH:RBS,R3        L/COMPLEMENT OF RING BUFFER SIZE
         STW,R0   CO:LST,R3         S/RING BUFFER POINTER
+4538,4538 10/20/74 PLS #23010
+4542,4542 10/20/74 PLS #23010
         AI,R6    BELL**8           +BELL TO LINE #
+END
