From: hackbard Date: Thu, 20 Sep 2007 17:17:42 +0000 (+0200) Subject: compilation errors fixed, debug now! X-Git-Url: https://hackdaworld.org/gitweb/?p=my-code%2Farm.git;a=commitdiff_plain;h=945d83a31473b984473f571bb92486991d14aa16 compilation errors fixed, debug now! --- diff --git a/betty/betty.c b/betty/betty.c index 2cd287f..0bd6d0a 100644 --- a/betty/betty.c +++ b/betty/betty.c @@ -16,6 +16,7 @@ const char announce[]="betty - live from flash at 0x80000000! ;)\r\n"; const char d1_txt[]="betty"; const char d2_txt[]="- alphablend -"; u8 contrast; +t_button button; /* * functions @@ -117,7 +118,6 @@ void input_event(void) { int main() { /* variables */ - t_button button; /* system init */ pll_init(); @@ -153,7 +153,7 @@ int main() { interrupt_ext_ir_config(INTERRUPT_EXT3,INTERRUPT_EXT_NOWAKE, INTERRUPT_EXT_MODE_EDGE, INTERRUPT_EXT_POLAR_LOW); - interrupt_enable(INTERRUPT_EINT3,INTERRUPT_MODE_VIRQ,0,input_event); + interrupt_enable(INTERRUPT_EINT3,INTERRUPT_MODE_VIRQ,0,(u32)input_event); /* * start it ... diff --git a/betty/interrupts.c b/betty/interrupts.c index 49ea0cd..db2061d 100644 --- a/betty/interrupts.c +++ b/betty/interrupts.c @@ -6,6 +6,7 @@ */ #include "interrupts.h" +#include "functions.h" // 'module global' interrupt variable static t_interrupt interrupt; @@ -16,9 +17,9 @@ static t_interrupt interrupt; void interrupt_init(void) { - memset(&interrupt,0,sizeof(t_interrupt)); - VICSoftIntClear=0xff; - VICIntEnClear=0xff; + interrupt.default_soft_callback=0; + VICSoftIntClr=0xffffffff; + VICIntEnClr=0xffffffff; VICDefVectAddr=0; } @@ -29,12 +30,12 @@ void interrupt_set_default_callback(u32 callback_addr) { void interrupt_set_soft_callback(void (*callback)(void)) { - interrupt->default_soft_callback=callback; + interrupt.default_soft_callback=callback; } void interrupt_soft_clear(u8 src_number) { - VICSoftIntClear=(1<