mirror of
https://github.com/zoriya/ComSquare.git
synced 2026-06-01 17:55:30 +00:00
fiw the prototype of getVramAddress uint8 -> uint16
This commit is contained in:
+4
-5
@@ -30,8 +30,8 @@ namespace ComSquare::PPU
|
||||
case 0x36:
|
||||
return this->_registers._mpy.mpyh;
|
||||
default:
|
||||
//throw InvalidAddress("PPU Internal Registers read", addr);
|
||||
std::cout << "PPU Internal Registers read" << addr << std::endl;
|
||||
throw InvalidAddress("PPU Internal Registers read", addr);
|
||||
//std::cout << "PPU Internal Registers read" << addr << std::endl;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -112,7 +112,7 @@ namespace ComSquare::PPU
|
||||
//std::cout << "vmdatal" << std::endl;
|
||||
if (!this->_registers._inidisp.fblank) {
|
||||
this->_registers._vmdata.vmdatal = data;
|
||||
this->vram->write_internal(getVramAddress(), this->_registers._vmdata.vmdata);
|
||||
this->vram->write_internal(getVramAddress(), this->_registers._vmdata.vmdatal);
|
||||
}
|
||||
if (!this->_registers._vmain.incrementMode)
|
||||
this->_registers._vmadd.vmadd += this->_registers._incrementAmount;
|
||||
@@ -121,7 +121,6 @@ namespace ComSquare::PPU
|
||||
//std::cout << "vmdatah" << std::endl;
|
||||
if (!this->_registers._inidisp.fblank) {
|
||||
this->_registers._vmdata.vmdatah = data;
|
||||
this->vram->write_internal(getVramAddress(), this->_registers._vmdata.vmdatal);
|
||||
this->vram->write_internal(getVramAddress(), this->_registers._vmdata.vmdatah);
|
||||
}
|
||||
if (this->_registers._vmain.incrementMode)
|
||||
@@ -202,7 +201,7 @@ namespace ComSquare::PPU
|
||||
}
|
||||
}
|
||||
|
||||
uint8_t PPU::getVramAddress()
|
||||
uint16_t PPU::getVramAddress()
|
||||
{
|
||||
uint16_t vanillaAddress = this->_registers._vmadd.vmadd;
|
||||
|
||||
|
||||
+1
-1
@@ -530,7 +530,7 @@ namespace ComSquare::PPU
|
||||
//! @param The number of cycles to update.
|
||||
virtual void update(unsigned cycles);
|
||||
//! @brief Give the Vram Address with the right Address remapping
|
||||
uint8_t getVramAddress();
|
||||
uint16_t getVramAddress();
|
||||
//! @brief Give the name of the Address register (used for debug)
|
||||
std::string getValueName(uint24_t addr);
|
||||
//! @brief Return true if the CPU is overloaded with debugging features.
|
||||
|
||||
Reference in New Issue
Block a user