Found a ZX81 and fixed it

Introduce yourself to your fellow forum members - what was your journey into the Sinclair world?
rmzalbar
Posts: 12
Joined: Mon Jun 22, 2020 5:07 am

Found a ZX81 and fixed it

Post by rmzalbar »

Hi! I am in San Diego, California.

Last year I bought a huge box of Commodore stuff locally. A C64, VIC-20, 1541 disk drive, tape drive, and some books, cartridges, tapes, and joysticks.

After getting home and unpacking everything however, at the bottom of the box was a ZX81! I knew what it was from reading about them, but never encountered one before and know next to nothing about them. I tried plugging it into the TV, but got nothing. The power supply was a generic 9V wall wart, not original. Papers and receipts in the box for various things suggested the original owner was in the military in the 80's and stationed overseas, probably a NATO base in W. Germany or England. I figured it was a PAL model and set it aside.

Well, now I have a monitor capable of supporting a PAL signal, so a few days ago I remembered the ZX81 and dug it up to give it another go. I don't have a PAL tuner, so the first thing I did was buffer off the video input to the modulator and run it into the composite input.

Well, when plugging it in, I get a white screen for a fraction of a second, followed by a loss of vertical sync. Oscilloscope shows something very strange: Apparently valid rasters being generated, but at about 31khz instead of the expected 15khz. Well, video monitors don't do doublescan and I know this is a TV-output device, so that can't be right. For the first fraction of a second when plugging it in, I do get 15khz, which is that white screen.

I find a schematic. I spend the rest of the day verifying the clocks, address and data paths throughout the board and looking at the signals. Everything looks okay. So, what can I try with what I have on hand? Well, I don't have a ULA, obviously. I don't have a Z80. I do have equivalent SRAMs to the 4118 that it came with, so I try a couple of those, but it makes no difference.

The only other thing I might be able to do is to replace the ROM. I search around and find the ROM is eqivalent to 2364. I have 2764 EPROMS. I look around for some instructions, and also pull up the datasheets side by side. The 2364 is 24-pin, the 2764 is 28-pin and there is a 28-pin socket on the board. I start probing the extra pins on the board, and it turns out that the extra pins are already mapped to the right places! I only had to redirect two pins.

I find an 8K basic rom online, zipped together with an emulator. I take out my trusty TL866 and burn it. I hold my breath, plug in the power and.. am greeted with a stable picture with a little "K" on the corner of the screen. Success! Even the keyboard all seems to work OK!

I put a heatsink on the ULA. I also took a run at upgrading the RAM to 16K, but that didn't work - I'll ask about that in a different thread - however a 6116 worked fine, so I have 2K now.

Now to learn about the ZX81 - figure out storage, and get a handle on the BASIC for it. It's quite a cool little machine!

FYI, the instructions for adapting the 2764 EPROM to the 2364 ROM on the ZX81 that I found were either inaccurate or had unnecessary steps. Here is what I did to make the 2764 EPROM work. I used one 28-pin socket as an adapter and only had to redirect the following:

2764 EPROM pin 20: Bend out, connect to GND
2764 EPROM pin 23: Bend out, connect to ZX81 SOCKET pin 20

The four additional pins 1, 2, 27, 28 were already connected to the right places on my ZX81 motherboard, so nothing needed to be done with those.
20200622_094743.jpg
Last edited by rmzalbar on Tue Jun 23, 2020 7:24 pm, edited 1 time in total.
rmzalbar
Posts: 12
Joined: Mon Jun 22, 2020 5:07 am

Re: Found a ZX81 and fixed it

Post by rmzalbar »

Moggy wrote: Tue Jun 23, 2020 2:48 pm Hello and welcome to the forum.

Nice to see another zeddy back in action. :D

The 2764 is well known and used by some people here, myself included, but I can't help but notice a few things re your 2764 re-wiring.

Pins 1-27-28 need to be held at 5volts and the best place to do that on the motherboard socket is where pin 26(not connected) lies as it is conveniently at 5volts, so pins 1-27-28 need to be bent out and connected to pin 26 by one continuous wire so as to be held at 5volts.

