$CONTROL MAP,CODE,USLINIT                                               00010000
<<IOREM0 -- MODULE 25>>                                                 00015000
<< HP32002C MPE SOURCE C.00.00 >>                                       00020000
<< COPYRIGHT     "(C) COPYRIGHT HEWLETT-PACKARD CO. 1980.           >>  00025000
<<     THIS PROGRAM MAY BE USED WITH ONE COMPUTER SYSTEM AT A       >>  00030000
<<     TIME AND SHALL NOT OTHERWISE BE RECORDED, TRANSMITTED OR     >>  00035000
<<     STORED IN A RETRIEVAL SYSTEM.  COPYING OR OTHER REPRODUCTION >>  00040000
<<     OF THIS PROGRAM EXCEPT FOR ARCHIVAL PURPOSES IS PROHIBITED   >>  00045000
<<     WITHOUT THE PRIOR WRITTEN CONSENT OF HEWLETT-PACKARD COMPANY.>>  00050000
<< **** Note - Dollar Copyright cannot be used with this module *** >>  00055000
                                                                        00060000
$CONTROL PRIVILEGED,UNCALLABLE                                          00065000
$THIRTY                                                                 00070000
$TITLE "IOREM0 - 'REMOTE' HP 2100 DRIVER FOR THE HP 3000"               00075000
BEGIN  << IOREM0 >>                                                     00080000
DEFINE                                                                  00085000
        DISABLE    =    ASSEMBLE(SED 0)#,                               00090000
        ENABLE     =    ASSEMBLE(SED 1)#,                               00095000
        DUPLICATE  =    TOS := S0#,                                     00100000
        IAK        =    ( 1: 1)#,                                       00105000
        ERRBIT     =    (12: 1)#,                                       00110000
        RSTATUS    =    ( 8: 8)#,      <<IOQP:  RETURN STATUS       >>  00115000
        STATUS     =    IOQP(QSTAT).(8:8)#,                             00120000
        PFAILB     =    (11:1)#,                                        00125000
        SBUF       =    IOQP(QFLAG).(3:1)#,                             00130000
        STOPDEFS   =    <<>>#;         <<STOPPER FOR DEFINES        >>  00135000
