summaryrefslogtreecommitdiff
path: root/transz80.c
diff options
context:
space:
mode:
authorMike Pavone <pavone@retrodev.com>2013-04-28 18:53:43 -0700
committerMike Pavone <pavone@retrodev.com>2013-04-28 18:53:43 -0700
commit9c4a07e1e04310480313e9b963d5ee49421a319b (patch)
tree89995d6c0bae5b9660a2719a2ea1cc0258656c10 /transz80.c
parentcc0f4563e52f42b7653544e77e9e9b0f03426ea8 (diff)
Implement cycle limit in Z80 core.
Diffstat (limited to 'transz80.c')
-rw-r--r--transz80.c7
1 files changed, 5 insertions, 2 deletions
diff --git a/transz80.c b/transz80.c
index 3465efb..680a520 100644
--- a/transz80.c
+++ b/transz80.c
@@ -22,10 +22,13 @@ int main(int argc, char ** argv)
init_z80_context(&context, &opts);
//cartridge ROM
context.mem_pointers[0] = z80_ram;
- context.target_cycle = 0x7FFFFFFF;
+ context.sync_cycle = context.target_cycle = 0x7FFFFFFF;
//work RAM
context.mem_pointers[1] = context.mem_pointers[2] = NULL;
z80_reset(&context);
- z80_run(&context);
+ for(;;)
+ {
+ z80_run(&context);
+ }
return 0;
}