Continue to Site

Welcome to our site!

Electro Tech is an online community (with over 170,000 members) who enjoy talking about and building electronic circuits, projects and gadgets. To participate you need to register. Registration is free. Click here to register now.

  • Welcome to our site! Electro Tech is an online community (with over 170,000 members) who enjoy talking about and building electronic circuits, projects and gadgets. To participate you need to register. Registration is free. Click here to register now.

Quartz crystal and stopwatch help needed

Status
Not open for further replies.

JimmyJoe

New Member
Hello.

As the title says, I would appreciate some help with the stopwatch I'm making.

This is what I've got so far:
**broken link removed**

TTLs will be in LS versions.
The bottom part is the divider, it gets the frequency from 3.2768 MHz (the frequency of the crystal I'll use) down to 100 Hz.
The upper part is, of course, the counter and display part.
The counters should count as they are supposed to (according to the simulator).

All the resistors are 330 Ohms.

The thing that bothers me most is - connecting the crystal instead of the 5V square wave source. I simply don't have the knowledge to do that and in the time I spent with my friend Google, I didn't manage to figure it out.
I found a few possible ways to connect the crystal, but according to the simulator, they either produce the wrong frequency or drop the voltage quite a bit.

I would appreciate some help with that.

The other thing I'd like to ask is - are the resistors of the right size, and am I missing any?

Any other concerns?
 
Firstly, that circuit is using 40 year old technology. It could be done in fewer ICs if you want to.

Secondly, simulators can't do crystals. Crystal oscillators only start because noise is picked up and amplified. If you do get the simulator to agree that the circuit oscillates, the simulator will be dividing time, voltage and current into a number of discrete levels. On counters or amplifiers, that simply doesn't matter, but on crystal oscillators it can easily give frequencies that are completely wrong.

I don't understand what you mean by "drop the voltage quite a bit."

TTL gates make lousy oscillators, because of the high input current that they take. I suggest that you make a Pierce crystal oscillator, either with a CMOS gate or an NPN transistor as the oscillator active component.
 
Here is how to make a reliable oscillator using a CMOS Hex Inverter.
 

Attachments

  • CMOSosc.pdf
    51.9 KB · Views: 463
holy cow thats alot of silcone.
get modern and go with a micro controller. save your self alot of headachs
An 8 digit display = if just a small display then use an LCD
entire circuit using one LCD, one pic chip, an osscilator unless you want dead on accuracy then a RTC module is needed.
counting resistors, less than 10 componets needed.
I have a simple pinewood derby timer that uses 4 LED 7 seg displays, one 18 pin pic, couple of resistors.
 
Apparently my last post didn't get posted even though it waited for over 24 hours to be posted, so I'll just rephrase what I've said there.

Diver300:
I'm aware it can be done in fewer ICs and that it is an old technology.
I'm really new in the world of electronics and only have limited experience in the simulator. This was supposed to be the first thing I'd really make. It is by no means permanent it is just a learning project and the parts in it are based on what I could easily obtain in a reasonable time line.

Since I posted the answer which didn't pass through, I did look around a bit and I could get some CMOS ICs. I've revised the scheme to use 4511, 4518... and to use two 4040s for the frequency divider. I could also use 4060 and 4013 to get the same result but the simulator doesn't seem to like 4060.

As for the "voltage drop" I've tried to simulate Colpitts oscillator posted by MikeMl in a completely different thread (no links this time - hopefully this post will pass). It did produce the right frequency (and was the only oscillator I managed to get to do that in the simulator) but the output was only 1.88V.

I'm looking into some other oscillators and it appears you're right - the simulator doesn't like crystals. I guess I'll just have to try it out to see...
I also checked the Pierce oscillator, I might as well use that.


MikeMl:
Thanks. I probably won't use CDP1802, but the schematic does help :)


MrDEB:
I most likely wouldn't be able to do that, both because of the lack of experience and knowledge and because of the unavailability of the parts around here. I'd have to wait quite a bit for them to get here...
That might be a project for the future, though.
 
hi,
The LTSpice simulator can be used to simulate crystal models.

EDIT:
Run as requested.
Is there a problem.?
 

Attachments

  • 000esp01.gif
    000esp01.gif
    41 KB · Views: 380
  • 000esp02.gif
    000esp02.gif
    39.9 KB · Views: 434
Last edited:
hi,
The LTSpice simulator can be used to simulate crystal models.

It would be interesting to see the start-up transient, and the voltage at the two ends of the crystal.
 
Thanks MikeMl.

And thanks ericgibbs, I'll try it out. So far I've been using Multisim 10 and it's as glitchy as it gets.
 
here is where I started. Look at the forums etc. has an explaniation for everything. I have an extra Olson 595 as well as about 20+ ssr boards not populated but I do ave the parts for them (opti coupliers, triacs, rj45 jacks) You run cat 5 cable from control board to each SSr board (4 channels per board)
**broken link removed**
will locate all my parts and take some pics after I get this computer straighten out (had to rebuild w/ new MB.
 
nobody mentioned yet that you need to "debounce" your switches.....

while a PIC or a uC might be an ideal solution here, the object of this project is to learn How Things Work.... this project will work as intended without writing code, without program storage. without code debugging. it probably could be written on a PIC, but that's not the point. the point is, we start with 32.768Mhz, trigger a cascade of counters with some switches (or in a slightly more complex version, logic gates and trigger signals from opto or other sensors) and end up with a numeric display of time elapsed. we don't have to mess around figuring out how much time is required for a set of lines of code to execute and scaling the "wait" or "do" loops. you input a known frequency, divide it by whatever is needed, and get a displayed result. simple? yes... "old school"? yes.... but it works without question and without a lot of fuss.
 
I'm done with this stopwatch...using cmos 4518, 4511, uln2003, custer made 7 segmen led.
555 as an oscillator.
 
A 555 wont give you good accuracy, you can make a very accurate 1hz time signal from a 4060, 4027 and a 32.768 khz watch crystal, I've done it a few times and you can get 1 sec a day accuracy untrimmed, as good as most wall clocks.
Might be better with a 74hc4060, or if you are using 74ls technology a 74act4060, if you are reallly using 74 technology then a 4000 series might not work directly, you'll also find it hard to get 74 chips now.

Even lower end 'pics' have a built in oscillator specifically desgined to be used with a 32kc xtal, time keeping in sofware is trivial, as would be multiplexing a display from only a few pins of the 'pic'.
 
Last edited:
The 555 can be viewed as a Schmitt inverter and used with a crystal for good stability:

attachment.php


John
 
Must be me, none of my pics are working, but dont worry about it I found a few references.
I've never seen a 555 used as a xtal osc before.
 
Status
Not open for further replies.

Latest threads

New Articles From Microcontroller Tips

Back
Top