openMSX
RomHalnote.hh
Go to the documentation of this file.
1 #ifndef ROMHALNOTE_HH
2 #define ROMHALNOTE_HH
3 
4 #include "RomBlocks.hh"
5 
6 namespace openmsx {
7 
8 class RomHalnote final : public Rom8kBBlocks
9 {
10 public:
11  RomHalnote(const DeviceConfig& config, Rom&& rom);
12 
13  void reset(EmuTime::param time) override;
14  byte readMem(word address, EmuTime::param time) override;
15  const byte* getReadCacheLine(word address) const override;
16  void writeMem(word address, byte value, EmuTime::param time) override;
17  byte* getWriteCacheLine(word address) const override;
18 
19  template<typename Archive>
20  void serialize(Archive& ar, unsigned version);
21 
22 private:
23  byte subBanks[2];
24  bool sramEnabled;
25  bool subMapperEnabled;
26 };
27 
28 } // namespace openmsx
29 
30 #endif
openmsx::RomHalnote::serialize
void serialize(Archive &ar, unsigned version)
Definition: RomHalnote.cc:149
openmsx::RomHalnote::RomHalnote
RomHalnote(const DeviceConfig &config, Rom &&rom)
Definition: RomHalnote.cc:35
openmsx::RomHalnote::readMem
byte readMem(word address, EmuTime::param time) override
Read a byte from a location at a certain time from this device.
Definition: RomHalnote.cc:72
openmsx::DeviceConfig
Definition: DeviceConfig.hh:19
openmsx::RomHalnote::getReadCacheLine
const byte * getReadCacheLine(word address) const override
Test that the memory in the interval [start, start + CacheLine::SIZE) is cacheable for reading.
Definition: RomHalnote.cc:61
openmsx::RomHalnote::writeMem
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.
Definition: RomHalnote.cc:78
openmsx::RomHalnote
Definition: RomHalnote.hh:8
openmsx::RomBlocks
Definition: RomBlocks.hh:13
openmsx::MSXRom::rom
Rom rom
Definition: MSXRom.hh:20
openmsx::Rom
Definition: Rom.hh:20
openmsx::RomHalnote::getWriteCacheLine
byte * getWriteCacheLine(word address) const override
Test that the memory in the interval [start, start + CacheLine::SIZE) is cacheable for writing.
Definition: RomHalnote.cc:127
openmsx::word
uint16_t word
16 bit unsigned integer
Definition: openmsx.hh:29
openmsx::RomHalnote::reset
void reset(EmuTime::param time) override
This method is called on reset.
Definition: RomHalnote.cc:46
openmsx
Thanks to enen for testing this on a real cartridge:
Definition: Autofire.cc:5
RomBlocks.hh