One of the great things about the Sinclair/Timex family of computers is that it is ideally suited for hardware experimentation. This is especially true of the ZX81/TS1000. Still, a lot of folks are hesitant to tear into their precious machines for fear that their experiments will result in the death of the “patient.”
So here’s a little project that won’t even require the removal of the sticky-feet on the bottom of your computer. Do you have a spare Sinclair/Timex 16K RAM pack floating around? If not, you can probably pick one up for a song if you look around a bit. (Check Hal-Tronix‘ ad in SWN 3:2.) How would you like two banks of 8K memory in the 8-16K range? Well, with a 16K pack and one inexpensive chip you can have just that.
In addition to the RAM pack you’ll need a 74LS02 or 74HC02 IC (costs under $1). Add one 2.7K, 1/4W. resistor, a diode, and a subminiature SPST and you’re ready to go.
Theory
If you just want to get on with it, skip this section. But if you want to learn a little about memory decoding on the Sinclair, this section might give some insights.
First I’ll tell you how NOT to do it. I thunk up the circuit of Figure 1, using the following logic. A14 controls the 16K “block” of memory; when it is low, the 0-16K (and 32-48K) region is addressed, and when high, the 16-32K (and 48-64K) region is being paged. So the first step would be to invert this A14 signal, so that the RAM pack responds to signals in the 0-16K range instead of 16-32K as normal. Furthermore, the RAM pack’s MREQ NOT should be engaged (brought low) only when the 8-16K region is addressed; in other words, only if computer MREQ NOT is low and A13 is high. Lastly, we want to turn off the ROM under these conditions, as the Sinclair/Timex ROM “echoes” in the 8-16K range due to incomplete internal decoding. The RAM pack’s disconnected A13 line could then be used to select one of the two available banks. If you study Figure 1, you might think, as I did, that this should work fine.

However, there’s a problem. I wired up Figure 1 using a single 74LS00, and though it seemed to work, it occasionally corrupted the data stored in either of the two blocks. Time to send an S.O.S. to John Oliger… and true to his reputation, an answer came a couple weeks later.
The key is that, once again, it is the non-standardness of the Sinclair memory system that causes trouble. The above circuit would probably work with any other similarly mapped computer, but not with the Sinclair/Timex. To quote John,
“Your circuit for the 16K RAM pack is giving you problems because it will interfere with the RAM’s refresh. MREQ NOT is tied directly to the memory chips’ RAS NOT (Row-Address Strobe) pins through an OR gate, causing either a real RAS NOT or a RAS-only refresh during refresh time. MREQ NOT is active during a ‘window’ of the refresh cycle, and the Sinclair pack uses this fact to advantage. So, if A13 is not high from the ‘I’ register during this time (this is set for the video routines to 1Eh, which would NOT have A13 high), no refresh would be performed during refresh time. The memory would still be partially refreshed from normal READ/WRITE, but would be very erratic and undependable.”
“Try the circuit in Figure 2 and see if that fixes the problem. The key in using the Sinclair RAM pack like this is A14. A14 being high can be thought of as the ACTIVE HIGH CHIP SELECT for the RAM pack. Use IT instead of MREQ NOT.”
“Another benefit from doing it like this would be the fact that A15 is included in the decoding, and thus the RAM pack will be fully decoded for the 8-16K region, and NOT BE REFLECTED at 40-48K.”
If you study Figure 2, you’ll see that it accomplishes the same result, but doesn’t interfere with MREQ NOT. Note that we’re using A15 also (specifies 0-32K or 32-64K). If A14 and A15 are both low, and A13 is high, then ROMCS is inhibited and the RAM is activated (via its A14 line). MORAL: Go ahead and try your hare-brained ideas, they might even work. If they don’t – ask an expert.

Start Hacking
First come the mechanics. Open the RAM pack, and find a place to mount the switch where it won’t interfere with anything when you close it up later. I super-glued a small “DIP switch” via a small plastic pad to the upper-left corner of the decoder board (the one with the edge connector on it). A square hole in the front case-half allows the switch to protrude and be accessed when the pack is installed. This is the “BANK A/B” switch. You might want to use a magnetic reed switch and magnet (a la “ROMSWITCH”) and you won’t even have to put any holes in the case. Now cut the traces going to the edge connector lines A13 (13B) and A14 (12B). The connector is numbered 1 to 23, starting at the end closer to the key slot. Note that the key is actually pin 3, don’t get confused by this. The top row of contacts is the “A” row, the bottom is “B” (use “B” for “Bottom” as a mnemonic). To avoid confusion with address lines A0-A15, the actual connector designations will always be written with the number first. You’ll also be making connection to +5V (1B), Ground (4B and 5B), and A15 (11B).
If you plan to use this with 2K only (no other external RAM) you’ll also have to cut the traces that go between pins 1B and 2A (RAMCS NOT). Note that there’s a trace on each side of the board; you have to cut both. This is recommended but not vital even if you do use external RAM.
Now do the final wiring. Pin 14 goes to +5V (edge connector 1B) and pins 6, 7, 8 go to ground (4B and 5B). Pin 12 goes to A15 (11B) and pin 11 goes to A14 (12B). Pin 5 goes to A13 (13B). Finally, pin 1 connects to ROMCS NOT (23B) via a 1N914/1N4148 diode, banded end towards ROMCS NOT. Pin 1 ALSO goes straight to the other side of the cut trace to A14.
Finally, wire up your switch between the other side of the cut A13 line and ground. Also connect this trace to +5V through a 2.7K resistor. There! All done!
Now prepare the 74LS02 IC. Bend the legs so they stick straight out from the body of the chip. Bend the narrow parts of pins 3 and 4 toward each other and solder them together. Do the same to pins 6 and 7. Cut off the narrow parts of the remaining pins. Now run a jumper from pins 6 and 7 to pin 8. Run another (insulated) jumper from pin 2 to pin 10. Run a third jumper from pin 9 to pin 13. Route the jumpers over the numbered side (top).
Mount the IC with sticky-foam or silicone glue, on the backside of the decoder board, between the 74LS157 and the high-numbered end of the edge-connector. Position it carefully, there isn’t much room here (that’s why we trimmed off the excess pin length).
Test For Smoke
To test it, you’ll have to install it as the last thing in your line-up (obviously, since it doesn’t have a through-connector). If your main RAM is another Timex or Sinclair pack, you could add a finger board, but it’s tricky and you won’t be able to get it back in the case. Better to use another pack, that already has a finger board through-connector. Alternately, make up a “mother board” or extension cable to plug everything into.
Check everything over, then check it again. Use the pictorial diagram of Figure 3 as a guide. If all looks good, power ‘er up, and try POKEing values into the range from 8192 to 16383, and then PEEKing to see if you get the same values back. Then flip the bank switch, and do the same with the other bank.
If all went well so far, put it all back into the case and test it again. You’re now ready to run machine-code in this region, or simply use it to store often-used programs. I’ve successfully stored and run Memotext in one bank, with the Delphic 4K toolkit, Z-XLR8, UPD and a few other utilities in the other bank. Toggling the switch won’t corrupt memory or crash the machine provided you’re not addressing (reading from or writing to) this region at the time. In other words, flip the switch only when you’re back in BASIC.
There. Wasn’t that fun? As a final note, this doesn’t work with my TS1500. If any of you wizards out there can figure out why, I’d love to hear from you.
