OSDN Git Service

[General] Convert sourcecode's CRLF format: DOS(WINDOWS) to Unix, to apply patches...
[csp-qt/common_source_project-fm7.git] / source / src / vm / pasopia / floppy.h
1 /*
2         TOSHIBA PASOPIA Emulator 'EmuPIA'
3
4         Author : Takeda.Toshiya
5         Date   : 2006.09.20 -
6
7         [ floppy ]
8 */
9
10 #ifndef _FLOPPY_H_
11 #define _FLOPPY_H_
12
13 #include "../vm.h"
14 #include "../../emu.h"
15 #include "../device.h"
16
17 #define SIG_FLOPPY_INTR 0
18
19 class FLOPPY : public DEVICE
20 {
21 private:
22         DEVICE *d_fdc;
23         bool intr;
24         
25 public:
26         FLOPPY(VM* parent_vm, EMU* parent_emu) : DEVICE(parent_vm, parent_emu) {}
27         ~FLOPPY() {}
28         
29         // common functions
30         void initialize();
31         void write_io8(uint32 addr, uint32 data);
32         uint32 read_io8(uint32 addr);
33         void write_signal(int id, uint32 data, uint32 mask);
34         void save_state(FILEIO* state_fio);
35         bool load_state(FILEIO* state_fio);
36         
37         // unique functions
38         void set_context_fdc(DEVICE* device)
39         {
40                 d_fdc = device;
41         }
42         bool supported;
43 };
44
45 #endif
46