EQUATE                                                                  00140000
        MSTRCLEAR  =    %100000,       <<PROGRAMMED MASTER RESET    >>  00145000
        CLEAR      =    %040000,       <<RESET INTS,ENABLE INTS     >>  00150000
        NULL       =          0,       <<ZERO,NOTHING,EMPTY, ETC    >>  00155000
        QFUNC      =          6,       <<IOQ:  FUNCTION CODE        >>  00160000
        QMISC      =         3,       <<IOQ: DRIVER STATE FLAGS    >>   00165000
        QPAR1      =          8,       <<IOQ: PARAMETER #1          >>  00170000
        QPAR2      =          9,       <<IOQ: PARAMETER #2          >>  00175000
        QWBCT      =          7,       <<IOQ:  WORD/BYTE COUNT      >>  00180000
        QSTAT      =          10,      <<IOQ: STATUS>>                  00185000
        QFLAG      =           0,      <<IOQ: FLAGS>>                   00190000
        SIOJMP     =    %000000,       <<SIO JUMP COMMAND ORDER     >>  00195000
        SIORES     =    %010000,       <<SIO RETURN RESIDUE COMMAND >>  00200000
        SIOEND     =    %030000,       <<SIO END ORDER              >>  00205000
        SIOENDINT  =    %034000,       <<SIO END AND INTERRUPT ORDER>>  00210000
        SIOCNTRL   =    %040000,       <<SIO CONTROL COMMAND ORDER  >>  00215000
        SIOWRITE   =    %060000,       <<SIO WRITE COMMAND ORDER    >>  00220000
        SIOREAD    =    %070000,       <<SIO READ COMMAND ORDER     >>  00225000
        SIOCMWRT   =    %170000-SIOWRITE,                               00230000
        SIOCMRD    =    %170000-SIOREAD,                                00235000
        SETBANK    =    %014000,        <<SIO SET BANK INSTRUCTION>>    00240000
        COMPLETION =     3,                                             00245000
        WRITE      =     1,                                             00250000
        READ       =     0,                                             00255000
        OPEN       =     2,                                             00260000
        CLOSE      =     3,                                             00265000
        DEVCLOSE   =     4,                                             00270000
        CONTROL    =     28,                                            00275000
        DITSIZE    =          11,       <<DEVICE INFO. TABLE SIZE    >> 00280000
        SIOSIZE    =         20,       <<SIO PROGRAM AREA SIZE>>        00285000
        SIOSIZED2  =   SIOSIZE/2,<<SIO PGM SIZE/2 FOR INITIAL>><<01300>>00290000
        COUNT      =          8,       <<DIT:  CURRENT WORD COUNT   >>  00295000
        DSTAT      =          6,        <<DIT: DEV STATUS>>             00300000
        EROR       =          10,       <<DIT:  ERROR RETRY INFO     >> 00305000
        COND       =          9,       <<UNUSUAL CONDITION FLAG     >>  00310000
        ERROR      =       %400,       <<WORD COUNT MISMATCH-SEND/REC>> 00315000
        ABORTED    =        %33,       <<I/O ABORTED RETURN STATUS  >>  00320000
        BADCNTRL   =        %03,       <<INVALLID CONTROL FUNCTION  >>  00325000
        BADLGTH    =        %03,       <<BAD REQST LGTH>>  <<00.01>>    00330000
        PENDING    =        %10,       <<I/O INNITIATED STATUS      >>  00335000
        PFABORT    =        %63,                                        00340000
        BADBUF     =        %104,                                       00345000
        SIOFAIL    =        %45,       <<BAD RTN FRM STARTIO INTR >>    00350000
        SUCCESSFUL =          1,       <<I/O SUCCESSFULLY COMPLETED >>  00355000
        XFERERR    =        %15,       <<TRANSFER ERROR             >>  00360000
        ENDIO      =          5,       <<END OF I/O REQUEST         >>  00365000
        WCOMP      =        %13,       <<CALL COMPLETOR AFTER INT   >>  00370000
        TLOG       =          7,       <<IOQP-TRANSMISSION LOG      >>  00375000
        READCW     =    %000042,       <<READ READY C.W.            >>  00380000
        WRITECW    =    %000102,       <<WRITE READY C.W.           >>  00385000
        NRDYCW     =    %001002,       <<INTS. ON ONLY              >>  00390000
        RESIDUE    =         11,       <<SIO AREA:  INDEX TO RESIDUE>>  00395000
        SETDEVSTAT =        %10,       <<SET STATUS TO DEVICE STATUS>>  00400000
        SYSDB      =     %1000,                                         00405000
        STOPEQTS   =     000000;       <<STOPPER FOR EQUATES        >>  00410000
                                                                        00415000
$PAGE "IOREM0-DATA AREA-IOQH,DIT,SIO AREA"                              00420000
BYTE ARRAY CONFIG(0:7)=DB:=                                             00425000
      DITSIZE,                                                          00430000
      1,                                                                00435000
      0,                                                                00440000
      0,                                                                00445000
      0,                                                                00450000
      0,                                                                00455000
      SIOSIZED2,0;                                             <<01300>>00460000
<<------------------------------- DIT ------------------------------>>  00465000
ARRAY DITAB(1:DITSIZE)=DB:=                                             00470000
        0,0,0,0,0,0,0,0,0,0,0;                                          00475000
                                                                        00480000
<<----------------------------- SIO PROGRAM STORAGE ---------------->>  00485000
                                                                        00490000
ARRAY  SIOA(1:SIOSIZE)=DB:=                                             00495000
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0;                                        00500000
$PAGE "IOREM0-EXTERNAL DECLARATIONS"                                    00505000
<<---------------------- EXTERNAL PROCEDURE DECLARATIONS ----------->>  00510000
                                                                        00515000
                                                                        00520000
