play Gameboy Cartridge on C64 possible?

Discussion of development of software for any "obsolete" computer or video game system. See the WSdev wiki and ObscureDev wiki for more information on certain platforms.
Post Reply
Gamester
Posts: 14
Joined: Mon Nov 14, 2011 12:47 pm
Location: Germany

play Gameboy Cartridge on C64 possible?

Post by Gamester »

hi folks
iam new to the c64 scene and have a question.

Would it be possible to use a SuperGameboy to play Gameboy cartridges on a C64? (no emulation)

I have some experience with old video game consoles like NES / SNES /GB

the following data i collected makes me think it should be possible.

https://pastebin.com/vEEqZSP4

in short

use memory expasion port on the C64 to

-read SuperGameboy v-ram and recolor it.
-send control commands to Supergameboy

Do I miss something or is that really possible?
lidnariq
Posts: 11430
Joined: Sun Apr 13, 2008 11:12 am

Re: play Gameboy Cartridge on C64 possible?

Post by lidnariq »

Is the pixel format from the SGB compatible with what the VIC-2 expects? It seems like you might not have enough time to copy and repack the video, if not...
Gamester
Posts: 14
Joined: Mon Nov 14, 2011 12:47 pm
Location: Germany

Re: play Gameboy Cartridge on C64 possible?

Post by Gamester »

the Vram of the SGB contains 2BPP data but i dont know if the VIC-II can handel this ?

Image

The MCI mode of the C64 should be suitable for this application but that is just my guess.

2BPP= 4 colors/shades of grey

C64 MCI mode generates 320*200 pixel resolution with 4 colors per 8x8 cell.
lidnariq
Posts: 11430
Joined: Sun Apr 13, 2008 11:12 am

Re: play Gameboy Cartridge on C64 possible?

Post by lidnariq »

To the best of my memory, the SNES packs pixels as:
abcdefgh ABCDEFGH

while the VIC-2 (in 2bpp mode) packs pixels as:
AaBbCcDd EeFfGgHh

so ... you might have your work cut out for you.

It's possible (no promises) that clever rewiring of the data bus to the SGB would make it easier. (You don't have to connect D1 to D1, &c)
tepples
Posts: 22705
Joined: Sun Sep 19, 2004 11:12 pm
Location: NE Indiana, USA (NTSC)
Contact:

Re: play Gameboy Cartridge on C64 possible?

Post by tepples »

Rewire the bus

Code: Select all

abcdefgh -> aebfcgdh
Read pixels

Code: Select all

aebfcgdh
AEBFCGDH
mask off bits

Code: Select all

a0b0c0d0
0e0f0g0h
A0B0C0D0
0E0F0G0H
shift bits

Code: Select all

0a0b0c0d
0e0f0g0h
A0B0C0D0
E0F0G0H0
OR them together and write them to video memory

Code: Select all

A0B0C0D0 | 0a0b0c0d = AaBbCcDd
E0F0G0H0 | 0e0f0g0h = EeFfGgHh
I have no idea how quickly that can be done for the 5760 bytes in the SGB frame buffer.

But it would stretch the picture from the SGB pixel aspect ratio 8:7 to the C64 multicolor pixel aspect ratio 3:2, making everything 31% wider.
Gamester
Posts: 14
Joined: Mon Nov 14, 2011 12:47 pm
Location: Germany

Re: play Gameboy Cartridge on C64 possible?

Post by Gamester »

yes i think i have read something like that on

http://www.studiostyle.sk/dmagic/gallery/gfxmodes.htm
This mode uses two MultiColor pictures (160*200/4 colors in 4*8 cell), each using its own attributes
the SGB uses 160 × 144 in 8*8 cell (see picture in 3. post)
User avatar
Myask
Posts: 965
Joined: Sat Jul 12, 2014 3:04 pm

Re: play Gameboy Cartridge on C64 possible?

Post by Myask »

It's much easier to do that in a hardware fashion, really, since you then don't have any AND nor ORing, just a matter of what's being written or read.

I know of a relevant patent. Consider the "prior art" description.
Gamester
Posts: 14
Joined: Mon Nov 14, 2011 12:47 pm
Location: Germany

Re: play Gameboy Cartridge on C64 possible?

Post by Gamester »

The 33% wider screen only applies to NTSC C64 ,for PAL C64 it's only 6,8% wider wich is acceptable i think

1:1 Ratio

Image

1:0.75 ratio (133%) NTSC C64

Image

1:0.936 ratio (106.8%) PAL C64

Image
User avatar
tokumaru
Posts: 12427
Joined: Sat Feb 12, 2005 9:43 pm
Location: Rio de Janeiro - Brazil

Re: play Gameboy Cartridge on C64 possible?

Post by tokumaru »

The NTSC simulation doesn't look any worse than 4:3 content stretched to 16:9, something I see a lot of people doing (makes me cringe a bit, but it doesn't seem like a big deal to many people). If that's the price to pay for doing something cool like playing games for one retro machine on another retro machine, I think it's fine.
User avatar
Bregalad
Posts: 8055
Joined: Fri Nov 12, 2004 2:49 pm
Location: Divonne-les-bains, France

Re: play Gameboy Cartridge on C64 possible?

Post by Bregalad »

tokumaru wrote:The NTSC simulation doesn't look any worse than 4:3 content stretched to 16:9, something I see a lot of people doing (makes me cringe a bit, but it doesn't seem like a big deal to many people).
Agreed. How many youtube videos about retro games have them incorrectly converted to 16:9 format ?

Besides, does the C64 even have 2 shades of gray in the 1st place ? Or would any dark colour and any light colour do the job ?

I think a SGB on a C64 would be very cool to see !
ccovell
Posts: 1045
Joined: Sun Mar 19, 2006 9:44 pm
Location: Japan
Contact:

Re: play Gameboy Cartridge on C64 possible?

Post by ccovell »

The C64 has a (comparatively) whopping 3 shades of grey, plus black and white.
User avatar
tokumaru
Posts: 12427
Joined: Sat Feb 12, 2005 9:43 pm
Location: Rio de Janeiro - Brazil

Re: play Gameboy Cartridge on C64 possible?

Post by tokumaru »

Lack of grays isn't a problem, GB video looks good in all kinds of colored gradients.
Post Reply