10 reset(EmuTime::dummy());
25 unsigned bbb = (address >> 11) & 0b111;
27 unsigned region = bbb - 2;
28 if ((address & 1) == 0) {
29 blockReg[region] = uint16_t((blockReg[region] & 0xFF00) | value);
31 blockReg[region] = uint16_t((blockReg[region] & 0x00FF) | ((value & 0b1111) << 8));
33 setRom(region, blockReg[region]);
38 unsigned bbb = (address >> 11) & 0b111;
42template<
typename Archive>
45 ar.template serializeBase<Rom8kBBlocks>(*
this);
46 ar.serialize(
"blockReg", blockReg);
#define REGISTER_MSXDEVICE(CLASS, NAME)
static std::array< byte, 0x10000 > unmappedWrite
void setUnmapped(unsigned region)
Select 'unmapped' memory for this region.
void setRom(unsigned region, unsigned block)
Selects a block of the ROM image for reading in a certain region.
byte * getWriteCacheLine(word address) override
Test that the memory in the interval [start, start + CacheLine::SIZE) is cacheable for writing.
void serialize(Archive &ar, unsigned version)
RomNeo8(const DeviceConfig &config, Rom &&rom)
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.
void reset(EmuTime::param time) override
This method is called on reset.
This file implemented 3 utility functions:
uint16_t word
16 bit unsigned integer
#define INSTANTIATE_SERIALIZE_METHODS(CLASS)
constexpr auto xrange(T e)