I have not looked to your code in detail but as you say that the RPM increases in increments of 20 then these lines of code stand out
if (half_revolutions >= 20)
{
//Update RPM every 20 counts, increase this for better RPM resolution,
//decrease for faster update
Change the value being tested in the first line of code but note the comments about the trade off between resolution and rate of update.