Skip to content

Commit b3ba5d4

Browse files
committed
Fixing PWM on pins 9 & 10 on the Uno.
Resetting TCCR1B to 0 after it's configured by optiboot. http://code.google.com/p/arduino/issues/detail?id=364
1 parent 750c860 commit b3ba5d4

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

hardware/arduino/cores/arduino/wiring.c

+2
Original file line numberDiff line numberDiff line change
@@ -189,6 +189,8 @@ void init()
189189
// this is better for motors as it ensures an even waveform
190190
// note, however, that fast pwm mode can achieve a frequency of up
191191
// 8 MHz (with a 16 MHz clock) at 50% duty cycle
192+
193+
TCCR1B = 0;
192194

193195
// set timer 1 prescale factor to 64
194196
sbi(TCCR1B, CS11);

0 commit comments

Comments
 (0)