RetroBrew Computers Forum
Discussion forum for the RetroBrew Computers community.

Home » RBC Forums » General Discussion » z80 speed switch (Looking for circuit)
z80 speed switch [message #6358] Tue, 28 May 2019 06:50 Go to next message
b1ackmai1er is currently offline  b1ackmai1er
Messages: 396
Registered: November 2017
Senior Member
HI Guys,

I am looking for a circuit for the z80 to switch from full speed to half speed clock rate i.e. 8Mhz to 4MHz

If you've seen a desing for one could you let me know.

Thanks.
Re: z80 speed switch [message #6360 is a reply to message #6358] Tue, 28 May 2019 10:12 Go to previous messageGo to next message
norwestrzh is currently offline  norwestrzh
Messages: 190
Registered: November 2015
Senior Member
I've always used the 74LS393 with a jumper header so that you can use a shorting block to select the clock rate.

Avoid real switches -- they seem to radiate lots of noise.

Roger

edit: Here's a circuit that I've used to set the baud rate of serial ports. The top position of the jumper header gives 38,400, the next one down gives 19,200, the next 9,600, etc.

/forum/index.php?t=getfile&id=1416&private=0
  • Attachment: LS393.png
    (Size: 6.96KB, Downloaded 692 times)

[Updated on: Tue, 28 May 2019 10:37]

Report message to a moderator

Re: z80 speed switch [message #6362 is a reply to message #6360] Tue, 28 May 2019 15:31 Go to previous messageGo to next message
b1ackmai1er is currently offline  b1ackmai1er
Messages: 396
Registered: November 2017
Senior Member
Fantastic, thanks for the circuit.

I found this one (74LS74 based) http://www.user.dccnet.com/wrigter/index_files/turbo.htm

This looks like it would be suitable for connecting to a single input line to control the speed but am not if this requires the use of a halt sequence to ensure there is a smooth transition without crashing.

Regards Phil
Re: z80 speed switch [message #6366 is a reply to message #6362] Thu, 30 May 2019 03:26 Go to previous messageGo to next message
kman is currently offline  kman
Messages: 45
Registered: February 2019
Location: Germany
Member
Hi,
I've found the attached paper regarding glitch-free clock-switching a couble of month ago in the web. May be that it gives some additional help.

cheers
Kurt
Re: z80 speed switch [message #6386 is a reply to message #6366] Sun, 09 June 2019 20:42 Go to previous messageGo to next message
b1ackmai1er is currently offline  b1ackmai1er
Messages: 396
Registered: November 2017
Senior Member
Hi Kurt,

Thanks for the excellent article.

Going to try this out.

Regards Phil.

Re: z80 speed switch [message #6389 is a reply to message #6386] Sat, 15 June 2019 07:00 Go to previous messageGo to next message
b1ackmai1er is currently offline  b1ackmai1er
Messages: 396
Registered: November 2017
Senior Member
Hi, I am trying to implement this circuit on the sbc-v2 by replacing the nand gate IC1b with a 74ls06 inverter.

However, I can't see any output from this inverter. I assumed bad chip so I replaced it but it did not resolve the problem. Swapped to another unit on the device but no improvment either.

Is there something unusual about the 74LS06 with the open collector outputs that would be causing this?

/forum/index.php?t=getfile&id=1421&private=0

/forum/index.php?t=getfile&id=1422&private=0

Thanks.
Re: z80 speed switch [message #6390 is a reply to message #6389] Sat, 15 June 2019 09:59 Go to previous messageGo to next message
kman is currently offline  kman
Messages: 45
Registered: February 2019
Location: Germany
Member
Hi,
try to connect a Pull-Up resistor from PIN12 U26F to Vcc as shown in the attached screenshot.
That should solve your problem. The reason is, that the clock input of U28B need a rising edge as clock.
Without the resitor, there is no working load for the driving output transistor in U26B and hence no signal.

cheers
Kurt
Re: z80 speed switch [message #6391 is a reply to message #6390] Sat, 15 June 2019 14:26 Go to previous messageGo to next message
norwestrzh is currently offline  norwestrzh
Messages: 190
Registered: November 2015
Senior Member
Kurt is correct! Always put a pull-up on O.C. gates. They will go to ground OK, but they don't truly go to Vcc without a pull-up.

Roger
Re: z80 speed switch [message #6392 is a reply to message #6391] Sun, 16 June 2019 00:07 Go to previous messageGo to next message
kman is currently offline  kman
Messages: 45
Registered: February 2019
Location: Germany
Member
Hi,
a direct comparison of the internal schematics of a 74LS04 inverter and a 74LS06 OC-inverter
shows the reason why a OC stage needs a resitor. If you have one, you can replace the '06 by
a '04. That saves you one or more resitores in your circuit. See the attachment for the internal
schematics of the inverters.

cheers
Kurt
Re: z80 speed switch [message #6393 is a reply to message #6391] Sun, 16 June 2019 00:10 Go to previous messageGo to next message
b1ackmai1er is currently offline  b1ackmai1er
Messages: 396
Registered: November 2017
Senior Member
Thanks guys,

The spare inverter gate already was connected to a 4.7k pullup and I had bypassed this. I reinstalled but still did not see an output. Then I tried your 1K suggestion and can now see an output. Unfortunately the output is only about 1.5v which is probably not going to be high enough to be recognized by anything. Is this normal?

Should I try a lower value? i.e. 470R

I'll give it a try and report back.

There is a spare 3-input nand gate available which I can try - maybe that is a better approach.

Regards Phil
Re: z80 speed switch [message #6394 is a reply to message #6393] Sun, 16 June 2019 07:10 Go to previous message
b1ackmai1er is currently offline  b1ackmai1er
Messages: 396
Registered: November 2017
Senior Member
Hi Kurt,

Thanks for uploading the pictures of the two gates but unfortunately I do not have enough electronics experience to understand them. All I can decypher is that one place the load in parallel with the transistor and the other in series.

However, good news although I could not see a signal on the output of the inverter once I reconnected the 4K7 pullup, when I reconnected the circuit it worked!

/forum/index.php?t=getfile&id=1426&private=0

/forum/index.php?t=getfile&id=1427&private=0

So this is how the layout looks on the sbv-v2-004 design.

/forum/index.php?t=getfile&id=1428&private=0

Thank you for your help.
Previous Topic: Mike's 2nd 68K
Next Topic: Fake SIPEX SP3232E (RS232 Tx/Rx)


Current Time: Wed Apr 17 18:39:43 PDT 2024

Total time taken to generate the page: 0.00822 seconds