Google
 

Trailing-Edge - PDP-10 Archives - BB-R598A-RM_1983 - swskit-v3/listings/vnp36/vfio20.list
There are no other files named vfio20.list in the archive.
 Robinson, CREATION DATE: 25-NOV-78
!
! MODI								25-Jan-1983 10:15:27	TOPS-20 Bliss-36 2A(142)	    Page   1
								 1-Jan-1983 15:44:34	NETPKG:<VNP36>VFIO20.BLI.7 (1)

;	  0001	!<DECNET20-V3P0.TKB-VNP.VNPV3>FIO20.BLI.2, 11-Jul-80 07:07:45, Edit by SROBINSON
;	  0002	!<REL4A.TKB-VNP>FIO20.BLI.8,  3-Dec-79 14:30:05, Edit by SROBINSON
;	  0003	MODULE FIO20 (					!File I/O for TOPS-20
;	  0004			IDENT = 'X2.0-1'
;	  0005			) =
;	  0006	BEGIN
;	  0007	!
;	  0008	!                    COPYRIGHT (c) 1980, 1981, 1982
;	  0009	!                    DIGITAL EQUIPMENT CORPORATION
;	  0010	!                        Maynard, Massachusetts
;	  0011	!
;	  0012	!     This software is furnished under a license and may  be  used
;	  0013	!     and copied only in accordance with the terms of such license
;	  0014	!     and with the inclusion of the above copyright notice.   This
;	  0015	!     software  or any other copies thereof may not be provided or
;	  0016	!     otherwise made available to any other person.  No  title  to
;	  0017	!     and ownership of the software is hereby transferred.
;	  0018	!
;	  0019	!     The information  in  this  software  is  subject  to  change
;	  0020	!     without  notice  and should not be construed as a commitment
;	  0021	!     by DIGITAL EQUIPMENT CORPORATION.
;	  0022	!
;	  0023	!     DIGITAL assumes no responsibility for the use or reliability
;	  0024	!     of  its  software  on  equipment  which  is  not supplied by
;	  0025	!     DIGITAL.
;	  0026	!
;	  0027	
;	  0028	!++
;	  0029	! FACILITY: TKB-20 and VNP-20
;	  0030	!
;	  0031	! ABSTRACT:
;	  0032	!
;	  0033	!	This module does all I/O operations associated with the processing
;	  0034	!	of files by VNP-20 and TKB-20. It also contains routines that are
;	  0035	!	system dependent.
;	  0036	!
;	  0037	!	The I/O routines supported are:
;	  0038	!		RESET_ALL - initialization of I/O system
;	  0039	!		OPEN - open a file
;	  0040	!		CLOSE - close a file
;	  0041	!		INPUT - get data from a file
;	  0042	!		OUTPUT - put data onto a file
;	  0043	!
;	  0044	!	The system dependent routines are:
;	  0045	!		STOP_PROGRAM - terminate program
;	  0046	!
;	  0047	!	Channel 0 is always the terminal. Other channels are assigned at
;	  0048	!	will and are an artifact of programs written for TOPS-10 I/O.
;	  0049	!
;	  0050	! ENVIRONMENT: TOPS-20 User Mode
;	  0051	!
;	  0052	! AUTHOR: Scott G. Robinson, CREATION DATE: 25-NOV-78
FIO20								25-Jan-1983 10:15:27	TOPS-20 Bliss-36 2A(142)	    Page   2
X2.0-1								 1-Jan-1983 15:44:34	NETPKG:<VNP36>VFIO20.BLI.7 (1)

;	  0053	!
;	  0054	! MODIFIED BY:
;	  0055	!
;	  0056	!	Scott G. Robinson, 5-MAR-79 : VERSION X0.2
;	  0057	!	- Modify to use JSYS_CALL macro to resolve register conflicts
;	  0058	!
;	  0059	!	Scott G. Robinson, 13-JUN-79 : VERSION X0.3
;	  0060	!	- Add routine STOP_PROGRAM
;	  0061	!-----------------------------------------------------------------------
;	  0062	
;	  0063	!
;	  0064	!	Scott G. Robinson, 3-DEC-79 : Version X2.0
;	  0065	!	- Ensure DECnet-10 Compatibility
;	  0066	!
;	  0067	!	Scott G. Robinson, 11-JUL-80 : Version X2.0-1
;	  0068	!	- Implement Logging of Terminal Output
;	  0069	!
;	  0070	! 	, : VERSION
;	  0071	! 01	-
;	  0072	!--
;	  0073	
;	  0074	!
;	  0075	! TABLE OF CONTENTS:
;	  0076	!
;	  0077	
;	  0078	FORWARD ROUTINE
;	  0079	    RESET_ALL : NOVALUE,			!Reset all I/O
;	  0080	    OPEN,					!Open a file
;	  0081	    CLOSE : NOVALUE,				!Close a file
;	  0082	    INPUT,					!Read from a file
;	  0083	    OUTPUT : NOVALUE,				!Write on a file
;	  0084	    STOP_PROGRAM : NOVALUE;			!Terminate execution
;	  0085	
;	  0086	!
;	  0087	! INCLUDE FILES:
;	  0088	!
;	  0089	
;	  0090	LIBRARY 'BLI:MONSYM';
;	  0091	
;	  0092	LIBRARY 'BLI:TENDEF';
; WARN#050	........1  L1:0092
; Name already declared in this block:  $CHLFD
; WARN#050	........1  L1:0092
; Name already declared in this block:  $CHCRT
; WARN#050	........1  L1:0092
; Name already declared in this block:  $CHFFD
;	  0093	
;	  0094	!
;	  0095	! MACROS:
;	  0096	!
;	  0097	
;	  0098	MACRO
FIO20								25-Jan-1983 10:15:27	TOPS-20 Bliss-36 2A(142)	    Page   3
X2.0-1								 1-Jan-1983 15:44:34	NETPKG:<VNP36>VFIO20.BLI.7 (1)

;	M 0099	    JSYS_CALL (TYPE, FUNC, AC1, AC2, AC3, AC4) =
;	M 0100		BEGIN
;	M 0101		REGISTER T1=1,T2=2,T3=3,T4=4;
;	M 0102		LOCAL VALUE;
;	M 0103		BUILTIN JSYS;
;	M 0104	%IF NOT %NULL(AC1) %THEN T1=.AC1; %FI
;	M 0105	%IF NOT %NULL(AC2) %THEN T2=.AC2; %FI
;	M 0106	%IF NOT %NULL(AC3) %THEN T3=.AC3; %FI
;	M 0107	%IF NOT %NULL(AC4) %THEN T4=.AC4; %FI
;	M 0108		VALUE = JSYS(TYPE,FUNC,T1,T2,T3,T4);
;	M 0109	%IF NOT %NULL(AC1) %THEN %IF %DECLARED(AC1) %THEN AC1=.T1; %FI %FI
;	M 0110	%IF NOT %NULL(AC2) %THEN %IF %DECLARED(AC2) %THEN AC2=.T2; %FI %FI
;	M 0111	%IF NOT %NULL(AC3) %THEN %IF %DECLARED(AC3) %THEN AC3=.T3; %FI %FI
;	M 0112	%IF NOT %NULL(AC4) %THEN %IF %DECLARED(AC4) %THEN AC4=.T4; %FI %FI
;	M 0113		.VALUE
;	  0114		END	%;
;	  0115	
;	  0116	!
;	  0117	! EQUATED SYMBOLS:
;	  0118	!
;	  0119	
;	  0120	LITERAL
;	  0121	    DEBUG = 0,
;	  0122	    LEN_LINE_BUFF = 160,
;	  0123	    LOGGING_FILE = 1;
;	  0124	
;	  0125	!
;	  0126	! OWN STORAGE:
;	  0127	!
;	  0128	
;	  0129	OWN
;	  0130	    CHAN_MODE : VECTOR [16],			!1=Character, 2=Word
;	  0131	    CHAN_DIRECTION : VECTOR [16],		!0=Input, 1=Output
;	  0132	    CHAN_JFN : VECTOR [16],			!Channel to JFN Mapping
;	  0133	    CHAN_NEXT : VECTOR [16],			!Next byte in word mode
;	  0134	    LINE_BUFF : VECTOR [CH$ALLOCATION (LEN_LINE_BUFF)];	!Input line buffer
;	  0135	
;	  0136	!
;	  0137	! BOUND STORAGE FOR TERMINAL INPUT PROCESSING
;	  0138	!
;	  0139	
;	  0140	BIND
;	  0141	    LINE_LEN = CHAN_MODE [0],
;	  0142	    LINE_STATUS = CHAN_DIRECTION [0],
;	  0143	    LINE_PTR = CHAN_NEXT [0];
;	  0144	
;	  0145	!
;	  0146	! EXTERNAL REFERENCES:
;	  0147	!
;	  0148	
;	  0149	EXTERNAL ROUTINE
;	  0150	    ERROR : NOVALUE,				!Programming Error
FIO20								25-Jan-1983 10:15:27	TOPS-20 Bliss-36 2A(142)	    Page   4
X2.0-1								 1-Jan-1983 15:44:34	NETPKG:<VNP36>VFIO20.BLI.7 (1)

;	  0151	    ERRMSG : NOVALUE;				!Standard Error Message
;	  0152	
FIO20								25-Jan-1983 10:15:27	TOPS-20 Bliss-36 2A(142)	    Page   5
X2.0-1								 1-Jan-1983 15:44:34	NETPKG:<VNP36>VFIO20.BLI.7 (2)