PROCEDURE GIP;                                                          00525000
  OPTION EXTERNAL;                                                      00530000
                                                                        00535000
PROCEDURE HELP;                                                         00540000
  OPTION EXTERNAL;                                                      00545000
                                                                        00550000
LOGICAL PROCEDURE IOMESSAGE(DEST,CATN,P1,P2,P3,P4,DITP,BUF,CONT);       00555000
  VALUE DEST,CATN,P1,P2,P3,P4,DITP,BUF,CONT;                            00560000
  POINTER DITP;                                                         00565000
  INTEGER DEST,CATN,P1,P2,P3,P4,BUF,CONT;                               00570000
  OPTION VARIABLE,EXTERNAL;                                             00575000
                                                                        00580000
PROCEDURE SIODM(DITP,FLAGS);                                            00585000
  VALUE DITP,FLAGS;                                                     00590000
  LOGICAL FLAGS;                                                        00595000
  POINTER DITP;                                                         00600000
  OPTION EXTERNAL;                                                      00605000
                                                                        00610000
                                                                        00615000
PROCEDURE MASTERCLEAR(DITP);                                            00620000
  ARRAY DITP;                                                           00625000
  OPTION EXTERNAL;                                                      00630000
                                                                        00635000
                                                                        00640000
                                                                        00645000
PROCEDURE CHECKINDEX(INDEX,TABLE);                                      00650000
  VALUE INDEX,TABLE;                                                    00655000
  INTEGER INDEX;                                                        00660000
  INTEGER POINTER TABLE;                                                00665000
  OPTION EXTERNAL;                                                      00670000
                                                                        00675000
                                                                        00680000
                                                                        00685000
PROCEDURE STARTIO(DITP,SIOP,QFLAG);                                     00690000
   VALUE DITP,SIOP,QFLAG;                                               00695000
   POINTER DITP,SIOP;                                                   00700000
   LOGICAL QFLAG;                                                       00705000
   OPTION EXTERNAL;                                                     00710000
                                                                        00715000
                                                                        00720000
                                                                        00725000
PROCEDURE IOFAILURE(DRTN,DITP);                                         00730000
   VALUE DRTN;                                                          00735000
   INTEGER DRTN;                                                        00740000
   ARRAY DITP;                                                          00745000
   OPTION EXTERNAL;                                                     00750000
                                                                        00755000
                                                                        00760000
PROCEDURE INITZ(IDITP);                                                 00765000
   INTEGER ARRAY IDITP;                                                 00770000
   BEGIN                                                                00775000
<<  DUMMY    >>                                                         00780000
   END;                                                                 00785000
$PAGE "IOREM0-ENTRY:RESET INT,CHK FOR ABORT,DETERMINE ENTRY TYPE"       00790000
                                                                        00795000
<<-------------------------- DRIVER CODE PROCEDURE ----------------->>  00800000
                                                                        00805000
INTEGER PROCEDURE REMDVR(IOQP,DITP,BANK,BUFADR,SIOP,DRTN);              00810000
  VALUE IOQP,DITP,BANK,BUFADR,SIOP,DRTN;                                00815000
  INTEGER BANK,DRTN,BUFADR;                                             00820000
  INTEGER POINTER IOQP,DITP,SIOP;                                       00825000
                                                                        00830000
                                                                        00835000
  BEGIN                                                                 00840000
                                                                        00845000
    LOGICAL SIOCW;                                                      00850000
    INTEGER RDYCW,MSTATE=REMDVR,                                        00855000
       S0=S-0,                                                          00860000
       S1=S-1,                                                          00865000
       S2=S-2,                                                          00870000
       S3=S-3,                                                          00875000
       S4=S-4,                                                          00880000
       S5=S-5,                                                          00885000
       X=X,                                                             00890000
       FUNC,                                                            00895000
       P1,                                                              00900000
       P2;                                                              00905000
    DOUBLE POINTER DSIOP=SIOP;                                          00910000
    DEFINE SIOPBASE=@SIOP+SYSDB#;                                       00915000
                                                                        00920000
