Welcome
Username or Email:

Password:


Missing Code




[ ]
[ ]
Online
  • Guests: 17
  • Members: 0
  • Newest Member: omjtest
  • Most ever online: 396
    Guests: 396, Members: 0 on 12 Jan : 12:51
Members Birthdays:
All today's birthdays', congrats!
Desmogod (48)
Alex Smith (31)


Next birthdays
04/26 Bead (41)
04/26 Fumeaux (25)
04/28 Steve Conner (46)
Contact
If you need assistance, please send an email to forum at 4hv dot org. To ensure your email is not marked as spam, please include the phrase "4hv help" in the subject line. You can also find assistance via IRC, at irc.shadowworld.net, room #hvcomm.
Support 4hv.org!
Donate:
4hv.org is hosted on a dedicated server. Unfortunately, this server costs and we rely on the help of site members to keep 4hv.org running. Please consider donating. We will place your name on the thanks list and you'll be helping to keep 4hv.org alive and free for everyone. Members whose names appear in red bold have donated recently. Green bold denotes those who have recently donated to keep the server carbon neutral.


Special Thanks To:
  • Aaron Holmes
  • Aaron Wheeler
  • Adam Horden
  • Alan Scrimgeour
  • Andre
  • Andrew Haynes
  • Anonymous000
  • asabase
  • Austin Weil
  • barney
  • Barry
  • Bert Hickman
  • Bill Kukowski
  • Blitzorn
  • Brandon Paradelas
  • Bruce Bowling
  • BubeeMike
  • Byong Park
  • Cesiumsponge
  • Chris F.
  • Chris Hooper
  • Corey Worthington
  • Derek Woodroffe
  • Dalus
  • Dan Strother
  • Daniel Davis
  • Daniel Uhrenholt
  • datasheetarchive
  • Dave Billington
  • Dave Marshall
  • David F.
  • Dennis Rogers
  • drelectrix
  • Dr. John Gudenas
  • Dr. Spark
  • E.TexasTesla
  • eastvoltresearch
  • Eirik Taylor
  • Erik Dyakov
  • Erlend^SE
  • Finn Hammer
  • Firebug24k
  • GalliumMan
  • Gary Peterson
  • George Slade
  • GhostNull
  • Gordon Mcknight
  • Graham Armitage
  • Grant
  • GreySoul
  • Henry H
  • IamSmooth
  • In memory of Leo Powning
  • Jacob Cash
  • James Howells
  • James Pawson
  • Jeff Greenfield
  • Jeff Thomas
  • Jesse Frost
  • Jim Mitchell
  • jlr134
  • Joe Mastroianni
  • John Forcina
  • John Oberg
  • John Willcutt
  • Jon Newcomb
  • klugesmith
  • Leslie Wright
  • Lutz Hoffman
  • Mads Barnkob
  • Martin King
  • Mats Karlsson
  • Matt Gibson
  • Matthew Guidry
  • mbd
  • Michael D'Angelo
  • Mikkel
  • mileswaldron
  • mister_rf
  • Neil Foster
  • Nick de Smith
  • Nick Soroka
  • nicklenorp
  • Nik
  • Norman Stanley
  • Patrick Coleman
  • Paul Brodie
  • Paul Jordan
  • Paul Montgomery
  • Ped
  • Peter Krogen
  • Peter Terren
  • PhilGood
  • Richard Feldman
  • Robert Bush
  • Royce Bailey
  • Scott Fusare
  • Scott Newman
  • smiffy
  • Stella
  • Steven Busic
  • Steve Conner
  • Steve Jones
  • Steve Ward
  • Sulaiman
  • Thomas Coyle
  • Thomas A. Wallace
  • Thomas W
  • Timo
  • Torch
  • Ulf Jonsson
  • vasil
  • Vaxian
  • vladi mazzilli
  • wastehl
  • Weston
  • William Kim
  • William N.
  • William Stehl
  • Wesley Venis
The aforementioned have contributed financially to the continuing triumph of 4hv.org. They are deserving of my most heartfelt thanks.
Forums
4hv.org :: Forums :: General Science and Electronics
« Previous topic | Next topic »   

World's Simplest Frequency Counter

