From e6216d5d0a9f8cdb700124558d38cd47e63fbdda Mon Sep 17 00:00:00 2001 From: Michael Pavone Date: Sat, 3 Jan 2015 18:23:04 -0800 Subject: Made the Z80 core more contained by refactoring some code in blastem.c into z80_to_x86.c --- blastem.h | 4 ---- 1 file changed, 4 deletions(-) (limited to 'blastem.h') diff --git a/blastem.h b/blastem.h index 46d0b1b..cd75b64 100644 --- a/blastem.h +++ b/blastem.h @@ -19,8 +19,6 @@ #define RAM_FLAG_EVEN 0x1000 #define RAM_FLAG_BOTH 0x0000 -#define CYCLE_NEVER 0xFFFFFFFF - typedef struct { m68k_context *m68k; z80_context *z80; @@ -42,8 +40,6 @@ extern int headless; extern int break_on_sync; extern int save_state; extern tern_node * config; -extern uint8_t busreq; -extern uint8_t reset; #define CARTRIDGE_WORDS 0x200000 #define RAM_WORDS 32 * 1024 -- cgit v1.2.3 From 89ca3bce585f06927569ed1f18ad433d33e320e9 Mon Sep 17 00:00:00 2001 From: Michael Pavone Date: Tue, 5 May 2015 08:42:27 -0700 Subject: Added config option to allow specifying a max sync cycle smaller than the end of frame --- blastem.h | 2 ++ 1 file changed, 2 insertions(+) (limited to 'blastem.h') diff --git a/blastem.h b/blastem.h index cd75b64..680fc73 100644 --- a/blastem.h +++ b/blastem.h @@ -30,6 +30,8 @@ typedef struct { uint32_t save_flags; uint32_t master_clock; //Current master clock value uint32_t normal_clock; //Normal master clock (used to restore master clock after turbo mode) + uint32_t frame_end; + uint32_t max_cycles; uint8_t bank_regs[8]; io_port ports[3]; uint8_t bus_busy; -- cgit v1.2.3 From b88dc02ba056c2b5891b1bb062a2ad44df5df544 Mon Sep 17 00:00:00 2001 From: Michael Pavone Date: Thu, 14 May 2015 00:04:22 -0700 Subject: Sync machine state before entering debugger --- blastem.h | 1 + 1 file changed, 1 insertion(+) (limited to 'blastem.h') diff --git a/blastem.h b/blastem.h index 680fc73..23c62dd 100644 --- a/blastem.h +++ b/blastem.h @@ -52,6 +52,7 @@ extern uint16_t ram[RAM_WORDS]; extern uint8_t z80_ram[Z80_RAM_BYTES]; uint16_t read_dma_value(uint32_t address); +m68k_context * sync_components(m68k_context *context, uint32_t address); m68k_context * debugger(m68k_context * context, uint32_t address); void set_speed_percent(genesis_context * context, uint32_t percent); -- cgit v1.2.3 From 0be7e726ad839d36d50db630b24ea0f1dc141c08 Mon Sep 17 00:00:00 2001 From: Michael Pavone Date: Sun, 5 Jul 2015 14:21:34 -0700 Subject: WIP changes to support reading cart memory map from ROM DB --- blastem.h | 4 ---- 1 file changed, 4 deletions(-) (limited to 'blastem.h') diff --git a/blastem.h b/blastem.h index 23c62dd..f3bf4c6 100644 --- a/blastem.h +++ b/blastem.h @@ -15,10 +15,6 @@ #include "io.h" #include "config.h" -#define RAM_FLAG_ODD 0x1800 -#define RAM_FLAG_EVEN 0x1000 -#define RAM_FLAG_BOTH 0x0000 - typedef struct { m68k_context *m68k; z80_context *z80; -- cgit v1.2.3 From 358991e7fef42ae206231aabfeee045e5214dbe4 Mon Sep 17 00:00:00 2001 From: Michael Pavone Date: Mon, 6 Jul 2015 19:46:46 -0700 Subject: SRAM detection from ROM header is no working correctly again --- blastem.h | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'blastem.h') diff --git a/blastem.h b/blastem.h index f3bf4c6..b761149 100644 --- a/blastem.h +++ b/blastem.h @@ -21,14 +21,15 @@ typedef struct { vdp_context *vdp; ym2612_context *ym; psg_context *psg; - uint8_t *save_ram; + uint8_t *save_storage; + uint32_t save_size; uint32_t save_ram_mask; - uint32_t save_flags; uint32_t master_clock; //Current master clock value uint32_t normal_clock; //Normal master clock (used to restore master clock after turbo mode) uint32_t frame_end; uint32_t max_cycles; uint8_t bank_regs[8]; + uint8_t save_type; io_port ports[3]; uint8_t bus_busy; } genesis_context; -- cgit v1.2.3 From da7c1f27d44cb1bb77c057ce9cca7041931619ae Mon Sep 17 00:00:00 2001 From: Michael Pavone Date: Fri, 10 Jul 2015 18:46:18 -0700 Subject: Initial work on I2C EEPROM implementation --- blastem.h | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'blastem.h') diff --git a/blastem.h b/blastem.h index b761149..7d051b6 100644 --- a/blastem.h +++ b/blastem.h @@ -14,6 +14,7 @@ #include "psg.h" #include "io.h" #include "config.h" +#include "romdb.h" typedef struct { m68k_context *m68k; @@ -22,6 +23,8 @@ typedef struct { ym2612_context *ym; psg_context *psg; uint8_t *save_storage; + eeprom_map *eeprom_map; + uint32_t num_eeprom; uint32_t save_size; uint32_t save_ram_mask; uint32_t master_clock; //Current master clock value @@ -32,6 +35,7 @@ typedef struct { uint8_t save_type; io_port ports[3]; uint8_t bus_busy; + eeprom_state eeprom; } genesis_context; extern genesis_context * genesis; -- cgit v1.2.3 From 9d475a3ccb5b2e1e206cf4c219ec5984cec3574f Mon Sep 17 00:00:00 2001 From: Michael Pavone Date: Mon, 20 Jul 2015 21:15:34 -0700 Subject: Full support for Sega mapper when it comes to data. Code in remapped sections may not work reliably. SSF2 now works. --- blastem.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'blastem.h') diff --git a/blastem.h b/blastem.h index 7d051b6..43f694d 100644 --- a/blastem.h +++ b/blastem.h @@ -32,6 +32,7 @@ typedef struct { uint32_t frame_end; uint32_t max_cycles; uint8_t bank_regs[8]; + uint16_t mapper_start_index; uint8_t save_type; io_port ports[3]; uint8_t bus_busy; @@ -44,11 +45,10 @@ extern int break_on_sync; extern int save_state; extern tern_node * config; -#define CARTRIDGE_WORDS 0x200000 #define RAM_WORDS 32 * 1024 #define Z80_RAM_BYTES 8 * 1024 -extern uint16_t cart[CARTRIDGE_WORDS]; +extern uint16_t *cart; extern uint16_t ram[RAM_WORDS]; extern uint8_t z80_ram[Z80_RAM_BYTES]; -- cgit v1.2.3 From 6cd1ab5ac4004b9e9433c5d16a6ed7fa049cf767 Mon Sep 17 00:00:00 2001 From: Michael Pavone Date: Sun, 26 Jul 2015 16:32:34 -0700 Subject: Fix GDB remote debugging support --- blastem.h | 2 ++ 1 file changed, 2 insertions(+) (limited to 'blastem.h') diff --git a/blastem.h b/blastem.h index 43f694d..43ca592 100644 --- a/blastem.h +++ b/blastem.h @@ -22,6 +22,8 @@ typedef struct { vdp_context *vdp; ym2612_context *ym; psg_context *psg; + uint16_t *work_ram; + uint8_t *zram; uint8_t *save_storage; eeprom_map *eeprom_map; uint32_t num_eeprom; -- cgit v1.2.3