Prescaler question that no one can answer! :)

Thread Starter

KLillie

Joined May 31, 2014
137
Thanks MrC. The 74f161 datasheet says Fmax of 100MHz. What does that mean? Also I didn't see a minimum input frequency. My problem is my arduino frequency counter will only be able to read to about half my 16MHz clock speed without a prescaler. I've seen lots of prescalers that will go into the Ghz range but have Fmin of 100+MHz. This would leave me with a measuring gap between 8-100Mhz. If I use my internal scalers I should be able to get 30-50MHz reliable readings (from what I've read), so I would want a prescaler that could take the lead @ that range, right? Cheap is the key word. The problem is hunting components!
 

MrChips

Joined Oct 2, 2009
30,824
There is no minimum input frequency with TTL counters. They will clock down to zero Hz.

SN74F161A is available from well known suppliers for under $1 each ($0.30 at Newark). Read the data sheets closely and you will see 120MHz quoted (TI and Fairchild).

NXP N74F161A is quoted at 130MHz.
 

Dodgydave

Joined Jun 22, 2012
11,307
Fmax is the maximum permitted input frequency, the A versions are upto 120Mhz speed.

What frequency are you trying to measure, from DC to what?
 

Thread Starter

KLillie

Joined May 31, 2014
137
Thanks guys. ideally I'd like to be able to measure any and all frequencies in the know universe. Practically, I'd be happy with FM frequencies. The SN74F161A sounds good and cheap! ;) Dodgydave- building oscillating circuits has been kind of my restart point in this hobby, so it's more AC. ANALOG BABY!!! :)
 

MrChips

Joined Oct 2, 2009
30,824
So, get two 74F161 4-bit binary counters and that will give you 8 bits. Interface the 8-bit output of the counters to an 8-bit port.
This means that your MCU only has to accept clock frequencies up to 500kHz and your frequency counter is good to 128MHz.
 

Thread Starter

KLillie

Joined May 31, 2014
137
So, get two 74F161 4-bit binary counters and that will give you 8 bits. Interface the 8-bit output of the counters to an 8-bit port.
This means that your MCU only has to accept clock frequencies up to 500kHz and your frequency counter is good to 128MHz.
Nice! Thank you.
 

RichardO

Joined May 4, 2013
2,270
I have seen a trick for reading a counter that only uses a few pins on the MCU. First you select the external clock source and count the pulses. Then you switch the clock source to be from the MCU. The MCU clocks the counter until an overflow/carry occurs. External_counts = 2^Number_of counter_bits - Number_of_MCU_counts.

edit: Fixed equation.
 
Last edited:

Thread Starter

KLillie

Joined May 31, 2014
137
I have seen a trick for reading a counter that only uses a few pins on the MCU. First you select the external clock source and count the pulses. Then you switch the clock source to be from the MCU. The MCU clocks the counter until an overflow/carry occurs. External_counts = Number_of counter_bits ^2 - Number_of_MCU_counts.
Sounds a lot like these frequency counter codes I've been studying. Thanks for input!
 
Top