This discussion has been locked.
You can no longer post new replies to this discussion. If you have a question you can start a new discussion

fiq doesn't work

hi
I wrote a code for LPC2378 about External INT, in IRQ mode works very well but in FIQ doesn't work and when I debug this the debugger stay on "FIQ_Handler B FIQ_Handler" in startup.s

this is for FIQ source code:
. .
. //#################################
void FIQ_Handler( void ) __irq {
FIO0SET=0x200000; //set led1
EXTINT=1; //Acknowledge
VICVectAddr=0; //Acknowledge
j=0x0;
}

int main (){
. .
. PINSEL4 = 0x00100000;
EXTMODE=1;
EXTPOLAR=0;
VICIntSelect=0x00004000;
VICIntEnable=0x00004000;
. .
.

if write __fiq after (void) give an error that need "{" for the end of line.(I don't know why?)

but when I write this code, works very well:

__irq void int0_isr( void ) {
FIO0SET=0x200000; //set led1
EXTINT=1; //Acknowledge
VICVectAddr=0; //Acknowledge
j=0x0;
}

int main (){
. .
. PINSEL4 = 0x00100000;
EXTMODE=1;
EXTPOLAR=0;
VICIntSelect=0x00000000;
VICIntEnable=0x00004000;
VICVectAddr14=(unsigned long)int0_isr;
. .
.

I increased FIQ mode stack size in startup.s but didn't have any effect

0