News:

Printed Amstrad Addict magazine announced, check it out here!

Main Menu
avatar_radu14m

Overclocking CPC @6/8 Mhz

Started by radu14m, 22:05, 24 December 12

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

radu14m

I think that it"s not a new ideea, but i could't find a topic with this subject.
Just wonder if this is possible and what modifications are needed.
By achieving this, the CPC would be at the same Mhz level to Atari ST and Commodore Amiga :)

fano

Some of us already tried and there are more about this  ;)
6 MHz CPC - CPCWiki
"NOP" is the perfect program : short , fast and (known) bug free

Follow Easter Egg products on Facebook !

radu14m

is there a detailed DIY with pictures about this mod ?
On the cpcwiki is only a short description...

TotO

#3
The problem is that the 6MHz was done by changing the 16MHz clock with a 24MHz one... That mean all the system is overclocked.
So it is no more compatible with the existing CPC (sound, floppy, display...)

Another way may be to replace the Z80A with a Z80B (no CMOS 6MHz version) and generate a dedicated 8MHz signal to overclock it only.
From the 4MHz clock (Z80 pin6) or the 16MHz main clock (GA pin24) if the signal timing stay OK between the both IC...

But I suggest that some programs (like demo) counting NOP, will no more work properly. No?
"You make one mistake in your life and the internet will never let you live it down" (Keith Goodyer)

fano

#4
Quote from: TotO on 10:02, 25 December 12Another way may be to replace the Z80A with a Z80B (no CMOS 6MHz version) and generate a dedicated 8MHz signal to overclock it only.
From the 4MHz clock (Z80 pin6) or the 16MHz main clock (GA pin24) if the signal timing stay OK between the both IC...
Sadly, that does not work on the CPC.Weirdly, That works with 16Mhz/3 (but it seems to be slower maybe because GA arbitration on memory) but not more, maybe some other components do not support faster CPU (maybe some electronician can say more about this)
On a +, the machine boots with some cartridges but crashes later.

Measuring performance is not easy, i used interrupts because they rely on Vsync and Hsync and, in theory, they remain identical with the new CRTC R0 config (still 312 lines and 64us/line)
Problem with NOP counting is dependant of the CPU clock.
BTW, more complex testing program is not easy as it is not possible to read standart discs.I think i'll experiment more with ROM board if it wants to work with a 24Mhz CPC.

Quote from: radu14m on 08:27, 25 December 12
is there a detailed DIY with pictures about this mod ?
On the cpcwiki is only a short description...
This is just because there is nothing that need a longer description.Just unsolder the 16mhz crystal and replace it with a 24mhz crystal.I can post a picture of the PCB if you want , or TFM if he added a selector.
"NOP" is the perfect program : short , fast and (known) bug free

Follow Easter Egg products on Facebook !

TotO

#5
Yes, I forget to speak about the RAM.
Most CPC get 150ms RAM chip, but some have 120ms embedded. May be that allow to work...

But sure, like we spoke 1 year ago, the overall performances are not proportional to the overclock. (thank you GA)
The interesting thing about the 24MHz way is to get a better overscan mode with 256x256 / 288x224 screens for games.


"You make one mistake in your life and the internet will never let you live it down" (Keith Goodyer)

radu14m

#6
It"s clear that not all components are able to run at higer frecvency than 4.77Mhz.
Those components who are not suitable, can be replaced with better ones ?
I know, sound easy but it"s not.

Maybe the plus CPC's are more flexible for this mod, due to the fact that they were redesign significantly and enhanced too.

Some pictures with the mod would be nice too.

I imagine something like this:
All the software changes that need to be done in order to run and disply properly the application on higer frecvency can be writen into a special rom/roms.
The frecvency should be selectable at boot time.
With this overclocking possibility, we can have in our CPC the entire PCW familly too :)
A one in all solution, from 4Mhz to 16 Mhz......later some additional memory, an HxC, HDD ...ok i start already to dream  8)
8) 8) 

steve

Would it be possible to make a small pcb that plugs into the cpu socket, the pcb would have a faster z80 with clock circuit, cache ram and wait state generator, I remember something similar was made for the amiga 500 but with a 68000 obviously.

Sykobee (Briggsy)

In my opinion, you might as well take an FPGA CPC implementation and tweak it to get a dream CPC (that is still clearly a CPC, not something new). A key feature would be supporting the standard CPC mode, with a way to kick into the advanced mode (much like the C64 SuperCPU board starts up in 1MHz 6502 compatability mode).