SUBROUTINE SETFLAGS;                                                    00925000
  BEGIN                                                                 00930000
    FUNC:=IOQP(QFUNC);     <<GET FUNCTION CODE>>                        00935000
    P1:=IOQP(QPAR1);       <<GET PARAMETER 1>>                          00940000
    P2:=IOQP(QPAR2);       <<GET PARAMETER 2>>                          00945000
    <<  DETERMINE WORD COUNT     >>                                     00950000
    TOS:=IOQP(QWBCT);                                                   00955000
    IF < THEN                                                           00960000
    BEGIN     <<BYTES CONVERT TO  WORDS>>                               00965000
      TOS:=-TOS&ASR(1);  <<ROUND DOWN >>                                00970000
    END;                                                                00975000
    IF S0 >4096 THEN GO INVALIDLENGTH;                                  00980000
    DITP(COUNT):=TOS;                                                   00985000
    IF SBUF=1 THEN                                                      00990000
    BEGIN     <<BUFFERING NOT ALLOWED>>                                 00995000
      TOS:=BADBUF;                                                      01000000
      GO IODONE;                                                        01005000
    END;                                                                01010000
  END;  <<SETFLAGS>>                                                    01015000
                                                                        01020000
                                                                        01025000
<<  I  N  I  T  I  A  T  O  R    >>                                     01030000
     DISABLE;     <<DISABLE INTERRUPTS>>                                01035000
     TOS:=IOQP;                                                         01040000
     DEL;                                                               01045000
     IF < THEN                                                          01050000
     BEGIN     <<I/O HAS BEEN ABORTED>>                                 01055000
       ENABLE;                                                          01060000
       IF MSTATE = COMPLETION THEN                                      01065000
       MASTERCLEAR(DITP);                                               01070000
       IF IOQP.PFAILB =1 THEN TOS:=PFABORT ELSE TOS:=ABORTED;           01075000
       GO TO IODONE;                                                    01080000
     END;                                                               01085000
     ENABLE;                                                            01090000
     IF MSTATE = COMPLETION THEN GO COMP;                               01095000
     TOS:=DRTN;     <<ENABLE DEV STATUS,CLEAR INTERRUPTS>>              01100000
     TOS:=CLEAR;                                                        01105000
     ASSEMBLE (CIO 1; DEL);                                             01110000
     IF <> THEN                                                         01115000
     BEGIN                                                              01120000
UFAIL:                                                                  01125000
       IOFAILURE(DRTN,DITP);   <<NON RESPONDING DEVICE>>                01130000
      TOS:=%54;                                                         01135000
      TOS:=ENDIO;                                                       01140000
FAIL:                                                                   01145000
      MASTERCLEAR(DITP);                                                01150000
      GO TO OUT;                                                        01155000
    END;                                                                01160000
    SETFLAGS;                                                           01165000
    IF P1.(0:1)=1 THEN HELP;                                            01170000
   IF FUNC=CONTROL THEN                                                 01175000
    BEGIN                              << THIS IS A CONTROL REQ.    >>  01180000
     GO CONTRL;                                                         01185000
    END; DEL;                                                           01190000
   IF FUNC = WRITE THEN                                                 01195000
    BEGIN                              << WRITE REQUEST             >>  01200000
     TOS := SIOCMWRT;                                                   01205000
     TOS := WRITECW;                                                    01210000
    END                                                                 01215000
   ELSE                                                                 01220000
    BEGIN                              << READ REQUEST              >>  01225000
     TOS := SIOCMRD;                                                    01230000
     TOS := READCW;                                                     01235000
    END;                                                                01240000
   RDYCW := TOS;                                                        01245000
   SIOCW := TOS;                                                        01250000
                                                                        01255000
   TOS := DITP(COUNT);                                                  01260000
   IF = THEN GO INVALIDLENGTH;         << LEAVE WORD COUNT ON TOS   >>  01265000
