From 00f0049405b59a3931ed9f24e9084902118e0ce7 Mon Sep 17 00:00:00 2001 From: Michael Pavone Date: Mon, 31 Oct 2016 09:23:25 -0700 Subject: Get Jaguar disassembler more or less working. Dump gpu program to file when GPU GO bit is set --- jaguar.c | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'jaguar.c') diff --git a/jaguar.c b/jaguar.c index 96ceec5..0caea87 100644 --- a/jaguar.c +++ b/jaguar.c @@ -142,6 +142,11 @@ void rom0_write_16(uint32_t address, jaguar_context *system, uint16_t value) //GPU/Blitter registers if (address < 0x102200) { fprintf(stderr, "Unhandled write to GPU registers %X: %X\n", address, value); + if (address == 0x102116 && (value & 1)) { + FILE *f = fopen("gpu.bin", "wb"); + fwrite(system->gpu_local, 1, sizeof(system->gpu_local), f); + fclose(f); + } } else { fprintf(stderr, "Unhandled write to Blitter registers %X: %X\n", address, value); } -- cgit v1.2.3