Check my website below. The first project listed is called 'Super Probe' it does 16 functions including frequency counting, and event counting. The full source listing is included.
By the way, are you looking for frequency or pulse width? Pulse width is much easier to handle.
Luhan Monat (luhanis \'at\' yahoo \'dot\' com)
"The future is not what it used to be..."
http://members.cox.net/berniekm
Didn't find your answer? Ask the community — no account required.
B
Bob Monsen
You can use Timer0 as a free-running, async clock on many of the PICs. The claim is that you can measure up to 50MHz with it. Start a different clock, clear the timer register, and then start Timer0. When it overflows, you have 256 ticks, so the clock >> 8 is the period. If it's too fast, count some number of overflow interrupts. Use a crystal, since the RC clock is pretty inaccurate.
There are fixed point routines available for divides, which will allow you to output a frequency.
There is also a tech note on the microchip site that describes all of this.
Regards,
Bob Monsen
F
Fernando
I don't know if this is the right forum. If it doesn't go, please, find out the correct for my questions.
I am developing system to measure frequencies with PIC and I am with difficulty in programming the capture of the information (pulses) and to record in a variable. If somebody can help myself, I thank. TIA
Fernando
F
Fernando
If you can send me a small example, it would help me a lot.
Thanks Fernando
"Bob M> > I don't know if this is the right forum. If it doesn't go, please, find
out
this.
L
Luhan Monat
Hi,
Near the bottom of the are text links to source and object codes.
An LCD would be easier, the LED's I have need to run constantly.
If you have questions on the code, you can email me directly - just be sure to put something specific in the subject line so you wont 'get thrown out with the spam'.
Luhan Monat (luhanis \'at\' yahoo \'dot\' com)
"The future is not what it used to be..."
http://members.cox.net/berniekm
M
martin griffith
try
formatting link
and the comp arch.embedded newsgroup
martin
After the first death, there is no other. (Dylan Thomas)
P
Parmin
Luhan Monat while reading the NewsGroups, decided to share his knowledge in news:rAuge.14856$tQ.14761@fed1read06:
Thanks Luhan
Thats a great project.
I have not yet see the source code but, anyway I could port this model to run an LCD? Or is the metering code really intertwined to the display code?
Par.
B
Bob Monsen
Here you go:
formatting link
F
Fernando
I thank for you to be interested in helping me. If I do Timer1 to begin in the ascent of a pulse present square in the pin RA2 (for example) and in the descent of this same pulse, to stop Timer1 I have the half of the period of this square wave. Am I right? Tks Fernando
"Luhan M> > I don't know if this is the right forum. If it doesn't go, please, find
out
Join the Discussion
Have something to add? Share your thoughts — no account required.
Didn't find your answer?
Ask the community — no account required
Report Content
You are reporting this content to the moderators. They will look at it
ASAP.