	.TITLE  TEST ROUTINE
	.IODEV 1,2,3	/ASSIGN TTA, LT1, LT2 TO DAT SLOTS
	.GLOBL SEMA1,SEMA2,SEMA3,SAVE1,SAVE2,SAVE3
	.GLOBL	PS,SEMA,SUPER,COUNT
/ 
/ 
/DEVICE HANDLER FOR DAT SLOT 1
/ 
/ 
START1	JMP	IONIT	/GO TO INITIALIZE ROUTINE THEN REPLACE WITH NOP.
	LAC*	(SEMA
	JMS*	PS
	LAC*	(SAVE1
	.READ	1,2,BUF1,34
NX1	LAC*	(SEMA
	JMS*	PS
	LAC*	(SAVE1
WRITE1	.WRITE	1,2,BUF1,34	/RETURN FROM INITIALIZE ROUTINE
NX2	JMP	START1
BUF1	.BLOCK	42
	.ASCII	<15>
/ 
/ 
/DEVICE HANDLER FOR DAT SLOT 2
/ 
/ 
START2	LAC*	(SEMA
	JMS*	PS
	LAC*	(SAVE2
	.READ	2,2,BUF2,34
	LAC*	(SEMA
	JMS*	PS
	LAC*	(SAVE2
WRITE2	.WRITE	2,2,BUF2,34
	JMP	START2
BUF2	.BLOCK	42
	.ASCII	<15>
/ 
/ 
/DEVICE HANDLER FOR DAT SLOT 3
/ 
/ 
START3	LAC*	(SEMA
	JMS*	PS
	LAC*	(SAVE3
	.READ	3,2,BUF3,34
	LAC*	(SEMA
	JMS*	PS
	LAC*	(SAVE3
WRITE3	.WRITE	3,2,BUF3,34
	JMP	START3
BUF3	.BLOCK	42
	.ASCII	<15>
/ 
/ 
/INITIALIZE ROUTINE
/ 
/ 
IONIT	LAC	ERR	/PUT NOP IN START1
	DAC	START1
	LAC*	(SEMA
	JMS*	PS
	LAC*	(SAVE1
	.INIT	1,0,IONIT	/START READ ON DEVICE 1
	.READ	1,2,BUF1,34
	.INIT	2,0,IONIT	/START READ ON DEVICE 2
	.READ	2,2,BUF2,34
	.INIT	3,0,IONIT	/START READ ON DEVICE 3
	.READ	3,2,BUF3,34
	ISZ*	SEMA3	/INCREMENT DEVICE SEMAPHORES
ERR	NOP
	ISZ*	SEMA1
	NOP
	ISZ*	SEMA2
	NOP
	LAC*	(SEMA
	JMS*	PS
	LAC*	(SAVE1
	JMP	WRITE1	/RETURN FOR DEVICE 1
	LAC*	(SEMA
	JMS*	PS
	LAC*	(SAVE2
	JMP	WRITE2	/RETURN FOR DEVICE 2
	LAC*	(SEMA
	JMS*	PS
	LAC*	(SAVE3
	JMP	WRITE3	/RETURN FOR DEVICE 3
LOT	CLC		/SET COUNT TO -1 TO INDICATE
	DAC	COUNT		/INITIALIZATION COMPLETE.
	JMP*	SUPER
COUNT	0
	.END
