OSDN Git Service

[LIBNEWDEV][I8086] Apply to FM16pi, FM-R30, PC-100 and PC98HA.
authorK.Ohta <whatisthis.sowhat@gmail.com>
Thu, 9 Feb 2017 11:45:47 +0000 (20:45 +0900)
committerK.Ohta <whatisthis.sowhat@gmail.com>
Thu, 9 Feb 2017 11:45:47 +0000 (20:45 +0900)
13 files changed:
source/build-cmake/cmake/config_pc98ha.cmake
source/build-cmake/fm16pi/CMakeLists.txt
source/build-cmake/fmr30/CMakeLists.txt
source/build-cmake/pc100/CMakeLists.txt
source/src/vm/fm16pi/fm16pi.cpp
source/src/vm/fm16pi/fm16pi.h
source/src/vm/fmr30/fmr30.cpp
source/src/vm/fmr30/fmr30.h
source/src/vm/pc100/pc100.cpp
source/src/vm/pc100/pc100.h
source/src/vm/pc6031.cpp
source/src/vm/pc98ha/pc98ha.cpp
source/src/vm/pc98ha/pc98ha.h

index 09ec2f9..b2f70d2 100644 (file)
@@ -46,16 +46,16 @@ if(BUILD_PC98HA)
    set(EXEC_TARGET emupc98ha)
    set(VMFILES ${VMFILES}
                   upd4991a.cpp
-                  i286.cpp
    )
+   set(FLAG_USE_I86 ON)
    set(RESOURCE ${CMAKE_SOURCE_DIR}/../../src/qt/common/qrc/pc98ha.qrc)
 elseif(BUILD_PC98LT)
    add_definitions(-D_PC98LT)
    set(EXEC_TARGET emupc98lt)
    set(VMFILES ${VMFILES}
                   upd1990a.cpp
-                  i286.cpp
    )
+   set(FLAG_USE_I86 ON)
    set(RESOURCE ${CMAKE_SOURCE_DIR}/../../src/qt/common/qrc/pc98lt.qrc)
 endif()
 
index 24151ec..68a825a 100644 (file)
@@ -21,7 +21,7 @@ set(WITH_JOYSTICK OFF)
 set(WITH_MOUSE ON)
 
 set(VMFILES
-                  i286.cpp
+#                 i286.cpp
 #
                   i8253.cpp
                   i8255.cpp
@@ -43,6 +43,8 @@ set(VMFILES_LIB
                   i8251.cpp
                   not.cpp
 )
+
+set(FLAG_USE_I86 ON)
 set(BUILD_SHARED_LIBS OFF)
 set(USE_OPENMP ON CACHE BOOL "Build using OpenMP")
 set(USE_OPENGL ON CACHE BOOL "Build using OpenGL")
index bdd8933..f51c4d1 100644 (file)
@@ -39,7 +39,7 @@ set(VMFILES_LIB
                   pcm1bit.cpp
                   i8251.cpp
 )
-set(FLAG_USE_I286 ON)
+set(FLAG_USE_I86 ON)
 
 set(BUILD_SHARED_LIBS OFF)
 set(USE_OPENMP ON CACHE BOOL "Build using OpenMP")
index a15d8d8..bd4490c 100644 (file)
@@ -19,7 +19,7 @@ set(WITH_JOYSTICK OFF)
 set(WITH_MOUSE ON)
 
 set(VMFILES
-                  i286.cpp
+#                 i286.cpp
                   
                   i8255.cpp
                   i8259.cpp
@@ -38,6 +38,8 @@ set(VMFILES_LIB
                   beep.cpp
                   pcm1bit.cpp
 )
+set(FLAG_USE_I86 ON)
+
 set(BUILD_SHARED_LIBS OFF)
 set(USE_OPENMP ON CACHE BOOL "Build using OpenMP")
 set(USE_OPENGL ON CACHE BOOL "Build using OpenGL")
index 16289ce..2e0cd5c 100644 (file)
@@ -16,7 +16,7 @@
 #include "../i8253.h"
 #include "../i8255.h"
 #include "../i8259.h"
-#include "../i286.h"
+#include "../i86.h"
 #include "../io.h"
 #include "../mb8877.h"
 #include "../memory.h"
@@ -45,7 +45,7 @@ VM::VM(EMU* parent_emu) : emu(parent_emu)
        pit = new I8253(this, emu);
        pio = new I8255(this, emu);     // for system port
        pic = new I8259(this, emu);
-       cpu = new I286(this, emu);
+       cpu = new I86(this, emu);
        io = new IO(this, emu);
        fdc = new MB8877(this, emu);
        memory = new MEMORY(this, emu);
@@ -58,7 +58,7 @@ VM::VM(EMU* parent_emu) : emu(parent_emu)
 #if defined(_USE_QT)
        dummy->set_device_name(_T("1st Dummy"));
        event->set_device_name(_T("EVENT"));
-       cpu->set_device_name(_T("CPU(i286)"));
+       cpu->set_device_name(_T("CPU(MBL8086L)"));
 
        sio->set_device_name(_T("i8251(RS-232C)"));
        pio->set_device_name(_T("i8259(SYSTEM PORT)"));
index e90446c..e6d4236 100644 (file)
@@ -68,7 +68,7 @@ class I8251;
 class I8253;
 class I8255;
 class I8259;
-class I286;
+class I86;
 class IO;
 class MB8877;
 class MEMORY;
@@ -90,7 +90,7 @@ protected:
        I8253* pit;
        I8255* pio;
        I8259* pic;
-       I286* cpu;
+       I86* cpu;
        IO* io;
        MB8877* fdc;
        MEMORY* memory;
index f78231a..bcb9626 100644 (file)
@@ -16,7 +16,7 @@
 #include "../i8251.h"
 #include "../i8253.h"
 #include "../i8259.h"
-#include "../i286.h"
+#include "../i86.h"
 #include "../io.h"
 #include "../mb8877.h"
 #include "../scsi_hdd.h"
@@ -56,7 +56,7 @@ VM::VM(EMU* parent_emu) : emu(parent_emu)
        sio_ch2 = new I8251(this, emu); // RS-232C ch.2
        pit = new I8253(this, emu);
        pic = new I8259(this, emu);
-       cpu = new I286(this, emu);
+       cpu = new I86(this, emu);
        io = new IO(this, emu);
        fdc = new MB8877(this, emu);
 #if defined(_USE_QT)
@@ -70,7 +70,7 @@ VM::VM(EMU* parent_emu) : emu(parent_emu)
        sio_ch2->set_device_name(_T("i8251 SIO(RS-232C #2)"));
        pit->set_device_name(_T("i8253 PIT"));
        pic->set_device_name(_T("i8259 PIC"));
-       cpu->set_device_name(_T("CPU(i8086)"));
+       cpu->set_device_name(_T("CPU(80C86)"));
 #endif
        
        scsi_host = new SCSI_HOST(this, emu);
index 338310d..ee0909d 100644 (file)
@@ -72,7 +72,7 @@ class I8237;
 class I8251;
 class I8253;
 class I8259;
-class I286;
+class I86;
 class IO;
 class MB8877;
 class SCSI_HOST;
@@ -104,7 +104,7 @@ protected:
        I8251* sio_ch2;
        I8253* pit;
        I8259* pic;
-       I286* cpu;
+       I86* cpu;
        IO* io;
        MB8877* fdc;
        SCSI_HOST* scsi_host;
index fdbc7a8..cef27ff 100644 (file)
@@ -18,7 +18,7 @@
 #include "../i8251.h"
 #include "../i8255.h"
 #include "../i8259.h"
-#include "../i286.h"
+#include "../i86.h"
 #include "../io.h"
 #include "../memory.h"
 #include "../msm58321.h"
@@ -54,7 +54,7 @@ VM::VM(EMU* parent_emu) : emu(parent_emu)
        pio0 = new I8255(this, emu);
        pio1 = new I8255(this, emu);
        pic = new I8259(this, emu);
-       cpu = new I286(this, emu);
+       cpu = new I86(this, emu);
        io = new IO(this, emu);
        memory = new MEMORY(this, emu);
        rtc = new MSM58321(this, emu);
index dab38f8..aff454c 100644 (file)
@@ -75,7 +75,7 @@ class BEEP;
 class I8251;
 class I8255;
 class I8259;
-class I286;
+class I86;
 class IO;
 class MEMORY;
 class MSM58321;
@@ -100,7 +100,7 @@ protected:
        I8255* pio0;
        I8255* pio1;
        I8259* pic;     // includes 2chips
-       I286* cpu;
+       I86* cpu;
        IO* io;
        MEMORY* memory;
        MSM58321* rtc;
index 657c0c9..102a4e4 100644 (file)
@@ -40,13 +40,13 @@ void PC6031::event_callback(int event_id, int err)
                }
                add_sound(PC6031_SND_TYPE_SEEK);
        }
