9 , bunsetsuRom(getName() +
"_1",
"rom", config,
"bunsetsu")
10 , jisyoRom (getName() +
"_2",
"rom", config,
"jisyo")
12 reset(EmuTime::dummy());
22 if (address == 0xBFFF) {
23 byte result = jisyoRom[jisyoAddress];
24 jisyoAddress = (jisyoAddress + 1) & 0x1FFFF;
26 }
else if ((0x4000 <= address) && (address < 0xC000)) {
27 return bunsetsuRom[address - 0x4000];
37 jisyoAddress = (jisyoAddress & 0x1FF00) | value;
40 jisyoAddress = (jisyoAddress & 0x100FF) | (value << 8);
43 jisyoAddress = (jisyoAddress & 0x0FFFF) |
54 return &bunsetsuRom[start - 0x4000];
67template<
typename Archive>
70 ar.template serializeBase<MSXDevice>(*
this);
71 ar.serialize(
"jisyoAddress", jisyoAddress);
#define REGISTER_MSXDEVICE(CLASS, NAME)
byte * getWriteCacheLine(word start) override
Test that the memory in the interval [start, start + CacheLine::SIZE) is cacheable for writing.
void reset(EmuTime::param time) override
This method is called on reset.
void writeMem(word address, byte value, EmuTime::param time) override
Write a given byte to a given location at a certain time to this device.
const byte * getReadCacheLine(word start) const override
Test that the memory in the interval [start, start + CacheLine::SIZE) is cacheable for reading.
MSXBunsetsu(const DeviceConfig &config)
byte readMem(word address, EmuTime::param time) override
Read a byte from a location at a certain time from this device.
void serialize(Archive &ar, unsigned version)
An MSXDevice is an emulated hardware component connected to the bus of the emulated MSX.
static std::array< byte, 0x10000 > unmappedWrite
This file implemented 3 utility functions:
uint16_t word
16 bit unsigned integer
#define INSTANTIATE_SERIALIZE_METHODS(CLASS)