Fix code gaff in reset in BSX code

This commit is contained in:
Brandon Wright 2017-12-06 18:39:10 -06:00
parent 94f9f6ff25
commit dd1202a2ad
1 changed files with 11 additions and 12 deletions

13
bsx.cpp
View File

@ -450,7 +450,7 @@ static void map_psram_mirror_sub (uint32 bank)
static void BSX_Map_PSRAM(void)
{
int c, i;
int c;
if (!BSX.MMC[0x02])
{
@ -773,7 +773,6 @@ uint8 S9xGetBSX (uint32 address)
void S9xSetBSX (uint8 byte, uint32 address)
{
uint8 bank = (address >> 16) & 0xFF;
uint16 offset = address & 0xFFFF;
// MMC
if ((bank >= 0x01 && bank <= 0x0E))
@ -1517,12 +1516,12 @@ void S9xResetBSX (void)
BSX.MMC[0x0E] = 0x80;
// stream reset
BSX.sat_pf_latch1_enable, BSX.sat_dt_latch1_enable = FALSE;
BSX.sat_pf_latch2_enable, BSX.sat_dt_latch2_enable = FALSE;
BSX.sat_pf_latch1_enable = BSX.sat_dt_latch1_enable = FALSE;
BSX.sat_pf_latch2_enable = BSX.sat_dt_latch2_enable = FALSE;
BSX.sat_stream1_loaded, BSX.sat_stream2_loaded = FALSE;
BSX.sat_stream1_first, BSX.sat_stream2_first = FALSE;
BSX.sat_stream1_count, BSX.sat_stream2_count = 0;
BSX.sat_stream1_loaded = BSX.sat_stream2_loaded = FALSE;
BSX.sat_stream1_first = BSX.sat_stream2_first = FALSE;
BSX.sat_stream1_count = BSX.sat_stream2_count = 0;
if (BSX.sat_stream1.is_open())
BSX.sat_stream1.close();