Skip to content

Commit

Permalink
n64: fix a typo in ISViewer address range
Browse files Browse the repository at this point in the history
Added in 1478637. This basically prevented ROM size between
0x3f0'0000 and 0x3ff'0000 to work correctly in Ares.
  • Loading branch information
rasky committed Jan 31, 2025
1 parent fa1c21b commit 3ccfac7
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion ares/n64/cartridge/cartridge.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@ auto Cartridge::connect() -> void {

rtc.load();

if(rom.size <= 0x03fe'ffff) {
if(rom.size <= 0x03ff'0000) {
isviewer.ram.allocate(64_KiB);
isviewer.tracer = node->append<Node::Debugger::Tracer::Notification>("ISViewer", "Cartridge");
isviewer.tracer->setAutoLineBreak(false);
Expand Down
4 changes: 2 additions & 2 deletions ares/n64/pi/bus.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@ inline auto PI::busRead(u32 address) -> u32 {
if(cartridge.flash) return cartridge.flash.read<Size>(address);
return unmapped;
}
if(cartridge.isviewer.enabled() && address >= 0x13f0'0000 && address <= 0x13ff'ffff) {
if(cartridge.isviewer.enabled() && address >= 0x13ff'0000 && address <= 0x13ff'ffff) {
return cartridge.isviewer.read<Size>(address);
}
if(address <= 0x1000'0000 + cartridge.rom.size - 1) {
Expand Down Expand Up @@ -94,7 +94,7 @@ inline auto PI::busWrite(u32 address, u32 data) -> void {
if(cartridge.flash) return cartridge.flash.write<Size>(address, data);
return;
}
if(address >= 0x13f0'0000 && address <= 0x13ff'ffff) {
if(address >= 0x13ff'0000 && address <= 0x13ff'ffff) {
if(cartridge.isviewer.enabled()) {
writeForceFinish(); //Debugging channel for homebrew, be gentle
return cartridge.isviewer.write<Size>(address, data);
Expand Down

0 comments on commit 3ccfac7

Please sign in to comment.