Also pin 2 needs to be bent out and a wire soldered to it and run over to the hole vacated by your bent out pin 23 in the same manner as as your pin 23 to 20, A11 link, otherwise address line A12 is missing.

As you have the equipment for EPROM burning, this thread may be of interest concerning a double speed BASIC, ROM image which indeed does speed up some BASIC routines very well.

https://www.sinclairzxworld.com/viewtop ... f=5&t=2986


Again welcome aboard and have fun.


Regards.

Moggy.
Thank you for the welcome!

What I discovered with continuity checking was that pins 1-27-28 were already directly connected to the +5VDC source on the ZX81 motherboard. Pin 2 was also already connected to pin 23. Therefore the only connections I had to make were the bending out and rerouting of pins 20 and 23 according to the diagram you posted. I don't know if this varies from board to board, but this is how it was with mine.

I'm attaching an image from the underside of the socket so you can see the connections. I've reversed it left<-->right so that it matches your drawing; pins 1-14 on the left, 15-28 on the right.

Pins 1-27-28 - highlighted yellow - are all connected to +5 volts. You can see that 26-27-28 are common, and pin 1 is is on the large +5VDC trace on the left.

Pins 2 and 23, highlighted green, are common. Pin 23 passes through the highlighted via and then, on the top of the board, there is a trace running across to pin 2 where I've drawn a green line. Hopefully this is standard across ZX81 boards, and simplifies the procedure for others as the job is half done already.

Also, it turns out I did not vacate pin 26 in my socket. I checked resistance on the EPROM from pin 26 to all other pins to ensure it is truly N.C as specified, so it is OK to leave it connected. I will edit my earlier post to reflect this.

I'm definitely interested in checking out an alternate basic ROM. I've also posted in hardware to ask for help on getting a 16K or 32K SRAM working, as I ran into trouble on the first attempt.
20200623_095601-flipped.jpg
Last edited by rmzalbar on Tue Jun 23, 2020 7:30 pm, edited 4 times in total.
User avatar
1024MAK
Posts: 4257
Joined: Mon Sep 26, 2011 10:56 am
Location: Looking forward to summer in Somerset, UK...

Re: Found a ZX81 and fixed it

Post by 1024MAK »

Welcome on board rmzalbar!

:D :D :D

Welcome to Sinclair ZX World :D

Mark
Moggy
Posts: 2810
Joined: Wed Jun 18, 2008 2:00 pm

Re: Found a ZX81 and fixed it

Post by Moggy »

.
Last edited by Moggy on Tue May 24, 2022 3:11 pm, edited 3 times in total.
Moggy
Posts: 2810
Joined: Wed Jun 18, 2008 2:00 pm

Re: Found a ZX81 and fixed it

Post by Moggy »

Excellent information there rmzalbar concerning the board voltages.

I'm now going to double check my issue one boards to see if they are the same and I've been doing this wrong if so life just got a whole lot easier. :lol:

Also apart from the various BASIC ROM images there is also FORTH both US and UK versions and an assembler ROM if memory serves so when you're ready just give a shout out and we can point you in the right direction and rest assured one of the gurus will most certainly sort out your RAM problem.

Thanks again for the info which I think should now be shown as the definitive way of wiring 2764 EPROM's for the ZX81. :D

EDIT.

Well bugger me with a fishfork!!

I have just checked a couple of issue ones and they are the same connection/voltage wise as your issue three!! Which begs the question did Sinclair do this with an eye on using EPROMs in times of chip shortages?

I can only assume I did something wrong way back then when measuring voltages/connections etc :oops: :oops: :oops:



Regards.

Moggy.
Last edited by Moggy on Tue May 24, 2022 3:14 pm, edited 1 time in total.
rmzalbar
Posts: 12
Joined: Mon Jun 22, 2020 5:07 am

Re: Found a ZX81 and fixed it

