	SUBROUTINE GETBIT( BUFFER, OFFSET, VALUE )
C
	INTEGER BUFFER(1), OFFSET, VALUE, ADDRESS
C
C
	VALUE = 0
	INDEX = 1
	IOFF = OFFSET
	DO WHILE ( IOFF .GT. 32 )
	    INDEX = INDEX + 1
	    IOFF = IOFF - 32
	ENDDO
D	TYPE *,'INDEX, IOFF = ',INDEX,IOFF
	VALUE = IBITS( BUFFER(INDEX), IOFF, 1 )
D	TYPE *,'VALUE = ',VALUE
	RETURN
	END