-//#endif
+#endif
 }
 
 int PC6031::Seek88(int drvno, int trackno, int sectno)
 {
        if(drvno < 2) {
-//#if defined(USE_SOUND_FILES)
+#if defined(USE_SOUND_FILES)
 
                if(cur_trk[drvno] != trackno) {
                        seek_track_num[drvno] = (cur_trk[drvno] & 0xfe);
@@ -55,7 +55,7 @@ int PC6031::Seek88(int drvno, int trackno, int sectno)
                        }
                        register_event(this, EVENT_SEEK_SOUND + drvno, 16000, false, &seek_event_id[drvno]);
                }
-//#endif
+#endif
                cur_trk[drvno] = trackno;
                cur_sct[drvno] = sectno;
                cur_pos[drvno] = 0;
index ab8172a..a7e8827 100644 (file)
 #include "../i8253.h"
 #include "../i8255.h"
 #include "../i8259.h"
-#include "../i286.h"
+#if defined(HAS_V30) || defined(HAS_I86)
+# include "../i86.h"
+#else
+# include "../i286.h"
+#endif
 #include "../io.h"
 #include "../not.h"
 //#include "../pcpr201.h"
@@ -64,7 +68,11 @@ VM::VM(EMU* parent_emu) : emu(parent_emu)
        pio_sys = new I8255(this, emu); // for system port
        pio_prn = new I8255(this, emu); // for printer
        pic = new I8259(this, emu);     // V50 internal
+#if defined(HAS_V30) || defined(HAS_I86)
+       cpu = new I86(this, emu);       // V50
+#else
        cpu = new I286(this, emu);      // V50
+#endif
        io = new IO(this, emu);
        not_busy = new NOT(this, emu);
 #ifdef _PC98HA
index 20db894..0a5d248 100644 (file)
@@ -81,7 +81,11 @@ class I8251;
 class I8253;
 class I8255;
 class I8259;
+#if defined(HAS_V30) || defined(HAS_I86)
+class I86;
+#else
 class I286;
+#endif
 class IO;
 class NOT;
 #ifdef _PC98HA
@@ -115,7 +119,11 @@ protected:
        I8255* pio_sys;
        I8255* pio_prn;
        I8259* pic;
+#if defined(HAS_V30) || defined(HAS_I86)
+       I86* cpu;
+#else
        I286* cpu;
+#endif
        IO* io;
        NOT* not_busy;
 #ifdef _PC98HA