;	  0153	GLOBAL ROUTINE RESET_ALL : NOVALUE = 		!Reset all I/O
;	  0154	
;	  0155	!++
;	  0156	! FUNCTIONAL DESCRIPTION:
;	  0157	!
;	  0158	!	Initializes the I/O system
;	  0159	!
;	  0160	! FORMAL PARAMETERS:
;	  0161	!
;	  0162	!	NONE
;	  0163	!
;	  0164	! IMPLICIT INPUTS:
;	  0165	!
;	  0166	!	NONE
;	  0167	!
;	  0168	! IMPLICIT OUTPUTS:
;	  0169	!
;	  0170	!	NONE
;	  0171	!
;	  0172	! COMPLETION CODES:
;	  0173	!
;	  0174	!	NONE
;	  0175	!
;	  0176	! SIDE EFFECTS:
;	  0177	!
;	  0178	!	All Files currently open are dropped
;	  0179	!
;	  0180	!--
;	  0181	
;	  0182	    BEGIN
;	  0183	
;	  0184	    BIND
;	  0185		ROUTINE_NAME = UPLIT (%ASCIZ'RESET_ALL');
;	  0186	
;	  0187	    JSYS_CALL (0, RESET);
;	  0188	    END;					!of RESET_ALL


	TITLE	FIO20
	TWOSEG


	.REQUEST  SYS:B362LB.REL


	RELOC	400000				;					400000'
P.AAA:	BYTE	(7)"R","E","S","E","T"		; RESET					400000' 122 105 123 105 124
	BYTE	(7)"_","A","L","L",000		; _ALL					400001' 137 101 114 114 000


	RELOC	0				;					000000'
CHAN_MODE:
FIO20								25-Jan-1983 10:15:27	TOPS-20 Bliss-36 2A(142)	    Page   6
X2.0-1								 1-Jan-1983 15:44:34	NETPKG:<VNP36>VFIO20.BLI.7 (2)

	BLOCK	20				;					000000'
CHAN_DIRECTION:
	BLOCK	20				;					000020'
CHAN_JFN:
	BLOCK	20				;					000040'
CHAN_NEXT:
	BLOCK	20				;					000060'
LINE_BUFF:
	BLOCK	40				;					000100'


	EXTERN	ERROR, ERRMSG


LINE_LEN=	    CHAN_MODE			;						000000	000000'
LINE_STATUS=	    CHAN_DIRECTION		;						000000	000020'
LINE_PTR=	    CHAN_NEXT			;						000000	000060'
ROUTINE_NAME=	    P.AAA			;						000000	400000'


AC0=	0
AC1=	1
AC2=	2
AC3=	3
AC4=	4
AC5=	5
AC6=	6
AC7=	7
AC10=	10
AC11=	11
AC12=	12
AC13=	13
AC14=	14
FP=	15
AC16=	16
SP=	17


	RELOC	400002				;					400002'
RESET_ALL::
	JSYS	147				; 147					400002' 104 00 0 00 000147		0187
	SETZ	AC1,				; VALUE,				400003' 400 01 0 00 000000
	POPJ	SP,				; SP,					400004' 263 17 0 00 000000		0153

; Routine Size:  3 words


;	  0189	
FIO20								25-Jan-1983 10:15:27	TOPS-20 Bliss-36 2A(142)	    Page   7
X2.0-1								 1-Jan-1983 15:44:34	NETPKG:<VNP36>VFIO20.BLI.7 (3)

;	  0190	GLOBAL ROUTINE OPEN (CHANX, FNAME, MODE, IO, DEFEXT) : = 	!Open a File
;	  0191	
;	  0192	!++
;	  0193	! FUNCTIONAL DESCRIPTION:
;	  0194	!
;	  0195	!	Opens a file on channel "CHANX" with name "FNAME" in mode "MODE"
;	  0196	!	 with direction "IO" with default extension "DEFEXT".
;	  0197	!
;	  0198	! FORMAL PARAMETERS:
;	  0199	!
;	  0200	!	CHANX - Contains the channel number to associate with the file
;	  0201	!	FNAME - Points at the file name
;	  0202	!	MODE - File Mode (1=Character, 2= Word)
;	  0203	!	IO - Direction (0=Input,1=Output)
;	  0204	!	DEFEXT - Default extension if none specified in FNAME
;	  0205	!
;	  0206	! IMPLICIT INPUTS:
;	  0207	!
;	  0208	!	NONE
;	  0209	!
;	  0210	! IMPLICIT OUTPUTS:
;	  0211	!
;	  0212	!	NONE
;	  0213	!
;	  0214	! ROUTINE VALUE:
;	  0215	!
;	  0216	!	1 If OPEN Successful, 0 If not.
;	  0217	!
;	  0218	! SIDE EFFECTS:
;	  0219	!
;	  0220	!	Modifies OWN storage to reflect associated file information.
;	  0221	!
;	  0222	!--
;	  0223	
;	  0224	    BEGIN
;	  0225	
;	  0226	    BIND
;	  0227		ROUTINE_NAME = UPLIT (%ASCIZ'OPEN');
;	  0228	
;	  0229	    LOCAL
;	  0230		CHAN,
;	  0231		GTJFN_BLOCK : VECTOR [9],
;	  0232		BYTE_SIZE,
;	  0233		AC1,
;	  0234		AC2,
;	  0235		AC3;
;	  0236	
;	  0237	!
;	  0238	! Check on legality of channel number
;	  0239	!
;	  0240	    CHAN = .CHANX;
;	  0241	
FIO20								25-Jan-1983 10:15:27	TOPS-20 Bliss-36 2A(142)	    Page   8
X2.0-1								 1-Jan-1983 15:44:34	NETPKG:<VNP36>VFIO20.BLI.7 (3)

;	  0242	    IF (.CHAN EQL 0)
;	  0243	    THEN
;	  0244		ERROR (UPLIT (%ASCIZ'May not OPEN channel 0 - OPEN'))
;	  0245	    ELSE
;	  0246	
;	  0247		IF ((.CHAN GTR 15) OR (.CHAN LSS 0))
;	  0248		THEN
;	  0249		    ERROR (UPLIT (%ASCIZ'Invalid Channel Number - OPEN'))
;	  0250		ELSE
;	  0251	
;	  0252		    IF (.CHAN_JFN [.CHAN] NEQ 0)
;	  0253		    THEN
;	  0254			ERROR (UPLIT (%ASCIZ'Attempting to OPEN an already OPEN channel - OPEN'))
;	  0255		    ELSE
;	  0256	!
;	  0257	! We now have what appears to be a valid request: The channel number is within
;	  0258	!  range and it is not open.
;	  0259	!
;	  0260	! Build a GTJFN Block to attempt and access the file.
;	  0261	!
;	  0262			BEGIN
;	  0263			GTJFN_BLOCK [$GJGEN] = (CASE .IO FROM 0 TO 1 OF
;	  0264			    SET
;	  0265			    [0] : GJ_OLD;
;	  0266			    [1] : GJ_FOU + GJ_NEW;
;	  0267			    [OUTRANGE] : -1;
;	  0268			    TES);
;	  0269	
;	  0270			INCR FOO FROM $GJDEV TO $GJJFN DO
;	  0271			    GTJFN_BLOCK [.FOO] = 0;
;	  0272	
;	  0273			GTJFN_BLOCK [$GJSRC] = %O'377777377777';	!.NULIO,,.NULIO
;	  0274			GTJFN_BLOCK [$GJEXT] = CH$PTR (.DEFEXT);
;	  0275			AC2 = CH$PTR (.FNAME);
;	  0276			AC1 = GTJFN_BLOCK;
;	  0277	
;	  0278			IF NOT JSYS_CALL (1, GTJFN, AC1, AC2)	!Get the JFN
;	  0279			THEN
;	  0280			    BEGIN			!and if in error
;	  0281			    ERRMSG (0, 2, ROUTINE_NAME, .FNAME, 0, 0, 0);
;	  0282			    RETURN 0
;	  0283			    END;
;	  0284	
;	  0285			CHAN_JFN [.CHAN] = .AC1;	!Save returned JFN
;	  0286			CHAN_MODE [.CHAN] = .MODE;	! and mode
;	  0287			CHAN_DIRECTION [.CHAN] = .IO;	! with direction
;	  0288			CHAN_NEXT [.CHAN] = -1;		!Indicate Initial State
;	  0289	!
;	  0290	! Because we were apparently successful in accessing the file, open
;	  0291	! it.
;	  0292	!
;	  0293			BYTE_SIZE = (CASE .MODE FROM 1 TO 2 OF
FIO20								25-Jan-1983 10:15:27	TOPS-20 Bliss-36 2A(142)	    Page   9
X2.0-1								 1-Jan-1983 15:44:34	NETPKG:<VNP36>VFIO20.BLI.7 (3)

;	  0294			    SET
;	  0295			    [1] : 7;			!Character mode
;	  0296			    [2] : 18;			!16-bit word mode
;	  0297			    [OUTRANGE] : 0;		!Use default
;	  0298			    TES);
;	  0299			AC2 = FLD (.BYTE_SIZE, OF_BSZ) + (CASE .IO FROM 0 TO 1 OF
;	  0300			    SET
;	  0301			    [0] : OF_RD;
;	  0302			    [1] : OF_WR;
;	  0303			    [OUTRANGE] : 0;
;	  0304			    TES);
;	  0305			AC1 = .CHAN_JFN [.CHAN];
;	  0306	
;	  0307			IF NOT JSYS_CALL (1, OPENF, AC1, AC2)
;	  0308			THEN
;	  0309			    BEGIN			!OPENF Failed!!!
;	  0310			    ERRMSG (0, 3, ROUTINE_NAME, .FNAME, 0, 0, 0);
;	  0311			    CHAN_JFN [.CHAN] = 0;
;	  0312			    RETURN 0
;	  0313			    END;
;	  0314	
;	  0315			END;
;	  0316	
;	  0317	    1
;	  0318	    END;					!End of OPEN


P.AAB:	BYTE	(7)"O","P","E","N",000		; OPEN					400005' 117 120 105 116 000
P.AAC:	BYTE	(7)"M","a","y"," ","n"		; May n					400006' 115 141 171 040 156
	BYTE	(7)"o","t"," ","O","P"		; ot OP					400007' 157 164 040 117 120
	BYTE	(7)"E","N"," ","c","h"		; EN ch					400010' 105 116 040 143 150
	BYTE	(7)"a","n","n","e","l"		; annel					400011' 141 156 156 145 154
	BYTE	(7)" ","0"," ","-"," "		;  0 -					400012' 040 060 040 055 040
	BYTE	(7)"O","P","E","N",000		; OPEN					400013' 117 120 105 116 000