On a standard CPC you would probably need a CPU+RAM solution that plugs into the Z80 socket, with some logic to allow the rest of the system to access the on-board RAM (rather than the original CPC RAM) as if nothing had changed. It's probably possible, for a hardware guru. This would probably take the form of an FPGA implementing a Z80 core, with the on-board SRAM being used for system memory, and more of the FPGA providing a compatible interface with the rest of the system.  However in the CPC IIRC the ULA interfaces to the RAM, not the CPU, as the ULA provides support for memory banks - this probably makes things horribly complicated.

TFM

#9
Quote from: radu14m on 08:27, 25 December 12
is there a detailed DIY with pictures about this mod ?
On the cpcwiki is only a short description...
When I did the  6 MHz Mod two decades ago it was just easy, so no detailed description is needed:
- Replace the Z80A with a Z80B (or higher)
- Put a 24 MHz crystal on the 16 MHz crystal and add a switch that allows to switch between them.

Problems: It doesn't work with all motherboards

Quote from: TotO on 10:53, 25 December 12
The interesting thing about the 24MHz way is to get a better overscan mode with 256x256 / 288x224 screens for games.
That's probably the most important point :)

Data transfer: I used the Inicron accumulator buffered RAM-disc to transfer files and play Starfox, Nebulus and much more like never before ;-)

And yes: You have to adjust you monitor depending on the program you use with 6 MHz.
TFM of FutureSoft
Also visit the CPC and Plus users favorite OS: FutureOS - The Revolution on CPC6128 and 6128Plus

TFM

Quote from: steve on 22:06, 25 December 12
Would it be possible to make a small pcb that plugs into the cpu socket, the pcb would have a faster z80 with clock circuit, cache ram and wait state generator, I remember something similar was made for the amiga 500 but with a 68000 obviously.
You talk about the Sprinter card for the Joyce PCW  ;)
TFM of FutureSoft
Also visit the CPC and Plus users favorite OS: FutureOS - The Revolution on CPC6128 and 6128Plus

steve

If I could find a sprinter card, would it work in a cpc?

TFM

Not without some mods IIRC. But the principle itself is of interrest.
TFM of FutureSoft
Also visit the CPC and Plus users favorite OS: FutureOS - The Revolution on CPC6128 and 6128Plus

radu14m

I didn't kow about the sprinter card...yes, something like this i imagine  ;D

arnoldemu

Wasn't there a turbo mode on the TREX hardware implementation of the CPC?

How did that do the turbo?

My games. My Games
My website with coding examples: Unofficial Amstrad WWW Resource

MacDeath

The Amstrad PCW16 is basically a Z80 Amstrad machine at 16mhz with all the video modes of a proper Amstrad CPC...


ok, i'm out... (still couldn't it emulate the Amstrad CPC ?)

Sykobee (Briggsy)

Sadly the screen memory layout is sane, and also has the PCW per-scanline pointer system ("roller ram"), and in the colour modes the bit layout within a byte is also sane (AAAABBBB, not ABABABAB; AABBCCDD, not ABCDABCD).  It really is an enhanced PCW, rather than a CPC++ refactored into a word processor.


Anyway ... easy vertical scrolling (and stretchy demo effects) because of the roller ram. I don't know about horizontal scrolling, even if the roller ram system let you specify the exact starting byte for a scanline, it would still be byte oriented scrolling rather than pixel oriented scrolling.


From the screenshots of the PCW16 attached to a VGA monitor, it appears that the system also has an extensive colour palette to pick from?

arnoldemu

Quote from: Briggsy on 22:15, 26 December 12
Sadly the screen memory layout is sane, and also has the PCW per-scanline pointer system ("roller ram"), and in the colour modes the bit layout within a byte is also sane (AAAABBBB, not ABABABAB; AABBCCDD, not ABCDABCD).  It really is an enhanced PCW, rather than a CPC++ refactored into a word processor.


Anyway ... easy vertical scrolling (and stretchy demo effects) because of the roller ram. I don't know about horizontal scrolling, even if the roller ram system let you specify the exact starting byte for a scanline, it would still be byte oriented scrolling rather than pixel oriented scrolling.


From the screenshots of the PCW16 attached to a VGA monitor, it appears that the system also has an extensive colour palette to pick from?
colour palette is the same as the cpc's.
modes are the same, although arranged as nibbles rather than interleaved bits.
My games. My Games
My website with coding examples: Unofficial Amstrad WWW Resource

TFM

#18
You guys are great in getting off topic  :P

