Originally Posted by MaxiBoost
PBP...
Use the Pulsin twice; once to measure the pulse width when low, then right after that, measure the pulse width when high. Add the two results together. Multiply the total result by 100 and divide that total by the pulse-high result and you'll get a percentage relating to a duty cycle. This will get you close, but not absolutely perfect. The total pulse width could change a lot between successive readings (i.e. during fast acceleration or deceleration) and completely ruin the end result. Maybe a little bit of software filtering or averaging over a couple of cycles added to the software.
JDG
Bookmarks