6502.org Forum  Projects  Code  Documents  Tools  Forum
It is currently Fri Nov 01, 2024 11:35 pm

All times are UTC




Post new topic Reply to topic  [ 29 posts ]  Go to page 1, 2  Next
Author Message
 Post subject: Harry The Bastard
PostPosted: Wed Oct 11, 2006 4:43 pm 
Offline

Joined: Fri Jul 28, 2006 12:12 am
Posts: 27
Can anyone explain how the clock circuit works. I can't seem to find Harry The Bastards website anywhere, which supposedly will explain it.

Thanks


Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: Wed Oct 11, 2006 9:07 pm 
Offline

Joined: Tue Jul 05, 2005 7:08 pm
Posts: 1042
Location: near Heidelberg, Germany
ahmmm... which clock circuit? The 6502 takes a clock signal as input, and does not have a clock circuit itself.

Andre


Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: Thu Oct 12, 2006 1:42 am 
Offline

Joined: Fri Jun 27, 2003 8:12 am
Posts: 618
Location: Meadowbrook
www.archive.org has it on there, at least the code, dont know bout the rest....

_________________
"My biggest dream in life? Building black plywood Habitrails"


Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: Thu Oct 12, 2006 4:22 am 
Offline
User avatar

Joined: Fri Aug 30, 2002 1:09 am
Posts: 8535
Location: Southern California
kernal34, I think we need to know a little more precisely what you're looking for. Do you want to know how an oscillator works, or how the 65xx processor and bus uses the clock, or how to use the on-board oscillator on a 65c02, or something else?


Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: Thu Oct 12, 2006 2:46 pm 
Offline

Joined: Fri Jul 28, 2006 12:12 am
Posts: 27
I guess nobody caught the title....

"Harry The Bastard's" clock circuit is used in several of the projects on this sight, but no one explains how it works. They point you to his web site, but it doesn't work.


Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: Thu Oct 12, 2006 5:25 pm 
Offline
User avatar

Joined: Tue Mar 02, 2004 8:55 am
Posts: 996
Location: Berkshire, UK
He's referring to this circuit:
Image

_________________
Andrew Jacobs
6502 & PIC Stuff - http://www.obelisk.me.uk/
Cross-Platform 6502/65C02/65816 Macro Assembler - http://www.obelisk.me.uk/dev65/
Open Source Projects - https://github.com/andrew-jacobs


Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: Fri Oct 13, 2006 9:53 am 
Offline

Joined: Tue Jul 05, 2005 7:08 pm
Posts: 1042
Location: near Heidelberg, Germany
Considering that it uses half a '04 and additional board space for a crystal, I'd rather stay with my approach of using a clock generator (available in various frequencies) in a DIL14 case (with only the 4 edge pins used).
That's probably why I didn't catch it...

Andre


Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: Fri Oct 13, 2006 1:42 pm 
Offline

Joined: Fri Jun 27, 2003 8:12 am
Posts: 618
Location: Meadowbrook
That clock circuit is the standard crystal circuit. It is used on the arcade game Space Invaders. Stable and cheap to make. Basically, it is a simple loop with the signal inverting over one end of the loop to the other in a dynamic way. I dont pretend to understand exactly how it works, though.

http://www.hanssummers.com/radio/penning/index.htm
shows the schematic hand drawn

_________________
"My biggest dream in life? Building black plywood Habitrails"


Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: Fri Oct 13, 2006 8:10 pm 
Offline

Joined: Mon Mar 20, 2006 2:03 am
Posts: 24
Here's a page with some info
http://www.gaby.de/z80/uexosc.htm


Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: Sat Oct 14, 2006 4:09 pm 
Offline

Joined: Sat Jan 04, 2003 10:03 pm
Posts: 1706
It is essentially a 180-degree phase-shift oscillator -- in this configuration, a Colpitts oscillator. The two inverters provide (over-)unity gain for the otherwise analog signal coming from the crystal. The fact that it's over-unity gain means that the signal is being clipped at the Vcc/GND rails -- thus, a digital output. Inside the circuit, however, the crystal acts as a band-pass filter, selecting only the frequency of the desired oscillation. The signal thus fed back to the initial inverter should approximate a real sine wave.


Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: Mon Oct 16, 2006 8:37 am 
Offline

Joined: Mon Oct 16, 2006 8:28 am
Posts: 106
fachat wrote:
Considering that it uses half a '04 and additional board space for a crystal, I'd rather stay with my approach of using a clock generator (available in various frequencies) in a DIL14 case (with only the 4 edge pins used).
That's probably why I didn't catch it...

Andre

Hi, I'm a newb :)

Long time C64 user, pro software developer, wanting to get into 6502 hardware as a hobby now that I have settled down a bit in life.

I've been looking at the 65816's datasheet from WDC, and it specifies that the maximum clock slew must be 5ns. Most of the TTL oscillators I see on web stores quote slews of 10ns for the kind of clock speeds the 65816 is normally used at (ie sub-20MHz). Are you using some sort of clock waveform shaping, am I looking at the wrong parts, or is the datasheet a bit too conservative?


Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: Mon Oct 16, 2006 8:56 am 
Offline

Joined: Tue Jul 05, 2005 7:08 pm
Posts: 1042
Location: near Heidelberg, Germany
I'm currently not using the 65816. But you made a good point, I shall have to look into that when I get to the 65816.

Andre


Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: Mon Oct 16, 2006 3:06 pm 
Offline

Joined: Sat Jan 04, 2003 10:03 pm
Posts: 1706
Don't bother -- I can already answer this one, since I have built a 65816-based system already.

The answer is, anything slower than 5ns slew on the clock input WILL cause the CPU to perform in a very flakey manner. Expect many crashes, and even memory locations being overwritten randomly. In short, unless you're driving the clock input with F-series logic, don't even think it will work. Because it won't.

It is best to drive the clock input with one of those pre-packaged CMOS clock oscillator cans; most of those already meet the 5ns slew rate requirement (though just barely).


Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: Mon Oct 16, 2006 5:05 pm 
Offline
User avatar

Joined: Fri Aug 30, 2002 1:09 am
Posts: 8535
Location: Southern California
There's more discussion of the 5ns stuff at:
viewtopic.php?t=646
viewtopic.php?p=5655
viewtopic.php?t=786

although the last one has links to two other discussions that it's now saying don't exist:
http://www.6502.org/forum/viewtopic.php?p=895
http://www.6502.org/forum/viewtopic.php?t=195
so I'd like to find out from Mike what's happening-- what the numbers at the end mean, and if they change.


Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: Mon Oct 16, 2006 7:26 pm 
Offline

Joined: Mon Oct 16, 2006 8:28 am
Posts: 106
Thank you for the info! Sounds like the way to go then is a simple can TTL oscillator with say a 74F04 to shape the waveform? But then, except for the passives, we're sortof back to Harry's design...

One last question about Harry's design if I may. I'm a bit confused by the combination of digital and analog circuitry he uses so I can't tell - is the resulting clock frequency going to be that of the crystal, or half it? Also, I'm thinking of making my first board run at 4 MHz or below, so I don't have to worry about RF interference between circuit traces (or more likely wires in my wirewrap :)) Could his circuit handle that frequency as-is? I suspect so, but from reading this forum it seems like the clock is the 65xx's achilles heel (and linear electronics is not my forte right now) so I might as well save myself the headache and ask :)


Top
 Profile  
Reply with quote  
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 29 posts ]  Go to page 1, 2  Next

All times are UTC


Who is online

Users browsing this forum: No registered users and 12 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to: