Hi there! I am trying to get my interrupts working on my mc9s12ne64 board. The code is as follows. ##################################################### #include <hidef.h> /* common defines and macros */ #include <MC9S12NE64.h> /* derivative information */ #pragma LINK_INFO DERIVATIVE "1" void main(void) { long i; int a,b; //init PLL so PLL is 50MHz and bus is 25 MHz SYNR = 0; REFDV = 0; //wait for PLL lock while(!(CRGFLG & 0x08)); //choose PLLCLK CLKSEL |= 0x80; EnableInterrupts; while(1); } ######################################################## All code are executed fine but the funktion after EnableInterrupts makes it crach. Whith the statement "no source reference found" in Metrowerks code warrior. Have anyone any clue what i could be that is wrong? I now that the code doesnt do anything i just trying to have as litte code as possible to find out why it aint workingl /regards Martin
mc9s12ne64 Trying to enable Interrupt result in "no source reference found" ?
Started by ●June 27, 2006
Reply by ●June 27, 20062006-06-27
I have done further research and found that the error is that An interrupt occurs all the time and makes the CPU hang here.. This is the interrupt... 6 $FFF2, $FFF3 Virq IRQ I-Bit INTCR (IRQEN) $F2
Reply by ●June 27, 20062006-06-27
That's because the external interrupt is enable out of reset. You can either disable it: IRQCR_IRQEN = 0; or you can put a pull-up to the PE1 pin. Regards Petr mupptupp@hotmail.com wrote:> I have done further research and found that the error is that > An interrupt occurs all the time and makes the CPU hang here.. > This is the interrupt... > > 6 $FFF2, $FFF3 Virq IRQ I-Bit INTCR (IRQEN) $F2
Reply by ●June 28, 20062006-06-28
It works!! Thanx ;D Petr Cach skrev:> That's because the external interrupt is enable out of reset. You can > either disable it: > IRQCR_IRQEN = 0; > or you can put a pull-up to the PE1 pin. > Regards > Petr > > mupptupp@hotmail.com wrote: > > I have done further research and found that the error is that > > An interrupt occurs all the time and makes the CPU hang here.. > > This is the interrupt... > > > > 6 $FFF2, $FFF3 Virq IRQ I-Bit INTCR (IRQEN) $F2