Speedometer simple code addition?

I am not an expert but, one problem I see is you need to change your int to unsigned long. Your program uses similar variables like "Blink without Delay". You do need to show all of your code you are using.

unsigned long pulseBegin = millis();
unsigned long pulseDuration = millis() - pulseBegin;