Dear experts, I working on 8051 microcontroller. I have an quiry regarding the pulses of unknown frequency.
I am equipped with the following things: 1) I have an 8051 microcontroller. 2)I have an unknown frequency source.
My Purpose: I want to measure the digital count of the unknown frequency that will be fed to 8051.
My queries:
1) Please let me know what logic has to be used to calculate the digital output after these pulses(unknown frequenc pulses) are fed to an 8051 microcontroller.
2) for the above issue whether one counter is sufficient or two counters are required since 8051 has two number of counters.
Thanks, SUNNY.
The types of questions you ask indicates that you haven't spent any (!) own time pondering this problem.
Return back when you have thought about it and have more specific questions. You can't really claim that you are stuck before you have started. And you can't expect people on the net to jump in and spend time as private tutors or as cost-free labour.
Here is a clue: "capture".
I want to measure the digital count of the unknown frequency
do you want to count pulses or do you want to measure frequency?
Eril
Where a real solution could potentially do both.
Count pulses during fixed time interval for high-frequency signals. Measure time between two pulses for low-frequency signal.
Is this frequency source a sine wave, square wave?
Do you know the frequency range?
measuring frequency in terms of digital output.............
input signal is square wave.........
More dots should solicit better answers. I suggest you use more........................................
Here is a clue: "capture" maybe too complicated for the OP Here is another clue: "timers"
Erik
Do something very simple to start until you have the time to become familliar with your device.
For example: Use an edge interrupt to increment a counter. At the same time use a timer interrupt to re-start the counter and give you a fixed time base.
While doing this you will probably read over the capture register feature and you could see how that might be used.