P.AAD:	BYTE	(7)"I","n","v","a","l"		; Inval					400014' 111 156 166 141 154
	BYTE	(7)"i","d"," ","C","h"		; id Ch					400015' 151 144 040 103 150
	BYTE	(7)"a","n","n","e","l"		; annel					400016' 141 156 156 145 154
	BYTE	(7)" ","N","u","m","b"		;  Numb					400017' 040 116 165 155 142
	BYTE	(7)"e","r"," ","-"," "		; er -					400020' 145 162 040 055 040
	BYTE	(7)"O","P","E","N",000		; OPEN					400021' 117 120 105 116 000
P.AAE:	BYTE	(7)"A","t","t","e","m"		; Attem					400022' 101 164 164 145 155
	BYTE	(7)"p","t","i","n","g"		; pting					400023' 160 164 151 156 147
	BYTE	(7)" ","t","o"," ","O"		;  to O					400024' 040 164 157 040 117
	BYTE	(7)"P","E","N"," ","a"		; PEN a					400025' 120 105 116 040 141
	BYTE	(7)"n"," ","a","l","r"		; n alr					400026' 156 040 141 154 162
	BYTE	(7)"e","a","d","y"," "		; eady					400027' 145 141 144 171 040
	BYTE	(7)"O","P","E","N"," "		; OPEN					400030' 117 120 105 116 040
	BYTE	(7)"c","h","a","n","n"		; chann					400031' 143 150 141 156 156
	BYTE	(7)"e","l"," ","-"," "		; el -					400032' 145 154 040 055 040
	BYTE	(7)"O","P","E","N",000		; OPEN					400033' 117 120 105 116 000
FIO20								25-Jan-1983 10:15:27	TOPS-20 Bliss-36 2A(142)	    Page  10
X2.0-1								 1-Jan-1983 15:44:34	NETPKG:<VNP36>VFIO20.BLI.7 (3)

ROUTINE_NAME=	    P.AAB			;						000000	400005'


OPEN::	PUSH	SP,AC0				; SP,AC0				400034' 261 17 0 00 000000		0190
	PUSH	SP,AC10				; SP,AC10				400035' 261 17 0 00 000010
	PUSH	SP,AC11				; SP,AC11				400036' 261 17 0 00 000011
	ADJSP	SP,11				; SP,11					400037' 105 17 0 00 000011
	MOVE	AC10,-21(SP)			; CHAN,CHANX				400040' 200 10 0 17 777757		0240
	JUMPN	AC10,L.1			; CHAN,L.1				400041' 326 10 0 00 400044'		0242
	PUSH	SP,C.1				; SP,[0,,P.AAC]				400042' 261 17 0 00 400233'		0244
	JRST	L.3				; L.3					400043' 254 00 0 00 400053'
L.1:	CAIG	AC10,17				; CHAN,17				400044' 307 10 0 00 000017		0247
	JUMPGE	AC10,L.2			; CHAN,L.2				400045' 325 10 0 00 400050'
	PUSH	SP,C.2				; SP,[0,,P.AAD]				400046' 261 17 0 00 400234'		0249
	JRST	L.3				; L.3					400047' 254 00 0 00 400053'
L.2:	SKIPN	CHAN_JFN(AC10)			; CHAN_JFN(CHAN)			400050' 336 00 0 10 000040'		0252
	JRST	L.4				; L.4					400051' 254 00 0 00 400056'
	PUSH	SP,C.3				; SP,[0,,P.AAE]				400052' 261 17 0 00 400235'		0254
L.3:	PUSHJ	SP,ERROR			; SP,ERROR				400053' 260 17 0 00 000000*
	ADJSP	SP,-1				; SP,-1					400054' 105 17 0 00 777777
	JRST	L.23				; L.23					400055' 254 00 0 00 400225'		0252
L.4:	MOVE	AC1,-16(SP)			; AC1,IO				400056' 200 01 0 17 777762		0263
	JUMPL	AC1,L.6				; AC1,L.6				400057' 321 01 0 00 400065'
	CAIGE	AC1,2				; AC1,2					400060' 305 01 0 00 000002
	JRST	L.5(AC1)			; L.5(AC1)				400061' 254 00 0 01 400063'
	JRST	L.6				; L.6					400062' 254 00 0 00 400065'
L.5:	JRST	L.7				; L.7					400063' 254 00 0 00 400067'
	JRST	L.8				; L.8					400064' 254 00 0 00 400071'
L.6:	SETO	AC1,				; AC1,					400065' 474 01 0 00 000000
	JRST	L.9				; L.9					400066' 254 00 0 00 400072'
L.7:	MOVSI	AC1,100000			; AC1,100000				400067' 205 01 0 00 100000
	JRST	L.9				; L.9					400070' 254 00 0 00 400072'
L.8:	MOVSI	AC1,-200000			; AC1,-200000				400071' 205 01 0 00 600000
L.9:	MOVEM	AC1,-10(SP)			; AC1,GTJFN_BLOCK			400072' 202 01 0 17 777770
	MOVEI	AC2,2				; FOO,2					400073' 201 02 0 00 000002		0270
L.10:	MOVEI	AC1,-10(SP)			; AC1,GTJFN_BLOCK			400074' 201 01 0 17 777770		0271
	ADD	AC1,AC2				; AC1,FOO				400075' 270 01 0 00 000002
	SETZM	0(AC1)				; 0(AC1)				400076' 402 00 0 01 000000
	ADDI	AC2,1				; FOO,1					400077' 271 02 0 00 000001		0270
	CAIG	AC2,10				; FOO,10				400100' 307 02 0 00 000010
	JRST	L.10				; L.10					400101' 254 00 0 00 400074'
	MOVE	AC0,C.4				; AC0,[377777377777]			400102' 200 00 0 00 400236'		0273
	MOVEM	AC0,-7(SP)			; AC0,GTJFN_BLOCK+1			400103' 202 00 0 17 777771
	MOVE	AC1,-15(SP)			; AC1,DEFEXT				400104' 200 01 0 17 777763		0274
	MOVEI	AC1,-1(AC1)			; AC1,-1(AC1)				400105' 201 01 0 01 777777
	HRLI	AC1,10700			; AC1,10700				400106' 505 01 0 00 010700
	MOVEM	AC1,-3(SP)			; AC1,GTJFN_BLOCK+5			400107' 202 01 0 17 777775
	MOVE	AC1,-20(SP)			; AC1,FNAME				400110' 200 01 0 17 777760		0275
	MOVEI	AC1,-1(AC1)			; AC1,-1(AC1)				400111' 201 01 0 01 777777
	HRLI	AC1,10700			; AC1,10700				400112' 505 01 0 00 010700
	MOVE	AC11,AC1			; AC2,AC1				400113' 200 11 0 00 000001
	MOVEI	AC0,-10(SP)			; AC1,GTJFN_BLOCK			400114' 201 00 0 17 777770		0276
FIO20								25-Jan-1983 10:15:27	TOPS-20 Bliss-36 2A(142)	    Page  11
X2.0-1								 1-Jan-1983 15:44:34	NETPKG:<VNP36>VFIO20.BLI.7 (3)

	MOVE	AC1,AC0				; T1,AC1				400115' 200 01 0 00 000000		0278
	MOVE	AC2,AC11			; T2,AC2				400116' 200 02 0 00 000011
	JSYS	20				; 20					400117' 104 00 0 00 000020
	TDZA	AC5,AC5				; AC5,AC5				400120' 634 05 0 00 000005
	MOVEI	AC5,1				; AC5,1					400121' 201 05 0 00 000001
	MOVE	AC3,AC5				; VALUE,AC5				400122' 200 03 0 00 000005
	MOVE	AC0,AC1				; AC1,T1				400123' 200 00 0 00 000001
	MOVE	AC11,AC2			; AC2,T2				400124' 200 11 0 00 000002
	TRNE	AC3,1				; VALUE,1				400125' 602 03 0 00 000001
	JRST	L.11				; L.11					400126' 254 00 0 00 400140'
	PUSH	SP,C.5				; SP,[0]				400127' 261 17 0 00 400237'		0281
	PUSH	SP,C.6				; SP,[2]				400130' 261 17 0 00 400240'
	PUSH	SP,C.7				; SP,[0,,ROUTINE_NAME]			400131' 261 17 0 00 400241'
	PUSH	SP,-23(SP)			; SP,FNAME				400132' 261 17 0 17 777755
	PUSH	SP,C.5				; SP,[0]				400133' 261 17 0 00 400237'
	PUSH	SP,C.5				; SP,[0]				400134' 261 17 0 00 400237'
	PUSH	SP,C.5				; SP,[0]				400135' 261 17 0 00 400237'
	PUSHJ	SP,ERRMSG			; SP,ERRMSG				400136' 260 17 0 00 000000*
	JRST	L.22				; L.22					400137' 254 00 0 00 400223'
L.11:	MOVEM	AC0,CHAN_JFN(AC10)		; AC1,CHAN_JFN(CHAN)			400140' 202 00 0 10 000040'		0285
	MOVE	AC1,-17(SP)			; AC1,MODE				400141' 200 01 0 17 777761		0286
	MOVEM	AC1,CHAN_MODE(AC10)		; AC1,CHAN_MODE(CHAN)			400142' 202 01 0 10 000000'
	MOVE	AC2,-16(SP)			; AC2,IO				400143' 200 02 0 17 777762		0287
	MOVEM	AC2,CHAN_DIRECTION(AC10)	; AC2,CHAN_DIRECTION(CHAN)		400144' 202 02 0 10 000020'
	SETOM	CHAN_NEXT(AC10)			; CHAN_NEXT(CHAN)			400145' 476 00 0 10 000060'		0288
	SOJL	AC1,L.13			; AC1,L.13				400146' 361 01 0 00 400154'		0293
	CAIGE	AC1,2				; AC1,2					400147' 305 01 0 00 000002
	JRST	L.12(AC1)			; L.12(AC1)				400150' 254 00 0 01 400152'
	JRST	L.13				; L.13					400151' 254 00 0 00 400154'
L.12:	JRST	L.14				; L.14					400152' 254 00 0 00 400156'
	JRST	L.15				; L.15					400153' 254 00 0 00 400160'
