HyperHacker
Raving Lunatic
What I did when I couldn't see any video output was to hack the drawing code to draw whatever was in VRAM instead, that way I could at least verify the drawing routines worked and the game had loaded some graphics.
void Interpreter::z80_LDH_A_n8()
{
/* load reg.A with mem at address 0xFF00+immediate */
reg.A=mem.memory[0xFF00+mem.memory[reg.PC++]];
/* add the cycles */
cpu.cycles+=4;
}
ShizZie said:Thanks guys! Ladies and Gentlemen, I think he's done it! arty:
Ahh.. so maybe it isn't much, but it's something! Finally I get video :bouncy: Sure made my day. (Big Scroller Demo btw, and everything else still crashes hahaha)
I'm currently stumped on a problem with my f0 opcode, which would be LDH an immediate to A. I've double and triple checked my code, and I'm sure that it's right. What it is doing is setting AF to 0x4440 in the Big Scroller Demo, when it should be setting it to 0x4040 - which leads me to believe that somewhere else I am setting A wrong, or somewhere else I'm not setting A at all... which is puzzling. Here's my LDH code:
Any suggestions? Thanks!Code:void Interpreter::z80_LDH_A_n8() { /* load reg.A with mem at address 0xFF00+immediate */ reg.A=mem.memory[0xFF00+mem.memory[reg.PC++]]; /* add the cycles */ cpu.cycles+=4; }
Cheers!
I hope you mean that in a good way :happy: Somewhere I'm setting that address in high ram to a wrong value before loading it into AF, so as long as I pinpoint that spot things should work out. I'm going to work through it some more tomarrow.things become alot more fun now