Quote from: arnoldemu on 16:14, 26 December 12
Wasn't there a turbo mode on the TREX hardware implementation of the CPC?

How did that do the turbo?
That's not a CPC, that's another Chip simulating a Z80, so you can choose speed freely. Check out its HP.
TFM of FutureSoft
Also visit the CPC and Plus users favorite OS: FutureOS - The Revolution on CPC6128 and 6128Plus

ZbyniuR

Maybe my questions are naive because I'm not an electronics engineer. Maybe just stick the heatsink on the processor, overclocked by 100% and use VGA monitor to catch the synchronization. Although I do not know whether or not it would be necessary change memory into faster .
Or is it possible to overclock the only processor by 100% and leave the rest of the main board normal? On the Amiga 500, such methods works.
Or by an adapter insert Zilog eZ80. Apparently, despite the 24bit registers is compatible with Z80, and performs commands in 4 times less cycles. So in theory, the CPC would be 4 times faster, even without changing the frequency.
What you think about it? Do you know someone who already tried something like this?
In STARS, TREK is better than WARS.

TotO

On A500, this method (doubling the clock) allow a non sinificative gain. (around 15%)
Here, it's exactly the same... +50% speed allow 7% gain... Because, in both case, the RAM is not enough faster to take advantage on this hack.
You may have problem with the PPI too... Because, it will not work faster to drive properly the peripherals.
"You make one mistake in your life and the internet will never let you live it down" (Keith Goodyer)

Bryce

For many reasons, this unfortunately wouldn't work. At least not az 8MHz. If the Z80 was running at 8MHz, the Gate Array would need to be running at 32MHz and I doubt it can handle that. Several other parts that run at 4MHz would also have problems at 8MHz.

Bryce.

rpalmer

The only means by which the Z80 can/may be sped up is with replacing the RAM with much faster SRAM ones, feeding the Z80 with 8Mhz directly (rather than from the VGA) and replacing the ROMs with faster ones as well.

The RAM would not need any refresh by the VGA (or DRAM access controls), so the only issue might be with the RAM configuration since the VGA does control it somewhat.

If the above were possible, the increased speed would only be of limited use anway, since sound would different and disc access might prove an issue.

However, for general program execution like games, there maybe a gain in performance like playability. Also gains might allow for Video playback with quicker/smoother screen updates or even MP3 playback.

rpalmer

TotO

#23
QuoteThe only means by which the Z80 can/may be sped up is with replacing the RAM with much faster SRAM ones, feeding the Z80 with 8Mhz directly (rather than from the VGA) and replacing the ROMs with faster ones as well.
You can't replace the DRAM with faster SRAM. You need DRAM too... And don't forget that the GatteArray is the master in board, not the Z80.

QuoteThe RAM would not need any refresh by the VGA (or DRAM access controls), so the only issue might be with the RAM configuration since the VGA does control it somewhat.
You are speaking about an ideal computer, not about the CPC...
The GateArray get control over the CPU for reading the RAM content. You can't avoid that.

QuoteIf the above were possible, the increased speed would only be of limited use anway, since sound would different and disc access might prove an issue.
But, it is not... And you have to change the PIO too... Finaly you change all the computer, only to get more CPU power for doing... What? Nothing... Better, to use an other computer! ;)

QuoteHowever, for general program execution like games, there maybe a gain in performance like playability. Also gains might allow for Video playback with quicker/smoother screen updates or even MP3 playback.
Just in dream...
"You make one mistake in your life and the internet will never let you live it down" (Keith Goodyer)

ralferoo

Theoretically, you could put a faster Z80 and some SRAM on a daughterboard that fits into the old Z80 socket.

There are numerous technical problems to overcome though. The clocks would need to be very accurately synchronised, so you'd need a PLL not a crystal. You'd need to override the WAIT' signal generated by the gate array so as to not be stalled all the time, and you'd want to generate your own WAIT' signal anyway to access any of the RAM/ROM/IO devices on the mainboard, because otherwise the CPU would try to access data before the gate array presents the data to it.

As soon as you start considering that any memory that's being written to in the base 64K (which is where almost everything needs to run from) could conceivably be being using as screen memory and so would need to be slowed down to a 1us access pattern anyway.

In short, it's a very technically difficult job and even if you got it to work, you'd only speed up access to the local RAM that could only be used as a banked RAM expansion. It's really not worth even thinking about doing.

That said, you could build a CPC-like system from scratch but it'd be a complete redesign.

Powered by SMFPacks Menu Editor Mod