L.13:	SETZ	AC1,				; BYTE_SIZE,				400154' 400 01 0 00 000000
	JRST	L.16				; L.16					400155' 254 00 0 00 400161'
L.14:	MOVEI	AC1,7				; BYTE_SIZE,7				400156' 201 01 0 00 000007
	JRST	L.16				; L.16					400157' 254 00 0 00 400161'
L.15:	MOVEI	AC1,22				; BYTE_SIZE,22				400160' 201 01 0 00 000022
L.16:	LSH	AC1,36				; AC1,36				400161' 242 01 0 00 000036		0299
	JUMPL	AC2,L.18			; AC2,L.18				400162' 321 02 0 00 400170'
	CAIGE	AC2,2				; AC2,2					400163' 305 02 0 00 000002
	JRST	L.17(AC2)			; L.17(AC2)				400164' 254 00 0 02 400166'
	JRST	L.18				; L.18					400165' 254 00 0 00 400170'
L.17:	JRST	L.19				; L.19					400166' 254 00 0 00 400172'
	JRST	L.20				; L.20					400167' 254 00 0 00 400174'
L.18:	SETZ	AC2,				; AC2,					400170' 400 02 0 00 000000
	JRST	L.21				; L.21					400171' 254 00 0 00 400175'
L.19:	MOVEI	AC2,200000			; AC2,200000				400172' 201 02 0 00 200000
	JRST	L.21				; L.21					400173' 254 00 0 00 400175'
L.20:	MOVEI	AC2,100000			; AC2,100000				400174' 201 02 0 00 100000
L.21:	MOVE	AC11,AC1			; AC2,AC1				400175' 200 11 0 00 000001
	ADD	AC11,AC2			; AC2,AC2				400176' 270 11 0 00 000002
	MOVE	AC0,CHAN_JFN(AC10)		; AC1,CHAN_JFN(CHAN)			400177' 200 00 0 10 000040'		0305
	MOVE	AC1,AC0				; T1,AC1				400200' 200 01 0 00 000000		0307
FIO20								25-Jan-1983 10:15:27	TOPS-20 Bliss-36 2A(142)	    Page  12
X2.0-1								 1-Jan-1983 15:44:34	NETPKG:<VNP36>VFIO20.BLI.7 (3)

	MOVE	AC2,AC11			; T2,AC2				400201' 200 02 0 00 000011
	JSYS	21				; 21					400202' 104 00 0 00 000021
	TDZA	AC5,AC5				; AC5,AC5				400203' 634 05 0 00 000005
	MOVEI	AC5,1				; AC5,1					400204' 201 05 0 00 000001
	MOVE	AC3,AC5				; VALUE,AC5				400205' 200 03 0 00 000005
	MOVE	AC0,AC1				; AC1,T1				400206' 200 00 0 00 000001
	MOVE	AC11,AC2			; AC2,T2				400207' 200 11 0 00 000002
	TRNE	AC3,1				; VALUE,1				400210' 602 03 0 00 000001
	JRST	L.23				; L.23					400211' 254 00 0 00 400225'
	PUSH	SP,C.5				; SP,[0]				400212' 261 17 0 00 400237'		0310
	PUSH	SP,C.8				; SP,[3]				400213' 261 17 0 00 400242'
	PUSH	SP,C.7				; SP,[0,,ROUTINE_NAME]			400214' 261 17 0 00 400241'
	PUSH	SP,-23(SP)			; SP,FNAME				400215' 261 17 0 17 777755
	PUSH	SP,C.5				; SP,[0]				400216' 261 17 0 00 400237'
	PUSH	SP,C.5				; SP,[0]				400217' 261 17 0 00 400237'
	PUSH	SP,C.5				; SP,[0]				400220' 261 17 0 00 400237'
	PUSHJ	SP,ERRMSG			; SP,ERRMSG				400221' 260 17 0 00 000000*
	SETZM	CHAN_JFN(AC10)			; CHAN_JFN(CHAN)			400222' 402 00 0 10 000040'		0311
L.22:	ADJSP	SP,-7				; SP,-7					400223' 105 17 0 00 777771		0307
	TDZA	AC1,AC1				; AC1,AC1				400224' 634 01 0 00 000001		0309
L.23:	MOVEI	AC1,1				; AC1,1					400225' 201 01 0 00 000001		0190
	ADJSP	SP,-11				; SP,-11				400226' 105 17 0 00 777767
	POP	SP,AC11				; SP,AC11				400227' 262 17 0 00 000011
	POP	SP,AC10				; SP,AC10				400230' 262 17 0 00 000010
	POP	SP,AC0				; SP,AC0				400231' 262 17 0 00 000000
	POPJ	SP,				; SP,					400232' 263 17 0 00 000000
C.1:	XWD	0,P.AAC				; 0,P.AAC				400233' 000000	400006'
C.2:	XWD	0,P.AAD				; 0,P.AAD				400234' 000000	400014'
C.3:	XWD	0,P.AAE				; 0,P.AAE				400235' 000000	400022'
C.4:	EXP	377777377777			; 377777377777				400236' 377777	377777
C.5:	EXP	0				; 0					400237' 000000	000000
C.6:	EXP	2				; 2					400240' 000000	000002
C.7:	XWD	0,ROUTINE_NAME			; 0,ROUTINE_NAME			400241' 000000	400005'
C.8:	EXP	3				; 3					400242' 000000	000003

; Routine Size:  135 words


;	  0319	
FIO20								25-Jan-1983 10:15:27	TOPS-20 Bliss-36 2A(142)	    Page  13
X2.0-1								 1-Jan-1983 15:44:34	NETPKG:<VNP36>VFIO20.BLI.7 (4)

;	  0320	GLOBAL ROUTINE CLOSE (CHANX) : NOVALUE = 	!Close a channel
;	  0321	
;	  0322	!++
;	  0323	! FUNCTIONAL DESCRIPTION:
;	  0324	!
;	  0325	!	Close a file channel
;	  0326	!
;	  0327	! FORMAL PARAMETERS:
;	  0328	!
;	  0329	!	CHANX - the channel to close
;	  0330	!
;	  0331	! IMPLICIT INPUTS:
;	  0332	!
;	  0333	!	NONE
;	  0334	!
;	  0335	! IMPLICIT OUTPUTS:
;	  0336	!
;	  0337	!	NONE
;	  0338	!
;	  0339	! COMPLETION CODES:
;	  0340	!
;	  0341	!	NONE
;	  0342	!
;	  0343	! SIDE EFFECTS:
;	  0344	!
;	  0345	!	Minipulation of the OWN data base occurs
;	  0346	!
;	  0347	!--
;	  0348	
;	  0349	    BEGIN
;	  0350	
;	  0351	    BIND
;	  0352		ROUTINE_NAME = UPLIT (%ASCIZ'CLOSE');
;	  0353	
;	  0354	    LOCAL
;	  0355		CHAN,
;	  0356		AC1;
;	  0357	
;	  0358	!
;	  0359	! Validate Channel number
;	  0360	!
;	  0361	    CHAN = .CHANX;
;	  0362	
;	  0363	    IF (.CHAN EQL 0)
;	  0364	    THEN
;	  0365		ERROR (UPLIT (%ASCIZ'You May Not Close Channel 0 - CLOSE'))
;	  0366	    ELSE
;	  0367	
;	  0368		IF ((.CHAN LSS 0) OR (.CHAN GTR 15))
;	  0369		THEN
;	  0370		    ERROR (UPLIT (%ASCIZ'Invalid Channel Number - CLOSE'))
;	  0371		ELSE
FIO20								25-Jan-1983 10:15:27	TOPS-20 Bliss-36 2A(142)	    Page  14
X2.0-1								 1-Jan-1983 15:44:34	NETPKG:<VNP36>VFIO20.BLI.7 (4)

;	  0372	
;	  0373		    IF (.CHAN_JFN [.CHAN] EQL 0)
;	  0374		    THEN
;	  0375			ERROR (UPLIT (%ASCIZ'Channel is not OPEN - CLOSE'))
;	  0376		    ELSE
;	  0377			BEGIN
;	  0378			AC1 = .CHAN_JFN [.CHAN];
;	  0379			JSYS_CALL (1, CLOSF, AC1);
;	  0380			CHAN_JFN [.CHAN] = 0;
;	  0381			END;
;	  0382	
;	  0383	    END;					!End of CLOSE


P.AAF:	BYTE	(7)"C","L","O","S","E"		; CLOSE					400243' 103 114 117 123 105
	BYTE	(7)000,000,000,000,000		;					400244' 000 000 000 000 000
P.AAG:	BYTE	(7)"Y","o","u"," ","M"		; You M					400245' 131 157 165 040 115
	BYTE	(7)"a","y"," ","N","o"		; ay No					400246' 141 171 040 116 157
	BYTE	(7)"t"," ","C","l","o"		; t Clo					400247' 164 040 103 154 157
	BYTE	(7)"s","e"," ","C","h"		; se Ch					400250' 163 145 040 103 150
	BYTE	(7)"a","n","n","e","l"		; annel					400251' 141 156 156 145 154
	BYTE	(7)" ","0"," ","-"," "		;  0 -					400252' 040 060 040 055 040
	BYTE	(7)"C","L","O","S","E"		; CLOSE					400253' 103 114 117 123 105
	BYTE	(7)000,000,000,000,000		;					400254' 000 000 000 000 000
P.AAH:	BYTE	(7)"I","n","v","a","l"		; Inval					400255' 111 156 166 141 154
	BYTE	(7)"i","d"," ","C","h"		; id Ch					400256' 151 144 040 103 150
	BYTE	(7)"a","n","n","e","l"		; annel					400257' 141 156 156 145 154
	BYTE	(7)" ","N","u","m","b"		;  Numb					400260' 040 116 165 155 142
	BYTE	(7)"e","r"," ","-"," "		; er -					400261' 145 162 040 055 040
	BYTE	(7)"C","L","O","S","E"		; CLOSE					400262' 103 114 117 123 105
	BYTE	(7)000,000,000,000,000		;					400263' 000 000 000 000 000
