1khz Sine Wave Generator

You'd need to do the whole cli()-timer_setup()-sti() sequence again if you want to change the interrupt rate on the fly. Yes, the available frequencies are probably fairly granular, if the closest to 1KHz you can get is 1007Hz.