The first problem is easy to solve...
const int ocr1aval = 0;
For the second problem, how did you measure the frequency?