P.AAI:	BYTE	(7)"C","h","a","n","n"		; Chann					400264' 103 150 141 156 156
	BYTE	(7)"e","l"," ","i","s"		; el is					400265' 145 154 040 151 163
	BYTE	(7)" ","n","o","t"," "		;  not					400266' 040 156 157 164 040
	BYTE	(7)"O","P","E","N"," "		; OPEN					400267' 117 120 105 116 040
	BYTE	(7)"-"," ","C","L","O"		; - CLO					400270' 055 040 103 114 117
	BYTE	(7)"S","E",000,000,000		; SE					400271' 123 105 000 000 000


ROUTINE_NAME=	    P.AAF			;						000000	400243'


CLOSE:: PUSH	SP,AC0				; SP,AC0				400272' 261 17 0 00 000000		0320
	PUSH	SP,AC10				; SP,AC10				400273' 261 17 0 00 000010
	MOVE	AC10,-3(SP)			; CHAN,CHANX				400274' 200 10 0 17 777775		0361
	JUMPN	AC10,L.24			; CHAN,L.24				400275' 326 10 0 00 400300'		0363
	PUSH	SP,C.9				; SP,[0,,P.AAG]				400276' 261 17 0 00 400325'		0365
	JRST	L.27				; L.27					400277' 254 00 0 00 400310'
L.24:	JUMPL	AC10,L.25			; CHAN,L.25				400300' 321 10 0 00 400303'		0368
	CAIG	AC10,17				; CHAN,17				400301' 307 10 0 00 000017
	JRST	L.26				; L.26					400302' 254 00 0 00 400305'
L.25:	PUSH	SP,C.10				; SP,[0,,P.AAH]				400303' 261 17 0 00 400326'		0370
FIO20								25-Jan-1983 10:15:27	TOPS-20 Bliss-36 2A(142)	    Page  15
X2.0-1								 1-Jan-1983 15:44:34	NETPKG:<VNP36>VFIO20.BLI.7 (4)

	JRST	L.27				; L.27					400304' 254 00 0 00 400310'
L.26:	MOVE	AC0,CHAN_JFN(AC10)		; AC0,CHAN_JFN(CHAN)			400305' 200 00 0 10 000040'		0373
	JUMPN	AC0,L.28			; AC0,L.28				400306' 326 00 0 00 400313'
	PUSH	SP,C.11				; SP,[0,,P.AAI]				400307' 261 17 0 00 400327'		0375
L.27:	PUSHJ	SP,ERROR			; SP,ERROR				400310' 260 17 0 00 000000*
	ADJSP	SP,-1				; SP,-1					400311' 105 17 0 00 777777
	JRST	L.29				; L.29					400312' 254 00 0 00 400322'		0373
L.28:	MOVE	AC5,AC0				; AC1,AC0				400313' 200 05 0 00 000000		0378
	MOVE	AC1,AC5				; T1,AC1				400314' 200 01 0 00 000005		0379
	JSYS	22				; 22					400315' 104 00 0 00 000022
	TDZA	AC0,AC0				; AC0,AC0				400316' 634 00 0 00 000000
	MOVEI	AC0,1				; AC0,1					400317' 201 00 0 00 000001
	MOVE	AC5,AC1				; AC1,T1				400320' 200 05 0 00 000001
	SETZM	CHAN_JFN(AC10)			; CHAN_JFN(CHAN)			400321' 402 00 0 10 000040'		0380
L.29:	POP	SP,AC10				; SP,AC10				400322' 262 17 0 00 000010		0320
	POP	SP,AC0				; SP,AC0				400323' 262 17 0 00 000000
	POPJ	SP,				; SP,					400324' 263 17 0 00 000000
C.9:	XWD	0,P.AAG				; 0,P.AAG				400325' 000000	400245'
C.10:	XWD	0,P.AAH				; 0,P.AAH				400326' 000000	400255'
C.11:	XWD	0,P.AAI				; 0,P.AAI				400327' 000000	400264'

; Routine Size:  30 words


;	  0384	
FIO20								25-Jan-1983 10:15:27	TOPS-20 Bliss-36 2A(142)	    Page  16
X2.0-1								 1-Jan-1983 15:44:34	NETPKG:<VNP36>VFIO20.BLI.7 (5)

;	  0385	GLOBAL ROUTINE INPUT (CHANX) : = 		!Read from file
;	  0386	
;	  0387	!++
;	  0388	! FUNCTIONAL DESCRIPTION:
;	  0389	!
;	  0390	!	Returns the next character (or PDP-11) word from a file.
;	  0391	!
;	  0392	! FORMAL PARAMETERS:
;	  0393	!
;	  0394	!	CHANX - the channel number associated with the file
;	  0395	!
;	  0396	! IMPLICIT INPUTS:
;	  0397	!
;	  0398	!	NONE
;	  0399	!
;	  0400	! IMPLICIT OUTPUTS:
;	  0401	!
;	  0402	!	NONE
;	  0403	!
;	  0404	! ROUTINE VALUE:
;	  0405	!
;	  0406	!	The character or word is returned.
;	  0407	!	If EOF or an ERROR is reached then -1 is returned.
;	  0408	!
;	  0409	! SIDE EFFECTS:
;	  0410	!
;	  0411	!	NONE
;	  0412	!
;	  0413	!--
;	  0414	
;	  0415	    BEGIN
;	  0416	
;	  0417	    BIND
;	  0418		ROUTINE_NAME = UPLIT (%ASCIZ'INPUT');
;	  0419	
;	  0420	    LOCAL
;	  0421		CHAN,
;	  0422		CHAN_CHAR,
;	  0423		AC1,
;	  0424		AC2,
;	  0425		AC3;
;	  0426	
;	  0427	!
;	  0428	! Determine whether the channel is for the terminal or a file then
;	  0429	!  process accordingly.
;	  0430	!
;	  0431	    CHAN = .CHANX;
;	  0432	
;	  0433	    IF (.CHAN EQL 0)
;	  0434	    THEN
;	  0435		BEGIN
;	  0436	
FIO20								25-Jan-1983 10:15:27	TOPS-20 Bliss-36 2A(142)	    Page  17
X2.0-1								 1-Jan-1983 15:44:34	NETPKG:<VNP36>VFIO20.BLI.7 (5)

;	  0437		IF (.LINE_PTR EQL 0)
;	  0438		THEN
;	  0439		    BEGIN
;	  0440		    AC3 = 0;
;	  0441		    AC2 = RD_TOP + RD_RAI + LEN_LINE_BUFF;
;	  0442		    AC1 = CH$PTR (LINE_BUFF);
;	  0443		    LINE_STATUS = (IF NOT JSYS_CALL (1, RDTTY, AC1, AC2, AC3) THEN -1 ELSE .AC2);
;	  0444		    LINE_PTR = CH$PTR (LINE_BUFF);
;	  0445		    LINE_LEN = LEN_LINE_BUFF - (.LINE_STATUS AND %O'777777');
;	  0446		    END;
;	  0447	
;	  0448		CHAN_CHAR = CH$RCHAR_A (LINE_PTR);
;	  0449	
;	  0450		IF ((LINE_LEN = .LINE_LEN - 1) EQL 0) THEN LINE_PTR = 0;
;	  0451	
;	  0452		END
;	  0453	    ELSE
;	  0454		BEGIN
;	  0455	
;	  0456		IF ((.CHAN LSS 0) OR (.CHAN GTR 15))
;	  0457		THEN
;	  0458		    BEGIN
;	  0459		    ERROR (UPLIT (%ASCIZ'Channel number out of range - INPUT'));
;	  0460		    AC1 = 0;
;	  0461		    END
;	  0462		ELSE
;	  0463		    AC1 = .CHAN_JFN [.CHAN];
;	  0464	
;	  0465		IF (.AC1 EQL 0)
;	  0466		THEN
;	  0467		    BEGIN
;	  0468		    ERROR (UPLIT (%ASCIZ'Channel not OPEN - INPUT'));
;	  0469		    RETURN -1
;	  0470		    END;
;	  0471	
;	  0472	!
;	  0473	! The next section of code either returns the character just read for a
;	  0474	!  character mode file or the next byte of a word mode file.
;	  0475	! CHAN_NEXT[.CHAN] is -1 if a new BIN JSYS should be done.
;	  0476	!
;	  0477	
;	  0478		IF (.CHAN_NEXT [.CHAN] LSS 0)
;	  0479		THEN
;	  0480		    BEGIN
;	  0481		    CHAN_CHAR = (IF NOT JSYS_CALL (-1, BIN, AC1, AC2) THEN -1 ELSE .AC2);
;	  0482	
;	  0483		    IF ((.CHAN_MODE [.CHAN] EQL 2) AND (.CHAN_CHAR GEQ 0))
;	  0484		    THEN
;	  0485			BEGIN
;	  0486			CHAN_NEXT [.CHAN] = .CHAN_CHAR<8, 8>;	!Next character
;	  0487			CHAN_CHAR = .CHAN_CHAR<0, 8>;	!Current Character
;	  0488			END;
FIO20								25-Jan-1983 10:15:27	TOPS-20 Bliss-36 2A(142)	    Page  18
X2.0-1								 1-Jan-1983 15:44:34	NETPKG:<VNP36>VFIO20.BLI.7 (5)

;	  0489	
;	  0490		    END
;	  0491		ELSE
;	  0492		    BEGIN				!The second byte of the word
;	  0493		    CHAN_CHAR = .CHAN_NEXT [.CHAN];	!The character to return
;	  0494		    CHAN_NEXT [.CHAN] = -1;
;	  0495		    END;
;	  0496	
;	  0497		END;
;	  0498	
;	  0499	    .CHAN_CHAR
;	  0500	    END;					!End of INPUT


P.AAJ:	BYTE	(7)"I","N","P","U","T"		; INPUT					400330' 111 116 120 125 124
	BYTE	(7)000,000,000,000,000		;					400331' 000 000 000 000 000
