	.TITLE IMGDAT
	.IDENT	/COLOR/
;
;
;
DATBLK==60	;pattern to be used with read/write 16 words of COMTAL
		;data blkock,ie. cursor position,display mux ,etc.
;
;	specific unit # assignments for current COMTAL CD: driver
;
SPCUNT==16	;cd16: special mode 3 xfers
;
;
;	special N.C.A.R. unit names for special functional tests
;	devices not standard functionally

DEVIC1::	.ascii /BM/	;buffer memory imaging device
				;each unit is 512x512 8 bit bytes
DEVIC2::	.ascii /CD/	;color display imaging device
				;each unit is 512x512 8 bit bytes
DEVIC3::	.ascii /MT/	;mag tape TU-10 type
;
BUFLEN==512.			;blk length in bytes for each R/W
;
IMGMAX==100.			;max num of images to flip thru
;
;user temps
;
;	buffer for data
;
INFILE::	.word 0		;store flag for files-11 device 
OUTFIL::	.word 0		;store flag for files-11 device 
;
;----------------------------------------------------------------
;			these 8 raster line buffers will speed up xfers
;			even more than 4 !
;			keep these 4 buffers together they speed up xfers
BUF::		.blkb BUFLEN		;blk buffer between lun 4 & 5
BUF1::	.blkb BUFLEN	;1st of three bufs used by convolver
BUF2::	.blkb BUFLEN	;2nd of 3 for convolver
BUF3::	.blkb BUFLEN	;3rd of 3 for convolver
;----------------------------------------------------------------
BUFTMP::	.blkb BUFLEN	;secondary blk buffer for output lun
				;used in MOidfy switch commands
				;and in /SP, /CP printer cmds
BUFT1::		.blkb BUFLEN	;add length to 2nd buffer used by DOTLIN
BUFT2::		.blkb BUFLEN	;add length to 2nd buffer,used by SECLIN
BUFT3::		.blkb BUFLEN	;add length to 2nd buffer
;-------------------------------------------------------------------
BUFCTR::	0	;buferr counter used by convolver
;
MAXPXL::	0	;maximum pixels to PRINTER
MAXCHR::	0	;MAXIMUM chars to PRINTER---trilog
;			these args passed to/from GRAPHL by DOTLIN
MAXCOL::	3	;maximum NUMBER of ribbon colors
COLOR::	0	;color index 0,1,2 simple increment
TABLE::	YELLOW	;address of xlate tables
	MAGENT
	CYAN
;
;---------------------------------------------------------------------
;
BUFSIZ::	BUFLEN	;size of bytes in buffer
BYTSOT::	0	;num bytes to output
RECOUT::	0	;number of bytes for record output
BYTSIN::	0	;num bytes in
;
INVBN::		.blkw 2		;virtual blk # for file input
OUTVBN::	.blkw 2		;virtual blk # for file OUTPut
;
;
MODIDX::	0		;word index for /MO:x command
LINCNT::	0		;current raster line counter
;
;	switches
;
INITYI::	0		;initial Y line #
LASTYI::	0		;last Y line #
YIN::	0		;line addr
INCRYI::	0	;switch amount to incr in Y
YINX::	0	;amount line addr is incred by
;
ASCSIZ::	0	;size of ascii character 1,2,3, etc.
ALPHA::		0	;convolver kernel parameter
BETA::		0	;convolver kernel parameter
C::		0	;convolver kernel parameter
D::		0	;convolver kernel parameter
E::		0	;convolver kernel parameter
F::		0	;convolver kernel parameter
G::		0	;convolver kernel parameter
H::		0	;convolver kernel parameter
I::		0	;convolver kernel parameter
;
;
INITYO::	0		;initial Y line #
LASTYO::	0		;last Y line #
YOUT::	0		;line addr
INCRYO::	0	;switch amount to incr in Y
SINCYO::	0	;signed single step y incr +1 or -1
YOUTX::	0	;amount line addr is incred by
MODTYP::	0	;ascii char for modification type
BASE::	0	;decimal constant to be included in MODIFY ops
CPTNUM::	0	;color printer argument,print 1,2,3 colors
;
X::	0		;column addr
;
BYTEO::		0	;byte to sub on output
IMAGEO::	0	; LOW image to output
IMAGOH::	0	;HIGH IMAGE TO OUTPUT
;
NLINES::	0	;number of raster lines to xfer
;
LINES::	0	;number of raster lines per xfer in loop
			;if greater than 1 then xfer is faster
BYTEiL::	0	;LOW val byte to pass thru on INput
BYTEiH::	0	; HIGH val byte to pass thru on INput
IMGLOW::	0	;image to start with from file
IMGHGH::	0	;image to end with from file
;
;		buffers for holding LUN info for INPUT & OUTPUT 
;
LUNIN::		0	;device 2 char ascii name
UNTIN::		0	;device unit number
DEVIN::		0	;device characteristics word
HILIN::		0
LININ::		0	;number of raster lines for input device
BUFIN::		0	;number of bytes of stanadr buffer size
;
;
LUNOUT::		0	;device 2 char ascii name
UNTOUT::		0	;device unit number
DEVOUT::		0	;device characteristics word
HILOUT::		0	;high order number of blks
LINOUT::		0	;number of raster lines for OUTput device
BUFOUT::		0	;number of bytes of stanadr buffer size
;
;***************** buffers ***************************************
;
;
TTLIN==72.
TTBUF::	.blkb TTLIN
TTILIN==82.
TTIBUF::.blkb TTILIN
;

