OSDN Git Service

[VM][I286] Save cpustate without StateBuffer().
[csp-qt/common_source_project-fm7.git] / source / src / vm / mz80k / printer.h
1 /*
2         SHARP MZ-80K/C Emulator 'EmuZ-80K'
3         SHARP MZ-1200 Emulator 'EmuZ-1200'
4         SHARP MZ-80A Emulator 'EmuZ-80A'
5
6         Author : Hideki Suga
7         Date   : 2016.03.18-
8
9         [ printer ]
10 */
11
12 #ifndef _PRINTER_H_
13 #define _PRINTER_H_
14
15 #include "../vm.h"
16 #include "../../emu.h"
17 #include "../device.h"
18
19 class PRINTER : public DEVICE
20 {
21 private:
22         DEVICE* d_prn;
23 #if defined(_MZ1200) || defined(_MZ80K)
24         uint8_t out_ch;
25 #endif
26         
27 public:
28         PRINTER(VM_TEMPLATE* parent_vm, EMU* parent_emu) : DEVICE(parent_vm, parent_emu)
29         {
30                 set_device_name(_T("Printer I/F"));
31         }
32         ~PRINTER() {}
33         
34         // common functions
35         void write_io8(uint32_t addr, uint32_t data);
36         uint32_t read_io8(uint32_t addr);
37 #if defined(_MZ1200) || defined(_MZ80K)
38         bool process_state(FILEIO* state_fio, bool loading);
39 #endif
40         
41         // unique function
42         void set_context_prn(DEVICE* device)
43         {
44                 d_prn = device;
45         }
46 };
47
48 #endif
49