
Originally Posted by
mark_s
Hi Louis
You did not say which pic you are using. You can read frequency by feeding the signal to the external timer input on your pic. It works by setting the TMR1 register to 0 , start the timer, let it count for a fixed period of time, stop the timer, read the value in TMR1 to variable Freq and display. The Pause routine is not super accurate for gating the timer so you need to tweak the value. A better way would be to use a second timer with an interrupt. This should get you started
Bookmarks