51 |
$self->open_screen; |
$self->open_screen; |
52 |
$self->load_rom({ |
$self->load_rom({ |
53 |
0x1000 => 'dump/SCRINV.BIN', |
0x1000 => 'dump/SCRINV.BIN', |
54 |
|
# 0x6000 => 'dump/screen.dmp', |
55 |
0xC000 => 'rom/BAS12.ROM', |
0xC000 => 'rom/BAS12.ROM', |
56 |
0xE000 => 'rom/CRT12.ROM', |
0xE000 => 'rom/CRT12.ROM', |
57 |
}); |
}); |
58 |
|
|
59 |
$PC = 0xDD11; # BC |
# $PC = 0xDD11; # BC |
60 |
# $PC = 0xC274; # MC |
# $PC = 0xC274; # MC |
61 |
|
|
62 |
$orao = $self; |
$orao = $self; |
67 |
$self->trace( 0 ); |
$self->trace( 0 ); |
68 |
$self->debug( 0 ); |
$self->debug( 0 ); |
69 |
|
|
70 |
|
$self->render( @mem[ 0x6000 .. 0x7fff ] ); |
71 |
|
|
72 |
if ( $self->show_mem ) { |
if ( $self->show_mem ) { |
73 |
|
|
74 |
warn "rendering memory map\n"; |
warn "rendering memory map\n"; |
101 |
} else { |
} else { |
102 |
|
|
103 |
warn "rendering video memory\n"; |
warn "rendering video memory\n"; |
104 |
for my $a ( 0x6000 .. 0x7fff ) { |
# for my $a ( 0x6000 .. 0x7fff ) { |
105 |
$self->vram( $a - 0x6000, $mem[$a] ); |
# $self->vram( $a - 0x6000, $mem[$a] ); |
106 |
} |
# } |
107 |
|
$self->render( @mem[ 0x6000 .. 0x7fff ] ); |
108 |
|
|
109 |
} |
} |
110 |
$self->sync; |
$self->sync; |
156 |
$t = $end if ( $end < $t ); |
$t = $end if ( $end < $t ); |
157 |
|
|
158 |
warn sprintf("refresh video ram %04x-%04x\n", $f, $t); |
warn sprintf("refresh video ram %04x-%04x\n", $f, $t); |
159 |
foreach my $a ( $f .. $t ) { |
# foreach my $a ( $f .. $t ) { |
160 |
$self->vram( $a - 0x6000 , $mem[ $a ] ); |
# $self->vram( $a - 0x6000 , $mem[ $a ] ); |
161 |
} |
# } |
162 |
|
$self->render( @mem[ 0x6000 .. 0x7fff ] ); |
163 |
} |
} |
164 |
|
|
165 |
=head2 load_oraoemu |
=head2 load_oraoemu |
253 |
return sprintf(" %04x %s\n", $a, |
return sprintf(" %04x %s\n", $a, |
254 |
join(" ", |
join(" ", |
255 |
map { |
map { |
256 |
sprintf( "%02x", $_ ) |
if ( defined($_) ) { |
257 |
|
sprintf( "%02x", $_ ) |
258 |
|
} else { |
259 |
|
' ' |
260 |
|
} |
261 |
} @mem[ $a .. $a+8 ] |
} @mem[ $a .. $a+8 ] |
262 |
) |
) |
263 |
); |
); |
388 |
$a = $v if defined($v); |
$a = $v if defined($v); |
389 |
my $to = shift @v; |
my $to = shift @v; |
390 |
$to = $a + 32 if ( ! $to || $to <= $a ); |
$to = $a + 32 if ( ! $to || $to <= $a ); |
391 |
|
$to = 0xffff if ( $to > 0xffff ); |
392 |
my $lines = int( ($to - $a + 8) / 8 ); |
my $lines = int( ($to - $a + 8) / 8 ); |
393 |
printf "## e %04x %04x (%d bytes) lines: %d\n", $a, $to, ($to-$a), $lines; |
printf "## e %04x %04x (%d bytes) lines: %d\n", $a, $to, ($to-$a), $lines; |
394 |
while ( --$lines ) { |
while ( --$lines ) { |