Hi,
here, you are supposing your ECU Outputs a perfectly square wave ... is it real ???
At 1000 rpm or 16.667Hz, my LCD screen shows 950-1050 (hightime is around 1500counts)
??? 1500 counts are 3 ms @ 20 Mhz ... 6ms ( square wave ) per rev is ... 10 000 rpm !!! ... not 1000.
you have a calculation error somewhere !!!
let's say 15000 counts ...
60 000 000 / 2 / 2 / 15000 = 1000
60 000 000 is 60 Million µs in a minute
2 is for square wave ( you measure half duration )
2 is for 2 pulses per rev ( matches your DVM result ... hé,hé )
15000 is Pulsin result.
also see DIV32 for 60 E6 ( or 15 E6 ! ) value use ...
You'd better use " interrupts on edge " that would measure the full cycle ( High + Low parts of the signal ) regardless of the duty factor of your pulse ...
see " DT Instant interrupts " for that ... works great ++ aboard my Honda lawn tractor ( lol )
Alain
************************************************** ***********************
Why insist on using 32 Bits when you're not even able to deal with the first 8 ones ??? ehhhhhh ...
************************************************** ***********************
IF there is the word "Problem" in your question ...
certainly the answer is " RTFM " or " RTFDataSheet " !!!
*****************************************
Bookmarks