Google
 

Trailing-Edge - PDP-10 Archives - BB-H348C-RM_1982 - swskit-v21/certification/makimg.mac
There are no other files named makimg.mac in the archive.
TITLE MAKIMG CREATE FILES 11 FORMAT FIXED OR VARIABLE LENGTH FILES

COMMENT #

	Use this program to make NFT style /IMAGE/Fixed or /IMAGE/Variable
image mode files. Use a cross assembler to make Macy11 format files.
There is no easy tools to make /macy11/fix or /macy11/var files.

#

SEARCH MONSYM,MACSYM

T1=1
T2=2
T3=3
T4=4
IJFN=11
OJFN=12

START:	RESET
	TMSG <Input file spec (7 bit byte file):>
	MOVX T1,<GJ%OLD+GJ%FNS+GJ%SHT>
	MOVE T2,[.PRIIN,,.PRIOU]
	GTJFN
	HALTF
	HRRZ IJFN,T1
	MOVX T2,<^D7B5+OF%RD>
	OPENF
	HALTF
	TMSG <Output file spec (8 bit byte file):>
	MOVX T1,<GJ%NEW+GJ%FNS+GJ%SHT>
	MOVE T2,[.PRIIN,,.PRIOU]
	GTJFN
	HALTF
	HRRZ OJFN,T1
	MOVX T2,<^D8B5+OF%WR>
	OPENF
	HALTF
	TMSG <F(ixed) or V(variable): >
	PBIN
	MOVE T4,T1
	PBIN
	PBIN
	CAIE T4,"F"
	JRST VAR
FIX:	MOVE T1,IJFN
	BIN
	 ERJMP EOF
	MOVE T1,OJFN
	BOUT
	JRST FIX

VAR:	MOVE T1,IJFN
	MOVE T2,[POINT 8,BUFFER]
	MOVEI T3,^D200
	MOVEI T4,12
	SIN
	 ERJMP EOF
	MOVEI T1,^D200
	SUB T1,T3
	MOVE 5,T1
	LSH 5,^D8
	ANDI 5,177777
	MOVE 6,T1
	AND 6,377
	ADD 5,6
	DPB 5,[POINT 16,COUNT,31]
	ADDI T1,2
	MOVN T3,T1
	MOVE T1,OJFN
	MOVE T2,[POINT 8,COUNT,15]
	SOUT
	JRST VAR
EOF:	HRREI T1,-1
	CLOSF
	HALTF
	HALTF

COUNT:	BLOCK 1
BUFFER:	BLOCK ^D60

	END START