modem: modem must hang up as soon as reg20 is written
some games don't do a full reset and the modem would stay connected. Remove debug file dumps.
This commit is contained in:
parent
5b9dd96064
commit
a682e20bbd
|
@ -127,8 +127,6 @@ static bool data_sent;
|
|||
static u64 last_comm_stats;
|
||||
static int sent_bytes;
|
||||
static int recvd_bytes;
|
||||
static FILE *recv_fp;
|
||||
static FILE *sent_fp;
|
||||
#endif
|
||||
|
||||
static int modem_sched_func(int tag, int cycles, int jitter, void *arg)
|
||||
|
@ -436,12 +434,12 @@ static void modem_reset(u32 v)
|
|||
memset(&modem_regs, 0, sizeof(modem_regs));
|
||||
state = MS_RESET;
|
||||
LOG("Modem reset start ...");
|
||||
net::modbba::stop();
|
||||
}
|
||||
else
|
||||
{
|
||||
if (state == MS_RESET)
|
||||
{
|
||||
net::modbba::stop();;
|
||||
memset(&modem_regs, 0, sizeof(modem_regs));
|
||||
state = MS_RESETING;
|
||||
ControllerTestStart();
|
||||
|
@ -470,13 +468,6 @@ static u8 download_crc;
|
|||
|
||||
static void ModemNormalWrite(u32 reg, u32 data)
|
||||
{
|
||||
#ifndef NDEBUG
|
||||
if (recv_fp == NULL)
|
||||
{
|
||||
recv_fp = fopen("ppp_recv.dump", "w");
|
||||
sent_fp = fopen("ppp_sent.dump", "w");
|
||||
}
|
||||
#endif
|
||||
//if (!module_download && reg != 0x10)
|
||||
// LOG("ModemNormalWrite : %03X=%X", reg,data);
|
||||
u32 old = modem_regs.ptr[reg];
|
||||
|
@ -525,8 +516,6 @@ static void ModemNormalWrite(u32 reg, u32 data)
|
|||
data_sent = true;
|
||||
#ifndef NDEBUG
|
||||
sent_bytes++;
|
||||
if (sent_fp)
|
||||
fputc(data, sent_fp);
|
||||
#endif
|
||||
net::modbba::writeModem(data);
|
||||
modem_regs.reg1e.TDBE = 0;
|
||||
|
@ -686,10 +675,6 @@ u32 ModemReadMem_A0_006(u32 addr, u32 size)
|
|||
modem_regs.reg1e.RDBF = 0;
|
||||
SET_STATUS_BIT(0x0c, modem_regs.reg0c.RXFNE, 0);
|
||||
SET_STATUS_BIT(0x01, modem_regs.reg01.RXHF, 0);
|
||||
#ifndef NDEBUG
|
||||
if (connect_state == CONNECTED && recv_fp)
|
||||
fputc(data, recv_fp);
|
||||
#endif
|
||||
update_interrupt();
|
||||
}
|
||||
else if (reg == 0x16 || reg == 0x17)
|
||||
|
|
Loading…
Reference in New Issue