diff --git a/ares/n64/dd/dd.cpp b/ares/n64/dd/dd.cpp index 5c0152ec0e..3deaf8b35b 100644 --- a/ares/n64/dd/dd.cpp +++ b/ares/n64/dd/dd.cpp @@ -105,7 +105,6 @@ auto DD::disconnect() -> void { if(id.match("NDXJ")) dd.information.cic = "CIC-NUS-8401"; } - io.status.diskChanged = 0; io.status.diskPresent = 0; //Deal with cases when the disk is removed while in use @@ -142,7 +141,9 @@ auto DD::power(bool reset) -> void { state = {}; io.status.resetState = 1; + io.status.diskChanged = 1; if(disk) io.status.diskPresent = 1; + io.id = 3; if(dd.information.cic.match("CIC-NUS-8401")) io.id = 4; diff --git a/ares/n64/dd/io.cpp b/ares/n64/dd/io.cpp index 9716ee25ef..6d8423f181 100644 --- a/ares/n64/dd/io.cpp +++ b/ares/n64/dd/io.cpp @@ -123,7 +123,6 @@ auto DD::readHalf(u32 address) -> u16 { if(address == 36) { } - debugger.io(Read, address, data); return data; } @@ -195,7 +194,7 @@ auto DD::writeHalf(u32 address, u16 data_) -> void { //ASIC_HARD_RESET if(address == 16) { - if((data >> 16) == 0xAAAA) { + if(data == 0xAAAA) { power(true); } } @@ -242,18 +241,20 @@ auto DD::writeHalf(u32 address, u16 data_) -> void { //ASIC_TEST_PIN_SEL if(address == 36) { } - - debugger.io(Write, address, data); } auto DD::readWord(u32 address) -> u32 { + address = (address & 0x7f); n32 data; data.bit(16,31) = readHalf(address + 0); data.bit( 0,15) = readHalf(address + 2); + debugger.io(Read, address >> 2, data); return (u32)data; } auto DD::writeWord(u32 address, u32 data) -> void { + address = (address & 0x7f); writeHalf(address + 0, data >> 16); writeHalf(address + 2, data & 0xffff); + debugger.io(Write, address >> 2, data); }