robtillaart:
Can you explain the *4 and the *10 ? Looking at the code I expected other result (a growing value for smoothrpm).
The out put was a 1/4 of the RPM; example
rpm 3703 smooth rpm 925
so I added *4, the 10 was to try and get an even more average.