Multicart Controller
The multicard controller (MC) is inserted between the VP cartridge port
and the game ROM/EPROM/FLASH storage chip. It generates the address for
the storage chip based on the VP address and the current mode settings.
In general, the MC operates in either of two modes:
- menu mode
- application mode
After reset, it starts in menu mode and traverses to application mode
once under software control. Switching back to menu mode is only
possible with reset or power cycle.
Menu Mode
The first 2k of the external storage memory are available as plain
program memory in menu mode. I.e. this range is mapped as a standard 2k
game cartridge with exclusion of A10, BS0 and BS1. To allow for 256
menu entries, there is a bank switching mechanism active that banks the
last page of the first 1k
--> programm address range from
0700h to 07ffh
Whenever this range is accessed, a programmable bank offset is added to
the external memory address:
External memory 8048 program
memory
+-------+
+-------+
| 0700h | ebank 0 | 0700h |
| 07ffh | --------+-> | 07ffh |
+-------+ |
+-------+
| 0800h | ebank 1 |
| 08ffh | --------+
+-------+ |
| 0900h | ebank 2 |
| 09ffh | --------+
+-------+
[...]
In menu mode, there are several registers defined and active that serve
the purpose of configuring the application mode by means of software.
CART_2K_OFFSET (@ 080h)
Specifies the offset for external storage memory access in application
mode in units or 2k blocks. All 8 bits are used, thus the max offset is
255 * 2k = 510k
CART_SIZE_MASK (@ 081h)
Bit 7: 0 = skip A10, 1 = use A10
Selects the usage of A10 in application
mode.
Setting this to 0 skips A10, resulting in a memory layout compatible
with standard 2k, 4k and 8k cartridge.
Setting this to 1 uses A10 for cartridges with 12k or 16k size.
Bit 1..0: Size mask
Selects the size mask in application
mode.
These bits mask the BS0 (bit 0) and BS1 (bit 1) to generate the proper
addresses for 2k, 4k and >= 8k cartridges.
Cart Bits
Size 1 0
------------
2k 0 0
4k 0 1
>=8k 1 1
CART_EBANK (@ 082h)
Specifies the offset for program memory range 0700h to 07ffh in menu
mode in units of a page. Only the lower 4 bits are used, thus the max
offset is
15 * 256 = 3840
CART_MODE (@0ffh)
When written with 0a5h, the mode is switched from menu to application.
A reset on mc_res_n_o output is generated and the settings in
CART_2K_OFFSET and CART_SIZE_MASK become effective.
Application Mode
All registers of menu mode are disabled, thus there's no means for the
game software to change the settings done during menu mode.