Bank Switch Mini 256K

Bank Switch Mini 256K

Bank Switch Mini 256K

When I started selling the Classic 64K Bank-Switch Boards on the CHC store, I wanted to follow Jon’s lead and offer a cartridge shell. Currently the only place to get a 99/4A cartridge shell is to removed the circuit board from an existing TI produced cartridge, at least until someone coughs up the cash to have an injection mold tool made…  Maybe when I’m rich (don’t hold your breath.)

So, I’m taking the circuit boards out of a perfectly good TI Invaders cart so I can supply the shell with the 64K Boards being bought on the store.  As I’m doing this, I start to become perplexed by the whole thing.  The TI produced cartridge boards are in excellent condition and they have pretty much everything necessary to become a bank switching board.

Swapping a TI board for a 64K board

They look almost the same, don’t they? 😉 However, the TI board has a ROM and GROM, while the 64K boards use some sort of programmable chip like an EPROM and requires a logic chip (currently the 74LS379) to support the bank switching.  However, the TI boards have all the necessary connections except for two, the we* (write enable) and A3 (address line 3 on a 99/4A is A12 for the rest of the world since TI numbered their pins backwards from everyone else.)  The TI cartridge did not connect we* because you can’t write to a ROM, and the A3 was not necessary because the ROM is only 4K on this board.

So I started thinking that I could make a smaller circuit board to plug into the ROM location and pick up the we* and A3 with wires.  This way I could convert a typical TI produced cartridge board into a bank switch board.  Thus the Bank Switch Mini idea was hatched.

As long as I was making a new board, I figured I would fix a few of the things I would have done different from the 64K boards that Jon made.

Disclaimer: don’t get me wrong, what Jon did is absolutely wonderful and he spent a lot of personal time and money making the 64K boards, and without them I would not be selling much on the CHC store, and people would not be making their own carts.

I had some ideas of my own though, so I thought I would try some. My goals for the board were:

  • Be smaller and cheaper than the 64K board, otherwise the project is not much different than the existing 64K board…
  • Eliminate the 74LS379.  The biggest problem with the 379 is that the part is obsolete, i.e. no one is making it any more, so it is hard to get and usually expensive (for a logic chip) once you find old stock.
  • Eliminate the jumpers.
  • Support bigger memories, since they exist.

I’m not sure why Jon used the 74LS379, except I think it had to do with compatibility with old bank-switching carts.  Also, the 379 is a QUAD latch, but only 3 of the 4 latches are used, which limits the board to supporting up to only 8 banks via a 512K x 8 chip (27512).  However, by simply adding the extra traces to the board during the design phase to pick up that 4th latch, Jon could have doubled the banking capacity to 16 banks.  The board can do it, everything is there except two traces on the board.  I have not asked Jon about it yet, but it was probably just an oversight and I think this was his first board too. Anyway, not that it matters, it is just a little confusing.


When I started researching memory components I quickly realized that the old UV EPROMs are EXPENSIVE!  Industry has moved on and the cost for those chips are going up.  A new 27512 from STMicro can cost as much as $7 to $9 from Mouser and DigiKey. Ouch!  They are also a pain in the ass to work with and erase.  What I did find, however, is that flash and EEPROM memories have replaced them, which are much easier to deal with, have pin-compatible layouts, and most importantly are a *lot* cheaper.

So, I picked a nice fat 27SF020, which is a 2Mbit x 8 chip, in a 32-pin PLCC package costing about $1.09 each. 🙂  That is a 256K *byte* chip, which means it can have 32 8K banks! And for that cheap, there is no need to support various size chips, and that simplifies the design.  Just stick a 020 in the board and be done with it, whether you use 1, 5, 18, or all 32 banks, it does not matter.