Post by rmzalbar »

Indeed I have a board that says "ISS 3" in the corner. So the connections are the same on your earlier one? Nice!

What happened to my post was that I edited it, and being new each post (or even edit) requires administrator approval, so that caused my post to disappear while pending that approval. It looks like I'm unrestricted now, though.

I got the 16k RAM mod to work as well (seems it was the SRAM at fault rather than my wiring) and I've already gone on to make the 32k mod using an AND gate, verified the memory is there and POKEable. I then tried out using my PC headphone/mic ports to save and load, and while I generated a WAV when saving, I couldn't get the ZX to recognize it when feeding it back in. I read around a little bit and it looks like it needs more amplification than modern stuff will deliver. I wonder if replacing the 220R resistor inside the ZX with a larger value would help?
Moggy
Posts: 2810
Joined: Wed Jun 18, 2008 2:00 pm

Re: Found a ZX81 and fixed it

Post by Moggy »

This is great news,a new and improved zeddy back on the road.

As a side issue I have removed the excess baggage from my EPROMs and all's well!

They do tend to be temperamental tape loaders which is why a good deal of us are using a device called the ZXpand+,which amongst other things uses SD cards for load and save. Demand for them is quite high and they tend to go as quickly as they are built and are sold through the site here... https://www.sellmyretro.com/

I believe the creator (Sir Morris) announces when he is going to build some more then takes pre-orders and as soon as they are built he ships them out so worth checking the above mentioned site now and then.

The 81 was meant to be used with the "shoe box" type cassette player recorder, using the earphone socket for loading which as you may appreciate has a reasonable amount of "punch". One method that has been suggested By f/m 1024MAK is to send your WAV into say a pair of PC desktop speakers then run a suitable cable from the EAR socket (that these speakers generally have fitted so as to regain said "punch") into the 81.

Obviously the stereo needs slimming down to mono but I get a feeling that's well within your capabilities.
As for the resistor I cannot say whether or not it would work but certainly worth a shot and I cannot see it harming anything.
User avatar
1024MAK
Posts: 4257
Joined: Mon Sep 26, 2011 10:56 am
Location: Looking forward to summer in Somerset, UK...

Re: Found a ZX81 and fixed it

Post by 1024MAK »

Photos showing the ROM on both an issue 1 ZX81 board and on a ZX81/TS1000 issue 3 board:
Issue 1 PCB topside showing the ROM
Issue 1 PCB topside showing the ROM
Issue 1 PCB bottom side showing the ROM connections
Issue 1 PCB bottom side showing the ROM connections
Issue 3 PCB topside showing the ROM
Issue 3 PCB topside showing the ROM
Issue 3 PCB bottom side showing the ROM connections
Issue 3 PCB bottom side showing the ROM connections
As these particular boards have the 24 pin DIL ROM IC soldered in rather than having a 28 pin DIL socket soldered to the board, it’s possible to see some of the tracks and connections to socket pins 1, 2, 27 and 28 :)

As to the compatibility between different EPROMs and the pin-out on the board, back in the early 1980s there were a number of different pin-outs in use for both ROMs and EPROMs. Not all manufacturers of EPROMs used the same pin-out that we are now used to and which is used by 27xxx series EPROMs.

So yes, the ROM and RAM pin-outs on the board were designed for as much flexibility with sourcing parts as was possible while not making it too complex (complex means more expensive).

And there was a series of EPROM chip that could just be plugged in without any wiring changes being needed. But these went obsolete long ago.

Mark
Moggy
Posts: 2810
Joined: Wed Jun 18, 2008 2:00 pm

Re: Found a ZX81 and fixed it

Post by Moggy »

Thanks for this Mark, I learn something new every day and make life easier into the bargain. :lol:
User avatar
1024MAK
Posts: 4257
Joined: Mon Sep 26, 2011 10:56 am
Location: Looking forward to summer in Somerset, UK...

Re: Found a ZX81 and fixed it

Post by 1024MAK »

I just edited my post above!
Post Reply