I have the impression that the OP's code is measuring the RPM correctly and what he is concerned about is the process of displaying it.
When the actual RPM changes from (say) 1100 to 1560 I think he does not want the display o change instantly between those numbers but, instead o go through the display steps 1100, 1020, 1130, 1140 etc to give the impression of the digits scrolling.
But I may be wrong. I will await confirmation before thinking about a solution.
...R