2 EPSON HC-40 Emulator 'eHC-40'
4 Author : Takeda.Toshiya
13 #define DEVICE_NAME "EPSON HC-40"
14 #define CONFIG_NAME "hc40"
16 // device informations for virtual machine
17 #define FRAMES_PER_SEC 72
18 #define LINES_PER_FRAME 64
19 #define CPU_CLOCKS 3686400
20 #define SCREEN_WIDTH 240
21 #define SCREEN_HEIGHT 64
24 // device informations for win32
25 #define WINDOW_WIDTH (SCREEN_WIDTH * 2)
26 #define WINDOW_HEIGHT (SCREEN_HEIGHT * 2)
28 #define USE_SPECIAL_RESET
34 #define NOTIFY_KEY_DOWN
35 #define USE_ALT_F10_KEY
36 #define USE_AUTO_KEY 6
37 #define USE_AUTO_KEY_RELEASE 10
38 #define USE_ACCESS_LAMP
42 #include "../../common.h"
43 #include "../../fileio.h"
74 // ----------------------------------------
76 // ----------------------------------------
81 // ----------------------------------------
82 // for emulation class
83 // ----------------------------------------
85 // drive virtual machine
92 DEVICE *get_cpu(int index);
100 void initialize_sound(int rate, int samples);
101 uint16* create_sound(int* extra_frames);
102 int sound_buffer_ptr();
105 void key_down(int code, bool repeat);
106 void key_up(int code);
109 void open_disk(int drv, const _TCHAR* file_path, int bank);
110 void close_disk(int drv);
111 bool disk_inserted(int drv);
112 void set_disk_protected(int drv, bool value);
113 bool get_disk_protected(int drv);
114 void play_tape(const _TCHAR* file_path);
115 void rec_tape(const _TCHAR* file_path);
117 bool tape_inserted();
119 bool tape_recording();
123 void update_config();
124 void save_state(FILEIO* state_fio);
125 bool load_state(FILEIO* state_fio);
127 // ----------------------------------------
129 // ----------------------------------------
132 DEVICE* get_device(int id);
134 DEVICE* first_device;