Would this be possible? Trying to program 2x 2MB games to a 29f032 and use an extra 139 decoder to switch between the two and also bank switch the Sram all via the system reset. I'm not sure on how it would be setup if it's possible, but took a best guess anyway.
139(forum was formatting the text)
http://pastebin.com/ruXjSgMF
I suppose it's possible. It depends on how you plan to implement the switch.
All you are wanting is a static high or low signal on A21 and on the SRAM highest address line.
Both of these lines would have to be disconnected from the Snes buss. Pull the pins or cut the traces.
So to get this static signal, the 139 can act like a high low switch if you do this...
Pin 1 OE (output enable). When this line is low, then one of the 4 output lines will be low based on the state of the 2 inputs A & B. When the OE line is high, it causes all 4 outputs to go high.
Pin 2 input A. -- tie to ground
Pin 3 input B. -- tie to ground
Pin 4 output. -- this will be your static high or low to A21 and SRAM.
Pin 7 power ground
Pin 16 power +5volts
Do not connect any other pins to anything.
So making the OE pin high or low will cause pin 4 to go high or low.
You could put a pull up resistor on the OE pin. Then all you would need is just a low signal to make it switch. Your question was If the 139 could be used to bank switch rom and SRAM address lines. Yes it can.
But all this being said, a SPDT toggle switch would do the same thing. Wire the A21 and SRAM high address line to the center pole of the switch, then wire ground to one of the outside pins and +5v to the other outside pin.
What are you wanting to accomplish anyway?
So a 139 can do the decoding, but what is going to be used to tie pin 1 high or low is the question? That is why you are suggesting a toggle switch to begin with right? What about a 393 binary ripple counter? Is the 393 similar in that it can also do the decoding, but only needs a pulse to toggle the outputs, or is this wrong? Could one be used to tie /RST to pin 1 and carry out the needed decoding? I'm trying for is a simple multi cart with two games that each use 16KB of Sram and to better understand how these decoders work.
Edit: Found a design that apparently you tipped MrPete1985 off about on NintendoAge forums Mark. I'll try it out when I get the parts and post my results here in the future. Cheers:)
http://www.nintendoage.com/auth/forum/m ... did=137848
Yeah, that was mine. I have a small pcb that I make (and sell) if you want one.