<< SET UP SIO PROGRAM                                               >>  01270000
   TOS := SIOCNTRL;                    << TURN ON RDY BIT           >>  01275000
   TOS := RDYCW;                                                        01280000
   TOS:=TOS LOR LOGICAL(DITP(COND));   <<SET UNUSUAL CONDITION      >>  01285000
   ASSEMBLE(DDUP);                     <<DUPLICATE CONTROL ORDER>>      01290000
   DSIOP(0):=TOS;                                                       01295000
   IF RDYCW = READCW                   <<READ OPERATION>>               01300000
    THEN                               <<CONSTRUCT SPECIAL READ ORDERS>>01305000
     BEGIN                                                              01310000
      TOS:=LOGICAL(-1)-LOGICAL(SIOCW); <<READ ORDER, 1 WORD>>           01315000
      TOS:=SIOPBASE+8;                 <<ADDR OF 2ND READ ORDER>>       01320000
      DSIOP(X:=X+1):=TOS;                                               01325000
      TOS:=SIOENDINT;                  <<END WITH INTERRUPT>>           01330000
      TOS:=0;                          <<SPACE FOR STATUS>>             01335000
      DSIOP(X:=X+1):=TOS;                                               01340000
      DSIOP(X:=X+1):=TOS;              <<REPEAT CONTROL ORDER>>         01345000
     END                                                                01350000
    ELSE                               <<WRITE OPERATION>>              01355000
     BEGIN                                                              01360000
      DDEL;                            <<DELETE EXTRA CONTROL ORDER>>   01365000
      TOS:=SETBANK;                                                     01370000
      TOS:=BANK;                                                        01375000
      DSIOP(X:=X+1):=TOS;                                               01380000
      TOS:=SIOJMP;                     <<JUMP TO WRITE ORDER  >>        01385000
      TOS:=SIOPBASE+8;                 <<JUMP ADDRESS>>                 01390000
      DSIOP(X:=X+1):=TOS;                                               01395000
      X:=X+1;                                                           01400000
     END;                                                               01405000
   TOS := -TOS;  TOS := LOGICAL(TOS) - LOGICAL(SIOCW);                  01410000
   TOS :=BUFADR;                                                        01415000
   DSIOP(X:=X+1):=TOS;                                                  01420000
   TOS := SIORES;                      << RETURN RESIDUE            >>  01425000
   TOS := 0;                                                            01430000
   DSIOP(X:=X+1) := TOS;                                                01435000
   TOS := SIOCNTRL;                    << TURN OFF RDY BIT          >>  01440000
   TOS := NRDYCW;                                                       01445000
   DSIOP(X:=X+1) := TOS;                                                01450000
   TOS := SIOEND;                      <<SIO END--NO INTERRUPT      >>  01455000
   TOS := 0;                                                            01460000
   DSIOP(X:=X+1) := TOS;                                                01465000
<< START SIO PROGRAM                                                >>  01470000
DOIO:                                                                   01475000
   STARTIO(DITP,SIOP,1);                                                01480000
   IF <> THEN GO BADSIO;                                                01485000
   TOS := PENDING;                                                      01490000
   TOS := WCOMP;                                                        01495000
   GO OUT;                                                              01500000
                                                                        01505000
