TIMER0_OVF_vect compile error

I believe the problem is that TIMER0 is used by the Arduino library for the delay, micros and millis functions, if you know you are not going to be using these you may be able to change this by playing around with wiring.c, but this may have unexpected results, particularly if you are planning on using any other libraries.
It is generally better to use one of the other timer/counter modules, they all do slightly different things but from a very quick look at your code I think you've got the right idea. Have a look at the ATMEL ATmega328 datasheet as this goes in to loads of detail on what each timer does.