From 764bd2bc01160f6021640babf30d2b52c39557ee Mon Sep 17 00:00:00 2001 From: ukw Date: Sun, 18 Sep 2011 15:12:21 +0000 Subject: [PATCH] Corrected Timer for ATTiny85 git-svn-id: svn://mikrocontroller.net/irmp@81 aeb2e35e-bfc4-4214-b83c-9e8de998ed28 --- README.txt | 2 +- main.c | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/README.txt b/README.txt index 5914be5..213dad1 100644 --- a/README.txt +++ b/README.txt @@ -1,7 +1,7 @@ IRMP - Infrared Multi Protocol Decoder -------------------------------------- -Version IRMP: 2.0.0-pre7 12.09.2011 +Version IRMP: 2.0.0-pre8 18.09.2011 Version IRSND: 2.0.0-pre7 12.09.2011 Dokumentation: diff --git a/main.c b/main.c index 44fe1bb..c704b87 100644 --- a/main.c +++ b/main.c @@ -33,7 +33,7 @@ void timer1_init (void) { #if defined (__AVR_ATtiny45__) || defined (__AVR_ATtiny85__) // ATtiny45 / ATtiny85: - OCR1A = (F_CPU / F_INTERRUPTS / 4) - 1; // compare value: 1/15000 of CPU frequency, presc = 4 + OCR1C = (F_CPU / F_INTERRUPTS / 4) - 1; // compare value: 1/15000 of CPU frequency, presc = 4 TCCR1 = (1 << CTC1) | (1 << CS11) | (1 << CS10); // switch CTC Mode on, set prescaler to 4 #else // ATmegaXX: OCR1A = (F_CPU / F_INTERRUPTS) - 1; // compare value: 1/15000 of CPU frequency -- 2.39.2