80Mhz frequency counter


Last updated: June 22, 2015



Starting with the IBM AT all PCs contain an Intel 8254 timer or some equivalent circuitry. One of the 8254 counters is clocked with 1.19Mhz. This counter is used to do time measurements with a resolution of 840 nsec. To get a frequency counter a TTL compatible signal is connected to a LPT or COM port in such a way that one or both edges generate an interrupt. The interrupt routine reads the 8254 counter. Subtracting 2 consecutive readings gives the period of the input signal. To miminize errors several readings are averaged. Averaging during 1 second gives a resolution of approx. 10e-6. The 1.19Mhz clock should be stable. Check your motherboard for a TCXO, a simple Xtal won't give you the stability you want. Calibrate against a known frequency. The software does not allow easy calibration (yet), you have to change a constant and recompile.



The hardware is based on a design by PA2OHH found in the Benelux QRP magazine.

The counter fits into an old whiteboard marker. The tip is a 2 mm banana plug. This makes it easy to attach 'accessoires' like a small pickup coil.

The voltage levels on the serial port of most laptops are to low to generate a usable +5V supply. Use an external power supply in such cases, eg a 9V battery.

Sensitivity



Archive containing the Xcircuit files (encapsulated postscript), the C-sources and a DOS executable.