In this project we are building a basic and low cost frequency counter circuit. Using temperaturecompensated voltage controlled crystal oscillator 2. Software notes, interrupt driven counting and time measurement. But i wanted to use 7segment led display, not lcd, so i found a second useful project. This kit is an affordable, dual purpose test equipment.
Frequency counter by pic16f628 posted wednesday, january 11, 2012 the counter can be used in many applications. The weeder frequency counter pic 16f84 port by peter cousens. All you need is a pic microcontroller or any microcontroller that has a high speed timer input module and a 2 line lcd display the standard hd44780 one is the one used. An easy to build open source diy kit of frequency counter based on pic16f628a microcontroller. Pic16f628a based frequency counter for up to 500mhz. Frequency counter by pic16f628 free open source codes. Sensitivity falls with frequency, but a simple 2turn loop on the input is more than sufficient to count my gdo2 project from 100khz to well over 35mhz. The schematic is fairly simple and straightforward and uses a pic16f628a microcontroller for measuring frequency and a high speed comparator for signal amplification and conditioning. How to easily make a 50mhz frequency counter using only a pic.
Full extended package includes mb506 prescaler that allows to measure hf and vhf up to 250mhz. Frequency counter with pic16f628a this is a frequency counter based on pic16f628a. Simple 100mhz frequency counter which uses 6 digit led display. Since it uses a base pic that is easily programmable, and provides a usefull bit of bench test equipment at very low cost, it makes an ideal pic learning project. This project shows how to build a very simple yet very useful tool that every diy enthusiast should have in his lab. New project on hhh 0 60mhz 5digit frequency counter.
The schematic of the frequency counter is actually almost the same as the previous. When used with a divideby64 prescaler, the three available resolutions become 1khz, 100hz and 10hz, corresponding to gate times of 64ms, 640ms and 6. Some time ago i made an audio oscillator with frequency counter which worked very well, but i sold it, and now i am making a new one. Cannot open file include file c not found halting build on first failure as requested. Pic16f628a is an 18pin tiny chip that contains processor, memory, io pins, other peripherals and mainly used for the embedded system, and in the applications that have a remote or direct connection with the automation. The oscillator itself will be mostly the same and when i finish the whole project there will be a separate article. This is another version of frequency counter using pic16f628a instead of pic16f84a written by vu3cns using the same circuit shown above.
The electrical circuit based on pic16f628a microprocessor and 164 configured mb506. Here i will show the frequency counter module i made for the project. I use a later device, the pic16f628a microprocessor pic,this chip is easy to buy and uses a fully compatible schematic to most pic16f84 based frequency counter projects. I have started work on an original program based on the an592 microchip application using a 16f84.
Using tmr0 as a counter you can also configure a tmr0 as a pulse counter. Mar 25, 2017 it is ideal for frequency counter project. I then bought a second hand 600mhz frequency counter at the right price and ended up shelving the project, but the programming skills i learned will be useful for future projects. Programming pic16f84a software delay routines by example. The examples ive seen in microchip pic assembly are just confusing to modify and use. As you can see very simple and yet elegant schematic. This is a port by peter cousens to the pic 16f84 of the 50mhz frequency counter kit originally available from weeder technologies. Im trying to modify a 6 digit led frequency counter that uses an integral pic16f648a, a mhz oscillator and an i2c coupled digital display. The lcd and driver module is a 2 lines 16 characters, it has 14 way connector. A simple pic 18f4550 usb powered frequency counter.
I came to realize that hex files are not compreensible to me, and that the usual method was to write. Lcd frequency counter see also tft counter, led counter. Luckily, i found a great library for arduino and i reworked it to be compatible with pic. New project on hhh 0 60mhz 5digit frequency counter using pic16f628a. Thanks for your last feedback in helping me installing my pic programmer. Frequency counter project detailed here is based on pic18f4550 for which design and firmware software support. This one exceeds 50 mhz, limited only by the pics counter timer. Frequency counter with pic16f628a use arduino for projects. It has a range from well under 100hz to about 60mhz, and has a 5digit, autoranging display. The input signal can be a sine, a square or a triangle waveform. The basic counter software allows three resolutions selected with rc4 and rc5.
The plj6leda module is a costeffective 8digit frequency counter and display module primarily to display the operating frequency in a transceiver and other equipment. Software functions are presented inside the dashed area. The previous frequency counter was made with cmos logic ics, but as i already own a pic programmer, this one is designed with pic microcontroller. Introduction to pic16f628a the engineering projects. This video is about changing the firmware of a pic frequency counter and crystal tester in kit form sold on the internet under many names. Sep 12, 2010 now, the timer0 will work as an 8bit counter, counting the pulses arrived at ra4t0cki pin at lowtohigh transition. A software counter watches for the tmr0 overflows, and the gating is done with another pin rb0 switching between input state highz which allows counting, and as an output lowz which halts counting. I checked with two different pic16f628a and they easily go over 200mhz barrier. Project description the counter can be used in many applications. Economy package intended to measure frequency input up to 5mhz. Frequency counter circuits, schematics or diagrams. The pic16f628a microcontroller will turn the ir diode on for 1 sec, and will count the reflected pulse during this interval through ir rx pulse output. Frequency counter with pic16f628a circuit wiring diagrams.
The schematic is fairly simple and straightforward and uses a pic16f628a microcontroller for measuring frequency and a high speed comparator for signal. It is a very useful bench test equipment for testing and finding out the frequency of various devices with unknown frequency such as oscillators, radio receivers, transmitters, function generators, crystals, etc. Frequency counter project detailed here is based on pic18f4550 for which design and firmware software support is given by fox delta team. A frequency counter with the pic16f628a proton basic. Modifications to the dl4yhf 16f628 firmware allow other clock speeds to be used for the 16f628.
Frequency counter with a pic and minimum hardware by wolfgang wolf buscher, dl4yhf last updated. So the maximum frequency can be between 100mhz and 256mhz. Setup in this experiment we are going to measure the mains ac frequency by using timer0 as counter. Frequency counter with pic and 4 to 5digit led display. In addition, i can see a high frequency oscillation of the brightness by eye while it slowly fades fading occurs over about 0. For instance, to observe an oscillators accuracy, to measure the mains frequency or to find out the rpm of a motor that is connected to an encoder. May 31, 20 a frequency counter is a useful addition to an engineers toolbox and you can create the design described on this page for free. With respect to the original version in the link provided. Mplab x integrated development environment ide mplabxide mplab x integrated development environment ide is an expandable, highly configurable software program that incorporates powerful tools to help you discover, configure, develop, debug and qualify embedded designs for most of microchips microcontrollers, microprocessors and digital signal controllers.
The 4 mhz xtal has been chosen for compatibility too although i think a 20 mhz xtal would be better. The module offers compact, reliable high performance with clear display at low cost. Ive been able to get it reprogrammed by using modified software that was written for 6 discrete leds running at either 4 or 20 mhz. Unique gate control and precise time algorithm nontimed interrupt. Do you have allready an updated and corrected c source andor hex file for this circuit its a pitty. Here ill illustrate a more sane way to program software time days. The original design used a gate time of one second which gives a count resolution of 1hz. The software is written and compiled with mikroc pro and uses its build in software i2c library for communicating with rtc chip.
Dec 07, 2014 open source frequency counter diy kit with pic16f628a and mb506 prescaler 10hz 250mhz rh electronics. This frequency meter has much simpler hardware than the 2002 version and because of improvements in the software 32 bit counter instead of 24 has a higher frequency limit. Additional clocking options for the dl4yhf frequency counter firmware by erich heinzle vk5hse. I present schematic, pcb, components and window software.
Since it uses a base pic that is easily programmable, and provides a usefull bit of bench test equipment at very low cost, it makes an ideal pic. But the downloadable software achive also contains a third firmware file counter3. Now, the timer0 will work as an 8bit counter, counting the pulses arrived at ra4t0cki pin at lowtohigh transition. During normal condition, the photo diode ir rx diode offers high impedance tens of k and so the voltage across it will make the bc557 transistor in the receiver part right cut off. Open source frequency counter diy kit with pic16f628a and mb506 prescaler 10hz 250mhz rh electronics. The software functions as a frequency meter with an input signal. Pic 16f628 frequency counter with rs232 output in a db9 backshell. The mains ac frequency is 120v, so we cannot directly feed it to pic port. The problem was the absence of library for pic microcontrolers.
Open source frequency counter diy kit with pic16f628a and. Both supplies should have a minimum resolution of 0. The precise gate is implemented in software as an accurate delay. A frequency counter is a useful addition to an engineers toolbox and you can create the design described on this page for free. It can measure from 16hz to 100hz signals with a maximum amplitude of 15v. On the other hand, in the datasheet of 16f628a there is a requirement for the input pulse at ra4 to be with minimum width of 10ns which is 100mhz frequency.
Jun 22, 2015 using tmr0 as a counter you can also configure a tmr0 as a pulse counter. The pic16f627a628a648a requires one programmable power supply for vdd 2. By adding couple of transistors and operation amplifier tl082, it is possible to lock the lc oscillator frequency. If someone wishes to use mplab software for compiling the code he should write his own i2c functionality from scratch. See programming pic16f84a pic16f628a interrupts tutorial. This project is a 5digit basic frequency counter, based on the cheap pic16f628a microprocessor chip. Pic 16f628 frequency counter with rs232 output in a db9. Of course, most of this hardware could be replaced by software routines in the pic itself. Jun 20, 2018 of course, most of this hardware could be replaced by software routines in the pic itself. It may also be used for conventional frequency measurement. You can select a gate period of 1 sec or 125ms with 1 hz or 10hz accuracy respectively. Pic16f627a628a648a eeprom memory programming specification. It uses pic16f628a microcontroller with external 32.
Frequency counter diy kit 10hz 250mhz with lcd, mb506, pic16f628a and open source code. Pic frequency counter with frequency lock function. A frequency counter with the pic16f628a proton basic compiler. Now im using a software chip burning system micropro which writes.
Software delay routines are useful and saves tying up hardware timers to be used for other purposes. The heart of this frequency counter is the pic16f628a, with timer 0 tmr0 acting as the input counter. All you need is a pic microcontroller or any microcontroller that has a high speed timer input module and a 2 line lcd display the standard hd44780 one is the one used here. This pic software combines frequency counter and frequency lock functions. Simple 100mhz frequency counter which uses 6 digit ledread more. It has a range from well under 100hz to about 60mhz. Oct 28, 2010 the pic16f628a microcontroller will turn the ir diode on for 1 sec, and will count the reflected pulse during this interval through ir rx pulse output.
869 1539 18 452 538 1373 756 353 1513 491 673 974 487 742 546 1263 249 1443 371 1349 1091 1365 624 1303 435 1279 1085 602 354 187 1496 1472 873 528 20 1371 1204 1045 1101 903 986 579 888 367