SDINP::	.WORD	SDBUF-1		;SECONDARY INPUT LINE DESCRIPTOR
	.WORD	SDBUF-1		;
	.WORD	SDBUF+132.	;SECONDARY INPUT BUFFER GUARD WORD
SDBUF::	.BLKB	134.		;SECONDARY INPUT BUFFER
 
CMSTP::	.WORD	CMBF-1
CMST2::	.WORD	CMBF-1
	.WORD	CMBF+132.
CMBF::	.BLKB	132.
ECMBF=.-1

TTLP1::	.WORD	TTLBUF-1
TTLP2::	.WORD	TTLBUF-1
	.WORD	TTLBUF+80.
TTLBUF::.BLKB	82.
STTLP1::.WORD	STTLBF-1
STTLP2::.WORD	STTLBF-1
	.WORD	STTLBF+80.
STTLBF::.BLKB	82.
;
;--------------------------------------------------------------------
;
CALLIN::	10.	;number of lines of CAL COLOR BAR
CALCNT::	0	;temp varible for above
;
;	SUPPRESS <CR> WITH $ AND SEND COLOR SEARCH COMMAND
;
CLRCOD::.byte 44,20,14,12		;zone 1
	.byte 44,21,1,1		;zone 2
	.byte 44,22,1,1		;zone 3
;
FRMBYT::	3	;number of bytes to pass from FORM FEED cmd
REVFRM::	.byte 0,27,14,14	;reverse form feed
;
COLCOD::	.byte 0,0,0,0	;load color search code here
;
;	1=1 DOT UPPER LEFT
;	2=2 DOTS UPPER LEFT & LOWER RIGHT
;	3=3 DOTS same as 2 & add upper right  --- USE RARELY
;	4=1 DOT UPPER RIGHT
;	5=1 DOT LOWER RIGHT
;	6=1 DOT LOWER LEFT
;	7=all 4 dots on---use rarely save paper ,printer and ribbon
;
YELLOW::		;0-255 counts per table
	.byte 0		;0=white
;
	.rept 15.	;0
	.byte 0
	.endr
	.rept 15.	;0
	.byte 0
	.endr
	.rept 15.	;0
	.byte 0
	.endr
	.rept 15.	;0
	.byte 0
	.endr
	.rept 15.	;0
	.byte 0
	.endr
	.rept 15.	;2
	.byte 2
	.endr
	.rept 15.	;1
	.byte 1
	.endr
	.rept 15.	;2
	.byte 2
	.endr
;				BLACK
	.rept 7.	;1&0 alternatiing
	.byte 0,1
	.endr
	.byte 0		;last of BLACK set on
;
	.rept 15.	;2
	.byte 2
	.endr
	.rept 15.	;2
	.byte 2
	.endr
	.rept 15.	;2
	.byte 2
	.endr
	.rept 15.	;2
	.byte 2
	.endr
	.rept 15.	;1
	.byte 1
	.endr
	.rept 15.	;2
	.byte 2
	.endr
	.rept 15.	;0
	.byte 0
	.endr
	.rept 15.	;0
	.byte 0
	.endr
MAGENT::	.byte 0
	.rept 15.	;2
	.byte 2
	.endr
	.rept 15.	;1
	.byte 1
	.endr
	.rept 15.	;1
	.byte 1
	.endr
	.rept 15.	;0
	.byte 0
	.endr
	.rept 15.	;0
	.byte 0
	.endr
	.rept 15.	;0
	.byte 0
	.endr
	.rept 15.	;0
	.byte 0
	.endr
	.rept 15.	;0
	.byte 0
	.endr
;				BLACK
	.rept 7.	;1&0 alternatiing
	.byte 0,1
	.endr
	.byte 0		;last of BLACK set on
;
	.rept 15.	;2
	.byte 2
	.endr
	.rept 15.	;5
	.byte 5
	.endr
	.rept 15.	;1
	.byte 1
	.endr
	.rept 15.	;0
	.byte 0
	.endr
	.rept 15.	;0
	.byte 0
	.endr
	.rept 15.	;1
	.byte 1
	.endr
	.rept 15.	;1
	.byte 1
	.endr
	.rept 15.	;2
	.byte 2
	.endr
CYAN::	.byte 0	;0-255 counts per table
	.rept 15.	;1
	.byte 1
	.endr
	.rept 15.	;1
	.byte 1
	.endr
	.rept 15.	;2
	.byte 2
	.endr
	.rept 15.	;2
	.byte 2
	.endr
	.rept 15.	;1
	.byte 1
	.endr
	.rept 15.	;1
	.byte 1
	.endr
	.rept 15.	;1
	.byte 1
	.endr
	.rept 15.	;2
	.byte 2
	.endr
;				BLACK
	.rept 7.	;1&0 alternatiing
	.byte 0,1
	.endr
	.byte 0		;last of BLACK set on
;
	.rept 15.	;1
	.byte 1
	.endr
	.rept 15.	;1
	.byte 1
	.endr
	.rept 15.	;1
	.byte 1
	.endr
	.rept 15.	;0
	.byte 0
	.endr
	.rept 15.	;0
	.byte 0
	.endr
	.rept 15.	;0
	.byte 0
	.endr
	.rept 15.	;0
	.byte 0
	.endr
	.rept 15.	;0
	.byte 0
	.endr
	.end