Now for the 74LS379 chip.  Aside from the lack of easy availability and cost, the chips only have 4 latches, and to get 32 banks we need 5.  Also, since the chips are discrete logic, they don’t have any known power-on state, which means you don’t know what bank would be selected when the cart is plugged in.  While this is not typically a big problem, and it can be solved by setting up the bank switching code correctly, it would be nice to have a known power-on bank, especially when dealing with 32 banks. The Motorola 379’s I bought all power-on with a 1011 output, which means bank 3 is always selected (remember only 3 of the 4 latches are used in the 64K boards.)

The last problem with the 74LS379 was the inverted outputs being used for bank selection.  From a programming standpoint it does not make any difference, however it makes a *really* big difference when you are programming your chip, and I personally don’t like to think backwards if I can help it.

With inverted bank selections you have to put your lowest numbered bank (bank 0) at the highest memory location in the chip, and all subsequent banks must grow down in the chip’s address space as the bank number goes up.  Like this:

That is a 4-bank chip, or 27C256. If you program the chip with your code for bank 0 starting at address >0000, then your program will not work.  Anyway, all that to say I’d rather have non-inverted bank selection, or at least a way to have the option.


Since I have been messing with FPGA’s lately, I started looking for a programmable logic solution and found this nice device called a “GAL” (generic array logic), which apparently replaced the “PAL” (programmable array logic).  So, I find this common GAL called the 16V8D which means 16 inputs and 8 outputs, all in a 16-pin package, available in PLCC and DIP cases (among others) and only costs about $1.07 at Mouser. So I bought a few made by Lattice (which much to my chagrin are actually now coming to their end of life…)

Now I had to figure out how to program the GAL (I bought them before I looked into that slight detail.) I downloaded the Lattice tools and discovered, to my delight, that I can use the same hardware description language (VHDL) that I had been using for the FPGA work! I think it took me about 10 minutes to described the logic of the 74LS379. It was a happy day.

Also, with the 16V8D I had the ability to have the required 5 inputs and 5 outputs to support all 32 banks, plus I have an input that, via a jumper (I know, but only 1 jumper) I could select inverted or non-inverted bank selection logic.  The GAL also has active pull-ups on all input pins as well as a guaranteed power-on state!  At power-on, all the outputs of the GAL are high, which means the highest bank (bank 31) in the 27020 will always be selected when the cart is plugged in.  While I would have liked all the outputs to be *low* at power-on, I’ll take what I can get, and consistency is better than nothing.


Designing a circuit board is something I have always wanted to do, but never actually done before (aside from the dismal attempts at etching my own back in the early 1990’s.)  I did some searching and found that Eagle CAD is still around and a popular choice, well supported, and they have a free version which is only limited in the max size of a board you can make.  After installing a few programs and poking around, I settled on Eagle and started following various tutorials from places like SparkFun and such.

After about two weeks of work I had a schematic and initial board layout and I started looking for a place to have it made.  I needed a prototype so I could test the design before I had a batch made up.  Again, after a lot of searching, calls, emails, and quotes from various board houses, I settled on which is part of SparkFun.  It is a nice service for limited small runs and prototypes, however you trade price for time.  It took me 4 weeks to get my boards from the time I ordered them, however this was no surprise as they clearly state it will take between 3 and 4 weeks. This is the result and I’m really happy with them.

Bank Switch Mini 256K Board - Front and Back

Also, I only ordered (and paid for) 2 boards and they sent me 4!!  I’m not sure why, maybe the small size (1.4″x1.3″), but I’m happy about it.


The biggest problem I realized during board assembly is that I need to fix the through-hole pins.  Since this board has to mate with the original TI board, it needs through-hole pins sticking out of the bottom.  However, since there is a surface mounted PLCC-32 *socket* on the top-side of the board, the pins can not come up through the board, they must be flush or shorter than the thickness of the board (which is only 0.062″).  You would not think that would really be a problem (finding such pins), but I’m here to tell you that it is! I can not find a standard header with a tail (the part that goes into the circuit board) short enough, and I ended up using two styles of individual PCB pins from Mill-Max:

PCB Pins, through hole and SMD mount

