12 :
MSXRom(config, std::move(rom_))
13 , romBlockDebug(*this, &conversion, 0x4000, 0x8000, 15)
25 if ((0x4000 <= address) && (address < 0xc000)) {
26 byte value =
rom[address - 0x4000];
31 return (value & 0xf8) | (value << 2 & 0x04) | (value >> 1 & 0x03);
33 return (value & 0xf8) | (value >> 2 & 0x01) | (value << 1 & 0x06);
37 switch (value & 0x07) {
45 if (conversion == 2)
return (value & 0xf8) | (((value << 2 & 0x04) | (value >> 1 & 0x03)) ^ 0x07);
46 if (conversion == 5)
return value ^ 0x07;
47 if (conversion == 6)
return (value & 0xf8) | (((value >> 2 & 0x01) | (value << 1 & 0x06)) ^ 0x07);
66 if ((0x4000 <= address) && (address < 0xc000)) {
67 conversion = value & 0x07;
80 template<
typename Archive>
83 ar.template serializeBase<MSXDevice>(*
this);
84 ar.serialize(
"conversion", conversion);
static byte unmappedWrite[0x10000]
byte readMem(word address, EmuTime::param time) override
Read a byte from a location at a certain time from this device.
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.
byte peekMem(word address, EmuTime::param time) const override
Read a byte from a given memory location.
void serialize(Archive &ar, unsigned version)
RomDooly(const DeviceConfig &config, Rom &&rom)
byte * getWriteCacheLine(word address) const override
Test that the memory in the interval [start, start + CacheLine::SIZE) is cacheable for writing.
This file implemented 3 utility functions:
REGISTER_MSXDEVICE(ChakkariCopy, "ChakkariCopy")
uint16_t word
16 bit unsigned integer
#define INSTANTIATE_SERIALIZE_METHODS(CLASS)