	.TITLE	DGPI
/
/  7 MAR 72 - MOD BY P. HENDERSON
/
/DISABLE GENERAL PURPOSE INTERRUPT
/     SUBROUTINE
/EXECUTION TIME: 64 TO 68 MICROSECONDS
/CALLING SEQUENCE:
/     CALL DGPI(NUMBER,ERROR)
/     NUMBER: 0-7 GPI NUMBER
/     ERROR=0: NO ERROR
/          =1: ILLEGAL GPI REQUESTED
/
	.GLOBL DGPI,%HALT
/
DGPI	XX
	.ARG	DGPI
	DAC NUMBER  /GPI NUMBER LOC.
	.ARG
	DAC ERROR   /ERROR LOCATION
	DZM* ERROR	/ERROR=0
	LAC* NUMBER
	AND (777770
	SZA!CLL
	JMP ERROR1  /GPI<0 OR GPI>7
	LAC* NUMBER /STEP COUNTER
	TAD (LRS    /LONG RIGHT SHIFT
	DAC .+2
	LAC (400000
	XX    /LOAD GPI MASK BIT
	IOT3
	JMP .-1
	SIMB        /SUSPEND INTERRUPT
	            /MASK BITS
	LAC (61
	TAD* NUMBER
	DAC NUMBER  /API TRAP LOCATION
	LAC* %HALT
	DAC* NUMBER /KILL INTERRUPTS
	JMP* DGPI
ERROR1	ISZ* ERROR  /ILL. GPI REQUESTED
	JMP* DGPI
ERROR
NUMBER
IOT3=703003
SIMB=705006
	.END
