prog.c:1:1: error: unknown type name ‘uint16_t’
static uint16_t second_ticks = 1.0 * 32768.0; // you know it's a whole number
^
prog.c:2:1: error: unknown type name ‘uint16_t’
static uint16_t third_second_ticks = 0.3 * second_ticks; // it was rounded
^
prog.c:2:1: error: initializer element is not constant
prog.c:4:1: error: unknown type name ‘uint16_t’
static uint16_t seconds_time;
^
prog.c:5:1: error: unknown type name ‘uint8_t’
static uint8_t counter = 0;
^
prog.c: In function ‘main’:
prog.c:9:1: warning: implicit declaration of function ‘sei’ [-Wimplicit-function-declaration]
sei(); //Enable interrupts
^
prog.c:10:1: error: ‘ASSR’ undeclared (first use in this function)
ASSR |= (1<<5);// enable bit 5 "ASSR". enables external 32kHZ crystal
^
prog.c:10:1: note: each undeclared identifier is reported only once for each function it appears in
prog.c:11:1: warning: implicit declaration of function ‘u8g_Delay’ [-Wimplicit-function-declaration]
u8g_Delay(250); //let external 32KHz crystal stabilize
^
prog.c:12:1: error: ‘TCCR2B’ undeclared (first use in this function)
TCCR2B &=~ (1 << WGM22); //Normal counting mode (overflow whenever at max value)
^
prog.c:12:18: error: ‘WGM22’ undeclared (first use in this function)
TCCR2B &=~ (1 << WGM22); //Normal counting mode (overflow whenever at max value)
^
prog.c:15:16: error: ‘TCNT2’ undeclared (first use in this function)
seconds_time = TCNT2;
^
prog.c:16:1: error: ‘OCR2A’ undeclared (first use in this function)
OCR2A = seconds_time + third_second_ticks;
^
prog.c:18:1: error: ‘TIMSK2’ undeclared (first use in this function)
TIMSK2 |= (1 << OCIE2A); //enable interrupts on OCR2A
^
prog.c:18:17: error: ‘OCIE2A’ undeclared (first use in this function)
TIMSK2 |= (1 << OCIE2A); //enable interrupts on OCR2A
^
prog.c: At top level:
prog.c:22:1: warning: return type defaults to ‘int’ [-Wreturn-type]
ISR(TIMER2_COMPA_vect)
^
prog.c: In function ‘ISR’:
prog.c:27:3: error: ‘OCR2A’ undeclared (first use in this function)
OCR2A = seconds_time + third_second_ticks;
^
prog.c:30:3: error: ‘lockseconds’ undeclared (first use in this function)
lockseconds++;
^
prog.c:31:9: error: ‘PORTA’ undeclared (first use in this function)
PORTA ^= (1 << 0); // Toggle the LED
^
prog.c: In function ‘main’:
prog.c:20:1: warning: control reaches end of non-void function [-Wreturn-type]
}
^
prog.c: In function ‘ISR’:
prog.c:36:1: warning: control reaches end of non-void function [-Wreturn-type]
}
^