$PAGE "IOREM0-CONTROL REQUEST"                                          01510000
<< CONTROL REQUEST                                                  >>  01515000
CONTRL:                                                                 01520000
   IF IOQP(QPAR1) =1                   <<DYNAMIC STATUS REQST?>>        01525000
    THEN                                                                01530000
     BEGIN                                                              01535000
      TOS:=DRTN;                                                        01540000
      TOS:=SETDEVSTAT;                                                  01545000
      ASSEMBLE(CIO 1);                 <<ENABLE DEVICE STATUS>>         01550000
      ASSEMBLE(TIO 0);                 <<READ DEVICE STATUS>>           01555000
      DITP(DSTAT):=TOS;  <<RETURN STATUS>>                              01560000
      DEL;                                                              01565000
      TOS:=1;                          <<ONE WORD READ>>                01570000
      GO CNTLDONE;                                                      01575000
     END;                                                               01580000
   IF IOQP(QPAR1) =%200 THEN                                            01585000
    DITP(COND):=IOQP(QPAR1);                                            01590000
   TOS:=0;                             <<NO ACTION ON OTHER REQUESTS >> 01595000
   GO CNTLDONE;                                                         01600000
$PAGE "IOREM0-COMPLETION SECT: CHK STATUS & RETURN IOQP"                01605000
COMP:                                                                   01610000
   TOS:=DRTN;                                                           01615000
   ASSEMBLE(TIO 0);                    <<READ INTERRUPT STATUS>>        01620000
   ASSEMBLE(DELB);                                                      01625000
   IF TOS.(13:1) THEN                  <<INITIAL READ INTERRUPT>>       01630000
    BEGIN                                                               01635000
     TOS:=SIOP(8);                     <<GET 2100 WORD COUNT>>          01640000
     DUPLICATE;                                                         01645000
     IF TOS=0 THEN GO UCOUNT;          <<INVALID COUNT >>               01650000
     DUPLICATE;                                                         01655000
     IF TOS = DITP(COUNT)              <<SEND/RECEIVE COUNTS MATCH>>    01660000
      THEN GO RESTRT                                                    01665000
      ELSE                                                              01670000
       BEGIN                                                            01675000
        DUPLICATE;                                                      01680000
        IF TOS > DITP(X)                                                01685000
         THEN                                                           01690000
UCOUNT:                                                                 01695000
          BEGIN                                                         01700000
           DEL;                        <<IGNORE 2100 WORD CNT>>         01705000
           TOS:=DITP(COUNT);           <<USE 3000 WORD COUNT>>          01710000
           SIOP(13):=LOGICAL(SIOP(13)) LOR ERROR;  <<2100 ERROR>>       01715000
          END;                                                          01720000
       END;                                                             01725000
RESTRT:                                                                 01730000
     TOS:=SETBANK;                                                      01735000
     TOS:=BANK;                                                         01740000
     DSIOP(0):=TOS;                                                     01745000
     TOS:=SIOJMP;                                                       01750000
     TOS:=SIOPBASE+6;                                                   01755000
     DSIOP(1):=TOS;                                                     01760000
     SIOP(8):=(-TOS).(4:12) LOR SIOREAD; <<SIO READ - MIN COUNT>>       01765000
     TOS:=DRTN;                                                         01770000
     TOS:=CLEAR;                       <<CLEAR ALL INTERRUPTS>>         01775000
     ASSEMBLE(CIO 1);                                                   01780000
     DEL;                                                               01785000
     STARTIO(DITP,SIOP,1);     <<START SIO OPERATION>>                  01790000
     IF <> THEN GO BADSIO;                                              01795000
     TOS:=PENDING;                                                      01800000
     TOS:=WCOMP;                                                        01805000
     GO OUT;                                                            01810000
    END;                                                                01815000
   TOS := DRTN;                                                         01820000
   TOS := MSTRCLEAR;                                                    01825000
   ASSEMBLE(CIO 1);                                                     01830000
   TOS := CLEAR;                                                        01835000
   ASSEMBLE(CIO 1);                                                     01840000
   DEL;                                                                 01845000
