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

IRQ0 interrupt on Aduc7020

I am trying to run a simple interruption routine on a EVAL-ADUC7020QSPZ development board. The .hex file is properly generated with Keil without error, however the code does not work. What I expect is that when pressing the IRQ0 interrupt button of the board, the LED (output P4.2) status should be complemented. Here is my code :

#include <ADuC7020.h>

void IRQ_Handler(void) __irq;

int main (void)  {
        IRQEN = XIRQ0_BIT;
        GP4DAT = 0x04000000;
        while(1){}
}

void IRQ_Handler() __irq
{
        GP4DAT ^= 0x00040000;
        while(GP0DAT & 0x00010){}
        return ;
}