In case you didn’t notice the penny sitting there, those are some SMALL pins, especially the ones designed for surface mounting!  The through-hole pins (on the right) actually stick up just enough to get in the way of the socket, so there are 8 pins (4 on each side) that use the really small ones on the left.  It was tedious to handle the pins and a show stopper for having the boards made, or for hand making them myself in any kind of quantity.  The hardest part about assembling the board was these pins and the PLCC-32 socket.

I bought a fancy SMD hot-air rework station and some solder paste to try and use with the sockets, however the paste ended up making more of a mess than it was worth and I could not make it work.  I guess I’ll have to experiment with it before trying to use it on another project.  So I tinned the leads of the PLCC-20 socket and the hot-air worked for that one.  The PLCC-32 socket was another story.  I could not get it to solder down flat with the hot-air, and after 5 failed attempts, I had to cut the center out of the socket and hand solder the pins.

32-Pin PLCC socket with the center removed for soldering

Not exactly what I wanted to do, but hey, it’s a prototype and my first SMD assembly.  One of the last minutes changes I made to the board was to add some low current LEDs and current limiting resistors to the board so I could see what bank was actually selected. These are 0603 SMD parts (the smallest currently made) and they were actually not to bad to solder once I got them aligned, which was a lot harder than I though it was going to be. They are so small that even taking them out of their packaging was a task in trying not to lose them.  The LEDs are smaller than a grain of rice and transparent, and I had to use a 10x loupe just to determine which end was the cathode.

I was also not sure if having the LEDs on the address lines was going interfere with the operation of the board, but I selected LEDs that use less current than a standard TTL input, and made my current limiting resistor selection carefully, and it all worked out.

Bank Swith Mini 256K mounted on a TI board

Bank Swith Mini Close Up


I tested the bank switching with Retroclousds’ PITFALL! and it worked perfectly the first time!  I was shocked! Actually, the first time I tried the board I had forgotten to program both the GAL and the 27SF020 and it did not work when I plugged in it (obviously).  It was a deflating end to a long night of board assembly (4 hours to put the sucker together thanks to those pins and that 32-pin socket.) But after realizing my error, and a quick programming later, I was playing PITFALL! on my 99/4A and watching the bank selecting via cool looking orange LEDs.  Here are a few shots with the board plugged into my test-bench 99/4A.

Bank 31 selected at power-on

Bank 28 (bank 3 in the game) selected during game play

The board in these pictures was set up to use the inverted bank selection, so in the second picture you see bank 28 is actually selected, i.e. binary 11100, but the game code actually executed a switch to bank 3.

To test the non-inverted bank selection I put the game in the 27SF020 twice, once at the top of the chip in reverse bank order, and again at the bottom of the chip with the four 8K game code banks in the opposite order.  With the non-inverting jumper set, the game ran and I could see banks 0 – 3 being selected.  Without the jumper banks 28 – 31 were used. It was pretty cool.


I can hear some of you yelling about programming the PLCC chip.  Well, for doing that I went to this really nice site,, where a guy is making chip adapters for *really* cheap, and got one of these:

PLCC-32 to DIP-32 from EZprototypes

It costs about $6.50 and is really well made. My chip programmer software already supports the 27SF020, so it worked right out of the box.  Not quite as convenient as a ZIF I know, but not too bad and you get the small size and *really* cheap 020 chips!  I also picked up a PLCC-20 to DIP-20 converter to program the GAL 16V8D, which I was really surprised to find my programmer also supported.

All around it was a fun project and one that I hope to have available soon on the CHC store if I can work out the pin problem.  I really need to find a single header for the through-hole connection to the TI board so the part count can go from 30+ pieces to about 7 (without the LEDs.)


I had a request for the code used to program the GAL, so here it is.


