openMSX
MSXSwitchedDevice.hh
Go to the documentation of this file.
1#ifndef MSXSWITCHEDDEVICE_HH
2#define MSXSWITCHEDDEVICE_HH
3
4#include "EmuTime.hh"
5#include "openmsx.hh"
6
7namespace openmsx {
8
9class MSXMotherBoard;
10
12{
13public:
14 [[nodiscard]] virtual byte readSwitchedIO(word port, EmuTime::param time) = 0;
15 [[nodiscard]] virtual byte peekSwitchedIO(word port, EmuTime::param time) const = 0;
16 virtual void writeSwitchedIO(word port, byte value, EmuTime::param time) = 0;
17
18protected:
19 MSXSwitchedDevice(MSXMotherBoard& motherBoard, byte id);
21
22private:
23 MSXMotherBoard& motherBoard;
24 const byte id;
25};
26
27} // namespace openmsx
28
29#endif
virtual byte peekSwitchedIO(word port, EmuTime::param time) const =0
virtual void writeSwitchedIO(word port, byte value, EmuTime::param time)=0
virtual byte readSwitchedIO(word port, EmuTime::param time)=0
This file implemented 3 utility functions:
Definition Autofire.cc:11
uint16_t word
16 bit unsigned integer
Definition openmsx.hh:29