Emulator: see below.
Windows: does not matter.
Here is the problem:
1: GENS's debugger wrong decodes ORI.W and some other opcodes.
2: I found a bug in emulation M68K in MOVE.L (A0)+,D1. First time it's work fine, after some calculations it's read garbage in D1, but A0 is still correct. MOVE.B (A0)+,D1 works perfectly. Here source, that not working:
Code: Select all
move.l #$FF0000,d2 *
move.l d2,a1 *
subq.l #1,d0 *
BuildLn: clr.l d1
move.l (a0)+,d1 * << Here is buggy command
move.w #39,d2 *
BuildLp: move.b (a0),d3 *
cmp.b #0,d3 *
beq BuildSkp *
move.b (a0),(a1)+ *
addq.l #1,a0 *
bra BuildFin *
BuildSkp: move.b #$20,(a1)+ *
BuildFin: dbra d2,BuildLp *
BuildZer: move.b (a0),d3 *
cmp.b #0,d3 *
beq BuildNxt *
addq.l #1,a0 *
bra BuildZer *
BuildNxt: addq #1,a0 *
move.l d1,(a1) *
add.l #24,a1 *
dbra d0,BuildLn *
If I replace that command this:
Code: Select all
move.b (a0)+,d1 *
rol.l #8,d1 *
move.b (a0)+,d1 *
rol.l #8,d1 *
move.b (a0)+,d1 *
rol.l #8,d1 *
move.b (a0)+,d1 *
All works perfectly. I'd made some tests and here is result:
Test passed emulators:
DGen v1.21
Fusion v3.51
Megasis v0.06a
Test not passed emulators:
Gens32 Surreal v1.7
Gens32 (Gens v2.10)
Gens32 V2.26
Gens v2.12a KMod 0.7b
Gens v2.11
Gens+ v0.0.3.38
GensD (Gens v2.10)
So, it seems this is "Gens" only problem in M68K emulation code.
Test ROM you can get
here.
PS. That command loads melody pointer. If it buggy, then melody can not be played correctly.
PPS. Can you do something with that terrible 16bit screen mode? That screen flashes is killing me... (Gens32 use 32bit screen mode)
![Sad :(](./images/smilies/icon_sad.gif)