This commit is contained in:
twinaphex 2015-07-26 13:50:20 +02:00
commit d8a85bf40b
12 changed files with 250 additions and 67 deletions

View File

@ -1,3 +1,151 @@
---------------------------------------------------------------------------------------------------------
Genesis Plus GX 1.7.5 (xx/xx/xxxx) (Eke-Eke)
---------------------------------------------------------------------------------------------------------
[Core/General]
---------------
* added optional dynamic allocation of cartridge/CD hardware buffer (for platforms with BSS size limitation)
* improved frame emulation timing, now starts with vertical blanking to reduce input lag by one more frame
(!!!warning: this breaks compatibility with previous savestates!!!)
* various code cleanup
[Core/CD]
---------------
* added CD-AUDIO & CD+G support
* added optional support for external VORBIS library
* added CDC & GFX register polling detection / synchronization
* improved CDC emulation (fixes random freezes during Jeopardy & ESPN Sunday Night NFL intro)
* improved emulation of mirrored memory areas
* improved savestate format
* improved Sub-CPU synchronization with Main-CPU (fixes "Soul Star")
* improved Main-CPU & Sub-CPU idle loop detection (fixes "Super League CD")
* disabled 68k and Z80 access to PRG-RAM when SUB-CPU is running (fixes USA version of Dungeon Explorer )
* disabled CD hardware reset on Soft-Reset (verified on real hardware)
* fixed DATA track minimal length (fixes BIOS refusing to boot small homebrew demos)
* fixed CDD "no disc" status code (fixes boot sequence loading time when no disc is loaded)
* fixed OGG file seeking when using with CUE file
* fixed PRG-RAM access from MAIN-CPU side on system reset
* fixed state loading bug when SUB-CPU interrupt is pending
* fixed incorrect masking of Level 3 (GFX) interrupts (spurious freeze during Japanese BIOS intro)
* fixed H-INT vector handling when using Mode 1
* fixed access to "write-only" communication flags (verified on real hardware by Notaz)
* fixed pending level 1 interrupts when GFX interrupt is disabled (fixes random freezes out of "Batman Returns" option menu)
* fixed CDD seek command again (Final Fight CD freeze with model 2 BIOS)
* optimized Sub-CPU / Main-CPU synchronization
[Core/MD]
---------------
* added support for some new unlicensed games with copy protection (Thunderbolt II, Tom Clown, Chaoji Puke / Super Poker)
* added support for Everdrive extended SSF mapper
* improved console region auto-detection for a few PAL-only games (The Smurfs Travel the World & Williams Arcade's Greatest Hits)
* fixed Game Genie / Pro Action Replay lock-on support when Mega CD hardware is enabled
* fixed SRAM support in Triple Play 96 & Triple Play - Gold Edition
* fixed automatic CD loading with .md ROM files
* fixed ROM padding for Sonic & Knuckles
* fixed SRAM detection for games where it is mapped to work RAM ("Feng Kuang Tao Hua Yuan" crash)
* fixed 1.7.4 regression with games using SRAM bank-switching
[Core/MS]
---------------
* added support for new SMS Power dump Jang Pung II (KR)
* added support for Hi-Com X-in-1 mapper (thanks to Bock from SMS Power)
* improved console hardware auto-detection
* improved emulation accuracy of SG-1000 & Mark-III hardware
* improved emulation accuracy of Japanese Master System I/O chip (315-5297)
* fixed Boot ROM loading when switching system hardware
[Core/GG]
---------------
* added optional LCD ghosting software filter
* fixed mirrored access to I/O control register (G-LOC Air Battle)
[Core/SG]
---------------
* added support for SG-1000 II clone hardware (2KB RAM + integrated VDP/PSG chip 315-5066)
* fixed SG-1000 internal RAM size (1KB instead of 2KB)
* restored SG-1000 Pause button support
[Core/CPU]
---------------
* fixed Z80 SP register initialization on power-on for Master System & Game Gear
(Ace of Aces, Shadow Dancer, Ecco the Dolphin, Evander Holyfield Real Deal Boxing)
[Core/IO]
---------------
* added Sega Graphic Board support (thanks to SMS Power)
* added Master Tap emulation (multi-player support in Boom homebrew)
* added gamepad type auto-detection
* added support for XE-1AP analog controller on both ports
* improved HVC latch behavior for gun emulation (fixes "Gunfight - 3 in 1" randomization when using Justifier)
* fixed TeamPlayer emulation (fixes multitap detection in Gauntlet 4)
[Core/VDP]
---------------
* implemented proper FIFO ring-buffer & unused bits behavior on CRAM/VSRAM reads (verified on real hardware by Nemesis)
* improved accuracy of DMA Copy/Fill & added support for CRAM/VSRAM Fill (verified on real hardware by Nemesis)
* improved V28/V30 mode switching during active display (verified on real hardware)
* improved Mode 5 sprites parsing accuracy (verified on real hardware)
* improved Mode 5 sprites rendering timings (fixes "Overdrive" demo)
* improved FIFO timings accuracy (fixes "Overdrive" Demo)
* improved H-Counter accuracy in H32 mode
* improved accuracy of Master System color palette brightness range (verified against real hardware)
* fixed misaligned buffer writes in Mode 4 when -DALIGN_LONG option is used
* fixed alpha channel for 15-bit (RGB555) and 32-bit (RGB888) color support
* fixed register #10 state on VDP¨reset (fixes GG Terminator 2: Judgment Day)
* fixed Mode 1 rendering (TMS99xx "text" mode)
* fixed Game Gear display rendering regression when left/right borders were disabled
* fixed 68k cycles delay on invalid VRAM writes (fixes "Microcosm" intro loop)
* optimized tile caching
[Gamecube/Wii]
---------------
* added configurable BIOS & Lock-on ROM files
* added configurable NTSC filter
* added configurable FPS display & toggleable fast-forward key combo
(HOME + MINUS with Wii controllers or R TRIGGER + START with Gamecube controller)
* added 50hz progressive mode (576p) support for emulation
* reduced SRAM files size
* improved A/V Sync: when VSYNC is enabled, audio resampler output rate is now adjusted (+/-0,1 %)
to always keep audio & video synchronized and input lag is reduced by one frame.
* improved GX video rendering (fixes screen tearing when VSYNC is disabled)
* improved ROM browser scrolling speed and added support for Classic Controller +/- buttons for page scrolling
* improved Cheats Menu
* fixed bug with PICO pointer
* fixed lightgun crosshair & CD leds positionning when using NTSC filter
* fixed low-pass filter menu setting
* various code cleanup & optimizations
[Gamecube]
---------------
* improved progressive mode switch request on startup when component cable is detected
* disabled simultaneous multiple .ogg files opening (fixes crashes caused to RAM size limitation)
* fixed broken DVD support
[Wii]
---------------
* added support for Wii U Pro Controller
* added Wiimote pointer calibration in Menu settings
* added configurable Wiimote timeout
* added game auto-load support through DOL args (compatible with "Wiiflow" plugin arguments)
* fixed support for 3rd-party classic controllers with invalid calibration settings
[GCW0]
---------------
* added GCW Zero port by Shin-NiL & David Knight (based on SDL port)
[libretro]
---------------
* added optional bootrom support for Master System, Game Gear & Mega Drive / Genesis
* added support for all emulated devices (except Activator)
* added support for in-game resolution changes through RETRO_ENVIRONMENT_SET_SYSTEM_AV_INFO
* added support for .mdx ROM files
* added missing core settings (system hardware, region, lock-on, multitap, master system FM,...)
* fixed incorrect SRAM file saving
* fixed framebuffer size for PAL interlaced mode
* fixed viewport width when NTSC Filter is enabled with Mega Drive or Mega CD games using H-32 mode
* code cleanup
---------------------------------------------------------------------------------------------------------
Genesis Plus GX 1.7.4 (21/06/2013) (Eke-Eke)
---------------------------------------------------------------------------------------------------------

View File

@ -8,13 +8,13 @@ Genesis Plus GX is an open-source Sega 8/16 bit emulator focused on accuracy and
----
The source code, originally based on Genesis Plus 1.2a by [Charles MacDonald](http://www.techno-junk.org/ ) has been heavily modified & enhanced, with respect to initial goals and design, in order to improve emulation accuracy as well as adding support for extra peripherals, cartridge or console hardware and many other exciting [features](https://bitbucket.org/eke/genesis-plus-gx/src/master/wiki/Features.md).
The source code, initially based on Genesis Plus 1.2a by [Charles MacDonald](http://www.techno-junk.org/ ) has been heavily modified & enhanced, with respect to original goals and design, in order to improve emulation accuracy as well as adding support for new peripherals, cartridge or console hardware and many other exciting [features](https://bitbucket.org/eke/genesis-plus-gx/src/master/wiki/Features.md).
The result is that Genesis Plus GX is now more a continuation of the original project than a simple port, providing very accurate emulation and [100% compatibility](https://bitbucket.org/eke/genesis-plus-gx/src/master/wiki/Compatibility.md) with Genesis / Mega Drive, Sega/Mega CD, Master System, Game Gear & SG-1000 released software (including all unlicensed or pirate known dumps), also emulating backwards compatibility modes when available. All the people who contributed (directly or indirectly) to this project are listed on the [Credits](https://bitbucket.org/eke/genesis-plus-gx/src/master/wiki/Credits.md) page.
----
Multi-platform sourcecode (core) is available on [Bitbucket](https://bitbucket.org/eke/genesis-plus-gx/src/) and [Github](https://github.com/ekeeke/Genesis-Plus-GX) for use under a specific non-commercial [license](https://bitbucket.org/eke/genesis-plus-gx/src/master/LICENSE.txt) so that other Genesis Plus ports can benefit of it, as I really wish this emulator to become a reference for _open-source_ and _accurate_ Genesis emulation. If you ported this emulator to other platforms or need help porting it, feel free to contact me.
Multi-platform sourcecode (core), which is made available for use under a specific non-commercial [license](https://bitbucket.org/eke/genesis-plus-gx/src/master/LICENSE.txt), is maintained on [Bitbucket](https://bitbucket.org/eke/genesis-plus-gx/src/) / [Github](https://github.com/ekeeke/Genesis-Plus-GX) so that other Genesis Plus ports can benefit of it, as I really wish this emulator becomes a reference for _portable_ and _accurate_ Sega 8/16-bit emulation. If you ported this emulator to other platforms or need help porting it, feel free to contact me.
----
@ -29,3 +29,9 @@ Latest official Gamecube / Wii standalone port (screenshots below) is available
----
You can also test latest compiled builds for Gamecube / Wii and Retroarch (Windows 32-bit version only) by downloading them from [here](https://bitbucket.org/eke/genesis-plus-gx/src/master/builds/).
----
[![btn_donate_LG.gif](https://www.paypalobjects.com/en_US/i/btn/btn_donate_LG.gif)](https://www.paypal.com/cgi-bin/webscr?cmd=_s-xclick&hosted_button_id=2966212) If you like this project and want to show your appreciation, Paypal donations are always welcomed.

Binary file not shown.

Binary file not shown.

Before

Width:  |  Height:  |  Size: 3.7 MiB

After

Width:  |  Height:  |  Size: 3.7 MiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 3.8 MiB

After

Width:  |  Height:  |  Size: 3.8 MiB

View File

@ -180,7 +180,8 @@ static const md_entry_t rom_database[] =
/* Thunderbolt II (uses 16-bits reads) */
{0x0000,0x1585,0x40,0x40,{{0x55,0x0f,0xaa,0xf0},{0xffffff,0xffffff,0xffffff,0xffffff},{0x400000,0x400002,0x400004,0x400006},0,0,NULL,NULL,default_regs_r_16,NULL}},
/* Chaoji Puke - Super Poker (correct ROM dump, original release is an overdump) */
{0xffff,0xd7b0,0x40,0x40,{{0x55,0x0f,0xaa,0xf0},{0xffffff,0xffffff,0xffffff,0xffffff},{0x400000,0x400002,0x400004,0x400006},0,0,NULL,NULL,default_regs_r,NULL}},
/* Super Bubble Bobble */
{0x0000,0x16cd,0x40,0x40,{{0x55,0x0f,0x00,0x00},{0xffffff,0xffffff,0xffffff,0xffffff},{0x400000,0x400002,0x000000,0x000000},0,0,NULL,NULL,default_regs_r,NULL}},
/* Tenchi wo Kurau II - The Battle of Red Cliffs (Unl) */

View File

@ -243,7 +243,7 @@ void cdc_dma_update(void)
}
}
int cdc_decoder_update(uint32 header)
void cdc_decoder_update(uint32 header)
{
/* data decoding enabled ? */
if (cdc.ctrl[0] & BIT_DECEN)
@ -274,7 +274,7 @@ int cdc_decoder_update(uint32 header)
/* buffer RAM write enabled ? */
if (cdc.ctrl[0] & BIT_WRRQ)
{
uint16 offset;
int offset;
/* increment block pointer */
cdc.pt.w += 2352;
@ -292,19 +292,14 @@ int cdc_decoder_update(uint32 header)
cdd_read_data(cdc.ram + 4 + offset);
/* take care of buffer overrun */
if (offset > (0x4000 - 2048 - 4))
offset = offset + 2048 + 4 - 0x4000;
if (offset > 0)
{
/* data should be written at the start of buffer */
memcpy(cdc.ram, cdc.ram + 0x4000, offset + 2048 + 4 - 0x4000);
memcpy(cdc.ram, cdc.ram + 0x4000, offset);
}
/* read next data block */
return 1;
}
}
/* keep decoding same data block if Buffer Write is disabled */
return 0;
}
void cdc_reg_w(unsigned char data)

View File

@ -63,7 +63,7 @@ extern void cdc_reset(void);
extern int cdc_context_save(uint8 *state);
extern int cdc_context_load(uint8 *state);
extern void cdc_dma_update(void);
extern int cdc_decoder_update(uint32 header);
extern void cdc_decoder_update(uint32 header);
extern void cdc_reg_w(unsigned char data);
extern unsigned char cdc_reg_r(void);
extern unsigned short cdc_host_r(void);

View File

@ -347,6 +347,12 @@ int cdd_load(char *filename, char *header)
/* DATA track end LBA (based on DATA file length) */
fseek(fd, 0, SEEK_END);
cdd.toc.tracks[0].end = ftell(fd) / cdd.sectorSize;
/* DATA track length should be at least 2s (BIOS requirement) */
if (cdd.toc.tracks[0].end < 150)
{
cdd.toc.tracks[0].end = 150;
}
/* DATA track start LBA (logical block 0) */
fseek(fd, 0, SEEK_SET);
@ -1454,7 +1460,7 @@ void cdd_process(void)
/* no audio track playing */
scd.regs[0x36>>1].byte.h = 0x01;
/* RS1-RS8 ignored, expects 0x0 ("no disc" ?) in RS0 once */
/* RS1-RS8 ignored, expects 0x0 (?) in RS0 once */
scd.regs[0x38>>1].w = 0x0000;
scd.regs[0x3a>>1].w = 0x0000;
scd.regs[0x3c>>1].w = 0x0000;
@ -1546,7 +1552,7 @@ void cdd_process(void)
break;
}
case 0x03: /* Play */
case 0x03: /* Play */
{
/* reset track index */
int index = 0;
@ -1814,7 +1820,7 @@ void cdd_process(void)
/* update status */
cdd.status = cdd.loaded ? CD_STOP : NO_DISC;
/* RS1-RS8 ignored, expects 0x0 ("no disc" ?) in RS0 once */
/* RS1-RS8 ignored, expects 0x0 (?) in RS0 once */
scd.regs[0x38>>1].w = 0x0000;
scd.regs[0x3a>>1].w = 0x0000;
scd.regs[0x3c>>1].w = 0x0000;

View File

@ -49,13 +49,13 @@
#define cdd scd.cdd_hw
/* CDD status */
#define NO_DISC 0x00
#define CD_PLAY 0x01
#define CD_SEEK 0x02
#define CD_SCAN 0x03
#define CD_READY 0x04
#define CD_OPEN 0x05 /* similar to 0x0E ? */
#define CD_OPEN 0x05
#define CD_STOP 0x09
#define NO_DISC 0x0B
#define CD_END 0x0C
#define CD_MAX_TRACKS 100

View File

@ -1480,7 +1480,7 @@ void scd_init(void)
case 0x0e:
{
/* $FE0000-$FEFFFF (mirrored every 1MB): 8KB backup RAM (Wonder Mega / X'Eye BIOS access it at $FD0000-$FD1FFF ?) */
/* $FE0000-$FEFFFF (mirrored every 1MB): 8KB backup RAM */
s68k.memory_map[i].base = NULL;
s68k.memory_map[i].read8 = bram_read_byte;
s68k.memory_map[i].read16 = bram_read_word;

View File

@ -1165,64 +1165,91 @@ static void rompathmenu ()
{
ret = GUI_RunMenu(m);
switch (ret)
if (ret < 0)
{
case -1:
{
GUI_DeleteMenu(m);
return;
}
GUI_DeleteMenu(m);
return;
}
/* Initialize System ROM browser */
if (OpenDirectory(config.l_device, ret + FILETYPE_MAX))
{
/* Get current System ROM path */
char *dir = GetCurrentDirectory();
default:
/* Open System ROM browser */
GUI_DeleteMenu(m);
i = FileSelector(ret + FILETYPE_MAX);
/* System ROM selected ? */
if (i >= 0)
{
/* Initialize System ROM browser */
if (OpenDirectory(config.l_device, ret + FILETYPE_MAX))
/* full System ROM pathname */
sprintf(config.sys_rom[ret],"%s%s",dir,filelist[i].filename);
/* mark System ROM as found */
strcpy(strstr(items[ret].text,":") + 2, "FOUND");
/* BOOT ROM special cases */
switch (ret)
{
/* Open System ROM browser */
GUI_DeleteMenu(m);
i = FileSelector(ret + FILETYPE_MAX);
/* Get current System ROM path */
char *dir = GetCurrentDirectory();
/* System ROM selected ? */
if (i >= 0)
case 0:
case 1:
case 2:
{
/* full System ROM pathname */
sprintf(config.sys_rom[ret],"%s%s",dir,filelist[i].filename);
/* mark System ROM as found */
strcpy(strstr(items[ret].text,":") + 2, "FOUND");
/* Genesis BOOT ROM special case */
if (config.sys_rom[ret] == MD_BIOS)
{
/* Genesis BOOT ROM must be reloaded */
if (load_archive(MD_BIOS, boot_rom, 0x800, NULL) > 0)
{
/* check if BOOT ROM header is valid */
if (!memcmp((char *)(boot_rom + 0x120),"GENESIS OS", 10))
{
/* mark Genesis BIOS as loaded */
system_bios |= SYSTEM_MD;
}
else
{
/* mark Genesis BIOS as unloaded */
system_bios &= ~SYSTEM_MD;
}
}
}
/* force CD BOOT ROM reloading */
system_bios &= ~0x10;
break;
}
free(dir);
GUI_InitMenu(m);
case 3:
{
/* Genesis BOOT ROM must be reloaded */
if (load_archive(MD_BIOS, boot_rom, 0x800, NULL) > 0)
{
/* check if BOOT ROM header is valid */
if (!memcmp((char *)(boot_rom + 0x120),"GENESIS OS", 10))
{
/* mark Genesis BOOT ROM as loaded */
system_bios |= SYSTEM_MD;
}
else
{
/* mark Genesis BOOT ROM as unloaded */
system_bios &= ~SYSTEM_MD;
}
}
break;
}
case 4:
case 5:
case 6:
{
/* force Master System BOOT ROM reloading */
system_bios &= ~SYSTEM_SMS;
break;
}
case 7:
{
/* force Game Gear BOOT ROM reloading */
system_bios &= ~SYSTEM_GG;
break;
}
default:
{
/* not a BOOT ROM */
break;
}
}
}
free(dir);
GUI_InitMenu(m);
}
}
GUI_DeleteMenu(m);
}
/****************************************************************************