Timing improvement changes:
- now using clock_gettime() instead of the deprecated gettimeofday()
- gear angular velocity is now controlled in real time so that it is fairly constant against frame rate
- frame rate is calculated a little more accurately