<< DETERMINE NUMBER OF WORDS TRANSFERRED                            >>  01850000
   TOS := SIOP(RESIDUE);                                                01855000
   TOS:=TOS LAND %7777;                <<ISOLATE RESIDUE COUNT >>       01860000
   IF <> THEN TOS:=TOS LOR %170000;    <<RESIDUE NOW 0 OR NEG  >>       01865000
   TOS := -(LOGICAL(SIOP(8).(4:12)) LOR %170000);  << + SIO CNT >>      01870000
   TOS:=TOS+TOS;                       <<SIO WD CNT - RESIDUE  >>       01875000
   IF IOQP(QWBCT) < 0 THEN                                              01880000
     BEGIN                             <<CONVERT TO BYTES           >>  01885000
      TOS := -TOS & ASL(1);             <<00.01>>                       01890000
     END;                                                               01895000
   TOS := DRTN;                                                         01900000
   TOS := SETDEVSTAT;                                                   01905000
   ASSEMBLE(CIO 1);                                                     01910000
   ASSEMBLE(TIO 0);                                                     01915000
   TOS.ERRBIT := 1;                                                     01920000
   ASSEMBLE(DDEL);                                                      01925000
   IF <> THEN                                                           01930000
    BEGIN                                                               01935000
     TOS:=TOS-1;                       <<RESIDUE 1 OFF ON DEVICE END>>  01940000
     GO TRANSERR;                                                       01945000
    END                                                                 01950000
    ELSE GO WELLDONE;                                                   01955000
INVALIDCNTRL:                                                           01960000
   TOS := BADCNTRL;                                                     01965000
   GO IODONE;                                                           01970000
INVALIDLENGTH:                                                          01975000
   IOQP(TLOG):=0;                                                       01980000
   TOS:= BADLGTH;                                                       01985000
   GO IODONE;                                                           01990000
TRANSERR:                                                               01995000
   IOQP(TLOG):=TOS;                                                     02000000
   TOS := XFERERR;                                                      02005000
   GO IODONE;                                                           02010000
BADSIO:                                                                 02015000
   TOS := SIOFAIL;                                                      02020000
   GO IODONE;                                                           02025000
TRYAGAIN:                                                               02030000
   TOS := DRTN;                                                         02035000
   TOS := MSTRCLEAR;                                                    02040000
   ASSEMBLE(CIO 1;DEL);                                                 02045000
   GO DOIO;                                                             02050000
$PAGE "IOREM0-EXITS:  GOOD,BAD, AND INDIFFERENT"                        02055000
WELLDONE:                                                               02060000
   DITP(COND):=0;                      <<RESET CONDITION FLAG>>         02065000
CNTLDONE:                                                               02070000
   IOQP(TLOG) := TOS;                                                   02075000
   TOS := SUCCESSFUL;                                                   02080000
IODONE:                                                                 02085000
   TOS := ENDIO;                                                        02090000
   TOS := DRTN;                                                         02095000
   TOS := MSTRCLEAR;                                                    02100000
   ASSEMBLE(CIO 1);                                                     02105000
   TOS := CLEAR;                                                        02110000
   ASSEMBLE(CIO 1);                                                     02115000
   TOS := NRDYCW;                                                       02120000
   ASSEMBLE(CIO 1);                                                     02125000
   DEL;                                                                 02130000
OUT:                                                                    02135000
   MSTATE:=TOS;                                                         02140000
   STATUS:=TOS;                                                         02145000
END  <<REMDVR >>  ;                                                     02150000
$PAGE "IOREM0-'DUMMY' OUTER BLOCK GIVES CONFIGURATION DATA"             02155000
ASSEMBLE(                                                               02160000
 PCAL SIODM;          <<MONITOR>>                                       02165000
 PCAL REMDVR;         <<INITIATOR>>                                     02170000
 PCAL REMDVR;         <<COMPLETOR>>                                     02175000
 CON 0;               <<NO IO PROCESS>>                                 02180000
 PCAL INITZ;          <<INITIALIZATION>>                                02185000
CON 1;                <<I INTERRUPT HANDLER>>                           02190000
PCAL GIP);            <<INTERRUPT HANDLER>>                             02195000
END  <<IOREM0  >> ;.............................................        02200000
