bugfixes, new scaling, double ym upd at 940
[picodrive.git] / platform / readme.txt
CommitLineData
01bc6b19 1For help / comments / questions visit GP32X boards at:\r
2http://www.gp32x.com/board/\r
3\r
cc68a136 4\r
5About\r
6-----\r
7\r
01bc6b19 8This is yet another Megadrive / Genesis / Sega CD / Mega CD emulator, which\r
9was written having ARM-based handheld devices in mind (such as PDAs,\r
10smartphones and handheld consoles like GP2X of course). The critical parts\r
11(renderer, 68K and Z80 cpu interpreters) and some other random code is\r
12written in ARM asm, other code is C. The base code originates from Dave's\r
13(fdave, finalburn) PicoDrive 0.30 for Pocket PC. The Sega/Mega CD code is\r
14roughly based on Stephane Dallongeville's Gens.\r
cc68a136 15\r
16\r
17How to make it run\r
18------------------\r
19\r
cc68a136 20Copy PicoDrive.gpe, code940.bin and mmuhack.o to any place in your filesystem\r
21(all 3 files must be in the same directory) and run PicoDrive.gpe.\r
0a051f55 22Then load a ROM and enjoy! ROMs can be in .smd or .bin format and can be zipped.\r
cc68a136 23\r
cc68a136 24If you have any problems (game does not boot, sound is glitchy, broken graphics),\r
25make sure you enable "Accurate timing", "Emulate Z80" and then disable\r
26"Fast renderer". This way you will get the best compatibility this emulator can\r
27provide.\r
28\r
29\r
0a051f55 30How to run Sega/Mega CD games\r
31-----------------------------\r
32\r
33To play any game, you need BIOS files. These files must be copied to the same\r
34directory as PicoDrive.gpe. Files can be named as follows:\r
35US: us_scd1_9210.bin us_scd2_9306.bin SegaCDBIOS9303.bin\r
36EU: eu_mcd1_9210.bin eu_mcd2_9303.bin eu_mcd2_9306.bin\r
37JP: jp_mcd1_9112.bin jp_mcd1_9111.bin\r
38these files can also be zipped.\r
39\r
40The game must be dumped to ISO format, but BIN can be used too. If you want\r
41CD music, you must use ISO+mp3 files. Audio from BIN files won't be read at\r
42all due to SD access issues. Also BIN files are usually larger, so it's better\r
43to use ISO. ISO+mp3 files can be named similarly as for other emus.\r
44Here are some examples:\r
45\r
46SonicCD.iso data track\r
47SonicCD_02.mp3 audio track 1 (CD track 2)\r
48SonicCD_03.mp3\r
49...\r
50\r
51Sonic the Hedgehog CD (US) - Track 01.iso\r
52Sonic the Hedgehog CD (US) - Track 02.mp3\r
53Sonic the Hedgehog CD (US) - Track 03.mp3\r
54...\r
55\r
56ISO files can also be zipped (but not mp3 files, as they are already\r
57compressed). Note that this can cause very long loading times, which may\r
58take up to several minutes. File naming is similar as with uncompressed ISOs.\r
59Example:\r
60\r
61SonicCD.zip data track\r
62SonicCD_02.mp3 audio track 1 (CD track 2)\r
63SonicCD_03.mp3\r
64...\r
65\r
66\r
cc68a136 67Configuration\r
68-------------\r
69\r
70See config.txt file.\r
71\r
72\r
0a051f55 73Other important stuff\r
74---------------------\r
75\r
76* When you use both GP2X CPUs, keep in mind that you can't overclock as high as\r
77 when using ARM920 only. For example my GP2X when run singlecore can reach\r
78 280MHz, but with both cores it's about 250MHz. When overclocked too much,\r
79 it may start hanging and producing random noise.\r
80* PicoDrive is not a mp3 player, so all mp3s MUST be encoded at 44.1kHz stereo.\r
81 Otherwise mp3s will play too fast or too slow.\r
82* Due to internal implementation mp3s must not be larger that ~15MB\r
83 (15548416 bytes). Larger mp3s will not be fully loaded.\r
84* Use lower bitrate for better performance (96 or 128kbps CBRs recommended).\r
85* RAM timings option is good for dualcore operation (it is disabled by\r
86 default because it doesn't work on every GP2X, so enable it in advanced\r
87 options).\r
88\r
89\r
90Cheat support\r
91-------------\r
92\r
93To use GG/patch codes, you must type them into your favorite text editor, one\r
94per line. Comments may follow code after a whitespace. Only GameGenie and\r
95Genecyst patch formats are supported.\r
96Examples:\r
97\r
98Genecyst patch (this example is for Sonic):\r
99\r
10000334A:0005 Start with five lives\r
101012D24:0001 Keep invincibility until end of stage\r
102009C76:5478 each ring worth 2\r
103009C76:5678 each ring worth 3\r
104...\r
105\r
106Game Genie patch (for Sonic 2):\r
107\r
108ACLA-ATD4 Hidden palace instead of death egg in level select\r
109...\r
110\r
111Both GG and patch codes can be mixed in one file.\r
112\r
113When the file is ready, name it just like your ROM file, but with additional\r
114.pat extension, making sure that case matches.\r
115\r
116Examples:\r
117\r
118ROM: Sonic.zip\r
119PATCH FILE: Sonic.zip.pat\r
120\r
121ROM: Sonic 2.bin\r
122PATCH FILE: Sonic 2.bin.pat\r
123\r
124Put the file into your ROMs directory. Then load the .pat file as you would\r
125a ROM. Then Cheat Menu Option should appear in main menu.\r
126\r
127\r
128What is emulated?\r
129-----------------\r
130\r
131Genesis/MegaDrive:\r
132main 68k @ 7.6MHz: yes, Cyclone core\r
133z80 @ 3.6MHz: yes, DrZ80 core\r
134VDP: yes, except some quirks not used by games\r
135YM2612 FM: yes, optimized MAME core\r
136SN76489 PSG: yes, MAME core\r
137\r
138Sega/Mega CD:\r
139another 68k @ 12.5MHz: yes, Cyclone too\r
140gfx scaling/rotation chip (custom ASIC): not yet (faked only)\r
141PCM sound source: yes\r
142CD-ROM controller: yes (mostly)\r
143bram (internal backup RAM): yes\r
144\r
145\r
cc68a136 146Problems / limitations\r
147----------------------\r
148\r
0a051f55 149* 32x and SVP are not emulated.\r
cc68a136 150* Various VDP quirks (window bug, scroll size 2, etc.) are not emulated,\r
0a051f55 151 as very few games use this (if any at all).\r
cc68a136 152* Some games don't work or have glitches because of inaccurate timing and sync\r
153 between the emulated chips.\r
154\r
155\r
156Credits\r
157-------\r
158\r
159This emulator uses code from these people/projects:\r
160\r
161Dave\r
162Cyclone 68000 core, Pico emulation library\r
163Homepage: http://www.finalburn.com/\r
164\r
165notaz\r
166GP2X port, Cyclone 68000 hacks, lots of additional coding (see changelog).\r
167\r
168Reesy & FluBBa\r
169DrZ80, the Z80 emulator written in ARM assembly.\r
170Homepage: http://reesy.gp32x.de/\r
171\r
172Tatsuyuki Satoh, Jarek Burczynski, MultiArcadeMachineEmulator development\r
173software implementation of Yamaha FM sound generator\r
174\r
175MultiArcadeMachineEmulator (MAME) development\r
176Texas Instruments SN76489 / SN76496 programmable tone /noise generator\r
177Homepage: http://www.mame.net/\r
178\r
0a051f55 179Stephane Dallongeville\r
180Gens, MD/Mega CD/32X emulator. Most Sega CD code is based on this emu.\r
181\r
182Helix community\r
183Helix mp3 decoder\r
184\r
cc68a136 185\r
186Additional thanks\r
187-----------------\r
188\r
189* Charles MacDonald (http://cgfm2.emuviews.com/) for old but still very useful\r
190 info about genesis hardware.\r
cc68a136 191* Steve Snake for all that he has done for Genesis emulation scene.\r
192* Bart Trzynadlowski for his SSFII and 68000 docs.\r
193* Haze for his research (http://haze.mameworld.info).\r
194* Mark and Jean-loup for zlib library.\r
195* Anyone else I forgot. You know who you are.\r
196\r
197GP2X:\r
198* rlyeh and all the other people behind the minimal library.\r
199* Squidge for his famous squidgehack(tm).\r
200* Dzz for his ARM940 sample code.\r
201* GnoStiC & Puck2099 for USB joystick support.\r
202* Hermes PS2R, god_at_hell for the CpuCtrl library.\r
203* craigix for supplying the GP2X hardware and making this port possible.\r
204\r
205Symbian:\r
206* Peter van Sebille for his various open-source Symbian projects to learn from.\r
207* Steve Fischer for his open-source Motorola projects.\r
208* The development team behind "Symbian GCC Improvement Project"\r
209 (http://www.inf.u-szeged.hu/symbian-gcc/) for their updated pre-SymbianOS9\r
210 compile tools.\r
211* AnotherGuest for all his Symbian stuff and support.\r
212* Inder for the icons.\r
213\r
214\r
215Changelog\r
216---------\r
2433f409 2171.32\r
218 + Added some new scaling options.\r
219 * Fixed DMA timing emulation (caused lock-ups for some genesis games).\r
220 * Idle loop detection was picking up wrong code and causing glitches, fixed.\r
221 * The ym2612 code on 940 now can handle multiple updates per frame\r
222 (fixes Thunger Force III "seiren" level drums for example).\r
223 * Memory handlers were ignoring some writes to PSG chip, fixed (missing sounds in\r
224 Popful Mail, Silpheed).\r
225\r
c008977e 2261.31\r
227 * Changed the way memory mode register is read (fixes Lunar 2, broken in 1.30).\r
228 * Fixed TAS opcode on sub-68k side (fixes Batman games).\r
229 * File browser now filters out mp3s, saves and some other files, which are not ROMS.\r
230\r
782f8f22 2311.30\r
0a051f55 232 + ISO files now can be zipped. Note that this causes VERY long loading times.\r
233 + Added data pre-buffering support, this allows to reduce frequency of short pauses\r
4ff2d527 234 in FMV games (caused by SD access), but makes those pauses longer.\r
0a051f55 235 * Fixed PCM DMA transfers (intro FMV in Popful Mail).\r
7336a99a 236 + Properly implemented "decode" data transformation (Jaguar XJ220).\r
237 * Integrated "better sync" code into cyclone code, what made this mode much faster.\r
238 * Fixed a bug related to game specific config saving.\r
4ff2d527 239 * Frameskipper was skipping sound processing, what caused some audio desyncs. Fixed.\r
48e8482f 240 * Fixed reset not working for some games.\r
a4030801 241 + New assembly optimized memory handlers for CD (gives at least a few fps).\r
782f8f22 242 Also re-enabled all optimizations from 0.964 release.\r
243 + New idle-loop detection code for sub-68k. Speeds up at least a few games.\r
0a051f55 244\r
2451.201\r
246 + Added basic cheat support (GameGenie and Genecyst patches).\r
247\r
2481.20\r
249 * Fixed a long-standing problem in audio mixing code which caused slight distortions\r
250 at lower sample rates.\r
251 * Changed the way 920 and 940 communicates (again), should be more reliable and give\r
252 slight performance increase.\r
253 * Some optimizations in audio mixing code.\r
254 * Some menu changes (background added, smaller font in ROM browser, savestate loader\r
255 now can select slots).\r
256 + 1M mode DMA transfers implemented (used by FMV games like Night Trap and Sewer Shark).\r
257 + Games now can run code from WORD RAM in 1M mode (fixes Adventures of Willy Beamish).\r
258 + "Cell arrange" address mapping is now emulated (Heart of the alien).\r
259 + "Color numeric operation" is now emulated (text in Lunar 2, Silpheed intro graphics).\r
260 + "Better sync" option added (prevents some games from hanging).\r
261\r
2621.14\r
263 + Region autodetection now can be customized.\r
264 * When CDDA music tracks changed, old buffer contents were incorrectly played. Fixed.\r
265 * BRAM is now automatically formatted (no need to enter BIOS menu and format any more).\r
266 * Games now can be reset, CDDA music no longer breaks after loading another ISO.\r
267 * Fixed a race condition between 920 and 940 which sometimes caused CDDA music not to play.\r
268 + Savestates implemented for Sega/Mega CD.\r
269 + PCM sound added.\r
270 * Some mixer code rewritten in asm. 22kHz and 11kHz sound rates are now supported in\r
271 Mega CD mode (but mp3s must still be 44kHz stereo).\r
272 + Timer emulation added.\r
273 * CDC DMA tansfers fixed. Snatcher and probably some more games now boot.\r
274 * 2M word RAM -> VDP transfers fixed, no more corruption in Ecco and some other games.\r
275\r
2761.10\r
277 + GP2X: Added experimental Sega CD support.\r
278 + GP2X: Added partial gmv movie playback support.\r
279\r
cc68a136 2800.964\r
281 * GP2X: Fixed a sound buffer underflow issue on lower sample rate modes, which was\r
282 happening for NTSC games and causing sound clicks.\r
283 * GP2X: Redone key config to better support USB joysticks (now multiple joysticks\r
284 should be useable and configurable).\r
285 + GP2X: Added save confirmation option.\r
286 + GP2X: Added 940 CPU crash detection.\r
287 + ALL: UIQ3 port added.\r
288\r
2890.963\r
290 * GP2X: Gamma-reset-on-entering-menu bug fixed.\r
291 * GP2X: Recompiled PicoDrive with gcc profiling option set as described here:\r
292 http://www.gp32x.com/board/index.php?showtopic=28490\r
293\r
2940.962\r
295 * GP2X: Fixed an issue with incorrect sounds in some games when dualcore operation\r
296 was enabled (for example punch sound in SOR).\r
297 * GP2X: Limited max volume to 90, because higher values often cause distortions.\r
298 * GP2X: Fixed a bug with lower res scaling.\r
299 * GP2X: Gamma is now reset on exit.\r
300\r
3010.96\r
302 * ALL: Severely optimized MAME's YM2612 core, part of it is now rewritten in asm.\r
303 + GP2X: The YM2612's code now can be run in GP2X's ARM940T CPU, what causes large\r
304 performance increase.\r
305 * ALL: Accurate renderers are slightly faster now.\r
306 + GP2X: Using quadruple buffering instead of doublebuffer now, also updated\r
307 framelimitter, this should eliminate some scrolling and tearing problems.\r
308 * GP2X: Fixed some flickering issues of 8bit accurate renderer.\r
309 + GP2X: craigix's RAM timings now can be enabled in the menu (see advanced options).\r
310 + GP2X: Added ability to save config for specific games only.\r
311 + GP2X: Gamma control added (using GP2X's hardware capabilities for this).\r
312 * GP2X: Volume keys are now configurable.\r
313 + GP2X: GnoStiC added USB joystick support, I made it possible to use it for\r
314 player 2 control (currently untested).\r
315 * GP2X: squidgehack is now applied through kernel module (cleaner way).\r
316\r
3170.95\r
318 * ALL: Fixed a bug in sprite renderer which was causing slowdowns for some games.\r
319 + GP2X: Added command line support\r
320 + GP2X: Added optional hardware scaling for lower-res games like Shining Force.\r
321 * ALL: Sound chips are now sampled 2 times per frame. This fixed some games which\r
322 had missing sounds (Vectorman 2 1st level, Thunder Force 3 water level,\r
323 etc.).\r
324 + ALL: Added another accurate 8-bit renderer which is slightly faster and made it\r
325 default.\r
326\r
3270.945\r
328 + GP2X: Added frame limiter for frameskipped modes.\r
329 * GP2X: Increased brightness a bit (unused pixel bits now also contain data).\r
330 * GP2X: Suidgehack was not applied correctly (was applied before allocating some\r
331 high memory and had no effect).\r
332\r
3330.94\r
334 + Added GP2X port.\r
335 * Improved interrupt timing, Mazin Saga and Burning Force now works.\r
336 * Rewritten renderer code to better suit GP2X, should be faster on other\r
337 ports too.\r
338 + Added support for banking used by 12-in-1 and 4-in-1 ROMs (thanks Haze).\r
339 + Added some protection device faking, used by some unlicensed games like\r
340 Super Bubble Bobble, King of Fighters, Elf Wor, ... (thanks to Haze again)\r
341 + Added primitive Virtua Racing SVP faking, so menus can be seen now.\r
342\r
3430.93\r
344 * Fixed a problem with P900/P910 key configuration in FC mode.\r
345 * Improved shadow/hilight mode emulation. Still not perfect, but should be\r
346 enough for most games.\r
347 + Save state slots added.\r
348 + Region selector added.\r
349\r
3500.92\r
351 VDP changes:\r
352 * VDP emulation is now more accurate (fixes flickering in Chase HQ II,\r
353 Super Hang-On and some other problems in other games).\r
354 * HV counter emulation is now much more accurate. Fixes the Asterix games,\r
355 line in Road Rash 3, etc.\r
356 * Minor sprite and layer scroll masking bugs fixed.\r
357 + Added partial interlace mode renderer (Sonic 2 vs mode)\r
358 * Fixed a crash in both renderers when certain size window layers were used.\r
359 + Added emulation of shadow/hilight operator sprites. Other shadow/hilight\r
360 effects are still unemulated.\r
361 + Sprite emulation is more accurate, sprite limit is emulated.\r
362 + Added "accurate sprites" option, which always draws sprites in correct\r
363 order and emulates sprite collision bit, but is significantly slower.\r
364\r
365 Emulation changes:\r
366 * Improved interrupt handling, added deferred interrupt emulation\r
367 (Lemmings, etc).\r
368 + Added serial EEPROM SRAM support (Wonder Boy in Monster World,\r
369 Megaman - The Wily Wars and many EA sports games like NBA Jam).\r
370 + Implemented ROM banking for Super Street Fighter II - The New Challengers\r
371 * Updated to the latest version of DrZ80 core, integrated memory handlers\r
372 in it for better performance. A noticeable performance increase, but save\r
373 states may not work from the previous version (you can only use them with\r
374 sound disabled in that case).\r
375 + SRAM word read handler was using incorrect byte order, fixed.\r
376\r
377 Changes in Cyclone 0.0086:\r
378 + Added missing CHK opcode handler (used by SeaQuest DSV).\r
379 + Added missing TAS opcode handler (Gargoyles,Bubba N Stix,...). As in real genesis,\r
380 memory write-back phase is ignored (but can be enabled in config.h if needed).\r
381 + Added missing NBCD and TRAPV opcode handlers.\r
382 + Added missing addressing mode for CMP/EOR.\r
383 + Added some minor optimizations.\r
384 - Removed 216 handlers for 2927 opcodes which were generated for invalid addressing modes.\r
385 + Fixed flags for ASL, NEG, NEGX, DIVU, ADDX, SUBX, ROXR.\r
386 + Bugs fixed in MOVEP, LINK, ADDQ, DIVS handlers.\r
387 * Undocumented flags for CHK, ABCD, SBCD and NBCD are now emulated the same way as in Musashi.\r
388 + Added Uninitialized Interrupt emulation.\r
389 + Altered timing for about half of opcodes to match Musashi's.\r
390\r
3910.80\r
392 * Nearly all VDP code was rewritten in ARM asm. Gives ~10-25% performance\r
393 increase (depends on game).\r
394 * Optimized 32-column renderer not to render tiles offscreen, games which\r
395 use 32-column display (like Shining Force) run ~50% faster.\r
396 + Added new "Alternative renderer", which gives another ~30-45% performance\r
397 increase (in addition to mentioned above), but works only with some games,\r
398 because it is missing some features (it uses tile-based renderering\r
399 instead of default line-based and disables H-ints).\r
400 + Added "fit2" display mode for all FC gamers. It always uses 208x146 for\r
401 P800 and 208x208 for all other phones.\r
402 + Added volume control for Motorolas (experimental).\r
403\r
404 VDP changes:\r
405 + Added support for vertical window (used by Vapor Trail, Mercs, GRIND\r
406 Stormer and others).\r
407 + Added sprite masking (hiding), adds some speed.\r
408 + Added preliminary H counter emulation. Comix Zone and Sonic 3D Blast\r
409 special stage are now playable.\r
410 + Added column based vertical scrolling (Gunstar Heroes battleship level,\r
411 Sonic and Knuckles lava boss, etc).\r
412\r
413 Emulation changes:\r
414 + Re-added and improved Z80 faking when Z80 is disabled. Many games now can\r
415 be played without enabling Z80 (Lost Vikings, Syndicate, etc), but some\r
416 still need it (International Superstar Soccer Deluxe).\r
417 * Improved ym2612 timers, Outrun music plays at correct speed, voices in\r
418 Earthworm Jim play better, more games play sound.\r
419 * I/O registers now remember their values (needed for Pirates! Gold)\r
420 + Added support for 6 button pad.\r
421\r
422 Changes in Cyclone 0.0083wip:\r
423 + Added missing CHK opcode (used by SeaQuest DSV).\r
424 + Added missing TAS opcode (Gargoyles). As in real genesis, write-back phase\r
425 is ignored (but is enabled for other systems).\r
426\r
427 Backported stuff from Snes9x:\r
428 * Fixed Pxxx jog up/down which were not working in game.\r
429 + Added an option to gzip save states to save space.\r
430 + The emulator now pauses whenever it is loosing focus, so it will now pause\r
431 when alarm/ponecall/battery low/... windows come up.\r
432 - Removed 'pause on phonecall' feature, as it is no longer needed.\r
433 + Video fix for asian A1000s.\r
434\r
4350.70\r
436 * Started using tools from "Symbian GCC Improvement Project", which give\r
437 considerable speed increase (~4fps in "center 90" mode).\r
438 * Rewrote some drawing routines in ARM assembly (gives ~6 more fps in\r
439 "center 90" mode).\r
440 * Minor improvement to 0 and 180 "fit" modes. Now they look slightly better\r
441 and are faster.\r
442 * Minor stability improvements (emulator is less likely to crash).\r
443 + Added some background for OSD text for better readability.\r
444 + Added Pal/NTSC detection. This is needed for proper sound speed.\r
445 + Implemented Reesy's DrZ80 Z80 emu. Made some changes to it with hope to make\r
446 it faster.\r
447 + Implemented ym2612 emu from the MAME project. Runs well but sometimes sounds\r
448 a bit weird. Could be a little faster, so made some changes too.\r
449 + Implemented SN76489 emu from the MAME project.\r
450 + Added two separate sound output methods (mediaserver and cmaudiofb) with\r
451 autodetection (needs testing).\r
452 * Fixed VDP DMA fill emulation (as described in Charles MacDonald's docs),\r
453 fixes Contra and some other games.\r
454\r
4550.301\r
456 Launcher:\r
457 * Launcher now starts emulation process from current directory,\r
458 not from hardcoded paths.\r
459 * Improved 'pause on call' feature, should hopefully work with Motorola phones.\r
460\r
4610.30\r
462 Initial release.\r
463\r
464\r
465Disclaimer\r
466----------\r
467\r
468THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" \r
469AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE \r
470IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE \r
471ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE \r
472LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR \r
473CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF \r
474SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS \r
475INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN \r
476CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) \r
477ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE \r
478POSSIBILITY OF SUCH DAMAGE. \r
0a051f55 479\r
480SEGA/Genesis/MegaDrive/SEGA-CD/Mega-CD/32X are trademarks of\r
481Sega Enterprises Ltd.\r
482\r