9 static const char*
const PAC_Header =
"PAC2 BACKUP DATA";
14 getName() +
" SRAM", 0x1FFE, config, PAC_Header))
34 if (address < 0x1FFE) {
35 result = (*sram)[address];
36 }
else if (address == 0x1FFE) {
38 }
else if (address == 0x1FFF) {
53 if (address < (0x1FFE & CacheLine::HIGH)) {
54 return &(*sram)[address];
55 }
else if (address == (0x1FFE & CacheLine::HIGH)) {
78 if (sramEnabled && (address < 0x1FFE)) {
79 sram->write(address, value);
87 if (address == (0x1FFE & CacheLine::HIGH)) {
90 if (sramEnabled && (address < 0x1FFE)) {
97 void MSXPac::checkSramEnable()
99 bool newEnabled = (r1ffe == 0x4D) && (r1fff == 0x69);
100 if (sramEnabled != newEnabled) {
101 sramEnabled = newEnabled;
106 template<
typename Archive>
109 ar.template serializeBase<MSXDevice>(*this);
110 ar.serialize(
"SRAM", *sram);
111 ar.serialize(
"r1ffe", r1ffe);
112 ar.serialize(
"r1fff", r1fff);