>>>Can anyone suggest what they think the best way is to use a PIC as a >>>tachometer-like sensor with a very low frequency input, (0-70 Hz) that would work >>>in the background of an application? Any suggestions and/or code samples >>>would be GREATLY appreciated! >>I recently finished code for an alarm/carstarter project for my car. I found it much >>easier to measure time between pulses of my ignition coil signal to determine >>engine speed (about 33 Hz at 1000 rpms). I just used an interrupt to detect it, >>because of all the other things the program was doing and the fact that the positive >>going pulse is very short and I didn't want to scatter the code with polling snippets. >>And I used the prescaled RTCC to do the timing. It worked very well. It just stores >>the value in a known register, avalible at any time. If you'd like I can post the >>interrupt handler I wrote. Good luck. >I'd like to see this routine if you don't mind. Here it is. Sorry about the use of Parallax mnemonics, its all I've ever learned. Its not optimized yet either, so uses many varibles. It is however very flexible and easy to use. Its part of a large multitasking OS, so it may seem kind'a over done, but it had to be this way. Content-Type: application/x-wais-source; name="INTHNDLR.SRC" Attachment converted: wonderland:INTHNDLR.SRC (????/----) (0000755D)