minor changes

This commit is contained in:
kirjavascript 2023-02-23 22:32:04 +00:00
parent 100ab590ea
commit 9b6e00c753
4 changed files with 10 additions and 7 deletions

View file

@ -16,11 +16,7 @@ use gfx::Gfx;
// just draw directly to layers
// just have two layers
// set version?? store in core
// or just have a parser to get the version
//
// TODO: dump resolution and support it
pub struct Megadrive {
pub core: ConfiguredCore<AutoInterruptController, mem::Mem>,

View file

@ -37,7 +37,10 @@ impl Mem {
0xA11100..=0xA112FF => self.z80.ctrl_read(address) as _,
0xC00000..=0xDFFFFF => self.vdp.read(address),
0xFF0000..=0xFFFFFF => self.ram[address as usize & 0xFFFF] as _,
_ => 0, //todo!("read byte {:X}", address),
_ => {
println!("todo: read byte {:X}", address);
0
},
}
}
pub fn read_u16(&self, address: u32) -> u32 {
@ -67,7 +70,7 @@ impl Mem {
0xFF0000..=0xFFFFFF => {
self.ram[address as usize & 0xFFFF] = value as u8;
},
_ => (), //todo!("write byte {:X} {:X}", address, value),
_ => println!("todo: write byte {:X} {:X}", address, value),
}
}
pub fn write_u16(&mut self, address: u32, value: u32) {

View file

@ -27,6 +27,8 @@
html, body {
height: 100%;
margin: 0;
}
body, a {
background-color: #111;
color: #777;
}
@ -62,8 +64,10 @@
<label for="file" class="file">
choose ROM
</label>
<br />
<input id="file" type="file" />
<pre class="frameCount"></pre>
<a href="https://archive.org/download/sonicproto_bin/sonicproto.bin">example rom</a>
</main>
<script type="module" src="./app.js"></script>
</body>