Google
 

Trailing-Edge - PDP-10 Archives - AP-4178E-RM - swskit-sources/crdrv.lis
There are no other files named crdrv.lis in the archive.
CRDRV	(CD-11 DRIVER FOR RSX10	MACRO M1108  13-JAN-78 14:10
TABLE OF CONTENTS

    1-   2	TITLE PAGE
    2-  37	COMMON PARAMETERS AND MACROS
    3-  65	CD-11 DEVICE REGISTER BIT DEFINITIONS
    5-   1	COMMON DEVICE PARAMETER MODULE
    6-  34	DEVICE STATUS BIT DEFINITIONS
    8-   1	CD-11 DRIVER COMMON DATA MODULE
    9-  33	COMMON DATABASE DEFINITIONS
   11-   1	CD-11 DRIVER TASK MODULE
   12-  33	TASK INITIALIZATION
   13-  67	CRLOOP (MAIN PROCESSING LOOP)
   14- 186	SSTSCR	(SEND CD-11 STATUS TO -10)
   15- 331	INITCR	(INITIALIZE CD-11)
   17-   1	CD-11 DRIVER COMMON SUBROUTINES MODULE
   18-  39	$CDINT	(CD-11 INTERRUPT SERVICE)
   19-  68	..STCR	(START CD-11)
   20-  97	..SPCR	(STOP CD-11)
   21- 120	..AKCR	(READ CARD)
   23-   1	END
CRDRV	(CD-11 DRIVER FOR RSX10	MACRO M1108  13-JAN-78 14:10  PAGE 1


      1						.TITLE	CRDRV	(CD-11 DRIVER FOR RSX10F)
      2						.SBTTL	TITLE PAGE
      3						.IDENT	/001000/
      4					;
      5					;                             COPYRIGHT (C) 1975, 1978 BY
      6					;                     DIGITAL EQUIPMENT CORPORATION, MAYNARD MASS.
      7					;
      8					;       THIS SOFTWARE IS FURNISHED UNDER A LICENSE AND MAY BE  USED  AND  COPIED
      9					;       ONLY IN ACCORDANCE WITH THE TERMS OF SUCH LICENSE AND WITH THE INCLUSION
     10					;       OF THE ABOVE COPYRIGHT NOTICE.  THIS SOFTWARE OR ANY OTHER COPIES THERE-
     11					;       OF  MAY NOT BE PROVIDED OR OTHERWISE MADE AVAILABLE TO ANY OTHER PERSON.
     12					;       NO TITLE TO OR OWNERSHIP OF THE SOFTWARE IS HEREBY TRANSFERRED.
     13					;
     14					;       THE INFORMATION CONTAINED IN THIS SOFTWARE IS SUBJECT TO CHANGE  WITHOUT
     15					;       NOTICE  AND SHOULD NOT BE CONSTRUED AS A COMMITMENT BY DIGITAL EQUIPMENT
     16					;       CORPORATION.
     17					;
     18					;       DIGITAL ASSUMES NO RESPONSIBILITY FOR THE  USE  OR  RELIABILITY  OF  ITS
     19					;       SOFTWARE ON EQUIPMENT WHICH IS NOT SUPPILED BY DIGITAL.
     20					;
     21					;		MODULE: COMMON DEFINITIONS
     22					;
     23					;		VERSION: 01-00
     24					;
     25					;		AUTHOR: TOM PORCHER
     26					;
     27					;		DATE: 25-SEP-75
     28					;
     29					;
     30					;	THIS MODULE CONTAINS:
     31					;
     32					;	1) COMMON PARAMETERS AND MACROS
     33					;
     34					;	2) CD-11 DEVICE REGISTER DEFINITIONS
     35					;
