FPS handler with gettimeofday()