OSDN Git Service

a815288c74e0f32f94c73e04c8217cf22238074b
[csp-qt/common_source_project-fm7.git] / source / src / vm / mz2800 / sysport.h
1 /*
2         SHARP MZ-2800 Emulator 'EmuZ-2800'
3
4         Author : Takeda.Toshiya
5         Date   : 2007.08.14 -
6
7         [ system poty ]
8 */
9
10 #ifndef _SYSPORT_H_
11 #define _SYSPORT_H_
12
13 #include "../vm.h"
14 #include "../../emu.h"
15 #include "../device.h"
16
17 class SYSPORT : public DEVICE
18 {
19 private:
20         DEVICE *d_pit, *d_sio;
21         
22 public:
23         SYSPORT(VM_TEMPLATE* parent_vm, EMU* parent_emu) : DEVICE(parent_vm, parent_emu)
24         {
25                 set_device_name(_T("System I/O"));
26         }
27         ~SYSPORT() {}
28         
29         // common functions
30         void write_io8(uint32_t addr, uint32_t data);
31         uint32_t read_io8(uint32_t addr);
32         
33         // unique functions
34         void set_context_pit(DEVICE* device)
35         {
36                 d_pit = device;
37         }
38         void set_context_sio(DEVICE* device)
39         {
40                 d_sio = device;
41         }
42 };
43
44 #endif
45