CRDRV	(CD-11 DRIVER FOR RSX10	MACRO M1108  13-JAN-78 14:10  PAGE 2
COMMON PARAMETERS AND MACROS

     37						.SBTTL	COMMON PARAMETERS AND MACROS
     38					;
     39					; MISC. MCALLS
     40					;
     41					.MCALL MRKT$,SPRA$S,SVTK$S,WTLO$S,WTSE$S,WSIG$S
     42					.MCALL DIR$,$DEF,CALL,RETURN,.INH,.ENB,PUSH,POP,.STKM
     43	000000					$DEF
     44						.ENABLE	AMA
     45						.LIST	MEB
     46					;
     47					; PARAMETERS
     48					;
     49		000001 			C$$D11=	1			;ONLY 1 CD-11
     50					;
     51					; EVENT FLAGS
     52					;
     53		000001 			E.FCRC= 1			;CD-11 MARK-TIME REQUEST
     54		000001 			 EF.CRC=BIT0
     55		000002 			E.FCRD=	2			;I/O DONE FROM INTERRUPT LEVEL
     56		000002 			 EF.CRD=BIT1
     57		000003 			E.FCRS=	3			;BUFFER AVAILABLE FOR STATUS
     58		000004 			 EF.CRS=BIT2
     59		000004 			E.FCRB=	4			;DATA BUFFER AVAILABLE
     60		000010 			 EF.CRB=BIT3
     61					;
     62					;
     63		000074 			.CYLTM=60.
CRDRV	(CD-11 DRIVER FOR RSX10	MACRO M1108  13-JAN-78 14:10  PAGE 3
CD-11 DEVICE REGISTER BIT DEFINITIONS

     65						.SBTTL	CD-11 DEVICE REGISTER BIT DEFINITIONS
     66					;
     67					;
     68		177160 			CDST=	177160			;CONTROL/STATUS REGISTER
     69		100000 				CDSERR=	BIT15
     70		040000 				CDSRCK=	BIT14
     71		020000 				CDSEOF=	BIT13
     72		010000 				CDSOFL=	BIT12
     73		004000 				CDSDER=	BIT11
     74		002000 				CDSDLT=	BIT10
     75		001000 				CDSNXM=	BIT9
     76		000400 				CDSPWC=	BIT8
     77		000200 				CDSRDY=	BIT7
     78		000100 				CDSIEN=	BIT6
     79		000040 				CDSB17=	BIT5
     80		000020 				CDSB16=	BIT4
     81		000010 				CDSTOL=	BIT3
     82		000004 				CDSHEM=	BIT2
     83		000002 				CDSPAK=	BIT1
     84		000001 				CDSRED=	BIT0
     85		177162 			CDCC=	177162			;COLUMN COUNT REGISTER
     86		177164 			CDBA=	177164			;BUS ADDRESS BITS 15-0
     87		177166 			CDDB=	177166			;DATA BUFFER REGISTER
     88					;AFTER DATA TRANSFERS (CDSRDY= 1):
     89		040000 				CDBRCK=	BIT14
     90		020000 				CDBPCK=	BIT13
     91		010000 				CDBSCK=	BIT12
CRDRV	(CD-11 DRIVER FOR RSX10	MACRO M1108  13-JAN-78 14:10  PAGE 5
COMMON DEVICE PARAMETER MODULE

      1						.SBTTL	COMMON DEVICE PARAMETER MODULE
      2					;
      3					;                             COPYRIGHT (C) 1975, 1978 BY
      4					;                     DIGITAL EQUIPMENT CORPORATION, MAYNARD MASS.
      5					;
      6					;       THIS SOFTWARE IS FURNISHED UNDER A LICENSE AND MAY BE  USED  AND  COPIED
      7					;       ONLY IN ACCORDANCE WITH THE TERMS OF SUCH LICENSE AND WITH THE INCLUSION
      8					;       OF THE ABOVE COPYRIGHT NOTICE.  THIS SOFTWARE OR ANY OTHER COPIES THERE-
      9					;       OF  MAY NOT BE PROVIDED OR OTHERWISE MADE AVAILABLE TO ANY OTHER PERSON.
     10					;       NO TITLE TO OR OWNERSHIP OF THE SOFTWARE IS HEREBY TRANSFERRED.
     11					;
     12					;       THE INFORMATION CONTAINED IN THIS SOFTWARE IS SUBJECT TO CHANGE  WITHOUT
     13					;       NOTICE  AND SHOULD NOT BE CONSTRUED AS A COMMITMENT BY DIGITAL EQUIPMENT
     14					;       CORPORATION.
     15					;
     16					;       DIGITAL ASSUMES NO RESPONSIBILITY FOR THE  USE  OR  RELIABILITY  OF  ITS
     17					;       SOFTWARE ON EQUIPMENT WHICH IS NOT SUPPILED BY DIGITAL.
     18					;
     19					;
     20					;		MODULE: COMMON DEVICE PARAMETERS
     21					;
     22					;		VERSION: 01-00
     23					;
     24					;		AUTHOR: TOM PORCHER
     25					;
     26					;		DATE: 25-AUG-75
     27					;
     28					;
     29					;	THIS MODULE CONTAINS:
     30					;
     31					;	1) DEVICE STATUS BIT DEFINITIONS
     32					;
CRDRV	(CD-11 DRIVER FOR RSX10	MACRO M1108  13-JAN-78 14:10  PAGE 6
DEVICE STATUS BIT DEFINITIONS

     34						.SBTTL	DEVICE STATUS BIT DEFINITIONS
     35					;
     36					; GENERAL FORM OF STATUS BLOCK
     37					;
     38					; WORD	0	STANDARD STAUS BITS (DV.XXX)
     39					; 	1	DEVICE-DEPENDENT BITS (DD.XXX)
     40					;	2	(HIGH BYTE) # BYTES OF DEVICE-DEPENDENT INFO TO FOLLOW
     41					;		(LOW BYTE) # BYTES OF DEVICE REGISTERS TO FOLLOW
     42					;	3-...	DEVICE DEPENDENT INFO (# BYTES IN WORD 2)
     43					;	.-...	DEVICE REGISTERS (# BYTES IN WORD 2)
     44					;
     45					;
     46					; STANDARD BITS (FIRST WORD OF STATUS)
     47					;
     48		000001 			DV.NXD=	BIT0			;NON-EX DEVICE
     49		000002 			DV.OFL=	BIT1			;OFF-LINE
     50		000004 			DV.OIR=	BIT2			;HARDWARE ERROR. OPERATOR INTERVENTION REQUIRED.
     51		000010 			DV.SCN=	BIT3			;SOFTWARE CONDITON. ACKNOWLEDGE REQUIRED.
     52		000020 			DV.IOP=	BIT4			;I/O IN PROGRESS
     53		000040 			DV.EOF=	BIT5			;END-OF-FILE ENCOUNTERED
     54		000100 			DV.LOG=	BIT6			;ERROR LOGGING REQUIRED
     55		000200 			DV.URE=	BIT7			;UN-RECOVERABLE ERROR
     56		000400 			DV.F11=	BIT8			;ERROR ON FROM -11 REQUEST
     57		001000 			DV.HNG=	BIT9			;DEVICE HUNG
     58					;
     59					;
     60					; DEVICE-DEPENDENT BITS (SECOND WORD OF STATUS)
     61					;
     62					; LP-20 LINEPRINTER
     63					;
     64		000001 			DD.PGZ=	BIT0			;PAGE COUNTER PASSED ZERO
     65		000002 			DD.CHI=	BIT1			;CHARACTER INTERRUPT (FROM RAM)
     66		000004 			DD.VFE=	BIT2			;VFU ERROR-- PAPER RE-ALIGNMENT REQUIRED
     67		000010 			DD.LER=	BIT3			;ERROR FINDING/READING VF AND RAM FILE
     68		000020 			DD.OVF=	BIT4			;PRINTER HAS OPTICAL VFU (AS OPPOSED TO DAVFU)
     69		000040 			DD.RME=	BIT5			;RAM PARITY ERROR-- RELOAD REQUIRED
     70					;
     71					; DEVICE DEPNDENT INFO FOR LP-20 (2 BYTES):
     72					; WORD	3	(LOW BYTE) ACCUMULATED CHECKSUM
     73					;		(HIGH BYTE) RETRY COUNT
     74					;
     75					;	4-13	LP-20 DEVICE REGISTERS (16. BYTES)
     76					;
     77					;
     78					; CD-11 CARD READER
     79					;
     80		000001 			DD.RCK=	BIT0			;READ (PHOTO) CHECK
     81		000002 			DD.PCK=	BIT1			;PICK CHECK
     82		000004 			DD.SCK=	BIT2			;STACK CHECK
     83		000010 			DD.HEM=	BIT3			;HOPPER EMPTY
     84		000020 			DD.SFL=	BIT4			;STACKER FULL
     85					;
     86					; DEVICE-DEPENDENT INFO FOR CD-11 (0 BYTES)
     87					; WORD	3-6	DEVICE REGISTERS FOR CD-11 (8. BYTES)
CRDRV	(CD-11 DRIVER FOR RSX10	MACRO M1108  13-JAN-78 14:10  PAGE 8
CD-11 DRIVER COMMON DATA MODULE

      1						.SBTTL	CD-11 DRIVER COMMON DATA MODULE
      2					;
      3					;                             COPYRIGHT (C) 1975, 1978 BY
      4					;                     DIGITAL EQUIPMENT CORPORATION, MAYNARD MASS.
      5					;
      6					;       THIS SOFTWARE IS FURNISHED UNDER A LICENSE AND MAY BE  USED  AND  COPIED
      7					;       ONLY IN ACCORDANCE WITH THE TERMS OF SUCH LICENSE AND WITH THE INCLUSION
      8					;       OF THE ABOVE COPYRIGHT NOTICE.  THIS SOFTWARE OR ANY OTHER COPIES THERE-
      9					;       OF  MAY NOT BE PROVIDED OR OTHERWISE MADE AVAILABLE TO ANY OTHER PERSON.
     10					;       NO TITLE TO OR OWNERSHIP OF THE SOFTWARE IS HEREBY TRANSFERRED.
     11					;
     12					;       THE INFORMATION CONTAINED IN THIS SOFTWARE IS SUBJECT TO CHANGE  WITHOUT
     13					;       NOTICE  AND SHOULD NOT BE CONSTRUED AS A COMMITMENT BY DIGITAL EQUIPMENT
     14					;       CORPORATION.
     15					;
     16					;       DIGITAL ASSUMES NO RESPONSIBILITY FOR THE  USE  OR  RELIABILITY  OF  ITS
     17					;       SOFTWARE ON EQUIPMENT WHICH IS NOT SUPPILED BY DIGITAL.
     18					;
     19					;		MODULE: CD-11 DRIVER COMMON DATA
     20					;
     21					;		VERSION: 01-00
     22					;
     23					;		AUTHOR: TOM PORCHER
     24					;
     25					;		DATE: 25-AUG-75
     26					;
     27					;
     28					;	THIS MODULE CONTAINS:
     29					;
     30					;	1) COMMON DATABASE DEFINITIONS
     31					;
CRDRV	(CD-11 DRIVER FOR RSX10	MACRO M1108  13-JAN-78 14:10  PAGE 9
COMMON DATABASE DEFINITIONS

     33						.SBTTL	COMMON DATABASE DEFINITIONS
     34					;
     35					;
     36					; CR TASK STACK HEADER
     37					;
     38	000000				CRHD::	.STKM	0,0,0,0,0,0,0,CRINI,174000,CRSTK
	000046	000000 	000000 	000000 		.WORD	0,0,0,0
	000054	000000
	000074	174000 	000730'	000260'		.WORD	174000,CRINI,CRSTK
	000130	000005 				.WORD	5
	000132	000000G				.WORD	TTPEN
	000134	000000 				.WORD	0
	000136	000000 				.WORD	0
	000140	000000 				.WORD	0
	000142	000000 				.WORD	0
	000144	000000 				.WORD	0
	000146	000000 				.WORD	0
	000150	000000 				.WORD	0
	000152	000000 				.WORD	0
	000154	000000 				.WORD	0
	000156	000000 				.WORD	0
	000260	000000 				.WORD	0
	000262	000000 				.WORD	0
	000264	000000 				.WORD	0
	000266	000000 				.WORD	0
	000270	000000 				.WORD	0
	000272	000000 				.WORD	0
	000274	000730'				.WORD	CRINI
	000276	174000 				.WORD	174000
     39					;
     40					; COMMON VARIABLES
     41					;
     42	000300	000302'			CREVFG:	.WORD	CRCEVF		;ADDRESS OF CR TASK'S EVENT FLAGS
     43	000302				CRCEVF:	.BLKW	1		;CURRENT EVENT FLAGS
     44	000304	000000 			CRHUNG:	.WORD	0		;# TIMES CR WAS CAUGHT SNOOZING
     45	000306	000000 			.CRPFL::.WORD	0		;POWER FAIL FLAG FOR CARD READER
     46					;
     47	000310				CRSTBH:	.BLKW	1		;HEADER WORD (UNIT/BYTE COUNT) OF STATUS BLOCK
     48	000312				CRSTBK:	.BLKW	2+1+<<CDDB+2-CDST>/2> ;STATUS RETURN BLOCK TO -10
     49		000016 			CRSTLN=.-CRSTBK
     50					;
     51	000330				CRBUFH:	.BLKW	1		;HEADER WORD (UNIT/BYTE COUNT) OF DATA BUFFER
     52	000332				CRBUFF:	.BLKW	80.		;DATA BUFFER FROM CD-11
     53		000240 			CRBFLN=.-CRBUFF
     54						.BLKW	20.		;FOR OVERRUN
     55					;
     56					; CR DEVICE STATUS TABLE
     57					;
     58	000642				CRTBL::
     59		000642'			CRTHD=.				;THREADED LIST POINTER (FOR ..STCR)
     60	000642	000000 				.WORD	0
     61		000644'			CREXP=.				;EXTERNAL PAGE ADDR OF CD-11
     62	000644	177160 				.WORD	CDST
     63		000646'			CRSTS=.				;STATUS BITS:
     64		100000 				CR.HNG=	BIT15		;CR IS HUNG, I.E. NO INPUT HAS OCCURED
     65									; IN 10 SECONDS.  SET AND CHECKED BY
     66									; MARK-TIME SERVICE, CLEARED BY I/O
CRDRV	(CD-11 DRIVER FOR RSX10	MACRO M1108  13-JAN-78 14:10  PAGE 9-1
COMMON DATABASE DEFINITIONS

     67									; DONE AT INTERRUPT.
     68		040000 				CR.SST=	BIT14		;A CHANGE IN DEVICE STATUS HAS OCCURED,
     69									; OR THE -10 HAS REQUESTED THE STATUS OF
     70									; THE CR.
     71		020000 				CR.IOP=	BIT13		;I/O IN PROGRESS. SET WHEN READ CARD STARTED,
     72									; CLEARED WHEN DONE INTERRUPT OCCURS.
     73		010000 				CR.IOD=	BIT12		;I/O DONE FROM INTERRUPT LEVEL. SET WHEN A
     74									; DATA BUFFER IS READY TO BE SENT TO THE -10.
     75		004000 				CR.ACK=	BIT11		;ACKNOWLEDGE RECEIVED.  READ NEXT CARD.
     76									; SET WHEN ACK RECEIVED FROM -10 (..AKCR).
     77		002000 				CR.RHN=	BIT10		;READER HUNG DURING READ. SET BY MKT ROUTINE
     78									; TESTED AND CLEARED BY SSTSCR
     79		001000 				CR.NXD=	BIT9		;NON-EX CD-11. SET BY INITCR, CHECKED
     80									; BEFORE TRANSFER STARTED.
     81		000400 				CR.NSF=	BIT8		;NOT STACKER FULL.  SET WHEN ANY OTHER ERROR
     82									; CONDITION IS SET.
     83	000646	000000 				.WORD	0
     84	000650	000000 				.WORD	0		;(NOT USED)
     85					;
     86		000010 			CRSIZE=.-CRTBL
     87					;
     88					; DIRECTIVE PARAMETER BLOCKS
     89					;
     90	000652				MRKTDP:	MRKT$	E.FCRC,10.*.CYLTM,10.*.CYLTM ;MARK-TIME REQUEST FOR 10 SECONDS
	000652	   027 	   005 			.BYTE	23.,5
	000654	000001 				.WORD	E.FCRC
	000656	001130 				.WORD	10.*.CYLTM
	000660	001130 				.WORD	10.*.CYLTM
	000662	000000 				.WORD
CRDRV	(CD-11 DRIVER FOR RSX10	MACRO M1108  13-JAN-78 14:10  PAGE 11
CD-11 DRIVER TASK MODULE

      1						.SBTTL	CD-11 DRIVER TASK MODULE
      2					;
      3					;                             COPYRIGHT (C) 1975, 1978 BY
      4					;                     DIGITAL EQUIPMENT CORPORATION, MAYNARD MASS.
      5					;
      6					;       THIS SOFTWARE IS FURNISHED UNDER A LICENSE AND MAY BE  USED  AND  COPIED
      7					;       ONLY IN ACCORDANCE WITH THE TERMS OF SUCH LICENSE AND WITH THE INCLUSION
      8					;       OF THE ABOVE COPYRIGHT NOTICE.  THIS SOFTWARE OR ANY OTHER COPIES THERE-
      9					;       OF  MAY NOT BE PROVIDED OR OTHERWISE MADE AVAILABLE TO ANY OTHER PERSON.
     10					;       NO TITLE TO OR OWNERSHIP OF THE SOFTWARE IS HEREBY TRANSFERRED.
     11					;
     12					;       THE INFORMATION CONTAINED IN THIS SOFTWARE IS SUBJECT TO CHANGE  WITHOUT
     13					;       NOTICE  AND SHOULD NOT BE CONSTRUED AS A COMMITMENT BY DIGITAL EQUIPMENT
     14					;       CORPORATION.
     15					;
     16					;       DIGITAL ASSUMES NO RESPONSIBILITY FOR THE  USE  OR  RELIABILITY  OF  ITS
     17					;       SOFTWARE ON EQUIPMENT WHICH IS NOT SUPPILED BY DIGITAL.
     18					;
     19					;		MODULE: CD-11 DRIVER TASK
     20					;
     21					;		VERSION: 01-00
     22					;
     23					;		AUTHOR: TOM PORCHER
     24					;
     25					;		DATE: 25-AUG-75
     26					;
     27					;
     28					;	THIS MODULE CONTAINS:
     29					;
     30					;	1) TASK LEVEL SERVICE FOR CD-11
     31					;
CRDRV	(CD-11 DRIVER FOR RSX10	MACRO M1108  13-JAN-78 14:10  PAGE 12
TASK INITIALIZATION

     33						.SBTTL	TASK INITIALIZATION
     34					;
     35					; SST VECTOR TABLE
     36					;
     37	000664	000666'			SSTVTB:	.WORD	TRAP04		;WHERE TO GO ON TRAP TO 4
     38					;
     39					; HERE ON TRAP TO 4, HOPEFULLY JUST NON-EX CR
     40					;
     41	000666	021627 	001400'		TRAP04:	CMP	(SP),#INTINS	;FROM MARK-TIME?
     42	000672	001404 				BEQ	10$		;YES-- OK
     43	000674	021627 	002132'			CMP	(SP),#CLRINS	;OR FROM INIT?
     44	000700	001401 				BEQ	10$		;YES-- ALSO OK
     45	000702	000004 				IOT			;***** NO, NOT OUR T04 *****
     46					;
     47	000704	052737 	001000 	000646'	10$:	BIS	#CR.NXD,CRSTS	;SAY NON-EX CR
     48	000712	052766 	000001 	000002 		BIS	#BIT0,2(SP)	;SET THE CARRY TO THE SST
     49	000720	000002 				RTI			;RETURN TO INTERRPUTED ROUTINE
     50					;
     51					; HERE ON POWER-UP AST
     52					;
     53	000722				CRPWUP:	CALL	INITCR		;RESET THE CR
	000722	004737 	002116'			JSR	PC,INITCR
     54	000726	000002 				RTI			;RETURN FROM AST
     55					;
     56					; HERE TO START CR TASK
     57					;
     58	000730	013737 	000000G	000300'	CRINI:	MOV	.CRTSK,CREVFG	;GET ADDRESS OF OUR TASK'S ENTRY
     59	000736	062737 	000000G	000300'		ADD	#A.EF,CREVFG	;MAKE THAT ADDRESS OF OUR EVENT FLAGS
     60	000744	052777 	000014 	177326 		BIS	#EF.CRB!EF.CRS,@CREVFG ;SAY OUR BUFFERS ARE AVAILABLE
     61	000752					DIR$	#MRKTDP		;SETUP FOR 10-SECOND MARK-TIME'S
	000752	012746 	000652'			MOV	#MRKTDP,-(SP)
	000756	104375 				EMT	375
     62	000760					SVTK$S	#SSTVTB,#1	;SETUP FOR TRAP-TO-4 RECOGNITION
	000760	012746 	000001 			MOV	#1,-(SP)
	000764	012746 	000664'			MOV	#SSTVTB,-(SP)
	000770	012746 				MOV	(PC)+,-(SP)
	000772	   071 	   003 			.BYTE	57.,3
	000774	104375 				EMT	375
     63	000776					SPRA$S	#CRPWUP		;SETUP FOR POWER-UP AST
	000776	012746 	000722'			MOV	#CRPWUP,-(SP)
	001002	012746 				MOV	(PC)+,-(SP)
	001004	   155 	   002 			.BYTE	109.,2
	001006	104375 				EMT	375
     64	001010					CALL	INITCR		;INITIALIZE CD-11 AND TABLES
	001010	004737 	002116'			JSR	PC,INITCR
     65					;	BR	CRLOOP		;FALL INTO PROCESSING LOOP
CRDRV	(CD-11 DRIVER FOR RSX10	MACRO M1108  13-JAN-78 14:10  PAGE 13
CRLOOP (MAIN PROCESSING LOOP)

     67						.SBTTL	CRLOOP (MAIN PROCESSING LOOP)
     68					;
     69					; WAIT  FOR EVENT FLAGS EF.CRC (10 SEC MARK-TIME), EF.CRD (I/O DONE).
     70					;
     71	001014				CRLOOP:	WTLO$S	1,#EF.CRC!EF.CRD ;WAIT FOR FLAGS
	001014	012746 	000003 			MOV	#EF.CRC!EF.CRD,-(SP)
	001020	012746 	000001 			MOV	#1,-(SP)
	001024	012746 				MOV	(PC)+,-(SP)
	001026	   053 	   003 			.BYTE	43.,3
	001030	104375 				EMT	375
     72					;
     73	001032					.INH			;;;A FLAG WAS SET-- LOCK OUT INTERRUPTS
	001032	013746 	177776 			MOV	PS,-(SP)
	001036	112737 	000340 	177776 		MOVB	#PR7,@#PS	;;
     74	001044	017737 	177230 	000302'		MOV	@CREVFG,CRCEVF	;;;GET OUR CURRENT EVENT FLAGS
     75	001052	042777 	000003 	177220 		BIC	#EF.CRC!EF.CRD,@CREVFG ;;;CLEAR THE FLAGS WE WAITED FOR
     76	001060					.ENB			;INTERRUPTS: ON!
	001060	012637 	177776 			MOV	(SP)+,@#PS	;;
     77	001064	005737 	000306'			TST	.CRPFL		;POWER FAIL?
     78	001070	001404 				BEQ	10$		;NO -- FORGET IT
     79	001072					CALL	INITCR		;YES -- INIT CR
	001072	004737 	002116'			JSR	PC,INITCR
     80	001076	005037 	000306'			CLR	.CRPFL
     81	001102				10$:
     82					;
     83					; SEE IF THIS IS EF.CRD (I/O DONE), AND FIND OUT WHY IT WAS SET.
     84					;
     85	001102	032737 	000002 	000302'	CRIOD:	BIT	#EF.CRD,CRCEVF	;THIS EF.CRD?
     86	001110	001517 				BEQ	90$		;NO-- TRY FOR MARK-TIME
     87					;
     88					; SEE IF A BUFFER IS READY TO BE SENT TO THE -10 (CR.IOD SET BY INTERRUPT SERVICE)
     89					;
     90	001112	032737 	010000 	000646'		BIT	#CR.IOD,CRSTS	;WE FINISH A TRANSFER?
     91	001120	001430 				BEQ	20$		;NO-- GO ON
     92	001122	012700 	000332'			MOV	#CRBUFF,R0	;YES-- GET ADDRESS OF BUFFER
     93					;
     94					; WE MUST SEND A DATA BUFFER TO THE -10.  SET UP FOR ..STIN:
     95					;	R0 --	ADDRESS OF BUFFER. FIRST WORD IS (LOW BYTE) BYTE COUNT
     96					;		OF BUFFER (NOT INCLUDING HEADER WORD), (HIGH BYTE) UNIT #.
     97					;	R1 --	BIT15+ FUNCTION CODE (BC.STR-- STRING DATA)
     98					;	R2 --	EVENT FLAG TO SET WHEN DONE
     99					;	R3 --	DEVICE CODE (D.CCDR)
    100					;
    101	001126	105040 				CLRB	-(R0)		;HIGH BYTE HEADER: UNIT # (ALWAYS 0)
    102	001130	112740 	000240 			MOVB	#CRBFLN,-(R0)	;LOW BYTE HEADER: SIZE OF BUFFER
    103	001134	012701 	100000G			MOV	#BIT15+BC.STR,R1 ;FUNCTION CODE: STRING DATA (INDIRECT FLAVOR)
    104	001140	012702 	000004 			MOV	#E.FCRB,R2	;EVENT FLAG TO SET WHEN DONE
    105	001144	012703 	000000G			MOV	#D.CCDR,R3	;DEVICE CODE: CDR
    106	001150	042777 	000010 	177122 		BIC	#EF.CRB,@CREVFG	;ASSUME SUCCESS
    107	001156					CALL	..STIN		;SEND TO -10
	001156	004737 	000000G			JSR	PC,..STIN
    108	001162	103404 				BCS	10$		;GIVE UP-- PRIMARY PROTOCOL (DDT)
    109	001164	042737 	112400 	000646'		BIC	#CR.IOD!CR.HNG!CR.RHN!CR.NSF,CRSTS ;OK-- NO LONGER BUFFER TO SEND
    110	001172	000403 				BR	20$		;GO ON
    111					;
    112	001174	052777 	000010 	177076 	10$:	BIS	#EF.CRB,@CREVFG	;..STIN FAILED-- BUFFER STILL AVAILABLE
    113					;
CRDRV	(CD-11 DRIVER FOR RSX10	MACRO M1108  13-JAN-78 14:10  PAGE 13-1
CRLOOP (MAIN PROCESSING LOOP)

    114					; SEE IF STATUS IS TO BE SENT TO -10, EITHER BECAUSE OF A CHANGE IN
    115					;  DEVICE STATUS OR A REQUEST FROM THE -10.
    116					;
    117	001202	032737 	040000 	000646'	20$:	BIT	#CR.SST,CRSTS	;TIME TO SEND DEVICE STATUS?
    118	001210	001402 				BEQ	30$		;NO-- GO ON
    119	001212					CALL	SSTSCR		;YES-- SEND SUCH TO -10
	001212	004737 	001510'			JSR	PC,SSTSCR
    120					;
    121					; SEE IF -10 WANTS US TO READ NEXT CARD, BY CR.ACK SET.
    122					;
    123	001216	032737 	004000 	000646'	30$:	BIT	#CR.ACK,CRSTS	;-10 WANT A CARD?
    124	001224	001451 				BEQ	90$		;NO-- ALL DONE
    125	001226	032737 	030000 	000646'		BIT	#CR.IOP!CR.IOD,CRSTS ;STILL I/O IN PROGRESS?
    126	001234	001045 				BNE	90$		;YES-- COME BACK LATER WHEN WE ARE DONE
    127	001236	042737 	106000 	000646'		BIC	#CR.ACK!CR.HNG!CR.RHN,CRSTS ;YES-- NO LONGER WANTING
    128	001244	032737 	001000 	000646'		BIT	#CR.NXD,CRSTS	;THIS NON-EX CD-11?
    129	001252	001017 				BNE	32$		;YES-- JUST SEND STATUS
    130	001254	032777 	000010 	177016 	34$:	BIT	#EF.CRB,@CREVFG	;BUFFER AVAILABLE TO US YET?
    131	001262	001007 				BNE	31$		;YES-- ALL OK
    132	001264					WSIG$S			;WAIT FOR SOMETHING TO HAPPEN
	001264	012746 				MOV	(PC)+,-(SP)
	001266	   061 	   001 			.BYTE	49.,1
	001270	104375 				EMT	375
    133	001272	032737 	000000G	000002G		BIT	#EF.PR1,.COMEF+2 ;IS PRIMARY PROTOCOL STILL RUNNING ?
    134	001300	001365 				BNE	34$		;YES, SEE IF BUFFER IS NOW FREE.
    135					;
    136	001302	032737 	010000 	177160 	31$:	BIT	#CDSOFL,@#CDST	;CD-11 OFF-LINE?
    137	001310	001403 				BEQ	33$		;NO-- LET'S START TRANSFER
    138	001312				32$:	CALL	SSTSCR		;YES-- TELL -10
	001312	004737 	001510'			JSR	PC,SSTSCR
    139	001316	000414 				BR	90$		; AND GO AWAY FOR NOW
    140					;
    141					; START TRNSFER OF CARD TO CRBUFF
    142					;
    143	001320	052737 	020000 	000646'	33$:	BIS	#CR.IOP,CRSTS	;SAY I/O NOW IN PROGRESS
    144	001326	012737 	177660 	177162 		MOV	#-<CRBFLN/2>,@#CDCC ;INDICATE TO READ 80. COLUMNS
    145	001334	012737 	000332'	177164 		MOV	#CRBUFF,@#CDBA	; INTO CRBUFF
    146	001342	012737 	000101 	177160 		MOV	#CDSIEN!CDSRED,@#CDST ;START CARD GOING
    147					;
    148					; ALL DONE WITH EF.CRD
    149					;
    150	001350				90$:
    151					;
    152					; CHECK FOR MARK-TIME REQUEST (EF.CRC SET), THEN DO HUNG CHECK IF SO.
    153					;
    154						.ENABLE LSB
    155	001350	032737 	000001 	000302'	CRMKT:	BIT	#EF.CRC,CRCEVF	;MARK-TIME REQUEST EVENT FLAG SET?
    156	001356	001452 				BEQ	90$		;NO-- GO ON
    157	001360	032737 	001000 	000646'		BIT	#CR.NXD,CRSTS	;NON-EX CR?
    158	001366	001011 				BNE	9$		;YES-- SKIP INT-ENB STUFF
    159	001370	000241 				CLC			;IN CASE OF TRAP
    160	001372	032737 	000100 	177160 		BIT	#CDSIEN,@#CDST	;INT-ENB STILL SET?
    161	001400	103404 			INTINS:	BCS	9$		;NON-EX CR-- GO ON
    162	001402	001003 				BNE	9$		;YES-- SKIP THE SET
    163	001404	052737 	000100 	177160 		BIS	#CDSIEN,@#CDST	;YES-- MAKE SURE WE STILL HAVE INT-ENB
    164	001412	032737 	074000 	000646'	9$:	BIT	#CR.SST!CR.IOD!CR.ACK!CR.IOP,CRSTS ;YES-- STUFF FOR US TO DO?
    165	001420	001426 				BEQ	30$		;NO-- IDLE-- CLEAR HUNG FLAG
CRDRV	(CD-11 DRIVER FOR RSX10	MACRO M1108  13-JAN-78 14:10  PAGE 13-2
CRLOOP (MAIN PROCESSING LOOP)

    166	001422	032737 	100000 	000646'		BIT	#CR.HNG,CRSTS	;WE BEEN HERE WITHIN 10 SECONDS?
    167	001430	001416 				BEQ	20$		;NO-- SET HUNG FLAG SO WE WILL IN 10 SEC
    168	001432	032737 	020000 	000646'		BIT	#CR.IOP,CRSTS	;YES-- WAS I/O IN PROGRESS
    169	001440	001407 				BEQ	10$		;NO-- JUST PROCESS OTHER FLAGS
    170	001442	052737 	042000 	000646'		BIS	#CR.RHN!CR.SST,CRSTS ;YES-- SAY READER HUNG
    171	001450	005237 	000304'			INC	CRHUNG		;COUNT # TIMES HUNG
    172	001454					CALL	INITCR		;RESET THE CD-11
	001454	004737 	002116'			JSR	PC,INITCR
    173					;
    174	001460	052777 	000002 	176612 	10$:	BIS	#EF.CRD,@CREVFG	;SAY TO LOOK AT THE FLAGS AGAIN
    175					;
    176	001466	052737 	100000 	000646'	20$:	BIS	#CR.HNG,CRSTS	;FLAG TO CHECK THIS AGAIN IN 10 SECONDS
    177	001474	000403 				BR	90$		;ALL DONE
    178					;
    179	001476	042737 	102000 	000646'	30$:	BIC	#CR.HNG!CR.RHN,CRSTS	;NOTHING TO DO-- DON'T SAY WE ARE HUNG
    180					;
    181					; ALL DONE WITH EF.CRC
    182					;
    183	001504	000137 	001014'		90$:	JMP	CRLOOP		;BACK TO MAIN LOOP
    184						.DSABLE	LSB
CRDRV	(CD-11 DRIVER FOR RSX10	MACRO M1108  13-JAN-78 14:10  PAGE 14
SSTSCR	(SEND CD-11 STATUS TO -10)

    186						.SBTTL	SSTSCR	(SEND CD-11 STATUS TO -10)
    187					;
    188					;+
    189					;
    190					;	SSTSCR IS CALLED WHEN CR.SST IS SET, EITHER BY A CHANGE IN HARDWARE
    191					; STATUS, OR ON REQUEST FROM THE -10.
    192					;
    193					;	THE STATUS PACKET IS ASSEMBLED INTO CRSTBK.  THE FORMAT OF THIS BLOCK
    194					; IS AS FOLLOWS:
    195					;
    196					; WORD	0	STANDARD BITS (DV.XXX)
    197					;	1	DEVICE DEPENDENT BITS (DD.XXX)
    198					;	2	(HIGH BYTE) # BYTES OF DEVICE DEPENDENT INFO (ALWAYS 0)
    199					;		(LOW BYTE) # BYTES OF DEVICE REGISTERS (ALWAYS 8.)
    200					; CD-11 DEVICE REGISTERS
    201					;	3	CDST
    202					;	4	CDCC
    203					;	5	CDBA
    204					;	6	CDDB
    205					;
    206					; THE FOLLOWING BITS ARE USED IN THE STATUS WORDS:
    207					;
    208					;	DV.NXD	NON-EX DEVICE
    209					;	DV.OFL	OFF-LINE
    210					;	DV.OIR	HARD ERROR (DD.RCK, DD.PCK, DD.SCK)
    211					;	DV.IOP	I/O IN PROGRESS (READING A CARD)
    212					;	DV.EOF	E-O-F BUTTON PUSHED
    213					;	DV.LOG	ERROR LOGGING REQUIRED
    214					;	DV.HNG	DEVICE HUNG
    215					;
    216					;	DD.RCK	READ CHECK
    217					;	DD.PCK	PICK CHECK
    218					;	DD.SCK	STACK CHECK
    219					;	DD.HEM	HOPPER EMPTY
    220					;	DD.SFL	STACKER FULL
    221					;
    222					;-
    223					;
    224	001510	042737 	040000 	000646'	SSTSCR:	BIC	#CR.SST,CRSTS	;SAY STATUS SENT ALREADY
    225	001516	032777 	000004 	176554 	60$:	BIT	#EF.CRS,@CREVFG	;IS STATUS BUFFER AVAILABLE?
    226	001524	001007 				BNE	10$		;YES-- ASSEMBLE STATUS
    227	001526					WSIG$S			;NO-- WAIT FOR IT TO BE THERE
	001526	012746 				MOV	(PC)+,-(SP)
	001530	   061 	   001 			.BYTE	49.,1
	001532	104375 				EMT	375
    228	001534	032737 	000000G	000002G		BIT	#EF.PR1,.COMEF+2 ;IF PRIMARY PROTOCOL IS STILL RUNNING
    229	001542	001365 				BNE	60$		;THEN CHECK IF STILL GOING
    230					;
    231					; ASSEMBLE STATUS INTO CRSTBK+0 CRSTBK+2
    232					;
    233	001544	012700 	000316'		10$:	MOV	#CRSTBK+4,R0	;GET ADDRESS OF STATUS BLOCK
    234	001550	005010 				CLR	(R0)		;CLEAR BYTE COUNT WORD(ASSUME NON-EX DEV)
    235	001552	005040 				CLR	-(R0)		; AND SECOND WORD OF STATUS
    236	001554	010001 				MOV	R0,R1		;SAVE ADDR OF SECOND WORD
    237	001556	005040 				CLR	-(R0)		; AND CLEAR FIRST WORD, R0 POINTS TO IT
    238					;
    239	001560	032737 	001000 	000646'		BIT	#CR.NXD,CRSTS	;NON-EX DEVICE?
CRDRV	(CD-11 DRIVER FOR RSX10	MACRO M1108  13-JAN-78 14:10  PAGE 14-1
SSTSCR	(SEND CD-11 STATUS TO -10)

    240	001566	001403 				BEQ	101$		;NO-- GET REAL STATUS
    241	001570	052710 	000007 			BIS	#DV.NXD!DV.OFL!DV.OIR,(R0) ;YES-- SAY NOT THERE
    242	001574	000522 				BR	50$		;SEND THIS STATUS
    243					;
    244	001576	013703 	177160 		101$:	MOV	@#CDST,R3	;COPY DEVICE STATUS
    245	001602	032703 	010000 			BIT	#CDSOFL,R3	;CD-11 OFF-LINE?
    246	001606	001402 				BEQ	11$		;NO-- GO ON
    247	001610	052710 	000006 			BIS	#DV.OFL!DV.OIR,(R0) ;YES-- SAY SO
    248					;
    249	001614	032737 	030000 	000646'	11$:	BIT	#CR.IOP!CR.IOD,CRSTS ;I/O STILL IN PROGRESS?
    250	001622	001402 				BEQ	12$		;NO
    251	001624	052710 	000020 			BIS	#DV.IOP,(R0)	;YES-- SAY SO
    252					;
    253	001630	032703 	020000 		12$:	BIT	#CDSEOF,R3	;E-O-F BUTTON PUSHED?
    254	001634	001402 				BEQ	13$		;NO-- GO ON
    255	001636	052710 	000040 			BIS	#DV.EOF,(R0)	;YES-- SAY EOF
    256					;
    257	001642	032737 	002000 	000646'	13$:	BIT	#CR.RHN,CRSTS	;READER HUNG?
    258	001650	001402 				BEQ	14$		;NO-- GO ON
    259	001652	052710 	001104 			BIS	#DV.HNG!DV.OIR!DV.LOG,(R0) ;YES-- SAY HUNG
    260					;
    261	001656	032703 	003000 		14$:	BIT	#CDSDLT!CDSNXM,R3 ;FATAL ERROR (DATA LATE, NXM)?
    262	001662	001402 				BEQ	15$		;NO-- GO ON
    263	001664	052710 	000300 			BIS	#DV.URE!DV.LOG,(R0) ;YES-- SAY SO
    264					;
    265	001670	032703 	000200 		15$:	BIT	#CDSRDY,R3	;BUT IS READER READY?
    266	001674	001451 				BEQ	30$		;NO-- BITS ARE NOT VALID-- GO ON
    267					;
    268	001676	013704 	177166 			MOV	@#CDDB,R4	;YES-- GET ERROR BITS TO R4
    269					;
    270	001702	032704 	040000 			BIT	#CDBRCK,R4	;READ (PHOTO) CHECK?
    271	001706	001402 				BEQ	16$		;NO
    272	001710	052711 	000001 			BIS	#DD.RCK,(R1)	;YES
    273					;
    274	001714	032704 	020000 		16$:	BIT	#CDBPCK,R4	;PICK CHECK?
    275	001720	001402 				BEQ	17$		;NO
    276	001722	052711 	000002 			BIS	#DD.PCK,(R1)	;YES
    277					;
    278	001726	032704 	010000 		17$:	BIT	#CDBSCK,R4	;STACK CHECK?
    279	001732	001402 				BEQ	18$		;NO
    280	001734	052711 	000004 			BIS	#DD.SCK,(R1)	;YES
    281					;
    282	001740	005711 			18$:	TST	(R1)		;FATAL ERRROR DETECTED?
    283	001742	001402 				BEQ	19$		;NO-- GO ON
    284	001744	052710 	000100 			BIS	#DV.LOG,(R0)	;YES-- SAY ERROR LOGGING NEEDED
    285					;
    286	001750	032703 	000004 		19$:	BIT	#CDSHEM,R3	;HOPPER EMPTY?
    287	001754	001402 				BEQ	20$		;NO-- GO ON
    288	001756	052711 	000010 			BIS	#DD.HEM,(R1)	;YES
    289					;
    290	001762	005711 			20$:	TST	(R1)		;ANY ERROR BITS SET?
    291	001764	001012 				BNE	21$		;YES-- NOT STACKER FULL
    292	001766	032703 	040000 			BIT	#CDSRCK,R3	;IS THIS A READER CHECK?
    293	001772	001412 				BEQ	23$		;NO-- CERTAINLY NOT STACKER FULL
    294	001774	032737 	000400 	000646'		BIT	#CR.NSF,CRSTS	;WE DECIDE IT WASN'T STACKER FULL BEFORE?
    295	002002	001006 				BNE	23$		;YES-- CAN'T BE STACKER FULL NOW
    296	002004	052711 	000020 			BIS	#DD.SFL,(R1)	;NO-- READER CHECK & NO ERRORS => STACKER FULL
CRDRV	(CD-11 DRIVER FOR RSX10	MACRO M1108  13-JAN-78 14:10  PAGE 14-2
SSTSCR	(SEND CD-11 STATUS TO -10)

    297	002010	000403 				BR	22$		;STACKER-FULL-- GO ON
    298					;
    299	002012	052737 	000400 	000646'	21$:	BIS	#CR.NSF,CRSTS	;FLAG THAT IT CAN'T BE STACKER FULL
    300	002020				22$:
    301	002020				23$:
    302	002020	012703 	177160 		30$:	MOV	#CDST,R3	;ADDRESS CD CSR
    303	002024	005721 				TST	(R1)+		;POINT TO FIRST WORD OF DEVICE REGISTERS IN STATUS BLOCK
    304	002026	012721 	000010 			MOV	#<CDDB+2-CDST>,(R1)+ ;SAVE SIZE OF FOLLOWING BLOCK
    305	002032	012321 			31$:	MOV	(R3)+,(R1)+	;MOVE A REGISTER
    306	002034	022701 	000330'			CMP	#CRSTBK+CRSTLN,R1 ;MOVED 'EM ALL?
    307	002040	101374 				BHI	31$		;NO-- LOOP FOR ALL OF THEM
    308					;
    309					; SET UP REGISTERS FOR ..STIN TO SEND BLOCK TO -10:
    310					;	R0 --	POINTER TO STATUS BLOCK
    311					;		FIRST WORD IS HEADER: (HIGH BYTE) UNIT # (LOW BYTE) BYTE COUNT OF BLCOK
    312					;	R1 --	BIT15 (FOR INDIRECT FUNCTION) + FUNCTION CODE (BC.HDS)
    313					;	R2 --	EVENT FLAG TO SET WHEN BLOCK DONE (EF.CRS)
    314					;	R3 --	DEVICE CODE (D.CCDR)
    315					;
    316	002042	105040 			50$:	CLRB	-(R0)		;HIGH BYTE HEADER: UNIT # (ALWAYS 0)
    317	002044	112740 	000016 			MOVB	#CRSTLN,-(R0)	;LOW BYTE: BYTE COUNT OF BLOCK (NOT INCLUDING HEADER)
    318	002050	012701 	100000G			MOV	#BIT15+BC.HDS,R1 ;FUNCTION: HERE IS DEVICE STATUS (INDIRECT FLAVOR)
    319	002054	012702 	000003 			MOV	#E.FCRS,R2	;EVENT FLAG TO SET WHEN DONE
    320	002060	012703 	000000G			MOV	#D.CCDR,R3	;DEVICE CODE: CDR (OF COURSE)
    321	002064	042777 	000004 	176206 		BIC	#EF.CRS,@CREVFG	;CLEAR BUFFER AVAILABLE FLAG
    322	002072					CALL	..STIN		;SEND TO -10
	002072	004737 	000000G			JSR	PC,..STIN
    323	002076	103006 				BCC	90$		;OK-- DONE
    324	002100	052777 	000004 	176172 		BIS	#EF.CRS,@CREVFG	;FAILED-- BUFFER STILL AVAILABLE
    325	002106	052737 	040000 	000646'		BIS	#CR.SST,CRSTS	;ERROR-- TRY AGAIN LATER
    326					;
    327					; ALL DONE
    328					;
    329	002114				90$:	RETURN			;ALL DONE FORM SSTSCR
	002114	000207 				RTS	PC
CRDRV	(CD-11 DRIVER FOR RSX10	MACRO M1108  13-JAN-78 14:10  PAGE 15
INITCR	(INITIALIZE CD-11)

    331						.SBTTL	INITCR	(INITIALIZE CD-11)
    332					;
    333					;+
    334					;
    335					;	INITCR IS CALLED FROM TASK INITIALIZATION AND FROM POWER-UP
    336					; ROUTINE TO RESET THE CD-11.
    337					;
    338					;-
    339					;
    340	002116	042737 	021000 	000646'	INITCR::BIC	#CR.IOP!CR.NXD,CRSTS ;NO LONGER I/O IN PROGRESS, ASSUME DEVICE EXISTS
    341	002124	012737 	000400 	177160 		MOV	#CDSPWC,@#CDST	;DO POWER-CLEAR
    342	002132	052777 	000001 	176140 	CLRINS:	BIS	#EF.CRC,@CREVFG	;FORCE HUNG CHECK
    343	002140					RETURN
	002140	000207 				RTS	PC
CRDRV	(CD-11 DRIVER FOR RSX10	MACRO M1108  13-JAN-78 14:10  PAGE 17
CD-11 DRIVER COMMON SUBROUTINES MODULE

      1						.SBTTL	CD-11 DRIVER COMMON SUBROUTINES MODULE
      2					;
      3					;                             COPYRIGHT (C) 1975, 1978 BY
      4					;                     DIGITAL EQUIPMENT CORPORATION, MAYNARD MASS.
      5					;
      6					;       THIS SOFTWARE IS FURNISHED UNDER A LICENSE AND MAY BE  USED  AND  COPIED
      7					;       ONLY IN ACCORDANCE WITH THE TERMS OF SUCH LICENSE AND WITH THE INCLUSION
      8					;       OF THE ABOVE COPYRIGHT NOTICE.  THIS SOFTWARE OR ANY OTHER COPIES THERE-
      9					;       OF  MAY NOT BE PROVIDED OR OTHERWISE MADE AVAILABLE TO ANY OTHER PERSON.
     10					;       NO TITLE TO OR OWNERSHIP OF THE SOFTWARE IS HEREBY TRANSFERRED.
     11					;
     12					;       THE INFORMATION CONTAINED IN THIS SOFTWARE IS SUBJECT TO CHANGE  WITHOUT
     13					;       NOTICE  AND SHOULD NOT BE CONSTRUED AS A COMMITMENT BY DIGITAL EQUIPMENT
     14					;       CORPORATION.
     15					;
     16					;       DIGITAL ASSUMES NO RESPONSIBILITY FOR THE  USE  OR  RELIABILITY  OF  ITS
     17					;       SOFTWARE ON EQUIPMENT WHICH IS NOT SUPPILED BY DIGITAL.
     18					;
     19					;		MODULE: CD-11 DRIVER COMMON SUBROUTINES
     20					;
     21					;		VERSION: 01-00
     22					;
     23					;		AUTHOR: TOM PORCHER
     24					;
     25					;		DATE: 25-AUG-75
     26					;
     27					;
     28					;	THIS MODULE CONTAINS:
     29					;
     30					;	1) $CDINT (CD-11 INTERRUPT SERVICE ROUTINE)
     31					;
     32					;	2) ..STCR (START CD-11)
     33					;
     34					;	3) ..SPCR (STOP CD-11)
     35					;
     36					;	4) ..AKCR (READ CARD)
     37					;
CRDRV	(CD-11 DRIVER FOR RSX10	MACRO M1108  13-JAN-78 14:10  PAGE 18
$CDINT	(CD-11 INTERRUPT SERVICE)

     39						.SBTTL	$CDINT	(CD-11 INTERRUPT SERVICE)
     40					;
     41					;+
     42					;
     43					;	$CDINT IS CALLED FROM THE INTERRUPT VECTOR FOR THE CD-11.
     44					; IT MERELY SAYS THAT I/O IS DONE BY SETTING CR.IOD IF I/O WAS
     45					; IN PROGRESS (CR.IOP), AND REQUESTS STATUS IF AN ERROR HAS OCCURED.
     46					;
     47					;-
     48					;
     49	002142	105737 	177160 		$CDINT:: TSTB	@#CDST		;;;CD-11 READY?
     50	002146	100025 				BPL	90$		;;;NO-- JUST GO AWAY
     51	002150	032737 	020000 	000646'		BIT	#CR.IOP,CRSTS	;;;YES-- WERE WE I/O IN PROGRESS (READING)?
     52	002156	001414 				BEQ	10$		;;;NO-- GO ON (SEE IF ERROR)
     53	002160	042737 	020000 	000646'		BIC	#CR.IOP,CRSTS	;;;YES-- MUST BE DONE NOW
     54	002166	005737 	177162 			TST	@#CDCC		;;;DID WE READ A CARD?
     55	002172	001006 				BNE	10$		;;;NO-- MUST BE ERROR-- SEND STATUS NOW
     56	002174	052737 	010000 	000646'		BIS	#CR.IOD,CRSTS	;;;SO MAKE TASK KNOW WE ARE DONE
     57					;
     58	002202	005737 	177160 			TST	@#CDST		;;;WAS THERE AN ERROR?
     59	002206	100003 				BPL	20$		;;;NO-- GO ON
     60					;
     61	002210	052737 	040000 	000646'	10$:	BIS	#CR.SST,CRSTS	;;;YES-- SEND DEVICE STATUS
     62	002216				20$:	CALL	IODNCR		;;;SAY I/O DONE TO TASK
	002216	004737 	002312'			JSR	PC,IODNCR
     63					;
     64					; ALL DONE WITH INTERRUPT
     65					;
     66	002222	000137 	000000G		90$:	JMP	..INTX		;;;FINISH OFF INTERRUPT
CRDRV	(CD-11 DRIVER FOR RSX10	MACRO M1108  13-JAN-78 14:10  PAGE 19
..STCR	(START CD-11)

     68						.SBTTL	..STCR	(START CD-11)
     69					;
     70					;+
     71					;
     72					;	..STCR IS CALLED FROM THE QUEUED PROTOCOL TASK ON A REQUEST
     73					; FOR STATUS.  NO OTHER REQUESTS TO THE CD-11 DRIVER ARE MADE THROUGH
     74					; ..STCR.
     75					;
     76					;	THE STATUS IS REQUESTED TO THE CD-11 DRIVER TASK BY SETTING
     77					; CR.SST AND EF.CRD.
     78					;
     79					; CALLING SEQUENCE:
     80					;	R0 --	POINTER TO THREAD BLOCK (WILL JUST BE DEALLOCATED)
     81					;	R2 --	POINTER TO CRTBL (MUST BE CRTBL+0)
     82					;
     83					; EXIT CONDITIONS:
     84					;
     85					;	NO REGISTERS MODIFIED
     86					;
     87					;-
     88					;
     89						.ENABLE	LSB
     90	002226	016001 	000000G		..STCR:: MOV	T.HBCT(R0),R1	;GET SIZE OF BLOCK
     91	002232					CALL	..DECB		;DE-ALLOCATE IT
	002232	004737 	000000G			JSR	PC,..DECB
     92	002236	020227 	000642'			CMP	R2,#CRTBL+0	;THIS CR0?
     93	002242	001031 				BNE	99$		;NO-- GO AWAY
     94	002244	052737 	040000 	000646'		BIS	#CR.SST,CRSTS	;YES-- MAKE STATUS HAPPEN
     95	002252	000417 				BR	IODNCR		; AND MAKE TASK RECOGNIZE IT
CRDRV	(CD-11 DRIVER FOR RSX10	MACRO M1108  13-JAN-78 14:10  PAGE 20
..SPCR	(STOP CD-11)

     97						.SBTTL	..SPCR	(STOP CD-11)
     98					;
     99					;+
    100					;
    101					;	..SPCR IS CALLED FROM THE QUEUED PROTOCOL TASK TO FLUSH
    102					; INPUT FROM THE CD-11.  ANY I/O THAT IS IN PROGRESS IS STOPPED,
    103					; AND NO FURTHER DATA IS SENT TO THE -10.
    104					;
    105					; CALLING SEQUENCE:
    106					;	R2 --	POINTER TO CRTBL (MUST BE CRTBL+0)
    107					;
    108					; EXIT CONDITIONS:
    109					;
    110					; NO REGISTERS MODIFIED
    111					;
    112					;-
    113					;
    114	002254	020227 	000642'		..SPCR:: CMP	R2,#CRTBL+0	;THIS CR0?????
    115	002260	001022 				BNE	99$		;NO-- GO AWAY
    116	002262					CALL	INITCR		;RESET THE CD-11
	002262	004737 	002116'			JSR	PC,INITCR
    117	002266	042737 	034000 	000646'		BIC	#CR.ACK!CR.IOD!CR.IOP,CRSTS ;SAY WE ARE HAPPY
    118	002274					RETURN
	002274	000207 				RTS	PC
CRDRV	(CD-11 DRIVER FOR RSX10	MACRO M1108  13-JAN-78 14:10  PAGE 21
..AKCR	(READ CARD)

    120						.SBTTL	..AKCR	(READ CARD)
    121					;
    122					;+
    123					;
    124					;	..AKCR IS CALLED FROM THE QUEUED PROTOCOL TASK ON AN ACKNOWLEDGE
    125					; REQUEST FROM THE -10.  THIS IMPLIES THAT A CARD SHOULD BE READ.
    126					;
    127					; CALLING SEQUENCE:
    128					;	R2 --	POINTER TO CRTBL (MUST BE CRTBL+0)
    129					;
    130					; EXIT CONDITIONS:
    131					;
    132					; NO REGISTERS MODIFIED
    133					;
    134					;-
    135					;
    136	002276	020227 	000642'		..AKCR:: CMP	R2,#CRTBL+0	;IS THIS CR0???
    137	002302	001011 				BNE	99$		;NO-- GIVE UP
    138	002304	052737 	004000 	000646'		BIS	#CR.ACK,CRSTS	;YES-- SAY TO READ A CARD
    139					;	BR	IODNCR		;SET I/O DONE TO SAY SOMETHING TO DO TO TASK
    140					;
    141					; HERE TO SET I/O DONE (EF.CRD) TO CR TASK TO INDICATE SOMETHING TO DO.
    142					;  ALSO SIGNIFICANT EVENT TO CAUSE CR TASK TO RUN.
    143					;
    144	002312	052777 	000002 	175760 	IODNCR:	BIS	#EF.CRD,@CREVFG	;SET EVENT FLAG
    145	002320	152737 	000000G	000000G		BISB	#EV.SE,.SERFG+0	; AND MAKE SIGN. EVENT TO WAKE TASK
    146	002326				99$:	RETURN			; FROM IODNCR
	002326	000207 				RTS	PC
    147						.DSABLE	LSB
CRDRV	(CD-11 DRIVER FOR RSX10	MACRO M1108  13-JAN-78 14:10  PAGE 23
END

      1						.SBTTL	END
      2					;
      3					;                             COPYRIGHT (C) 1975, 1978 BY
      4					;                     DIGITAL EQUIPMENT CORPORATION, MAYNARD MASS.
      5					;
      6					;       THIS SOFTWARE IS FURNISHED UNDER A LICENSE AND MAY BE  USED  AND  COPIED
      7					;       ONLY IN ACCORDANCE WITH THE TERMS OF SUCH LICENSE AND WITH THE INCLUSION
      8					;       OF THE ABOVE COPYRIGHT NOTICE.  THIS SOFTWARE OR ANY OTHER COPIES THERE-
      9					;       OF  MAY NOT BE PROVIDED OR OTHERWISE MADE AVAILABLE TO ANY OTHER PERSON.
     10					;       NO TITLE TO OR OWNERSHIP OF THE SOFTWARE IS HEREBY TRANSFERRED.
     11					;
     12					;       THE INFORMATION CONTAINED IN THIS SOFTWARE IS SUBJECT TO CHANGE  WITHOUT
     13					;       NOTICE  AND SHOULD NOT BE CONSTRUED AS A COMMITMENT BY DIGITAL EQUIPMENT
     14					;       CORPORATION.
     15					;
     16					;       DIGITAL ASSUMES NO RESPONSIBILITY FOR THE  USE  OR  RELIABILITY  OF  ITS
     17					;       SOFTWARE ON EQUIPMENT WHICH IS NOT SUPPILED BY DIGITAL.
     18					;
     19		000001 				.END
CRDRV	(CD-11 DRIVER FOR RSX10	MACRO M1108  13-JAN-78 14:10  PAGE 23-1
SYMBOL TABLE

A.EF  = ****** GX	CRLOOP  001014R  	DIAG2 = 174432   	INITCR  002116RG 	STATUS= 000022
BC.HDS= ****** GX	CRMKT   001350R  	DIAG3 = 174436   	INTINS  001400R  	SWR   = 177570
BC.STR= ****** GX	CRPWUP  000722R  	DIKL10= 000010   	INTROF= 000010   	SWSLLT= 100000
BIT0  = 000001   	CRSIZE= 000010   	DLYCNT= 174400   	INTRON= 000040   	TENAD1= 174410
BIT1  = 000002   	CRSTBH  000310R  	DON10C= 040000   	INTSON= 000001   	TENAD2= 174412
BIT10 = 002000   	CRSTBK  000312R  	DON10S= 100000   	INT10S= 000400   	TOBM  = 000004
BIT11 = 004000   	CRSTK   000260RG 	DON11C= 000100   	INT11C= 002000   	TOD   = 000003
BIT12 = 010000   	CRSTLN= 000016   	DON11S= 000200   	INT11S= 004000   	TOIP  = 000002
BIT13 = 020000   	CRSTS = 000646R  	DPS4  = 040000   	IODNCR  002312R  	TOIT  = 000001
BIT14 = 040000   	CRTBL   000642RG 	DRESET= 000100   	KLPWRF= 000010   	TO10  = 000200
BIT15 = 100000   	CRTHD = 000642R  	DR.DTE= 000011   	LOAD11= 000004   	TO10AD= 174420
BIT2  = 000004   	CR.ACK= 004000   	DSEND = 000004   	MPE11 = 001000   	TO10BC= 174414
BIT3  = 000010   	CR.HNG= 100000   	DS04  = 004000   	MRKTDP  000652R  	TO10BM= 000001
BIT4  = 000020   	CR.IOD= 010000   	DS05  = 002000   	M.KTAE= 000010   	TO10DB= 000400
BIT5  = 000040   	CR.IOP= 020000   	DS06  = 001000   	M.KTEF= 000002   	TO10DN= 100000
BIT6  = 000100   	CR.NSF= 000400   	DTECMD= 000451   	M.KTMG= 000004   	TO10DT= 174424
BIT7  = 000200   	CR.NXD= 001000   	DTEFLG= 000444   	M.KTUN= 000006   	TO10ER= 020000
BIT8  = 000400   	CR.RHN= 002000   	DTEF11= 000450   	NULSTP= 000040   	TO11  = 000100
BIT9  = 001000   	CR.SST= 040000   	DTEMTD= 000455   	NUPE  = 000002   	TO11AD= 174422
BPARER= 000020   	CS.EXP= 177670   	DTEMTI= 000456   	PERCLR= 001000   	TO11BC= 174416
CDBA  = 177164   	CYCLS = 000002   	DUPE  = 000020   	PHYS  = 100000   	TO11BM= 020000
CDBPCK= 020000   	C$$D11= 000001   	DURE  = 000004   	PIDENT= 000000   	TO11DB= 004000
CDBRCK= 040000   	DATE  = 000004   	DV.EOF= 000040   	PRI7  = 000340   	TO11DN= 000200
CDBSCK= 010000   	DCOMST= 000001   	DV.F11= 000400   	PROPNT= 000021   	TO11DT= 174426
CDCC  = 177162   	DD.CHI= 000002   	DV.HNG= 001000   	PRTOFF= 004000   	TO11ER= 000002
CDD   = 000020   	DD.HEM= 000010   	DV.IOP= 000020   	PR0   = 000000   	TRAP04  000666R
CDDB  = 177166   	DD.LER= 000010   	DV.LOG= 000100   	PR1   = 000040   	TTPEN = ****** GX
CDSB16= 000020   	DD.OVF= 000020   	DV.NXD= 000001   	PR2   = 000100   	T.HBCT= ****** GX
CDSB17= 000040   	DD.PCK= 000002   	DV.OFL= 000002   	PR3   = 000140   	UNASG1= 000032
CDSDER= 004000   	DD.PGZ= 000001   	DV.OIR= 000004   	PR4   = 000200   	UNASG2= 000033
CDSDLT= 002000   	DD.RCK= 000001   	DV.SCN= 000010   	PR5   = 000240   	UNASG3= 000034
CDSEOF= 020000   	DD.RME= 000040   	DV.URE= 000200   	PR6   = 000300   	UNASG4= 000035
CDSERR= 100000   	DD.SCK= 000004   	DXWRD1= 002000   	PR7   = 000340   	UNASG5= 000036
CDSHEM= 000004   	DD.SFL= 000020   	D.CCDR= ****** GX	PS    = 177776   	UNASG6= 000037
CDSIEN= 000100   	DD.VFE= 000004   	D1011 = 000040   	PSWW1 = 000005   	WEP   = 000010
CDSNXM= 001000   	DEP   = 010000   	EBSEL = 000100   	PSWW10= 000014   	ZSTOP = 040000
CDSOFL= 010000   	DEX   = 000400   	EBUSPC= 000020   	PSWW11= 000015   	$CDINT  002142RG
CDSPAK= 000002   	DEXDON= 000004   	EBUSPS= 000004   	PSWW12= 000016   	$$    = 000037
CDSPWC= 000400   	DEXWD1= 174406   	EDONES= 040000   	PSWW13= 000017   	$$$OST= 000012
CDSRCK= 040000   	DEXWD2= 174404   	EF.CRB= 000010   	PSWW2 = 000006   	.BRCLK= 005000
CDSRDY= 000200   	DEXWD3= 174402   	EF.CRC= 000001   	PSWW3 = 000007   	.CECLK= 004000
CDSRED= 000001   	DFUNC = 000200   	EF.CRD= 000002   	PSWW4 = 000010   	.CLRMR= 006000
CDST  = 177160   	DF.DMG= 000004   	EF.CRS= 000004   	PSWW5 = 000011   	.CLRUN= 010000
CDSTOL= 000010   	DF.DMN= 000007   	EF.PR1= ****** GX	PSWW6 = 000012   	.COMEF= ****** GX
CHNPNT= 000001   	DF.DOR= 000001   	EPTR  = 000000   	PSWW7 = 000013   	.CONBT= 012000
CLRINS  002132R  	DF.EHG= 000010   	ERR10C= 010000   	PULSE = 000020   	.CRPFL  000306RG
CNUPE = 000002   	DF.EHM= 000011   	ERR10S= 020000   	QSIZE = 000023   	.CRTSK= ****** GX
CRBFLN= 000240   	DF.EMG= 000005   	ERR11C= 000001   	RAMIS0= 010000   	.CSHRG= 164000
CRBUFF  000332R  	DF.EMN= 000006   	ERR11S= 000002   	RFMAD0= 100000   	.CYLTM= 000074
CRBUFH  000330R  	DF.KLR= 000012   	EV.SE = ****** GX	RFMAD1= 040000   	.DRLTC= 015000
CRCEVF  000302R  	DF.KLW= 000013   	E.FCRB= 000004   	RFMAD2= 020000   	.DSACF= 066000
CREVFG  000300R  	DF.KLX= 000014   	E.FCRC= 000001   	RFMAD3= 010000   	.DSIOJ= 065000
CREXP = 000644R  	DF.OFF= 000002   	E.FCRD= 000002   	RM    = 000010   	.EIOJA= 067000
CRHD    000000RG 	DF.ON = 000003   	E.FCRS= 000003   	SCD   = 000040   	.GFNR = 102000
CRHUNG  000304R  	DF.PDP= 000016   	FORPRO= 000020   	SSTSCR  001510R  	.INICL= 070000
CRINI   000730R  	DF.PEX= 000015   	HIBYTE= 177400   	SSTVTB  000664R  	.IRLTC= 014000
CRIOD   001102R  	DIAG1 = 174430   	IFLOP = 100000   	STAT  = 174434   	.LCRDL= 052000
CRDRV	(CD-11 DRIVER FOR RSX10	MACRO M1108  13-JAN-78 14:10  PAGE 23-2
SYMBOL TABLE

.LCRDR= 051000   	.LDCK1= 046000   	.MEMRS= 076000   	.RCSPF= 141000   	.STPCL= 000000
.LCRM1= 057000   	.LDCK2= 047000   	.PCAB1= 150000   	.RDJ14= 134000   	.STRCL= 001000
.LCRM2= 056000   	.LDDIS= 045000   	.PCAB2= 151000   	.RDJ71= 135000   	.WRMBX= 071000
.LCRM3= 055000   	.LDRJD= 064000   	.PCAB3= 152000   	.RDMAB= 133000   	..AKCR  002276RG
.LCRM4= 054000   	.LDRJV= 063000   	.PCAB4= 153000   	.SECLK= 003000   	..DECB= ****** GX
.LCRM5= 053000   	.LDRM1= 060000   	.RCRM1= 147000   	.SERFG= ****** GX	..INTX= ****** GX
.LDAR = 077000   	.LDRM2= 061000   	.RCRM2= 146000   	.SETMR= 007000   	..SPCR  002254RG
.LDBRL= 043000   	.LDRM3= 062000   	.RCRM3= 145000   	.SETRN= 011000   	..STCR  002226RG
.LDBRR= 042000   	.LDSEL= 044000   	.RCRM4= 144000   	.SSCLK= 002000   	..STIN= ****** GX

. ABS.	000000	   000
      	002330	   001
ERRORS DETECTED:  0

VIRTUAL MEMORY USED:  5144 WORDS  ( 21 PAGES)
DYNAMIC MEMORY:  6272 WORDS  ( 24 PAGES)
ELAPSED TIME:  00:01:02
,[100,20]CRDRV.LIS/-SP/CRF=[100,30]CR,DV,CRDATA,CRTASK,CRCOMM,END
CRDRV      CREATED BY  MACRO  ON 13-JAN-78 AT 14:10	PAGE 1

SYMBOL CROSS REFERENCE                                  CREF         

SYMBOL	VALUE		REFERENCES

A.EF  	= ******  GX	 12-59     
BC.HDS	= ******  GX	 14-318    
BC.STR	= ******  GX	 13-103    
BIT0  	= 000001	#2-43       2-54       3-84       6-48       6-64       6-80       12-48     
BIT1  	= 000002	#2-43       2-56       3-83       6-49       6-65       6-81      
BIT10 	= 002000	#2-43       3-74       9-77      
BIT11 	= 004000	#2-43       3-73       9-75      
BIT12 	= 010000	#2-43       3-72       3-91       9-73      
BIT13 	= 020000	#2-43       3-71       3-90       9-71      
BIT14 	= 040000	#2-43       3-70       3-89       9-68      
BIT15 	= 100000	#2-43       3-69       9-64       13-103     14-318    
BIT2  	= 000004	#2-43       2-58       3-82       6-50       6-66       6-82      
BIT3  	= 000010	#2-43       2-60       3-81       6-51       6-67       6-83      
BIT4  	= 000020	#2-43       3-80       6-52       6-68       6-84      
BIT5  	= 000040	#2-43       3-79       6-53       6-69      
BIT6  	= 000100	#2-43       3-78       6-54      
BIT7  	= 000200	#2-43       3-77       6-55      
BIT8  	= 000400	#2-43       3-76       6-56       9-81      
BIT9  	= 001000	#2-43       3-75       6-57       9-79      
BPARER	= 000020	#2-43      
CDBA  	= 177164	#3-86       13-145    
CDBPCK	= 020000	#3-90       14-274    
CDBRCK	= 040000	#3-89       14-270    
CDBSCK	= 010000	#3-91       14-278    
CDCC  	= 177162	#3-85       13-144     18-54     
CDD   	= 000020	#2-43      
CDDB  	= 177166	#3-87       9-48       14-268     14-304    
CDSB16	= 000020	#3-80      
CDSB17	= 000040	#3-79      
CDSDER	= 004000	#3-73      
CDSDLT	= 002000	#3-74       14-261    
CDSEOF	= 020000	#3-71       14-253    
CDSERR	= 100000	#3-69      
CDSHEM	= 000004	#3-82       14-286    
CDSIEN	= 000100	#3-78       13-146     13-160     13-163    
CDSNXM	= 001000	#3-75       14-261    
CDSOFL	= 010000	#3-72       13-136     14-245    
CDSPAK	= 000002	#3-83      
CDSPWC	= 000400	#3-76       15-341    
CDSRCK	= 040000	#3-70       14-292    
CDSRDY	= 000200	#3-77       14-265    
CDSRED	= 000001	#3-84       13-146    
CDST  	= 177160	#3-68       9-48       9-62       13-136     13-146     13-160     13-163     14-244     14-302    
                         14-304     15-341     18-49      18-58     
CDSTOL	= 000010	#3-81      
CHNPNT	= 000001	#2-43      
CLRINS	  002132 R	 12-43     #15-342    
CNUPE 	= 000002	#2-43      
CRBFLN	= 000240	#9-53       13-102     13-144    
CRBUFF	  000332 R	#9-52       9-53       13-92      13-145    
CRBUFH	  000330 R	#9-51      
CRCEVF	  000302 R	 9-42      #9-43      *13-74      13-85      13-155    
CRDRV      CREATED BY  MACRO  ON 13-JAN-78 AT 14:10	PAGE 2

SYMBOL CROSS REFERENCE                                  CREF         

SYMBOL	VALUE		REFERENCES

CREVFG	  000300 R	#9-42      *12-58     *12-59      12-60      13-74      13-75      13-106     13-112     13-130    
                         13-174     14-225     14-321     14-324     15-342     21-144    
CREXP 	= 000644 R	#9-61      
CRHD  	  000000 RG	#9-38      
CRHUNG	  000304 R	#9-44      *13-171    
CRINI 	  000730 R	 9-38       9-38      #12-58     
CRIOD 	  001102 R	#13-85     
CRLOOP	  001014 R	#13-71      13-183    
CRMKT 	  001350 R	#13-155    
CRPWUP	  000722 R	#12-53      12-63     
CRSIZE	= 000010	#9-86      
CRSTBH	  000310 R	#9-47      
CRSTBK	  000312 R	#9-48       9-49       14-233     14-306    
CRSTK 	  000260 RG	 9-38      #9-38      
CRSTLN	= 000016	#9-49       14-306     14-317    
CRSTS 	= 000646 R	#9-63      *12-47      13-90     *13-109     13-117     13-123     13-125    *13-127     13-128    
                        *13-143     13-157     13-164     13-166     13-168    *13-170    *13-176    *13-179    *14-224    
                         14-239     14-249     14-257     14-294    *14-299    *14-325    *15-340     18-51     *18-53     
                        *18-56     *18-61     *19-94     *20-117    *21-138    
CRTBL 	  000642 RG	#9-58       9-86       19-92      20-114     21-136    
CRTHD 	= 000642 R	#9-59      
CR.ACK	= 004000	#9-75       13-123     13-127     13-164     20-117     21-138    
CR.HNG	= 100000	#9-64       13-109     13-127     13-166     13-176     13-179    
CR.IOD	= 010000	#9-73       13-90      13-109     13-125     13-164     14-249     18-56      20-117    
CR.IOP	= 020000	#9-71       13-125     13-143     13-164     13-168     14-249     15-340     18-51      18-53     
                         20-117    
CR.NSF	= 000400	#9-81       13-109     14-294     14-299    
CR.NXD	= 001000	#9-79       12-47      13-128     13-157     14-239     15-340    
CR.RHN	= 002000	#9-77       13-109     13-127     13-170     13-179     14-257    
CR.SST	= 040000	#9-68       13-117     13-164     13-170     14-224     14-325     18-61      19-94     
CS.EXP	= 177670	#2-43      
CYCLS 	= 000002	#2-43      
C$$D11	= 000001	#2-49      
DATE  	= 000004	#2-43      
DCOMST	= 000001	#2-43      
DD.CHI	= 000002	#6-65      
DD.HEM	= 000010	#6-83       14-288    
DD.LER	= 000010	#6-67      
DD.OVF	= 000020	#6-68      
DD.PCK	= 000002	#6-81       14-276    
DD.PGZ	= 000001	#6-64      
DD.RCK	= 000001	#6-80       14-272    
DD.RME	= 000040	#6-69      
DD.SCK	= 000004	#6-82       14-280    
DD.SFL	= 000020	#6-84       14-296    
DD.VFE	= 000004	#6-66      
DEP   	= 010000	#2-43      
DEX   	= 000400	#2-43      
DEXDON	= 000004	#2-43      
DEXWD1	= 174406	#2-43      
DEXWD2	= 174404	#2-43      
DEXWD3	= 174402	#2-43      
CRDRV      CREATED BY  MACRO  ON 13-JAN-78 AT 14:10	PAGE 3

SYMBOL CROSS REFERENCE                                  CREF         

SYMBOL	VALUE		REFERENCES

DFUNC 	= 000200	#2-43      
DF.DMG	= 000004	#2-43      
DF.DMN	= 000007	#2-43      
DF.DOR	= 000001	#2-43      
DF.EHG	= 000010	#2-43      
DF.EHM	= 000011	#2-43      
DF.EMG	= 000005	#2-43      
DF.EMN	= 000006	#2-43      
DF.KLR	= 000012	#2-43      
DF.KLW	= 000013	#2-43      
DF.KLX	= 000014	#2-43      
DF.OFF	= 000002	#2-43      
DF.ON 	= 000003	#2-43      
DF.PDP	= 000016	#2-43      
DF.PEX	= 000015	#2-43      
DIAG1 	= 174430	#2-43      
DIAG2 	= 174432	#2-43      
DIAG3 	= 174436	#2-43      
DIKL10	= 000010	#2-43      
DLYCNT	= 174400	#2-43      
DON10C	= 040000	#2-43      
DON10S	= 100000	#2-43      
DON11C	= 000100	#2-43      
DON11S	= 000200	#2-43      
DPS4  	= 040000	#2-43      
DRESET	= 000100	#2-43      
DR.DTE	= 000011	#2-43      
DSEND 	= 000004	#2-43      
DS04  	= 004000	#2-43      
DS05  	= 002000	#2-43      
DS06  	= 001000	#2-43      
DTECMD	= 000451	#2-43      
DTEFLG	= 000444	#2-43      
DTEF11	= 000450	#2-43      
DTEMTD	= 000455	#2-43      
DTEMTI	= 000456	#2-43      
DUPE  	= 000020	#2-43      
DURE  	= 000004	#2-43      
DV.EOF	= 000040	#6-53       14-255    
DV.F11	= 000400	#6-56      
DV.HNG	= 001000	#6-57       14-259    
DV.IOP	= 000020	#6-52       14-251    
DV.LOG	= 000100	#6-54       14-259     14-263     14-284    
DV.NXD	= 000001	#6-48       14-241    
DV.OFL	= 000002	#6-49       14-241     14-247    
DV.OIR	= 000004	#6-50       14-241     14-247     14-259    
DV.SCN	= 000010	#6-51      
DV.URE	= 000200	#6-55       14-263    
DXWRD1	= 002000	#2-43      
D.CCDR	= ******  GX	 13-105     14-320    
D1011 	= 000040	#2-43      
EBSEL 	= 000100	#2-43      
CRDRV      CREATED BY  MACRO  ON 13-JAN-78 AT 14:10	PAGE 4

SYMBOL CROSS REFERENCE                                  CREF         

SYMBOL	VALUE		REFERENCES

EBUSPC	= 000020	#2-43      
EBUSPS	= 000004	#2-43      
EDONES	= 040000	#2-43      
EF.CRB	= 000010	#2-60       12-60      13-106     13-112     13-130    
EF.CRC	= 000001	#2-54       13-71      13-75      13-155     15-342    
EF.CRD	= 000002	#2-56       13-71      13-75      13-85      13-174     21-144    
EF.CRS	= 000004	#2-58       12-60      14-225     14-321     14-324    
EF.PR1	= ******  GX	 13-133     14-228    
EPTR  	= 000000	#2-43      
ERR10C	= 010000	#2-43      
ERR10S	= 020000	#2-43      
ERR11C	= 000001	#2-43      
ERR11S	= 000002	#2-43      
EV.SE 	= ******  GX	 21-145    
E.FCRB	= 000004	#2-59       13-104    
E.FCRC	= 000001	#2-53       9-90      
E.FCRD	= 000002	#2-55      
E.FCRS	= 000003	#2-57       14-319    
FORPRO	= 000020	#2-43      
HIBYTE	= 177400	#2-43      
IFLOP 	= 100000	#2-43      
INITCR	  002116 RG	 12-53      12-53      12-64      12-64      13-79      13-79      13-172     13-172    #15-340    
                         20-116     20-116    
INTINS	  001400 R	 12-41     #13-161    
INTROF	= 000010	#2-43      
INTRON	= 000040	#2-43      
INTSON	= 000001	#2-43      
INT10S	= 000400	#2-43      
INT11C	= 002000	#2-43      
INT11S	= 004000	#2-43      
IODNCR	  002312 R	 18-62      18-62      19-95     #21-144    
KLPWRF	= 000010	#2-43      
LOAD11	= 000004	#2-43      
MPE11 	= 001000	#2-43      
MRKTDP	  000652 R	#9-90       12-61     
M.KTAE	= 000010	#9-90      
M.KTEF	= 000002	#9-90      
M.KTMG	= 000004	#9-90      
M.KTUN	= 000006	#9-90      
NULSTP	= 000040	#2-43      
NUPE  	= 000002	#2-43      
PERCLR	= 001000	#2-43      
PHYS  	= 100000	#2-43      
PIDENT	= 000000	#2-43      
PRI7  	= 000340	#2-43      
PROPNT	= 000021	#2-43      
PRTOFF	= 004000	#2-43      
PR0   	= 000000	#2-43      
PR1   	= 000040	#2-43      
PR2   	= 000100	#2-43      
PR3   	= 000140	#2-43      
PR4   	= 000200	#2-43      
CRDRV      CREATED BY  MACRO  ON 13-JAN-78 AT 14:10	PAGE 5

SYMBOL CROSS REFERENCE                                  CREF         

SYMBOL	VALUE		REFERENCES

PR5   	= 000240	#2-43      
PR6   	= 000300	#2-43      
PR7   	= 000340	#2-43       13-73     
PS    	= 177776	#2-43       13-73      13-73      13-76     
PSWW1 	= 000005	#2-43      
PSWW10	= 000014	#2-43      
PSWW11	= 000015	#2-43      
PSWW12	= 000016	#2-43      
PSWW13	= 000017	#2-43      
PSWW2 	= 000006	#2-43      
PSWW3 	= 000007	#2-43      
PSWW4 	= 000010	#2-43      
PSWW5 	= 000011	#2-43      
PSWW6 	= 000012	#2-43      
PSWW7 	= 000013	#2-43      
PULSE 	= 000020	#2-43      
QSIZE 	= 000023	#2-43      
RAMIS0	= 010000	#2-43      
RFMAD0	= 100000	#2-43      
RFMAD1	= 040000	#2-43      
RFMAD2	= 020000	#2-43      
RFMAD3	= 010000	#2-43      
RM    	= 000010	#2-43      
SCD   	= 000040	#2-43      
SSTSCR	  001510 R	 13-119     13-119     13-138     13-138    #14-224    
SSTVTB	  000664 R	#12-37      12-62     
STAT  	= 174434	#2-43      
STATUS