P.AAK:	BYTE	(7)"C","h","a","n","n"		; Chann					400332' 103 150 141 156 156
	BYTE	(7)"e","l"," ","n","u"		; el nu					400333' 145 154 040 156 165
	BYTE	(7)"m","b","e","r"," "		; mber					400334' 155 142 145 162 040
	BYTE	(7)"o","u","t"," ","o"		; out o					400335' 157 165 164 040 157
	BYTE	(7)"f"," ","r","a","n"		; f ran					400336' 146 040 162 141 156
	BYTE	(7)"g","e"," ","-"," "		; ge -					400337' 147 145 040 055 040
	BYTE	(7)"I","N","P","U","T"		; INPUT					400340' 111 116 120 125 124
	BYTE	(7)000,000,000,000,000		;					400341' 000 000 000 000 000
P.AAL:	BYTE	(7)"C","h","a","n","n"		; Chann					400342' 103 150 141 156 156
	BYTE	(7)"e","l"," ","n","o"		; el no					400343' 145 154 040 156 157
	BYTE	(7)"t"," ","O","P","E"		; t OPE					400344' 164 040 117 120 105
	BYTE	(7)"N"," ","-"," ","I"		; N - I					400345' 116 040 055 040 111
	BYTE	(7)"N","P","U","T",000		; NPUT					400346' 116 120 125 124 000


ROUTINE_NAME=	    P.AAJ			;						000000	400330'


INPUT:: PUSH	SP,AC0				; SP,AC0				400347' 261 17 0 00 000000		0385
	PUSH	SP,AC10				; SP,AC10				400350' 261 17 0 00 000010
	PUSH	SP,AC11				; SP,AC11				400351' 261 17 0 00 000011
	PUSH	SP,AC12				; SP,AC12				400352' 261 17 0 00 000012
	MOVE	AC10,-5(SP)			; CHAN,CHANX				400353' 200 10 0 17 777773		0431
	JUMPN	AC10,L.33			; CHAN,L.33				400354' 326 10 0 00 400414'		0433
	SKIPE	LINE_PTR			; LINE_PTR				400355' 332 00 0 00 000060'		0437
	JRST	L.32				; L.32					400356' 254 00 0 00 400410'
	SETZ	AC12,				; AC3,					400357' 400 12 0 00 000000		0440
	MOVE	AC11,C.13			; AC2,[200200000240]			400360' 200 11 0 00 400474'		0441
	MOVE	AC0,C.14			; AC1,[POINT 7,LINE_BUFF-1,34]  <1,7>	400361' 200 00 0 00 400475'		0442
	MOVE	AC1,AC0				; T1,AC1				400362' 200 01 0 00 000000		0443
	MOVE	AC2,AC11			; T2,AC2				400363' 200 02 0 00 000011
	MOVE	AC3,AC12			; T3,AC3				400364' 200 03 0 00 000012
	JSYS	523				; 523					400365' 104 00 0 00 000523
	TDZA	AC5,AC5				; AC5,AC5				400366' 634 05 0 00 000005
	MOVEI	AC5,1				; AC5,1					400367' 201 05 0 00 000001
	MOVE	AC4,AC5				; VALUE,AC5				400370' 200 04 0 00 000005
FIO20								25-Jan-1983 10:15:27	TOPS-20 Bliss-36 2A(142)	    Page  19
X2.0-1								 1-Jan-1983 15:44:34	NETPKG:<VNP36>VFIO20.BLI.7 (5)

	MOVE	AC0,AC1				; AC1,T1				400371' 200 00 0 00 000001
	MOVE	AC11,AC2			; AC2,T2				400372' 200 11 0 00 000002
	MOVE	AC12,AC3			; AC3,T3				400373' 200 12 0 00 000003
	TRNE	AC4,1				; VALUE,1				400374' 602 04 0 00 000001
	JRST	L.30				; L.30					400375' 254 00 0 00 400400'
	SETO	AC1,				; AC1,					400376' 474 01 0 00 000000
	JRST	L.31				; L.31					400377' 254 00 0 00 400401'
L.30:	MOVE	AC1,AC11			; AC1,AC2				400400' 200 01 0 00 000011
L.31:	MOVEM	AC1,LINE_STATUS			; AC1,LINE_STATUS			400401' 202 01 0 00 000020'
	MOVE	AC1,C.14			; AC1,[POINT 7,LINE_BUFF-1,34]  <1,7>	400402' 200 01 0 00 400475'		0444
	MOVEM	AC1,LINE_PTR			; AC1,LINE_PTR				400403' 202 01 0 00 000060'
	MOVEI	AC0,240				; AC0,240				400404' 201 00 0 00 000240		0445
	HRRZ	AC1,LINE_STATUS			; AC1,LINE_STATUS			400405' 550 01 0 00 000020'
	SUB	AC0,AC1				; AC0,AC1				400406' 274 00 0 00 000001
	MOVEM	AC0,LINE_LEN			; AC0,LINE_LEN				400407' 202 00 0 00 000000'
L.32:	ILDB	AC12,LINE_PTR			; CHAN_CHAR,LINE_PTR			400410' 134 12 0 00 000060'		0448
	SOSN	LINE_LEN			; LINE_LEN				400411' 376 00 0 00 000000'		0450
	SETZM	LINE_PTR			; LINE_PTR				400412' 402 00 0 00 000060'
	JRST	L.42				; L.42					400413' 254 00 0 00 400465'
L.33:	JUMPL	AC10,L.34			; CHAN,L.34				400414' 321 10 0 00 400417'		0456
	CAIG	AC10,17				; CHAN,17				400415' 307 10 0 00 000017
	JRST	L.35				; L.35					400416' 254 00 0 00 400424'
L.34:	PUSH	SP,C.15				; SP,[0,,P.AAK]				400417' 261 17 0 00 400476'		0459
	PUSHJ	SP,ERROR			; SP,ERROR				400420' 260 17 0 00 000000*
	SETZ	AC0,				; AC1,					400421' 400 00 0 00 000000		0460
	ADJSP	SP,-1				; SP,-1					400422' 105 17 0 00 777777		0458
	JRST	L.36				; L.36					400423' 254 00 0 00 400425'		0456
L.35:	MOVE	AC0,CHAN_JFN(AC10)		; AC1,CHAN_JFN(CHAN)			400424' 200 00 0 10 000040'		0463
L.36:	JUMPN	AC0,L.37			; AC1,L.37				400425' 326 00 0 00 400433'		0465
	PUSH	SP,C.16				; SP,[0,,P.AAL]				400426' 261 17 0 00 400477'		0468
	PUSHJ	SP,ERROR			; SP,ERROR				400427' 260 17 0 00 000000*
	ADJSP	SP,-1				; SP,-1					400430' 105 17 0 00 777777		0465
	SETO	AC1,				; AC1,					400431' 474 01 0 00 000000		0467
	JRST	L.43				; L.43					400432' 254 00 0 00 400466'
L.37:	MOVE	AC1,CHAN_NEXT(AC10)		; AC1,CHAN_NEXT(CHAN)			400433' 200 01 0 10 000060'		0478
	JUMPGE	AC1,L.41			; AC1,L.41				400434' 325 01 0 00 400463'
	MOVE	AC1,AC0				; T1,AC1				400435' 200 01 0 00 000000		0481
	MOVE	AC2,AC11			; T2,AC2				400436' 200 02 0 00 000011
	SETZ	AC5,				; AC5,					400437' 400 05 0 00 000000
	JSYS	50				; 50					400440' 104 00 0 00 000050
	JUMP	16,L.38				; 16,L.38				400441' 320 16 0 00 400443'
	MOVEI	AC5,1				; AC5,1					400442' 201 05 0 00 000001
L.38:	MOVE	AC3,AC5				; VALUE,AC5				400443' 200 03 0 00 000005
	MOVE	AC0,AC1				; AC1,T1				400444' 200 00 0 00 000001
	MOVE	AC11,AC2			; AC2,T2				400445' 200 11 0 00 000002
	TRNE	AC3,1				; VALUE,1				400446' 602 03 0 00 000001
	JRST	L.39				; L.39					400447' 254 00 0 00 400452'
	SETO	AC12,				; CHAN_CHAR,				400450' 474 12 0 00 000000
	JRST	L.40				; L.40					400451' 254 00 0 00 400453'
L.39:	MOVE	AC12,AC11			; CHAN_CHAR,AC2				400452' 200 12 0 00 000011
L.40:	MOVEI	AC0,2				; AC0,2					400453' 201 00 0 00 000002		0483
	CAME	AC0,CHAN_MODE(AC10)		; AC0,CHAN_MODE(CHAN)			400454' 312 00 0 10 000000'
FIO20								25-Jan-1983 10:15:27	TOPS-20 Bliss-36 2A(142)	    Page  20
X2.0-1								 1-Jan-1983 15:44:34	NETPKG:<VNP36>VFIO20.BLI.7 (5)

	JRST	L.42				; L.42					400455' 254 00 0 00 400465'
	JUMPL	AC12,L.42			; CHAN_CHAR,L.42			400456' 321 12 0 00 400465'
	LDB	AC0,C.12			; AC0,[POINT 8,CHAN_CHAR,27]  <8,8>	400457' 135 00 0 00 400473'		0486
	MOVEM	AC0,CHAN_NEXT(AC10)		; AC0,CHAN_NEXT(CHAN)			400460' 202 00 0 10 000060'
	ANDI	AC12,377			; CHAN_CHAR,377				400461' 405 12 0 00 000377		0487
	JRST	L.42				; L.42					400462' 254 00 0 00 400465'		0483
L.41:	MOVE	AC12,AC1			; CHAN_CHAR,AC1				400463' 200 12 0 00 000001		0493
	SETOM	CHAN_NEXT(AC10)			; CHAN_NEXT(CHAN)			400464' 476 00 0 10 000060'		0494
L.42:	MOVE	AC1,AC12			; AC1,CHAN_CHAR				400465' 200 01 0 00 000012		0385
L.43:	POP	SP,AC12				; SP,AC12				400466' 262 17 0 00 000012
	POP	SP,AC11				; SP,AC11				400467' 262 17 0 00 000011
	POP	SP,AC10				; SP,AC10				400470' 262 17 0 00 000010
	POP	SP,AC0				; SP,AC0				400471' 262 17 0 00 000000
	POPJ	SP,				; SP,					400472' 263 17 0 00 000000
