Trying to get timer1 working
Added basic centering code

This is the basic implementation of the centering code. Needs
tweeking.