1 2 
Move Thread LAN_403
Hazmatt_(The Underdog)
Thu Nov 23 2006, 02:45AM Print
Hazmatt_(The Underdog) Registered Member #135 Joined: Sat Feb 11 2006, 12:06AM
Location: Anywhere is fine
Posts: 1735
That's right. I have made a frequency counter so simple that anyone can put it together (or so I hope).

I needed a tachometer for a motor, and spent 3 weeks going through counter circuits that just did not work. Some of the circuits were untested designs, and some fed pulses into monostables that were too short for the monostable to trigger.

I have done away with monostable triggering, and I have designed a rock solid MSI Frequency counter that really works!

The first step is to setup the counter so that we can see if it will count up, reset and latch the displays. Here is an example using 74XX family logic gates to accomplish this.
I am showing the pinout for the display so you can hook one up. If you have a different type of display you can figure out the segments by using a continuity tester. The resistors should be about 220-330R each. Once you get the display hooked up to the 7447, test your display to see if it decodes properly by jumpering the BCD inputs to logic 1 or 0.

The next step is to get the latch connected. The latch is a quad D flip-flop that stores the old count, or is transparent depending on the latch enable bit. You should be able to jumper the BCD inputs, freeze the display, then change all the jumpers, and the number will stay until you change the latch state. How cool is that!

After this comes the decade counters. These divide the input so that you end up with decades for each digit. The D output spills over into the A input of the next counter, making a decade chain. The 7490 automatically resets itself after 9 to 0, but we need to be able to clear the count, so we trigger the master reset by pin 2. You will be able to count up while the latch is held at logic 1 and reset is at logic 0. Then you can reset the count, freeze the count, and play with it.


1164248917 135 FT1630 3



So the hard part is done right? Well, kind of. We need to generate the timing structure now. We need to arrange the gate, latch, and reset pulses such that we make a functional counter. I have given you the timing diagram for the sequency generator, another 7490 and a couple of gates. This is where the real 'magic' happens. This sequencer takes your standard timebase input and derives the necessary pulses to control your counter.

1164248917 135 FT1630 2




The last step of all of this is coming up with your standard. What standard should I use?
Well, if you needed a tachometer, you want the operator to see R.P.M right? And of course for a frequency counter you would want to see counts/ second.

I have set up the divider of 30,000 to divide my 2MHz source so I get 66.6666 Hz. This gives me my timing for the motor.

But likewise, if you wanted 100 Hz timebase for your counter, you could implement a 1MHz crystal or 10MHz crystal and divide it down in decades.

1164248917 135 FT1630 4

**There's a bit of a mistake on the divider chain. If you look at the last two chips it should be 12 output to 14 input. All dividers are 14 inputs from previous stage, and 12 as the output to the next stage. Hope that clears up any confustion**

This is a great little counter. It will function up to about 40MHz. AND you can add as many digits to the right as you need. Anything more then 8 digits is really un-necessary, but I thought I might like to make a 20 digit counter someday for fun.

The next evolution of this counter is to take it from overly bulky 74XX logic and go full CMOS.
The CD 4026 Decade/latch/decoder replaces the 7490/7475/7447 ALL IN ONE!!!!! How cool is that!
So that will reduce the counter module to 4 chips and 4 displays right off.
Then if you take the 4017 and derive the timing pulses from it, any 3 you like, you have again your timing for latch, reset, and gate. So that will reduce the 'magic gating' even further.
And still yet, if you can find a crystal that matches up with a large 2^n divider chip, you could derive your timebase in the smallest number of chips possible.


A word of caution to builders: This circuit performs perfectly, but be careful about power supply noise. This may be an issue in your circuit. If you're like me, and you built your own regulated power supply, be aware that it may be switching at very high frequencies well in the hundreds of KHz. So if you get some strange results, like the display jitters quickly, that means you are seeing the result of high frequency rail noise.
It took me a while to track my noise down, and it was very high frequency. So I switched to a simple regulated supply unit by Interplex Enterprises. They make a little regulated supply that plugs into breadboards. This supply uses a 7805 and worked fine.
My supply still needs some rework, and that will come later.



Have fun.

Some more old pics showing it working: cheesey

