From 9b2d89a9400c60b566d8b3aadb6c5d6899a72508 Mon Sep 17 00:00:00 2001 From: Chris St John Date: Mon, 20 Nov 2023 10:28:58 +0000 Subject: [PATCH] task: fix unit tests after port to attiny88 --- soft/lib/task.c | 4 ++-- soft/sample/blinky/pwm.config | 2 +- soft/test/stubs/avr/sleep.h | 2 ++ 3 files changed, 5 insertions(+), 3 deletions(-) diff --git a/soft/lib/task.c b/soft/lib/task.c index f84f034..7e48f10 100644 --- a/soft/lib/task.c +++ b/soft/lib/task.c @@ -107,7 +107,7 @@ void task_main(void) sleep_enable(); /* We use TIMER0 with Counter A and /256 prescaler */ -#if TARGET_MCU == attiny88 +#if defined(__AVR_ATtiny48__) || defined(__AVR_ATtiny88__) TCCR0A = 0x04; /* /256 */ #else TCCR0A = 0x02; /* OCRA */ @@ -119,7 +119,7 @@ void task_main(void) OCR0A = (uint8_t)(TIMER_SYSCLK_256_2ms/2)-1; /* Raise interrupt on Compare Match A */ -#if TARGET_MCU == attiny88 +#if defined(__AVR_ATtiny48__) || defined(__AVR_ATtiny88__) TIMSK0 = 1<