Chris Eddy wrote... >I does got one problem with your circuit, the choice of a PNP. >You have connected it up in an emitter follower config. When >the input is 12V, the part is driven to 5V out. When the input is >0V, you drive about 0 out. But as a follower, any voltage >waveforms between 0 and 5V coming in will be reflected, >spikes, slopes, sags, and all into the output of the circuit. >A follower will amplify a signal straight through. A common >emitter will drive hard through a switching point into either on >or off. Hmm, I thought I was just reversing the polarity by using the PNP. I can't see right now why the NPN wouldn't act the same exact way (as an amp). I'll study it. >The up side is that it will probably work fine, since RB0 will >trigger on slope. But if you get some form of ring in between >0 and 5 on the ignition line, you might get multiple interrupts! Well, probably not because I'm not using RB0 but RA4. I'm using interrupts to increment the high byte of my 16bit counter. The mainline is looking at the signal highs and lows. >Try an NPN with the emitter in the ground..?? I'll do that and rewrite the code with the logic reversed. >Chris Eddy >JScarfon wrote: >> Thanks for all the basic electronics support. I think I'm going to try >> something like this as a starter: > >> 4.7K >> --/\/\--- +5 >> | >> 100 --------------------- RA4 >> +12 --\/\/--|<|--- / >> | / <- emitter (PNP) >> tach ------------------/\/\-----| >> | 10K \ >> 0 --\/\/--|>|--- \ >> 100 -- >> ---- >>