OSDN Git Service

[VM][BABBAGE2ND] Fix FTBFS.
[csp-qt/common_source_project-fm7.git] / source / src / vm / babbage2nd / babbage2nd.h
index 0c77bb1..6adb9ac 100644 (file)
 #define ONE_BOARD_MICRO_COMPUTER
 #define MAX_BUTTONS            21
 #define MAX_DRAW_RANGES                14
-#define USE_BINARY_FILE1
+#define USE_BINARY_FILE                1
 #define NOTIFY_KEY_DOWN
+#define USE_DEBUGGER
+#define USE_STATE
+#define USE_CPU_Z80
 
 #include "../../common.h"
 #include "../../fileio.h"
+#include "../vm_template.h"
 
 const struct {
        int x, y;
@@ -79,6 +83,8 @@ const struct {
        {369, 133, 17, 17},
 };
 
+class csp_state_utils;
+
 class EMU;
 class DEVICE;
 class EVENT;
@@ -92,13 +98,14 @@ class Z80PIO;
 class DISPLAY;
 class KEYBOARD;
 
-class VM
+class VM : public VM_TEMPLATE
 {
 protected:
-       EMU* emu;
+       //EMU* emu;
+       //csp_state_utils* state_entry;
        
        // devices
-       EVENT* event;
+       //EVENT* event;
        
        IO* io;
        MEMORY* memory;
@@ -130,6 +137,11 @@ public:
        void reset();
        void run();
        
+#ifdef USE_DEBUGGER
+       // debugger
+       DEVICE *get_cpu(int index);
+#endif
+       
        // draw screen
        void draw_screen();
        
@@ -148,6 +160,9 @@ public:
        bool is_frame_skippable();
        
        void update_config();
+       void decl_state();
+       void save_state(FILEIO* state_fio);
+       bool load_state(FILEIO* state_fio);
        
        // ----------------------------------------
        // for each device
@@ -155,9 +170,9 @@ public:
        
        // devices
        DEVICE* get_device(int id);
-       DEVICE* dummy;
-       DEVICE* first_device;
-       DEVICE* last_device;
+       //DEVICE* dummy;
+       //DEVICE* first_device;
+       //DEVICE* last_device;
 };
 
 #endif