Internal RAM upgrade

Discussions about Sinclair ZX80 and ZX81 Hardware
nickarmstrong1969
Posts: 2
Joined: Wed Feb 01, 2017 7:55 pm

Internal RAM upgrade

Post by nickarmstrong1969 » Thu Feb 02, 2017 1:17 am

After 30 years or so, I feel the need to revive my much loved ZX-81.

Although I have a 16k RAM pack, I would like to do an internal memory upgrade, to avoid RAM Pack wobble. I've found lots of discussion in previous threads on this, but no solution that exactly fits my requirements.

My requirement is to expand the internal memory to 32k so I can write larger BASIC programs. I don't want to write machine code, have battery backed RAM, Hi-Res graphics or maintain compatibility with existing software that depends upon ROM or RAM echoes. I would like to use the existing RAM socket on the ZX81 main board, to reduce wiring and increase reliability.

I can install a 32K Ram chip on the existing board like this :
http://www.zx81.de/english/32k-rame.htm
However the simple address decoding leaves the memory scattered through the address space; one block in 16k to 32k and another from 48k to 64k. This seems to preclude BASIC programs greater than 16k. I guess it also doesn't deal with the ROM echoes.

I've conclude that the best scheme is have the 32k sit in the 16k to 48k part of the address space. On the reasoning that basic programs cannot start at any location below 16k and must be located in a contiguous block of memory.

My hope is that I can use a 74LS138 3-to-8 decoder, connected to the highest 3 address lines, each output lines represents an 8k block, all the way from 0 to 64K. If I AND output lines 2,3,4 and 5 together I'm hoping to get the correct RAMCS for the 62256. placing the memory in the 16 to 48k range. Similarly output line 0 should go low at addresses between 0 and 8k, so should be correct for ROMCS ? Allowing for all ROM echoes to be suppressed.

My questions are :

- Does the above scheme seem workable and sensible ?
- What control signals should I use to enable the 74LS138 chip ?

Thanks in advance for your help. First post so please go easy on me :-)

Nick

User avatar
siggi
Posts: 875
Joined: Thu May 08, 2008 9:30 am
Location: Dauernheim, Germany
Contact:

Re: Internal RAM upgrade

Post by siggi » Thu Feb 02, 2017 2:14 pm

Hi Nick
Wilf Rigter used a 74HC251 as decoder, which makes memory decoding very flexible. Here as an example his 32K ram expansion (upper half of schema):
http://www.user.dccnet.com/wrigter/inde ... XRAMIO.htm

http://www.user.dccnet.com/wrigter/inde ... mories.htm

Regards
Siggi
My ZX81 web-server: online since 2007
http://zx81-siggi.endoftheinternet.org/index.html

nickarmstrong1969
Posts: 2
Joined: Wed Feb 01, 2017 7:55 pm

Re: Internal RAM upgrade

Post by nickarmstrong1969 » Thu Feb 02, 2017 2:48 pm

Hi Siggi

That's perfect. Just one chip for chip selection with simple wiring. Exactly what I am after.

Many Thanks


Nick

rom475
Posts: 12
Joined: Wed Jan 17, 2018 10:26 pm

Re: Internal RAM upgrade

Post by rom475 » Mon Feb 05, 2018 3:33 am

I found 2 64K upgrade wihich are of Wilf's and thought they would be easier to construct and implement...
Attachments
64Kintram.gif
64K with Rom Patch and HRES config.
64Kintram.gif (9.52 KiB) Viewed 1220 times
64K newdecoder.gif
64K Ram Upgrade
64K newdecoder.gif (8.62 KiB) Viewed 1220 times

User avatar
siggi
Posts: 875
Joined: Thu May 08, 2008 9:30 am
Location: Dauernheim, Germany
Contact:

Re: Internal RAM upgrade

Post by siggi » Mon Feb 05, 2018 11:55 am

The only disadvantage of this solutions is, that the signal for ram-A15 is generated very simple. Thus the ram cannot be used for running machine code above 32K (that would require a more complex generation of ram-A15).

In additon to that I would not connect ram-/OE to ram-/CE, but would use /RD AND /RFSH (using diode logic) for ram-/OE to avoid possible timing problems when writing data into ram.

Siggi
My ZX81 web-server: online since 2007
http://zx81-siggi.endoftheinternet.org/index.html

rom475
Posts: 12
Joined: Wed Jan 17, 2018 10:26 pm

Re: Internal RAM upgrade

Post by rom475 » Mon Feb 05, 2018 9:20 pm

So what would you suggest for a bare bones 64K upgrade to a Zeddy??
I am building a parabot,(everyone else would call it a robot),I have a
8K NVRAM board already completed that will be in the 8192-16384 region to
which I will use for the machine code routines...

User avatar
siggi
Posts: 875
Joined: Thu May 08, 2008 9:30 am
Location: Dauernheim, Germany
Contact:

Re: Internal RAM upgrade

Post by siggi » Tue Feb 13, 2018 10:51 am

rom475 wrote:
Mon Feb 05, 2018 9:20 pm
So what would you suggest for a bare bones 64K upgrade to a Zeddy??
I am building a parabot,(everyone else would call it a robot),I have a
8K NVRAM board already completed that will be in the 8192-16384 region to
which I will use for the machine code routines...
As written above: this memory expansion does not allow to run machine code above 32K. If your code is located at 8-16K, that would not be a problem for your robot program. Thus you could use this expansion, but you need to connect D1 (pin 3) of the 74HC251 to VCC/+5V (not to GND) to disable the ram expansion in address range 8-16K, where you already have your machine code in NVRAM.

If you don't need to show HIRES prictures using this ZX81, you could connect only the Z80 signal /RD to the /OE input of the ram-chip to avoid the timing problem (during ram write cycles).

HTH Siggi
My ZX81 web-server: online since 2007
http://zx81-siggi.endoftheinternet.org/index.html

rom475
Posts: 12
Joined: Wed Jan 17, 2018 10:26 pm

Re: Internal RAM upgrade

Post by rom475 » Tue Feb 13, 2018 9:43 pm

Thank you for the info...

I'm looking at the barebones 64K upgrade without the Rom Patch is that the same diagram
you are referencing?? Also would it be necessary to connect the /RD to the /OE?? Just trying
to keep board size and designing to a minimum...I am assuming that all the diodes referenced
are 1N34A and not !N4148/1N914's??

McKlaud
Posts: 195
Joined: Tue Dec 19, 2017 10:02 pm
Location: St Albans, UK

Re: Internal RAM upgrade

Post by McKlaud » Tue Feb 13, 2018 10:12 pm

In my mind you can use 1N4148 silicon diodes instead of germanium units like 1N34A. 1N34A can be also replaced them with Schottky type like BAT85 in this application.
Claudius
----------

User avatar
siggi
Posts: 875
Joined: Thu May 08, 2008 9:30 am
Location: Dauernheim, Germany
Contact:

Re: Internal RAM upgrade

Post by siggi » Wed Feb 14, 2018 11:07 am

Not all!
At least the diodes connected to /M1 and /RFSH should be Germanium or Schottky (to keep the logic LOW level low enough).
My ZX81 web-server: online since 2007
http://zx81-siggi.endoftheinternet.org/index.html

Post Reply