> Hi!
>
> I wonder: would it possible to make a GameBoy emulator for MSX? I know
> it also has a Z80... Maybe it will only work on 7MHz or Turbo R, but
> would it be possible?

Yes. It would be possible.
However, the GameBoy processor is NOT a Z80.
The GameBoy emulator is alike the Z80, but 'uitgekleed': All alternative
registers are gone, as well as IX and IY and all the instructions related to
it. This makes emulation easier & faster, because the MSX can switch from
its own registers to the GameBoy-registers with a simple EXX and EX AF,AF'.
Further, the GameBoy has some instructions added to it, for example SWAP r,
which swaps the high and the low nibble. Very useful, the Z80 should also
have had it. No more 4xRLCA-sequences.
Also, it has some opcodes which are mapped to different instructions.

To cut things short: The processor has to be emulated, which is quite slow.
But using a lot of JP (HL)s (only 4 T-states) and other optimizations it
should be fast enough to play at least Tetris. And maybe, it will run on a
reasonable speed on a turboR.

Now the video: Screen 2 would fit nice, because it is also
pattern-orientated, etc. But unfortunately, screen 2 can only handle 2
colors per line of the pattern, and the GameBoy needs 4 colors. So screen 5
is the only solution. Still fast enough for Tetris I think but not for other
games. However, there might be a good solution, and it's called Gfx9000.

I even have already made a start with an emulator, it can view the header of
ROMs (whow!)... Next time I have nothing to do I'll add CPU and
Video-emulation... I'll let you know.

But at the moment I'm busy with Illusion City, which is by the way poorly
programmed. A lot of speed could be gained by optimizing the code... But
first I'll make it run on an MSX2. Optimizations (and maybe translation?)
will be done later (or not at all, if not nessacary).


~Grauw


--
>>>>>>>>>>>>>>>>>>>>>>>>><<<<<<<<<<<<<<<<<<<<<<<<<
          email me: [EMAIL PROTECTED] or ICQ: 10196372
             visit the Datax homepage at http://datax.cjb.net/
MSX fair Bussum / MSX Marathon homepage: http://msxfair.cjb.net/
>>>>>>>>>>>>>>>>>>>>>>>>><<<<<<<<<<<<<<<<<<<<<<<<<


****
MSX Mailinglist. To unsubscribe, send an email to [EMAIL PROTECTED] and put
in the body (not subject) "unsubscribe msx [EMAIL PROTECTED]" (without the
quotes :-) Problems? contact [EMAIL PROTECTED] (www.stack.nl/~wiebe/mailinglist/)
****

Reply via email to