10 comments to Bank Switch Mini 256K

  • Wow, Mathew, what neat project! It would make a GREAT demo at the Faire. –Hal

    • matthew

      I’ll definitely be at the 2010 Faire and I want to talk to people about these devices and future projects, etc. I just need some table space. 🙂



    Would you consider doing the same, but as a full cartridge board, rather than an add on board?

    There would be 2 distinct advantages IMO:

    1) We would not have to kill perfectly good (and ageing) TI Cart boards – it’s bad enough that we have to steal the case!

    2) The mechanical issues that you described would be completely avoided.

    If you can produce a full board with this design, I’m on for at least 25, maybe 50 boards. 🙂

    • matthew

      Well, if I didn’t make the project as an add on board, then I still have a pile of perfectly good TI Invaders boards sitting in a box. Until we get some way to make our own shells, robbing old carts is, unfortunately, the only way. Also, the full size board makes them more expensive. However, as you mentioned, I still have the mechanical problem.

      I really intended to use these mini boards for the new games being produced, since it would allow the existing TI boards to be reused and be cheaper than a full size 64K board. Without all the LED fluff, the part count is 2 sockets, 2 chips, 2 caps, and 2 12-pin headers (assuming I can find some suitable.)


  • Another comment:

    Also, if you would consider doing a full board, rather than an add on, do you think you could add, say, 32K of FLASH (or some other non-volatile type of memory) for use as GROM/GRAM?

    It would mean programmable logic to emulate the address incrementing. However, it would mean that our cartridges would be FULL TI Spec, and our code could store important (and bloaty) data such as speech and graphics where TI always said it should be, in GROM 🙂

    That’s been my holy grail for a number of years now!


    • matthew

      A full board with GROM support is already in the works. 🙂 The thread I started over on the AtariAge forum was to get some feedback on that idea. I actually have a Flash version of the Mini, that uses a 39020, which I designed before using the 27020. The main difference between the 39020 and 27020 is the pin-out and that the 39020 uses the idea of “pages” for programming. The 27020 is more like an EPROM and behaves better in my aging programmer. However, the 27020 is a EEPROM based on flash memory, so it would be possible to program it in the circuit, you just need the programming voltage and a way to control it all.

      Anyway, I’m in the process of developing a full board that has banking RAM, banking ROM, and programmable GROM. It will be more expensive though since the GROM support will take more than a GAL offer, i.e. I need a full on CPLD that can implement a state machine.


  • Making new cartridge cases isn’t a huge problem. They can be made at a decent price using RTV silicone rubber and for black ones, Smooth-On’s Smooth-Cast Onyx would be the perfect resin. 3 minute pot life and 10 minute demold time. (May take longer due to the thinness of the cartridge shell.)

    The style to copy would of course be the screw together version.

    The biggest expense of course would be making the mold, you’d want more than one mold for faster production. Mold cost amortized over its production life can amount to pennies to fractions of a cent per casting if the mold is taken care of. In some cases an RTV mold can make 1,000 or more castings.

    If someone wants to get into the TI Command Module shell making business, I’m willing to provide free advice on how to go about it. I’ve too much on my plate with my reproduction auto parts to add cartridge shell production.

    I *could* make a mold, if someone provided a shell. But that’d cost almost as much as buying a gallon kit of Silicones Inc. P60 RTV and making the mold yourself. (Plus you’d have the rest of the gallon to make more molds.)

    I’ve been doing RTV mold making and resin casting since 2004.

    I’d love to see new TI cartridge shells, but I’m not too interested in doing them myself since I don’t have a TI, though I used to have seven and two PEBs.

    Send me an e-mail at g_alan_e @ (Despam by removing the space on either side of the @!)

  • matthew

    Awesome! I’ll be sending you an email for sure! Thanks.

  • I’ve even heard about an idea for wooden-carved cart cases… this is interesting to me, as a whittler. =)

Leave a Reply

You can use these HTML tags

<a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code class="" title="" data-url=""> <del datetime=""> <em> <i> <q cite=""> <s> <strike> <strong> <pre class="" title="" data-url=""> <span class="" title="" data-url="">