1 ** Qt porting for Common Source Code Project **
3 K.Ohta <whatisthis.sowhat _at_ gmail.com>
5 * If you can't read Japanese, read readme.qt.txt .
8 このパッケージは、Common Source Code Project (以下、CSP)
10 バイナリはGNU/Linux(64bit)用とMinGW (32bit Windows)用を
15 https://github.com/Artanejp/common_source_project-fm7/releases/tag/SNAPSHOT_20210801
19 各機種バイナリーは、osdn.net もしくはミラーサイトより入手可能です。
21 https://osdn.net/projects/csp-qt/
23 https://osdn.net/projects/csp-qt/releases/ をチェックしてください。
30 doc/以下の文書で日本語しかなかったものを英語に翻訳していますが、機械翻訳を使ってるのであやしいです。
32 英語の上手い方、校正などお願いします m(_ _)m
36 CSPは、非常に優れた構造のエミュレータです(しかし、些か重くてコンパイラ
38 しかし、このコードはM$ Visual C++依存の部分が非常に多いです。
39 そこで、GNU/Linuxでこれを動かすためにQtに色々と移植していきましょう。
44 a. Qt5 ツールキット。Qt 5.5以降を推奨します。
46 b. OpenGL, 多分、最低OpenGL 2.1は必要です。(注:ひょっとしたら、OpenGLES2以降ならば動くように変えるかも知れない)
48 c. gcc / g++ (5.0以降?)もしくは llvm clang / clang++ (3.5以降?)
51 d. SDL2 (SDL 1.xではないので注意)
55 f. ffmpegから、libavとlibswが必要です。 http://ffmpeg.org/ より。
57 g. ffmpegは、Windowsに関してはバンドルしてありますので、動かない時はインストールしてみてください。
59 h. Qt5.5(Ubuntu 16.04LTS向け)もしくはQt5.10(Win32とDebian GNU/Linux sid向け)でビルドしてあります。
61 i. 表示基盤のデフォルトが、OpenGL ES2.0になりました。コマンドラインオプション --opengl で変更が可能です(--helpで参照)
63 j. Windows のビルドを、Docker環境上のLLVM CLANG (9) にしました。例外処理に関して、MinGW-w64のgccは非常に遅い方法を取ってるためです(Borlandが悪いのですが)。
64 詳細は、 https://github.com/Artanejp/llvm-mingw と https://hub.docker.com/r/artanejp/llvm-mingw64-ubuntu-cosmic を参照して下さい。
66 * Windows もしくは GNU/Linux のcross tool chain (要Wine)で、MinGW (gcc6) と Qt 5.10 でのビルドができることを確認しました。
70 * Windows等で動かした時に、画面の書き替えが表示されない場合は、環境変数 QT_OPENGL を software にしてみてください。(例えば、
71 WindowsをVirtualBoxのゲストで使ってる場合など)
73 * Windows版バイナリには、ソフトウェアレンダリングのopengl32.dllが添付されてますが、最近のパソコンの専用GPUドライバなら、
74 もっと程度のいいOpenGLが入ってるはずです。
75 添付版opengl32.dllを適当な名前に変更して動くかどうか試してみて下さい。
79 ソースコードを解凍するか、git clone / pull した後で:
81 $ cd {srctop}/source/build-cmake/{Machine name}/
103 * 設定ファイル(scancode.cfg と foo.ini)は、"~/.config/CommonSourceCodeProject/emufoo/" (Windowsの場合は".\CommonSourceCodeProject\emudfoo\" ) におかれます(移動しました)。
105 * BIOSや効果音WAVやセーブステートは、、"~/CommonSourceCodeProject/emufoo/" (Windowsの場合は".\CommonSourceCodeProject\emudfoo\" ) におかれます(移動しました)。
107 * 全ての記録物(スクリーンショットや動画や録音WAV)は、*当面の間* "~/CommonSourceCodeProject/emufoo/" (Windowsの場合は".\CommonSourceCodeProject\emudfoo\" ) におかれます。
109 * ToolTipsを付けました。(2017-01-24)
111 * 日本語に翻訳しました。(2017-01-24)
114 * キーコード変換テーブルファイルが、$HOME/.config/CommonSourceCodeProject/emu{Machine Name}/scancode.cfg に書き込まれます。
116 書式は、カンマで区切られた16進データです(10進ではないので注意) .
118 1カラム目はM$ ヴァーチャルキーコード。
120 2カラム目はQtネィティブのスキャンキーコードです。
122 * UI部分の共通コンポーネント (src/qt/gui) を共有ライブラリlibCSPgui.soにまとめました。
124 * インストール用のBASHスクリプトを用意しました。src/tool/installer_unix.shです。
126 * ROMと同じところに、特定のWAVファイル(VMによって異なる)を入れると、FDDのシーク音やテープのボタン音・リレー音を鳴らすことが出来ます。
128 * ローマ字カタカナ変換支援機構が一部の機種に実装されてます。romaji_kana.ja.txt をお読みください。
132 a.現在、Debian GNU/Linux "sid"と、Ubuntu Linux 16.04LTS "Xenial"
133 の AMD64版でしかテストしていません。
134 が、多分他のGNU/Linux OSやBSD系のOS (Mac含む) でもビルドすれば
136 Windows もしくは GNU/Linux(要Wineとbinfmt-support)上でのMinGWと
137 Qt community edition でのビルドが通るようになりました。
139 b. 今は、Qtの開発側が「Qt4おわりね」とアナウンスしたので、Qt4ではなく
141 添付してあるバイナリは、Qt 5.5でビルドしました(が、Qt 5.1以降なら動くはずです)。
143 c. Linux用ビルドでは、GCCをリンク時最適化(LTO)モードで使っています。
144 d. MZ-2500のソケット機能を実装してみていますが、マトモにテストできてません(;´Д`)
146 6. Upstream repositry:
147 https://github.com/Artanejp/common_source_project-fm7
149 https://osdn.net/projects/csp-qt/scm/git/common_source_project-fm7
152 https://osdn.jp/projects/csp-qt/
154 8. Upstream (Takeda Toshiyaさんのオリジナル)
155 http://takeda-toshiya.my.coocan.jp/
159 Ryu Takegamiさん : eFM-8/7/77/AV/40/EX のデバッグに協力していただいています。
160 はせりんさん : eFM-8/7/77/AV/40/EX のデバッグに協力していただいています。
161 Ootake 開発者の皆さん: ePCENGINEの改善のヒントをソースコードから勉強させていただいてます。
162 Soji Yamakawaさん : eFM-Townsの開発で「津軽」を参考にさせていただいたり、
166 * 前の変更点をお読みになる場合には、ChangeLogと000_gitlog.txtをお読み下さい。
168 * SNAPSHOT August 01, 2021
169 * Upstream 2021-05-02.
170 * [BUILD/CMAKE] Add *Very Experimental* C++20 build settings.
171 * [OSD/EMU][MOUSE/JOYSTICK] Should LOCK/UNLOCK per referring buffers of joystick/mouse.
172 Note: This is MAJOR API CHANGE around mouse and joystick.
173 * [CONFIG/FMTOWNS] Add config.machine_features[32] to use machine configuration (w/o DIP SWITCH).Still not be bulidable.
174 Note: See vm/fmtowns/joystick.cpp, FMTOWNS::JOYSTICK::update_config().
175 * [FMTOWNS/KEYBOARD] SPECIAL_RESET: Available to boot with special key code (i.e. "CD" "DEBUG").
176 * [FMTOWNS/CDROM] Re-implement parsing CCD image file.Still ugly.
177 * [FMTOWNS/VRAM] Add __LIKELY_IF() and __UNLIKELY_IF() to assist compiler's optimization.
178 See [read|write]_memory_mapped_io32() and read_memory_mapped_io16() at FMTOWNS::TOWNS_VRAM class.
179 * [VM/I386_NP21] Add hints of branch-prediction whether accessing memory (and some of interrupts) is legal.
180 This reduces HOST CPU USAGE especially high-VM-clocks.
181 * [FMTOWNS/VRAM] More faster vram accessing.
182 * [FMTOWNS/MEMORY/VRAM] Add features around CACHE for after i486.Still be dummy.
183 * [FMTOWNS/CRTC] Use more SIMDs to be faster rendering.
184 * [FMTOWNS/KEYBOARD] Implement AUTO REPEAT.
185 * [FMTOWNS/TIMER] Clear OV and INTR when enabling interval timer.
186 * [FMTOWNS/VRAM] More faster VRAM access for packed pixel mode.
187 * [FMTOWNS/CDROM] Even reply without REQ_STATUS bit (0x20) with PAUSE/RESUME CDDA (85h/87h).
188 * [FMTOWNS/CDROM] Falldown intr even stat_reply_intr (04C2:bit6) == 0 on MCU interrupt.
189 * [FMTOWNS/CDROM] Reply error when reading beyond track on READ_SECTOR.
190 * [FMTOWNS/CDROM] Fix around booting from some version(s?) of TOWNS OS.
192 * [FMTOWNS/CRTC/TIMER/MEMORY] Improve around I/O.
193 * [FMTOWNS/DMAC] Remove some variables.Update state save version.
194 * [FMTOWNS/SCSI] Add a PORT: 0C34h.
195 * [FMTOWNS/MEMORY] Revert to use primitive_[read|write]. Fix CDROM's some issues (i.e. Crashing Ayayo4).
196 * [FMTOWNS/MEMORY] Add dma read/write functions with wait.
197 * [FMTOWNS/ICCARD] Improve logic around open/close.
198 * [FMTOWNS/JOYSTICK] Fix confused mouse mask.
199 * [FMTOWNS] Split MOUSE and JOYPADs to separate class.
200 * [FMTOWNS/FLOPPY] Add support for 1.44MB 2HD (2HC).
201 * [I286/I86/V30] Separate namespace CPUTYPE ENUMS.
202 * [I286/I86] Fix weird bitmask default value.
203 * [VM/UPD71071] Add read_io16(), write_io16() and ACK feature.
204 * [PC9801/EGC] Fix FTBFS with C++20 ; "error: ISO C++17 does not allow 'register' storage class specifier".
205 * [BUILD/CMake] Add samplescripts supports GCC-11 initially.
206 * [BUILD/CMake] Prepare to support LLVM12, but now unable to build Win32 version with llvm12 due to _aligned_alloc() and _aligned_free().
207 * [Build/Win32] LLVM12/MinGW-w64/Cross : Add libc++abi and others to toolchain.
208 * [Build/Win32] Update revision of ffmpeg to 4.4.
209 * [JOY_THREAD/SDL2/GAMECONTROLLER] Fix sample initial value.
210 * Built with ab2601af3b0de22bd806ce5312ebf06823a16405 (or later).
212 -- August 01, 2021 22:34:13 +0900 K.Ohta <whatisthis.sowhat@gmail.com>
215 * 前の変更点をお読みになる場合には、history.txtをお読み下さい。
219 [VM/DATAREC] fix mixing sound track
220 [VM/HD46505] support smooth vertical scroll
221 [VM/MC6843] fix seek command
222 [VM/MC6844] fix data chain register to consider 2/4 channel select bit
223 [VM/MC6844] fix to transfer 64K when byte count register is zero
224 [VM/Z80CTC] fix to apply written time constant just after reset bit is cleared
226 [BX1] fix memory map around ram
227 [BX1] support cartridge rom images
228 [BX1/DISPLAY] add missing font patterns
229 [BX1/FLOPPY] support i/o ports around fdc
230 [BX1/KEYBOARD] support PROG.SELECT switch
231 [BX1/PRINTER] support AUTO PRINT switch
232 [MZ1500/JOTSTICK] support joystick (thanks Mr.Koucha-Youkan)
233 [PC6001] remove some codes from iP6 Plus
234 [X1TURBO/DISPLAY] support smooth vertical scroll
239 [WINMAIN] improve WM_KEYDOW/WM_KEYUP events for VK_PROCESSKEY case
240 [WIN32/CONSLE] improve routine to change console size
242 [VM/DISK] fix density flag when loading solid image with fm sectors
243 [VM/MC6843] fix track zero flag in STRA
244 [VM/MC6843] fix seek error flag in STRB
245 [VM/MC6843] fix seek command
247 [BX1/DISPLAY] improve for drawing digitron display
248 [BX1/KEYBOARD] improve I/O ports for detecting key pressed/released
249 [BX1/PRINTER] add ugly patch for printer process
253 [VM/I8279] support 8279 (based on MAME)
255 [MP85] support MITEC MP-85
260 [VM/UPD765A] improve for the case tc is asserted while reading/writing sector
262 [PC8801/PC88] improve to render screen with port params at end of disp timing
263 [X1TURBO/FLOPPY] fix to change type of all drives (thanks Mr.Sato)
268 [WINMAIN] improve for pressing shift key and numpad key
270 [MZ80K] fix roman/kana conversion
271 [MZ80K/KEYBOARD] improve for pressing right shift key and numpad key
276 [PC8801/PC88] improve crtc to refer reverse setting in start display command
281 [VM/SCSI_CDROM] fix start frame of CD-DA playing when track number is specified
283 [PCENGINE/PCE] fix issue that ADPCM is mistakenly looped
288 [VM/SCSI_CDROM] fix pre-gap of first track when it is audio track
293 [VM/SCSI_CDROM] improve routine to get start/end frame of CD-DA playing
295 [PC8801/PC88] support 8inch DMA-type floppy drives for PC-8001mkII/SR
296 [PC9801/DISPLAY] improve EGC (thanks Mr.Ryuji Okamoto)
301 [PC8801/DISKIO] improve to read/write files in initial current directory
302 [PC8801/PC88] support force ready/drq mask register for DMA-type FDD
303 [PC8801/PC88] fix PC-8001mkIISR hiragana font when PCG-8100 is enabled
308 [PC8801/DISKIO] support M88 DiskDrv (thanks Mr.CISC and Mr.apaslothy)
309 [PC8801/PC88] support PC-8001mkIISR hiragana font
310 [PC8801/PC88] support to disable 5inch/8inch-FDD interfaces
311 [PC8801/PC88] support to disable updating scan line setting automatically
312 [PC8801/PC88] fix mouse data when position is not latched
317 [PC8801/PC88] support 8inch DMA-type floppy drives
322 [VM/MC6843] support MC6843 (based on MAME)
323 [[VM/SCSI_CDROM] fix to reset logical block size in Test Unit Ready command
325 [BX1] support CANON BX-1 (not work)
326 [MZ1500/QUICKDISK] improve for BSD record (thanks Mr.Motochan1500)
327 [PC8801/PC88] fix hireso graphic screen when scan line is disabled
332 [PC8801/PC88] fix to clear attibutes at starting new frame
333 [PC8801/PC88] fix to read status of 2nd OPNA
338 [PC8801/PC88] fix to run dma from memory to crtc when (rd,wr)=(0,0)
339 [PC8801/PC88] fix to run dma from scsi to memory only when count > 0
344 [COMMON] fix build error on VC++2019 (thanks Mr.Sato)
346 [VM/Z80CTC] fix not to clear in-service at software reset (thanks Mr.Sato)
347 [VM/Z80DMA] fix stall cycles at BUSACK in byte mode (thanks Mr.Sato)
349 [X1TURBOZ/DISPLAY] fix zpalette in 64 colors, 2 screens mode (thanks Mr.Sato)
354 [MZ1500] fix inp(0xe8) to detect voice board is missing (thanks Mr.kitahei88)
355 [X1TURBOZ/DISPLAY] fix to update zpalette at vline=0 (thanks Mr.Sato)
360 [OSD/WIN32] import Unity plug-in code (thanks Mr.Marukun)
362 [VM/I386_NP21] update to Neko Project 21/W ver0.86 rev79 beta4
363 [VM/UPD765A] fix transfer size to 128 << min(N, 7) (thanks Mr.Kugimoto)
365 [MZ1500/QUICKDISK] improve for QDF format (thanks Mr.kitahei88)
366 [MZ1500/QUICKDISK] improve for BSD record (thanks Mr.Yuushi)
367 [PC9801/MEMORY] fix switching BIOS ROM/RAM
368 [X1/CZ8RB] support CZ-8RB (thanks Mr.Meister)