int timer1_counter;
void setup() {
pinMode(13, OUTPUT);
noInterrupts();
TCCR1A = 0;
TCCR1B = 0;
timer1_counter = 10000; //65535 - 62500 = 3035
TCNT1 = timer1_counter;
TCCR1B |= (1 << CS12);
TIMSK1 |= (1 << TOIE1);
interrupts();
}
ISR(TIMER1_OVF_vect)
{
digitalWrite(13, digitalRead(13) ^ 1);
TCNT1 = timer1_counter;
}
void loop() {}