Inside a Gameboy cartridge.
The most popular name for a Gameboy game-cartridge is 'cart'. I will use that name throughout this site since
it saves on typing.
A cart contains the ROM that is neede to start the game. The ROM in fact IS the game. It is mapped in the lower 32 KB of the memorymap. The bottom 16 KB is fixed, the resst of the ROM is mapped in the second 16 KB of the memory map, using bank switching. For this purpose the Memory Bank Controller (MBC) is present. The cartridges I took apart all have the MBC-1 inside so I will only pay attention to this particular one. Please read the documentation section (see navigator) for all details. If you don't see a navigator, click here.
As I explained before, the most important parts of the game cart are:
This cart is meant to become a kind of docking station for hardware extensions. I'm not sure how I will do it. There are roughly two methods right now:
Signal pins of the I/O connector
| I/O pin | Signal name | ROM | MBC | I/O pin | Signal name | ROM | MBC | |
|---|---|---|---|---|---|---|---|---|
| 1 | +5 Volts | 32 | 24 | 2 | CLK / 4 | |||
| 3 | /WR | 22 | 4 | /RD | 24 | 11 | ||
| 5 | /CS | 23 | 6 | A0 | 12 | |||
| 7 | A1 | 11 | 8 | A2 | 10 | |||
| 9 | A3 | 9 | 10 | A4 | 8 | |||
| 11 | A5 | 7 | 12 | A6 | 6 | |||
| 13 | A7 | 5 | 14 | A8 | 27 | |||
| 15 | A9 | 26 | 16 | A10 | 23 | |||
| 17 | A11 | 25 | 18 | A12 | 4 | |||
| 19 | A13 | 20 | 19 | 20 | A14 | 20 | ||
| 21 | A15 | 22 | 21 | 22 | D0 | 13 | 1 | |
| 23 | D1 | 14 | 2 | 24 | D2 | 15 | 3 | |
| 25 | D3 | 17 | 4 | 26 | D4 | 18 | 5 | |
| 27 | D5 | 19 | 28 | D6 | 20 | |||
| 29 | D7 | 21 | 30 | /RESET | 10 | |||
| 31 | Audio in | 32 | Ground | 16 | 12 |
The bankswitcher
Below, I show how the ROM and the MBC are interconnected. Of course this is just one example and a simple one
too, but it shows how the hardware of the bankswitching took place.
Bankswitching was done by writing to some specific pages in the ROM area. Since the ROM doesn't react on Write
pulses, the MBC can be programmed without any side effects. If someone is to install an EEPROM here, care must
be taken however.
ROM pinout & connections MBC pinout & connections
+----- v -----+ +----- v -----+
GND 1 -| NC Vcc |- 32 +5V D0 1 -| |- 24 +5V
MBC16 2 -| A16 A18 |- 31 MBC14 D1 2 -| |o 23 CS
MBC17 3 -| A15 A17 |- 30 MBC15 D2 3 -| |o 22 WR
A12 4 -| A12 A14 |- 29 MBC6 D3 4 -| |- 21 A15
A7 5 -| A7 A13 |- 28 A13 D4 5 -| M |- 20 A14
A6 6 -| A6 A8 |- 26 A8 A14' 6 -| B |- 19 A13
A5 7 -| A5 R A9 |- 25 A9 GND 7 -| C |- 18 ??
A4 8 -| A4 O A11 |- 24 A11 +5V 8 -| |- 17 A15'
A3 9 -| A3 M RD |o 24 /RD GND 9 -| 1 |- 16 A16'
A2 10 -| A2 A10 |- 23 A10 RESET 10 o| |- 15 A17'
A1 11 -| A1 CS |o 22 A15 RD 11 o| |- 14 A18'
A0 12 -| A0 D7 |- 21 D7 GND 12 -| |- 13 GND
D0 13 -| D0 D6 |- 20 D6 +-------------+
D1 14 -| D1 D5 |- 19 D5
D2 15 -| D2 D4 |- 18 D4
GND 16 -| GND D3 |- 17 D3
+-------------+
| | | |
| | | | | |
| | +---------o--- | -- | ------ Internal function
| | | |
| +-------------------o -- | ------ Pin number
| |
+-----------------------------o------- Connection with Gameboy I/O connector
I'm not sure what pin 18 of the MBC is connected to. It is not connected on my cart, so I can only guess what
it's for. The most probable guess is that it is A19', i.e. the bankswitchable A19. If you know what it's for,
let me know. The E-mail address is in the topright section of
the navigator frame.
According to Dr Pan's text, the MBC-1 should be able to address 2 megabyte ROM's so it needs 21 address line for this. A0 - A13 come from the CPU. So the MBC-1 will need to generate A14 upto and including A20. So most probaly the pins now assignd to GND (except pin 12) can be the extra address lines.
Page created December 2005,
Page equipped with FroogleBuster technology