home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
CP/M
/
CPM_CDROM.iso
/
mbug
/
mbug099.arc
/
HIDUMP.I
< prev
next >
Wrap
Text File
|
1979-12-31
|
2KB
|
59 lines
Procedure ScreenDump;
{This routine dumps a HIRES2 screen to a parallel printer}
const
ScreenRam = $F000;
var
Column, Row, Bank : Byte;
Store, Location : Integer;
Procedure Lprint;
Begin
InLine($2A/Store/ { LD HL,(STORE) }
$11/$0F/$F0/ { LD DE,0F00FH }
$29/ { ADD HL,HL }
$29/ { ADD HL,HL }
$29/ { ADD HL,HL }
$29/ { ADD HL,HL }
$19/ { ADD HL,DE }
$06/$10/ { LD B,16 }
$5E/ {READ LD E,(HL) }
$C5/ { PUSH BC }
$E5/ { PUSH HL }
$F5/ { PUSH AF }
$0E/$05/ { LD C,5 }
$CD/$05/$00/ { CALL 0005 }
$F1/ { POP AF }
$0E/$05/ { LD C,5 }
$CD/$05/$00/ { CALL 0005 }
$E1/ { POP HL }
$C1/ { POP BC }
$2B/ { DEC HL }
$10/$EC); { DJNZ READ }
End;
Begin
Write(LST,#27'A'#8);
for Column := 0 to 63 do
begin
Write(LST,#27'K'#0#2);
for Row := 15 downto 0 do
begin
Location := ScreenRam + Column + Row * 64;
Store := Mem[Location];
Port[28] := 144;
Bank := Mem[Location];
Port[28] := Bank + 128;
Lprint;
Port[28] := 128;
end;
WriteLn(LST);
end;
Write(LST,#27'A'#9);
End;