News:

Printed Amstrad Addict magazine announced, check it out here!

Main Menu

Writing to GX4000 / plus cartridge space.

Started by SainT, 14:23, 27 January 14

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

SainT

Does anyone know what happens when you write to CPCplus / GX4000 cartridge space?


I'm hoping the address / data bus all get the appropriate signals applied to them, but /CE is not lowered. If that's the case I can actually detect this with a few key writes using a predefined sequence and then allow the plus/GX4000 to write to SRAM mapped to the cartridge area using a small CPLD as an interface.


I've been playing around with the idea of a SD based SRAM cartridge for the GX4000 for a while, but my original idea didn't pan out (not cheap enough). I've also been playing around with ideas for a Jaguar SD SRAM cart, which I'm mostly done on the PCB layout now, and it got me thinking about the GX4000 / plus again. On the Jag I use the above method of controlling the reading of the SD card and writing of the SRAM using the host machine. The CPLD acts as an SPI controller and general interface chip. The jag is a bit easier as it brings the full bus out to the cartridge.


If anyone has tried this, I'd be interested to hear. Otherwise I'll have to break out the logic sniffer later and see what happens...

Bryce

I've tried something similar. Your biggest problem is that the cartridge doesn't have a /WE ppin, so you have to use some trickery to get around that.

Bryce.

SainT

Quote from: Bryce on 14:40, 27 January 14
I've tried something similar. Your biggest problem is that the cartridge doesn't have a /WE ppin, so you have to use some trickery to get around that.

Bryce.


Yeah, the lack of /WE is the only thing making this non-trivial. As long as the address and data from the write make it onto the bus (which I hope you are confirming there Bryce!), I'll be happy with that. The CPU clock comes out to the cartridge at least, which is handy.


I'll have a play with the logic sniffer I think and see what happens... :)


Oh, and one question on the AC line filter for upgrading a 464+ with FDC, where did you get yours from Bryce? Had a quick search but couldn't find anything similar. Just going to knock myself up a 128KB SRAM replacement for the DRAM on the mainboard, and I've got most of the other bits now. I figure someone is going to want a replacement for the 41464 eventually (getting harder to find at a reasonable price now), so I've been meaning to come up with a replacement.




Bryce

Take your pick: Funkentstördrosseln, Ringkern bei reichelt elektronik
I think I chose a 100µH 1A part. The CPC had a 150µH 2A component as far as I can remember, but the wire on that was too thick for the hole in the PCB. Although before I fitted it a just bridged the pins and that seemed to work fine too.

Yes, the address and data lines all reacted fine for write statements as far as I can remember.

Bryce.



TFM

Quote from: SainT on 14:23, 27 January 14
Does anyone know what happens when you write to CPCplus / GX4000 cartridge space?


Whatever you will write to the ROM space will ultimately (also) end up in RAM. So be careful not to overwrite your program.

TFM of FutureSoft
Also visit the CPC and Plus users favorite OS: FutureOS - The Revolution on CPC6128 and 6128Plus

SainT

Quote from: TFM on 21:19, 27 January 14

Whatever you will write to the ROM space will ultimately (also) end up in RAM. So be careful not to overwrite your program.



Ahh, yes, thanks for reminding me of that. So the RAM is shadowed under the ROM space for writes.

Due to the new ROM paging for the cartridge on the plus, is it possible to have more than 128kb of RAM? And is there much point, either?

Just thinking about replacing the 64kb internal RAM with SRAM (mainly due to availability of 41464 chips... and for fun), and you can get 512kb SRAM in the same chip package as 128kb for very little. I made a nice 512kb SRAM upgrade for the Enterprise 64 like this.

TFM

Well, this is as far as I know...


- The Plus can use all 512 KB RAM expansions for the normal CPC (external at the expansion port).
- The regular Plus Cartridge can provide up to 512 KB of ROM
- The Plus can use up to 4 MB of ROM taken all together, the Cartridge ROM always starts at block 128 (each block is 16 KB in length) and upwards...


- I don't know if Jareks 4 MB internal RAM expansion for the CPC 6128 can also be used for the 6128 Plus, I assume it would need some modifications, since the hardware is not completely identical.


S-RAM is a great idea, you can buffer it and when using RDOS use a 444 KB RAM disc for Basic and CP/M (when having 512 KB expansion RAM).


Bryce an TotO know more about all that  ;)

TFM of FutureSoft
Also visit the CPC and Plus users favorite OS: FutureOS - The Revolution on CPC6128 and 6128Plus

arnoldemu

Quote from: SainT on 22:32, 27 January 14
Ahh, yes, thanks for reminding me of that. So the RAM is shadowed under the ROM space for writes.
I use this fact for my rom/cart filesystem.
My games. My Games
My website with coding examples: Unofficial Amstrad WWW Resource

SainT

Ok, this is quite interesting. Is "external" RAM faster than the internal RAM? Ie. does it use the same wait states for external bus access as it does to the internal RAM which can also be accessed by the CRTC? Certainly with the Enterprise, there is a 64K section shared by the video chip, all other RAM does not share the same wait state penalties, and as such you couldn't replace all RAM with one chip. In the case of the CPCplus it would appear the internal 128K at least can be replaced as one. But could I add 512K with one chip without conflict?


I take it on the ASIC CA14-18 are the output page address for bus access with A0-A15 being the Z80 bus, with /ROM brought low when accessing the cartridge space, but left high for normal expansion bus access?


Hmm, looking like this is probably not sensible as the internal RAM access and external don't share the same bus.


An internal 128K replacement board looks easy enough though, buffer the row, access on CAS while setting an address bit based on the CAS line.


Is there likely to be any interest if I create a 128K SRAM replacement for the plus? I'm not sure how (un)-reliable the 41464's are, but they will eventually become impossible to source for sensible money. It's likely to come in at about £15 though I'm guessing, so currently its still cheaper to source 4x 41464's...

Bryce

The external RAM will have the same wait state as the internal RAM, so it won't be faster. Your description of the operation is correct. However, attaching a memory expansion to the cartridge port has several dis-advantages. It will only work on the Plus, whereas adding the RAM to the expansion port means you can use it on any CPC. Also, you'll need to add an ACID and a ROM to your expansion, otherwise the Plus won't start.

Bryce.

TFM

#10
The point is ... THE RAM AND ROM OF THE CPC HAVE NO WAIT STATES  :laugh: :P :) :) :)  Oh what a good day!  :) :) :) [nb]Ok, the cpu commands get prolonged to the full mikrosecond, but that's not due to lack of speed of the RAM itself.[/nb]



The CRTC can only access the first 64 KB of RAM, except you do replace the corresponding chips by chips with more RAM and use them as RAM expansion (done with CPC oG, don't know if done with the Plus).

TFM of FutureSoft
Also visit the CPC and Plus users favorite OS: FutureOS - The Revolution on CPC6128 and 6128Plus

Powered by SMFPacks Menu Editor Mod