C.12:	POINT	8,AC12,27			; 8,CHAN_CHAR,27			400473' 10 10 0 00 000012
C.13:	EXP	200200000240			; 200200000240				400474' 200200	000240
C.14:	POINT	7,LINE_BUFF-1,34		; 7,LINE_BUFF-1,34			400475' 01 07 0 00 000077'
C.15:	XWD	0,P.AAK				; 0,P.AAK				400476' 000000	400332'
C.16:	XWD	0,P.AAL				; 0,P.AAL				400477' 000000	400342'

; Routine Size:  89 words


;	  0501	
FIO20								25-Jan-1983 10:15:27	TOPS-20 Bliss-36 2A(142)	    Page  21
X2.0-1								 1-Jan-1983 15:44:34	NETPKG:<VNP36>VFIO20.BLI.7 (6)

;	  0502	GLOBAL ROUTINE OUTPUT (CHANX, OUTWRD) : NOVALUE = 	!Output to a file
;	  0503	
;	  0504	!++
;	  0505	! FUNCTIONAL DESCRIPTION:
;	  0506	!
;	  0507	!	Output a byte or word to a file.
;	  0508	!
;	  0509	! FORMAL PARAMETERS:
;	  0510	!
;	  0511	!	CHANX - the channel number
;	  0512	!	OUTWRD - the byte or word to output
;	  0513	!
;	  0514	! IMPLICIT INPUTS:
;	  0515	!
;	  0516	!	NONE
;	  0517	!
;	  0518	! IMPLICIT OUTPUTS:
;	  0519	!
;	  0520	!	NONE
;	  0521	!
;	  0522	! COMPLETION CODES:
;	  0523	!
;	  0524	!	NONE
;	  0525	!
;	  0526	! SIDE EFFECTS:
;	  0527	!
;	  0528	!	NONE
;	  0529	!
;	  0530	!--
;	  0531	
;	  0532	    BEGIN
;	  0533	
;	  0534	    BIND
;	  0535		ROUTINE_NAME = UPLIT (%ASCIZ'OUTPUT');
;	  0536	
;	  0537	    LOCAL
;	  0538		CHAN,
;	  0539		AC1,
;	  0540		AC2;
;	  0541	
;	  0542	!
;	  0543	! Determine whether the channel is for the terminal or a file then
;	  0544	!  process accordingly.
;	  0545	!
;	  0546	    CHAN = .CHANX;
;	  0547	
;	  0548	    IF (.CHAN EQL 0)
;	  0549	    THEN
;	  0550		BEGIN
;	  0551		AC1 = $PRIOU;				!For Primary OUTPUT media
;	  0552		OUTPUT (LOGGING_FILE, .OUTWRD);		!Log file for terminal output
;	  0553		END
FIO20								25-Jan-1983 10:15:27	TOPS-20 Bliss-36 2A(142)	    Page  22
X2.0-1								 1-Jan-1983 15:44:34	NETPKG:<VNP36>VFIO20.BLI.7 (6)

;	  0554	    ELSE
;	  0555	
;	  0556		IF ((.CHAN LSS 0) OR (.CHAN GTR 15))
;	  0557		THEN
;	  0558		    BEGIN
;	  0559		    ERROR (UPLIT (%ASCIZ'Channel number out of range - OUTPUT'));
;	  0560		    AC1 = 0
;	  0561		    END
;	  0562		ELSE
;	  0563		    AC1 = .CHAN_JFN [.CHAN];
;	  0564	
;	  0565	    IF (.AC1 EQL 0)
;	  0566	    THEN
;	  0567		BEGIN
;	  0568		ERROR (UPLIT (%ASCIZ'Channel not OPEN - OUTPUT'));
;	  0569		RETURN
;	  0570		END;
;	  0571	
;	  0572	!
;	  0573	! The following code either outputs a character immediately in
;	  0574	!  character mode or waits for two bytes in word mode.
;	  0575	!
;	  0576	
;	  0577	    IF ((.CHAN_NEXT [.CHAN] LSS 0) OR (.CHAN EQL 0))
;	  0578	    THEN
;	  0579	
;	  0580		IF (.CHAN_MODE [.CHAN] EQL 2)
;	  0581		THEN
;	  0582		    CHAN_NEXT [.CHAN] = .OUTWRD<0, 8>	!First Byte of word
;	  0583		ELSE
;	  0584		    BEGIN
;	  0585		    AC2 = .OUTWRD;
;	  0586		    JSYS_CALL (0, BOUT, AC1, AC2);
;	  0587		    END
;	  0588	
;	  0589	    ELSE
;	  0590		BEGIN
;	  0591		AC2 = ((.OUTWRD<0, 8>)^8) + .CHAN_NEXT [.CHAN];
;	  0592		JSYS_CALL (0, BOUT, AC1, AC2);
;	  0593		CHAN_NEXT [.CHAN] = -1;
;	  0594		END;
;	  0595	
;	  0596	    END;					!End of OUTPUT


P.AAM:	BYTE	(7)"O","U","T","P","U"		; OUTPU					400500' 117 125 124 120 125
	BYTE	(7)"T",000,000,000,000		; T					400501' 124 000 000 000 000
P.AAN:	BYTE	(7)"C","h","a","n","n"		; Chann					400502' 103 150 141 156 156
	BYTE	(7)"e","l"," ","n","u"		; el nu					400503' 145 154 040 156 165
	BYTE	(7)"m","b","e","r"," "		; mber					400504' 155 142 145 162 040
	BYTE	(7)"o","u","t"," ","o"		; out o					400505' 157 165 164 040 157
	BYTE	(7)"f"," ","r","a","n"		; f ran					400506' 146 040 162 141 156
FIO20								25-Jan-1983 10:15:27	TOPS-20 Bliss-36 2A(142)	    Page  23
X2.0-1								 1-Jan-1983 15:44:34	NETPKG:<VNP36>VFIO20.BLI.7 (6)

	BYTE	(7)"g","e"," ","-"," "		; ge -					400507' 147 145 040 055 040
	BYTE	(7)"O","U","T","P","U"		; OUTPU					400510' 117 125 124 120 125
	BYTE	(7)"T",000,000,000,000		; T					400511' 124 000 000 000 000
P.AAO:	BYTE	(7)"C","h","a","n","n"		; Chann					400512' 103 150 141 156 156
	BYTE	(7)"e","l"," ","n","o"		; el no					400513' 145 154 040 156 157
	BYTE	(7)"t"," ","O","P","E"		; t OPE					400514' 164 040 117 120 105
	BYTE	(7)"N"," ","-"," ","O"		; N - O					400515' 116 040 055 040 117
	BYTE	(7)"U","T","P","U","T"		; UTPUT					400516' 125 124 120 125 124
	BYTE	(7)000,000,000,000,000		;					400517' 000 000 000 000 000


ROUTINE_NAME=	    P.AAM			;						000000	400500'


OUTPUT::PUSH	SP,AC0				; SP,AC0				400520' 261 17 0 00 000000		0502
	PUSH	SP,AC10				; SP,AC10				400521' 261 17 0 00 000010
	PUSH	SP,AC11				; SP,AC11				400522' 261 17 0 00 000011
	MOVE	AC10,-5(SP)			; CHAN,CHANX				400523' 200 10 0 17 777773		0546
	SETZ	AC11,				; AC11,					400524' 400 11 0 00 000000		0548
	JUMPN	AC10,L.44			; CHAN,L.44				400525' 326 10 0 00 400535'
	MOVEI	AC11,1				; AC11,1				400526' 201 11 0 00 000001
	MOVEI	AC0,101				; AC1,101				400527' 201 00 0 00 000101		0551
	PUSH	SP,C.18				; SP,[1]				400530' 261 17 0 00 400615'		0552
	PUSH	SP,-5(SP)			; SP,OUTWRD				400531' 261 17 0 17 777773
	PUSHJ	SP,OUTPUT			; SP,OUTPUT				400532' 260 17 0 00 400520'
	ADJSP	SP,-2				; SP,-2					400533' 105 17 0 00 777776		0550
	JRST	L.47				; L.47					400534' 254 00 0 00 400546'		0548
L.44:	JUMPL	AC10,L.45			; CHAN,L.45				400535' 321 10 0 00 400540'		0556
	CAIG	AC10,17				; CHAN,17				400536' 307 10 0 00 000017
	JRST	L.46				; L.46					400537' 254 00 0 00 400545'
L.45:	PUSH	SP,C.19				; SP,[0,,P.AAN]				400540' 261 17 0 00 400616'		0559
	PUSHJ	SP,ERROR			; SP,ERROR				400541' 260 17 0 00 000000*
	SETZ	AC0,				; AC1,					400542' 400 00 0 00 000000		0560
	ADJSP	SP,-1				; SP,-1					400543' 105 17 0 00 777777		0558
	JRST	L.47				; L.47					400544' 254 00 0 00 400546'		0556
L.46:	MOVE	AC0,CHAN_JFN(AC10)		; AC1,CHAN_JFN(CHAN)			400545' 200 00 0 10 000040'		0563
L.47:	JUMPN	AC0,L.48			; AC1,L.48				400546' 326 00 0 00 400553'		0565
	PUSH	SP,C.20				; SP,[0,,P.AAO]				400547' 261 17 0 00 400617'		0568
	PUSHJ	SP,ERROR			; SP,ERROR				400550' 260 17 0 00 000000*
	ADJSP	SP,-1				; SP,-1					400551' 105 17 0 00 777777		0565
	JRST	L.52				; L.52					400552' 254 00 0 00 400610'		0567
L.48:	MOVE	AC1,CHAN_NEXT(AC10)		; AC1,CHAN_NEXT(CHAN)			400553' 200 01 0 10 000060'		0577
	JUMPL	AC1,L.49			; AC1,L.49				400554' 321 01 0 00 400557'
	TRNN	AC11,1				; AC11,1				400555' 606 11 0 00 000001
	JRST	L.51				; L.51					400556' 254 00 0 00 400575'
