If you want it to freeze when you press a button then you'll have to add that into your code. For example when the button is pressed it can go to a different section of code that loops till the button is pressed again. You'll have to figure out a way to break away from the timer loop, display the timer value and keep it in that section till your ready to go back to the main loop.