Page 1 of 2
NES Zelda Multicart
Posted: Fri Nov 29, 2013 7:39 pm
by Tormenter
Interested in doing something like this game I found on eBay. Not to sell, I just like making my own reproductions so that I do not have to pay crazy prices for them. He created 4 of the Zelda hacks into a single cart, with a menu or something so that you can switch between games. Any idea how this was done??
Edit: Actually he stated that you can hit the reset button, and then it switches to a different rom on the cart somehow?

Re: Reset to switch game + Compiling roms to 1 file?
Posted: Fri Nov 29, 2013 8:31 pm
by tepples
The cartridge probably
detects reset by loss of oscillation on the M2 (CPU clock) pin, and this feeds a counter that controls the upper address lines. Standard operating procedure for pirate multis.
What I want to see is The Legend of Zelda/The Legend of Bagger Vance/The Legend of Korra/The Legend of Sleepy Hollow multi, with hidden extras
The Legend of Max,
The Legend of Bag, and
The Legend of Art (NSFW). (
period)
Re: Reset to switch game + Compiling roms to 1 file?
Posted: Fri Nov 29, 2013 8:49 pm
by NESHomebrew
This triggered my memory of a post I saw on hackaday.
http://hackaday.com/2011/05/19/nes-mult ... more-43216
Re: Reset to switch game + Compiling roms to 1 file?
Posted: Sat Nov 30, 2013 10:04 am
by tokumaru
I wonder how they do it in Atari 2600 cartridges, since the cartridge connector in that system doesn't provide any fancy signals... It has 8 data lines, 13 address lines, GND and +5V (plus a "shield ground" which I have no idea what it's used for). How do you detect a reset with that? I don't have any carts that do this with me anymore, but I know for a fact they exist because I had a couple of them when I was a kid.
Re: Reset to switch game + Compiling roms to 1 file?
Posted: Sat Nov 30, 2013 10:39 am
by qbradq
Note that you can detect a reset in software pretty easily. The OP is talking about detecting a reset in hardware only so you can bank between multiple unmodified ROM images within a single cart. I'm not 100% sure what you are referring to with the 2600 carts.
Re: Reset to switch game + Compiling roms to 1 file?
Posted: Sat Nov 30, 2013 11:57 am
by lidnariq
tokumaru wrote:I wonder how they do it in Atari 2600 cartridges, since the cartridge connector in that system doesn't provide any fancy signals... It has 8 data lines, 13 address lines, GND and +5V (plus a "shield ground" which I have no idea what it's used for). How do you detect a reset with that? I don't have any carts that do this with me anymore, but I know for a fact they exist because I had a couple of them when I was a kid.
I took an Argentinian pirate multicart for the 2600 apart earlier this year:
viewtopic.php?p=107406#p107406
(They use Vcc to clock the counter, and use a diode-capacitor to make a "UPS"-ed supply for the counter). My 2600 doesn't have a reset button, per se...
Re: Reset to switch game + Compiling roms to 1 file?
Posted: Sat Nov 30, 2013 4:22 pm
by tokumaru
qbradq wrote:The OP is talking about detecting a reset in hardware
tepples did suggest a hardware solution.
I'm not 100% sure what you are referring to with the 2600 carts.
tepples' solution might work on an NES, but since the 2600 doesn't make the same signals available to the cartridge, I was wondering how they handled the same situation in multicarts for that system that require power cycles to select games. BTW, thanks lidnariq for the explanation.
Re: Reset to switch game + Compiling roms to 1 file?
Posted: Sat Nov 30, 2013 8:21 pm
by blargg
Couldn't the hardware just watch the CPU's A0 line? It would be oscillating whenever it was running, but I'm pretty sure stopped when held in reset.
Re: Reset to switch game + Compiling roms to 1 file?
Posted: Sat Nov 30, 2013 9:26 pm
by lidnariq
Yeah,
A0 would be fine too,
Maxi 15 uses that.
You'd need to use a lowpass that was at most 1/4 the frequency as the one for M2, because A0 could remain low for two full instruction cycles in a row.
Re: Reset to switch game + Compiling roms to 1 file?
Posted: Sun Dec 01, 2013 1:32 pm
by tepples
The worst case I can think of for A0 is oscillating at 1/8 of M2. Consider instruction $23
RLA (d,X), which takes 8 cycles:
- RLA
- operand d
- Internal operation: Add X to d
- Retrieve indirect address low byte
- Retrieve indirect address high byte
- Read from address
- Write unmodified value
- Write modified value
Now consider a case where the instruction begins on an odd address, the operand is even, X is even, and the indirect address is odd. This produces the following for A0:
- RLA: Odd
- d: Even
- IO: Even (I think)
- Low byte: Even
- High byte: Odd
- Read: Odd
- Modify: Odd
- Write: Odd
Repeat this process and A0 ends up dividing M2 by almost eight.
Code: Select all
entry_C000:
ldx #$01
stx $FE
stx $FF
dex
; PC is now $C007
rlaloop:
rla ($FE,x) ; A0: 10001111
rla ($FE,x) ; A0: 10001111
rla ($FE,x) ; A0: 10001111
rla ($FE,x) ; A0: 10001111
; repeat this several times
jmp rlaloop ; A0: 101
Re: Reset to switch game + Compiling roms to 1 file?
Posted: Mon Dec 09, 2013 11:50 am
by Tormenter
Well I found this link that is done by the same person as the link above:
http://callanbrown.com/index.php/super- ... -multicart
I wired up the multi cart with all the zeldas, just like the link above, minus the wires to the chr, since the zeldas only use prg replacement. Game boots, but does not switch games when you h it reset?
Re: Reset to switch game + Compiling roms to 1 file?
Posted: Mon Dec 09, 2013 1:07 pm
by lidnariq
Make sure you've wired the '161 correctly: specifically pins 1,2,7,9, and 10.
Re: NES Zelda Multicart
Posted: Sun Feb 02, 2014 9:00 pm
by Tormenter
Yep everything was wired correct as far as I can see.
Re: NES Zelda Multicart
Posted: Sun Feb 02, 2014 9:13 pm
by lidnariq
Are you using a top-loader, or equivalently have you disabled your NES's CIC?
Re: NES Zelda Multicart
Posted: Mon Feb 03, 2014 3:02 am
by Tormenter
I tried on toaster as well as toploader. All standard, unaltered equipment. Not sure if that would matter, as regular repros work fine.