mirror of
https://github.com/Theaninova/Arduino-IRremote.git
synced 2025-12-11 00:46:14 +00:00
Merge pull request #119 from jan-r/ATmega8-IRQ-fix
Fixed problem with interrupt enable/disable on ATmega8
This commit is contained in:
@@ -303,8 +303,8 @@ extern volatile irparams_t irparams;
|
||||
#define TIMER_ENABLE_PWM (TCCR1A |= _BV(COM1A1))
|
||||
#define TIMER_DISABLE_PWM (TCCR1A &= ~(_BV(COM1A1)))
|
||||
#if defined(__AVR_ATmega8P__) || defined(__AVR_ATmega8__)
|
||||
#define TIMER_ENABLE_INTR (TIMSK = _BV(OCIE1A))
|
||||
#define TIMER_DISABLE_INTR (TIMSK = 0)
|
||||
#define TIMER_ENABLE_INTR (TIMSK |= _BV(OCIE1A))
|
||||
#define TIMER_DISABLE_INTR (TIMSK &= ~_BV(OCIE1A))
|
||||
#else
|
||||
#define TIMER_ENABLE_INTR (TIMSK1 = _BV(OCIE1A))
|
||||
#define TIMER_DISABLE_INTR (TIMSK1 = 0)
|
||||
|
||||
Reference in New Issue
Block a user