Pics of my Tachometer for my DCRSGC
1162083284 135 FT1630 Mvc001f

1162083284 135 FT1630 Mvc002f

1162083284 135 FT1630 Mvc003f

1162083284 135 FT1630 Mvc004f

1162083284 135 FT1630 Mvc005f

1162083284 135 FT1630 Mvc006f

1162083284 135 FT1630 Mvc007f

1162083284 135 FT1630 Mvc008f

Back to top
ragnar
Thu Nov 23 2006, 02:50AM
ragnar Registered Member #63 Joined: Thu Feb 09 2006, 06:18AM
Location:
Posts: 1425
Hooray! I've been looking forward to this, thanks Hazmatt. =)
Back to top
Hazmatt_(The Underdog)
Thu Nov 23 2006, 03:12AM
Hazmatt_(The Underdog) Registered Member #135 Joined: Sat Feb 11 2006, 12:06AM
Location: Anywhere is fine
Posts: 1735
You're very welcome. I hope to see lots and lots of variants of my design. AND I will be expecting to see some 12 Digit counters from you guys tongue

This circuit is fine up to 100Hz into the timebase generator, and with 8 digits, that gives you one heck of a counter!

I will have to see what I can do about microwave mixing down converters so you guys can have 4GHz counters. Now wouldn't that be fun!

If there is any debate of the timing diagram that I made some errors on the margins passed 0 to the left and after 0 on the right, don't worry. All we're interested in are the timing pulses from 0 to 0 in the full cycle, okay wink

Happy building and Measuring!
Back to top
Steve Conner
Thu Nov 23 2006, 11:13AM
Steve Conner Registered Member #30 Joined: Fri Feb 03 2006, 10:52AM
Location: Glasgow, Scotland
Posts: 6706
Nice work Hazmatt! smile Here's a thought: can you (or anyone else) figure out how to make it into a speed trap that reads out in meters per second (or fps or whatever) without losing the frequency counter function? A dual-purpose frequency counter and speed trap would be a great gizmo for coilgunners.

You get prescaler ICs for a few dollars that let these counters read up into the GHz. Link2
Back to top
Hazmatt_(The Underdog)
Thu Nov 23 2006, 07:20PM
Hazmatt_(The Underdog) Registered Member #135 Joined: Sat Feb 11 2006, 12:06AM
Location: Anywhere is fine
Posts: 1735
For a speed trap you would disengage the reset and make it a manual reset. Then you would need a rising edge trigger as the start count, and a falling edge trigger as the stop count. Inbetween the count trigger, the local oscillator timebase would free-run. You might be able to do both with the same counter, but you will need sets of latches to store the data until you can read it out on the display.

I did buy way back when, some Motorola prescalers that go to 1.2 GHz for $14 each! I had planned back in '98 to build an 8 digit counter and generator, but never got to it. I still have the ICM7216DIPI, and a zif socket for it.

I'm going to post the Dulux version of the counter soon too, All CMOS.

Matt
Back to top
Sulaiman
Fri Nov 24 2006, 09:59AM
Sulaiman Registered Member #162 Joined: Mon Feb 13 2006, 10:25AM
Location: United Kingdom
Posts: 3140
Nicely done project.





I have built parts of two frequency counters many years ago
One was VERY similar using 7490 etc. etc.
One used a 4 decade counter with 7-segment multiplexed drive ic
I never finished the hardware, enclosure, knobs, display window etc.

I bought an 80 MHz Philips frequency meter for about GBP15 from eBay
and a Racal Nixie computing Counter/Timer with ext. START/STOP for about the same
(the 5/6 decade counter board used 7490 + latches + decoders + nixies)

So for readers looking to learn, DIY is excellent
If you just want a timer/counter it's MUCH cheaper/quicker/easier to get a cheap one off eBay.
Back to top
Steve Conner
Fri Nov 24 2006, 12:13PM
Steve Conner Registered Member #30 Joined: Fri Feb 03 2006, 10:52AM
Location: Glasgow, Scotland
Posts: 6706
I still use an old nixie-tube frequency counter that I dumpster-dived years ago, so I kind of agree with Sulaiman's view there. But this is an excellent project for learning about all those textbook principles of digital electronics. I see hazmatt already learnt the "Never use monostables" rule the hard way wink
Back to top
Dr. Slack
Sat Nov 25 2006, 08:45AM
Dr. Slack Registered Member #72 Joined: Thu Feb 09 2006, 08:29AM
Location: UK St. Albans
Posts: 1659
If you just want a timer/counter it's MUCH cheaper/quicker/easier to get a cheap one off eBay.