L.49:	MOVEI	AC2,2				; AC2,2					400557' 201 02 0 00 000002		0580
	CAME	AC2,CHAN_MODE(AC10)		; AC2,CHAN_MODE(CHAN)			400560' 312 02 0 10 000000'
	JRST	L.50				; L.50					400561' 254 00 0 00 400565'
	LDB	AC1,C.17			; AC1,[POINT 8,OUTWRD,35]  <0,8>	400562' 135 01 0 00 400614'		0582
	MOVEM	AC1,CHAN_NEXT(AC10)		; AC1,CHAN_NEXT(CHAN)			400563' 202 01 0 10 000060'
	JRST	L.52				; L.52					400564' 254 00 0 00 400610'		0580
L.50:	MOVE	AC5,-4(SP)			; AC2,OUTWRD				400565' 200 05 0 17 777774		0585
FIO20								25-Jan-1983 10:15:27	TOPS-20 Bliss-36 2A(142)	    Page  24
X2.0-1								 1-Jan-1983 15:44:34	NETPKG:<VNP36>VFIO20.BLI.7 (6)

	MOVE	AC1,AC0				; T1,AC1				400566' 200 01 0 00 000000		0586
	MOVE	AC2,AC5				; T2,AC2				400567' 200 02 0 00 000005
	JSYS	51				; 51					400570' 104 00 0 00 000051
	SETZ	AC3,				; VALUE,				400571' 400 03 0 00 000000
	MOVE	AC0,AC1				; AC1,T1				400572' 200 00 0 00 000001
	MOVE	AC5,AC2				; AC2,T2				400573' 200 05 0 00 000002
	JRST	L.52				; L.52					400574' 254 00 0 00 400610'		0577
L.51:	LDB	AC2,C.17			; AC2,[POINT 8,OUTWRD,35]  <0,8>	400575' 135 02 0 00 400614'		0591
	LSH	AC2,10				; AC2,10				400576' 242 02 0 00 000010
	MOVE	AC5,AC2				; AC2,AC2				400577' 200 05 0 00 000002
	ADD	AC5,AC1				; AC2,AC1				400600' 270 05 0 00 000001
	MOVE	AC1,AC0				; T1,AC1				400601' 200 01 0 00 000000		0592
	MOVE	AC2,AC5				; T2,AC2				400602' 200 02 0 00 000005
	JSYS	51				; 51					400603' 104 00 0 00 000051
	SETZ	AC3,				; VALUE,				400604' 400 03 0 00 000000
	MOVE	AC0,AC1				; AC1,T1				400605' 200 00 0 00 000001
	MOVE	AC5,AC2				; AC2,T2				400606' 200 05 0 00 000002
	SETOM	CHAN_NEXT(AC10)			; CHAN_NEXT(CHAN)			400607' 476 00 0 10 000060'		0593
L.52:	POP	SP,AC11				; SP,AC11				400610' 262 17 0 00 000011		0502
	POP	SP,AC10				; SP,AC10				400611' 262 17 0 00 000010
	POP	SP,AC0				; SP,AC0				400612' 262 17 0 00 000000
	POPJ	SP,				; SP,					400613' 263 17 0 00 000000
C.17:	POINT	8,-4(SP),35			; 8,OUTWRD,35				400614' 00 10 0 17 777774
C.18:	EXP	1				; 1					400615' 000000	000001
C.19:	XWD	0,P.AAN				; 0,P.AAN				400616' 000000	400502'
C.20:	XWD	0,P.AAO				; 0,P.AAO				400617' 000000	400512'

; Routine Size:  64 words


;	  0597	
FIO20								25-Jan-1983 10:15:27	TOPS-20 Bliss-36 2A(142)	    Page  25
X2.0-1								 1-Jan-1983 15:44:34	NETPKG:<VNP36>VFIO20.BLI.7 (7)

;	  0598	GLOBAL ROUTINE STOP_PROGRAM : NOVALUE = 	!Terminate execution
;	  0599	
;	  0600	!++
;	  0601	! FUNCTIONAL DESCRIPTION:
;	  0602	!
;	  0603	!	Terminates the program. Usually used to stop program when some
;	  0604	!	abnormal condition occurs.
;	  0605	!
;	  0606	! FORMAL PARAMETERS:
;	  0607	!
;	  0608	!	NONE
;	  0609	!
;	  0610	! IMPLICIT INPUTS:
;	  0611	!
;	  0612	!	NONE
;	  0613	!
;	  0614	! IMPLICIT OUTPUTS:
;	  0615	!
;	  0616	!	NONE
;	  0617	!
;	  0618	! COMPLETION CODES:
;	  0619	!
;	  0620	!	NONE
;	  0621	!
;	  0622	! SIDE EFFECTS:
;	  0623	!
;	  0624	!	The program is halted.
;	  0625	!
;	  0626	!--
;	  0627	
;	  0628	    BEGIN
;	  0629	
;	  0630	    BIND
;	  0631		ROUTINE_NAME = UPLIT (%ASCIZ'STOP_PROGRAM');
;	  0632	
;	  0633	    JSYS_CALL (0, HALTF);
;	  0634	    END;					!of RESET_ALL


P.AAP:	BYTE	(7)"S","T","O","P","_"		; STOP_					400620' 123 124 117 120 137
	BYTE	(7)"P","R","O","G","R"		; PROGR					400621' 120 122 117 107 122
	BYTE	(7)"A","M",000,000,000		; AM					400622' 101 115 000 000 000


ROUTINE_NAME=	    P.AAP			;						000000	400620'


STOP_PROGRAM::
	JSYS	170				; 170					400623' 104 00 0 00 000170		0633
	SETZ	AC1,				; VALUE,				400624' 400 01 0 00 000000
	POPJ	SP,				; SP,					400625' 263 17 0 00 000000		0598
FIO20								25-Jan-1983 10:15:27	TOPS-20 Bliss-36 2A(142)	    Page  26
X2.0-1								 1-Jan-1983 15:44:34	NETPKG:<VNP36>VFIO20.BLI.7 (7)

; Routine Size:  3 words


;	  0635	
;	  0636	END						!End of module
;	  0637	
;	  0638	ELUDOM



	END

; Low  segment length:      96 words
; High segment length:     406 words




;				LIBRARY STATISTICS
;
;					     -------- Symbols --------    Blocks
;	File				     Total    Loaded   Percent      Read
;
;  NETPKG:<BRELEASE>MONSYM.L36.2	      3843        25         0         0
;  NETPKG:<BRELEASE>TENDEF.L36.2	        53         4         7         0




; Information:	0
; Warnings:	3
; Errors:	0

;	  0639	! Local Modes:
;	  0640	! Comment Column:36
;	  0641	! Comment Start:!
;	  0642	! Auto Save Mode:2
;	  0643	! Mode:Fundamental
;	  0644	! End:
; Size:		324 code + 178 data words
; Run Time:	00:07.7
; Elapsed Time:	00:37.1
; Memory Used:	41 pages
; Compilation Complete
AC1				  99	 104	 109#	 233	 276#	 278	 285	 305#	 307	 356	 378#	 379
				 423	 442#	 443	 460#	 463#	 465	 481	 539	 551#	 560#	 563#	 565
				 586	 592
AC2				  99	 105	 110#	 234	 275#	 278	 299#	 307	 424	 441#	 443	 481
				 540	 585#	 586	 591#	 592
AC3				  99	 106	 111#	 235	 425	 440#	 443
AC4				  99	 107	 112#
BIN				 481
BOUT				 586	 592
BYTE_SIZE			 232	 293#	 299
CHAN				 230	 240#	 242	 247	 252	 285	 286	 287	 288	 305	 311	 355
				 361#	 363	 368	 373	 378	 380	 421	 431#	 433	 456	 463	 478
				 483	 486	 493	 494	 538	 546#	 548	 556	 563	 577	 580	 582
				 591	 593
CHANX				 190	 240	 320	 361	 385	 431	 502	 546
CHAN_CHAR			 422	 448#	 481#	 483	 486	 487#	 493#	 499
CHAN_DIRECTION			 131	 142	 287#
CHAN_JFN			 132	 252	 285#	 305	 311#	 373	 378	 380#	 463	 563
CHAN_MODE			 130	 141	 286#	 483	 580
CHAN_NEXT			 133	 143	 288#	 478	 486#	 493	 494#	 577	 582#	 591	 593#
CLOSE				  81	 320*
CLOSF				 379
DEFEXT				 190	 274
ERRMSG				 151	 281	 310
ERROR				 150*	 244	 249	 254	 365	 370	 375	 459	 468	 559	 568
FIO20				   3#
FLD				 299
FNAME				 190	 275	 281	 310
FOO				 270	 271
FUNC				  99	 108
GJ_FOU				 266
GJ_NEW				 266
GJ_OLD				 265
GTJFN_BLOCK			 231	 263#	 271#	 273#	 274#	 276
GTJFN				 278
HALTF				 633
INPUT				  82	 385*
IO				 190	 263	 287	 299
JSYS				 103	 108
JSYS_CALL			  99#	 187	 278	 307	 379	 443	 481	 586	 592	 633
LEN_LINE_BUFF			 122#	 134	 441	 445
LINE_BUFF			 134	 442	 444
LINE_LEN			 141#	 445#	 450#
LINE_PTR			 143#	 437	 444#	 448	 450#
LINE_STATUS			 142#	 443#	 445
LOGGING_FILE			 123#	 552
MODE				 190	 286	 293
OF_BSZ				 299
OF_RD				 301
OF_WR				 302
OPEN				  80	 190*
OPENF				 307
OUTPUT				  83	 502*	 552
OUTWRD				 502	 552	 582	 585	 591
RDTTY				 443
RD_RAI				 441
RD_TOP				 441
RESET_ALL			  79	 153*
RESET				 187
ROUTINE_NAME			 185#	 227#	 281	 310	 352#	 418#	 535#	 631#
STOP_PROGRAM			  84	 598*
T1				 101#	 104#	 108	 109
T2				 101#	 105#	 108	 110
T3				 101#	 106#	 108	 111
T4				 101#	 107#	 108	 112
TYPE				  99	 108
VALUE				 102	 108#	 113#
$GJDEV				 270
$GJEXT				 274
$GJGEN				 263
$GJJFN				 270
$GJSRC				 273
$PRIOU				 551