1
0
mirror of https://github.com/arduino/Arduino.git synced 2024-11-29 10:24:12 +01:00

Moving TCCR1B reset into #ifdef check.

This commit is contained in:
David A. Mellis 2011-03-06 11:29:35 -05:00
parent 7f0cc2111c
commit 10ecfa8bea

View File

@ -212,10 +212,10 @@ void init()
// note, however, that fast pwm mode can achieve a frequency of up
// 8 MHz (with a 16 MHz clock) at 50% duty cycle
#if defined(TCCR1B) && defined(CS11) && defined(CS10)
TCCR1B = 0;
// set timer 1 prescale factor to 64
#if defined(TCCR1B) && defined(CS11) && defined(CS10)
sbi(TCCR1B, CS11);
sbi(TCCR1B, CS10);
#elif defined(TCCR1) && defined(CS11) && defined(CS10)