Absolutely. However, if you want a timer/counter that you can control, read, log and has extremely high resolution, then a program that uses your PC soundcard is a very easy and cheap way of doing it. I wrote one in Matlab, which reads 1000 samples from the sound card, fits the demodulated phase, then differentiaites it, which gives a noise-limited resolution in parts per billion ( don't count zero crossings, or look for the peak of an FFT, neither are in the same ball-park for resolution ). That resolution allows you to prescale your input frequency down to the 5-15kHz needed for the sound card, and still get useable resolution at UHF or even microwave input frequencies. Accuracy is down to the stability of your soundcard timebase, however it's easy enough to use the second channel to measure the frequency of a divided down reference source (10MHz oscillator, or the carrier from a designated radio station) if you are fussed about stability, and essentially the sound card does a comparison between the two.

My application was measuring the output of a differential capacitive oscillator transducer, so comparing two channels needs only resolution, not accuracy or stability.
Back to top
Hazmatt_(The Underdog)
Sun Nov 26 2006, 01:02AM
Hazmatt_(The Underdog) Registered Member #135 Joined: Sat Feb 11 2006, 12:06AM
Location: Anywhere is fine
Posts: 1735
Here is a very simple timebase generator for your counter. It uses the 4017 to generate the pulses. You can reset on pulse 5, but letting it go through its full count cycle will give you more display time, so it will appear to be more stable.

I was going to add the 4026 as your decade counter/display driver/latch, but it occured to me that the 4026 does not have a latch to 'store' the count. It can blank the display to save power, or force the display to all zeros, but no D flip-flops for storage.

Alternativily there are two chips that do a rather nice job for 3 displays. They are the 4511 and 4553. They come with a 3 digit up counter kit that you can chain together for n x 3 digit counter modules. So you could have a 9 digit frequency counter if you desired. I will post that circuit a bit later.


1164502484 135 FT1630 5
Back to top
Hazmatt_(The Underdog)
Sat Jun 08 2013, 01:31AM
Hazmatt_(The Underdog) Registered Member #135 Joined: Sat Feb 11 2006, 12:06AM
Location: Anywhere is fine
Posts: 1735
Now here is an ancient thread indeed!

But we come back to it with purpose, and a real application!

The picture is the counter connected to a VCO source system in the Aluminium box. The counter is not fully hooked up, if it were, there would be 6 digits reading out, but for test, all I needed was 3 digits.

The picture is showing 300, but.. 300 of what, hehehe.

That's not 300 KHz, 30.0 MHz, or even 300 MHz, its counting from the VCO 3000 MHz !!!!!!! NOW HOW COOL IS THAT!

The box is furnished with a Minicircuits ZX95-2800-S+, which feeds a microwave splitter, to a small +20 dB gain block, and to a divider chain.

The divider chain divides by 160, and feeds a buffer pulse amp so the TTL can see what is coming out, roughly 19 MHz max.

This then feeds the 6 digit counter system, with a 250 Hz clock, which offsets the 160 divde prescalar of my little 'magic box'.

Top that off with a selectable attenuator that is to come later, throw it in a neat little box, and you have yourself a frequency source
that spans 1240 MHz to 3000 MHz, with a max power out of +20 dBm!


033f
Back to top
1 2 

Moderator(s): Chris Russell, Noelle, Alex, Tesladownunder, Dave Marshall, Dave Billington, Bjørn, Steve Conner, Wolfram, Kizmo, Mads Barnkob

Go to:

Powered by e107 Forum System
 
Legal Information
This site is powered by e107, which is released under the GNU GPL License. All work on this site, except where otherwise noted, is licensed under a Creative Commons Attribution-ShareAlike 2.5 License. By submitting any information to this site, you agree that anything submitted will be so licensed. Please read our Disclaimer and Policies page for information on your rights and responsibilities regarding this site.