Hi guys, was thinking of using a P16F877A and a frequency generator to simulate a RPM sensor circuit for a car engine.
Am I correct in assuming that say 5,000RPM can be represented by 83.3Hz from a function generator or am I doing something wrong here?
Secondly, for the coding part, I am writing the code in CCS and need to create a subroutine that counts 0.5s and records how many pulses occur in that time frame to calculate the frequency
Am I better off just using Timer0 and whilst the tick reaches overflow just read the highs and use a count++ function. My only concern is im very confused when it comes to interrupts.
Using the capture function in Timer1?

Any feedback is appreciated or some advice, thanks in advance.