OSDN Git Service

d26ed7e1d86cae1e382eb3e641ead79baa9e09b4
[csp-qt/common_source_project-fm7.git] / source / src / vm / pasopia / rampac2.h
1 /*
2         TOSHIBA PASOPIA Emulator 'EmuPIA'
3         TOSHIBA PASOPIA 7 Emulator 'EmuPIA7'
4
5         Author : Takeda.Toshiya
6         Date   : 2006.09.20 -
7
8         [ ram pac 2 (32kbytes) ]
9 */
10
11 #ifndef _RAMPAC2_H_
12 #define _RAMPAC2_H_
13
14 #include "../vm.h"
15 #include "../../emu.h"
16 #include "pac2dev.h"
17
18 class RAMPAC2 : public PAC2DEV
19 {
20 private:
21         _TCHAR path[_MAX_PATH];
22         uint8_t ram[32*1024];
23         uint32_t ptr;
24         bool opened, modified;
25         
26 public:
27         RAMPAC2(VM* parent_vm, EMU* parent_emu) : PAC2DEV(parent_vm, parent_emu)
28         {
29                 set_device_name(_T("RAM PAC2"));
30         }
31         ~RAMPAC2() {}
32         
33         // common functions
34         void initialize(int id);
35         void release();
36         void reset();
37         void write_io8(uint32_t addr, uint32_t data);
38         uint32_t read_io8(uint32_t addr);
39         void open_file(const _TCHAR* file_path);
40         bool process_state(FILEIO* state_fio, bool loading);
41 };
42
43 #endif
44