openMSX
RomKonamiSCC.hh
Go to the documentation of this file.
1 #ifndef ROMKONAMISCC_HH
2 #define ROMKONAMISCC_HH
3 
4 #include "RomBlocks.hh"
5 #include "SCC.hh"
6 
7 namespace openmsx {
8 
9 class RomKonamiSCC final : public Rom8kBBlocks
10 {
11 public:
12  RomKonamiSCC(const DeviceConfig& config, Rom&& rom);
13 
14  void powerUp(EmuTime::param time) override;
15  void reset(EmuTime::param time) override;
16  byte peekMem(word address, EmuTime::param time) const override;
17  byte readMem(word address, EmuTime::param time) override;
18  const byte* getReadCacheLine(word address) const override;
19  void writeMem(word address, byte value, EmuTime::param time) override;
20  byte* getWriteCacheLine(word address) const override;
21 
22  template<typename Archive>
23  void serialize(Archive& ar, unsigned version);
24 
25 private:
26  SCC scc;
27  bool sccEnabled;
28 };
29 
30 } // namespace openmsx
31 
32 #endif
openmsx::RomKonamiSCC::reset
void reset(EmuTime::param time) override
This method is called on reset.
Definition: RomKonamiSCC.cc:47
openmsx::DeviceConfig
Definition: DeviceConfig.hh:20
openmsx::RomKonamiSCC::getWriteCacheLine
byte * getWriteCacheLine(word address) const override
Test that the memory in the interval [start, start + CacheLine::SIZE) is cacheable for writing.
Definition: RomKonamiSCC.cc:117
openmsx::RomKonamiSCC::peekMem
byte peekMem(word address, EmuTime::param time) const override
Read a byte from a given memory location.
Definition: RomKonamiSCC.cc:61
openmsx::SCC
Definition: SCC.hh:12
openmsx::RomBlocks
Definition: RomBlocks.hh:14
openmsx::MSXRom::rom
Rom rom
Definition: MSXRom.hh:20
openmsx::Rom
Definition: Rom.hh:21
openmsx::RomKonamiSCC::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: RomKonamiSCC.cc:89
openmsx::RomKonamiSCC::RomKonamiSCC
RomKonamiSCC(const DeviceConfig &config, Rom &&rom)
Definition: RomKonamiSCC.cc:26
openmsx::RomKonamiSCC::powerUp
void powerUp(EmuTime::param time) override
This method is called when MSX is powered up.
Definition: RomKonamiSCC.cc:41
openmsx::word
uint16_t word
16 bit unsigned integer
Definition: openmsx.hh:29
SCC.hh
openmsx::RomKonamiSCC::getReadCacheLine
const byte * getReadCacheLine(word address) const override
Test that the memory in the interval [start, start + CacheLine::SIZE) is cacheable for reading.
Definition: RomKonamiSCC.cc:79
openmsx::RomKonamiSCC::serialize
void serialize(Archive &ar, unsigned version)
Definition: RomKonamiSCC.cc:136
openmsx::RomKonamiSCC
Definition: RomKonamiSCC.hh:10
openmsx::RomKonamiSCC::readMem
byte readMem(word address, EmuTime::param time) override
Read a byte from a location at a certain time from this device.
Definition: RomKonamiSCC.cc:70
openmsx
This file implemented 3 utility functions:
Definition: Autofire.cc:5
RomBlocks.hh